added readme and made the size reflect the actual size and not random strlen

This commit is contained in:
Nicholas Stănescu 2025-04-26 17:12:03 +02:00 committed by Nanokloon
parent 0b3608c6ba
commit dabe013a4e
2 changed files with 5 additions and 2 deletions

3
README.MD Normal file
View File

@ -0,0 +1,3 @@
# Doing serial with c
# dont ask

4
main.c
View File

@ -3,16 +3,16 @@
//
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "communication.h"
extern struct sp_port *port;
int main(int argc, char *argv[]) {
comm_init_communication();
u_int8_t data = 205;
int size = strlen(&data);
int size = 1;
printf("size: %d\n", size);
unsigned int timeout = 50 * size; //50 ms timeout per byte