I was working on a project in which microcontroller is communicating serially with computer.
Initially it works properly but after some duration (i.e 2-3 hours) microcontroller get hanged.
I think it hangs due to serial communication with computer. To verify it I have written a program to for microcontroller as well as for computer to transmit and receive data serially.
In my program I am first transmitting string of five characters serially from computer. Microcontroller will receive the string and re-transmit the same string to computer. Computer will receive the string transmitted by microcontroller.
Now I have transmitted string and a received string at computer, I am comparing both the strings and if they are same I am writing '1' in a file and '0' if they are different.
I want to know that my process to verify serial port communication is correct or not?