C programming help

Completado Publicado hace 5 años Pagado a la entrega
Completado Pagado a la entrega

I wrote a program that polls 6 different messages via Serialport in C.

The program is already working but i would like to implement some additional error handling .

I would like to get help with the following .

If the serialport can not be openend wait for 1 second then try again ( endless loop)

If a write fails then close the serialport and start the programm from the beginning

Have a timeout of 2 seconds if the message is incomplete or not received at all

==> close serialport and reopen again to start the programm from the beginning

Check the first and second byte of the received message and compare if it is what i expect

The first byte is always the same as the first byte of the request i am sending

(identifier to show the beginning of the message) .

The second byte is the message lenght-1 which i also know for each of the 7 messages

Example :

send request 0xF3,0x02,0x0A

receive 0xF3,0x0A ..... (8 more bytes) ==> total message lenght 10 bytes (0x0A +1)

send request 0xDD 0x02 0x20

receive 0xDD 0x52..... (81 more bytes)==> total message Lenght 83 bytes (0x52 +1)

So i would need some professional coder to just bulletproof my code

Programación en C

Nº del proyecto: #17652654

Sobre el proyecto

4 propuestas Proyecto remoto Activo hace 5 años

Adjudicado a:

Manavx

HI, As I am fresher on freelance.I want to create a good techie profile [login to view URL] I will give my best to complete your project with good coding style.I have 2+ year work experience specially on driver as well as in C an Más

$20 USD en 1 día
(2 comentarios)
2.4

4 freelancers están ofertando un promedio de $21 por este trabajo

arjun366333

Ready to start the work to provide help C programming, We can discuss more over chat, Thanks Regard Arjun S.

$25 USD en 1 día
(3 comentarios)
3.2
RachitMundra

Hello, I think i can surely help you out with this as I am a professional c programmer with 4 years of experience in it. So feel free to contact me and i will help you out with it I gave 2 years c online tuitions

$25 USD en 1 día
(0 comentarios)
0.0