im sending some binary data over serial between two computers. I do it like this :
Receive
cat < /dev/ttyO5 >> $file
Send
cat < $file > /dev/ttyO5
When i check the files, sometimes the receiver machine copies some bytes of the beggining of file at the end. Something like this:
ce16 8fa7 bf54 dc6b 238a #Original file
ce16 8fa7 bf54 dc6b 238a ce16 8fa7 #Generated file on receive machine
The number of bytes added at the end is not fixed, sometimes is 3 bytes, sometimes 4....And i dont know why, I flush the memories before sending and receiving ....
Any clue?
EDIT: SOLVED; the option -echo needs to be disabled on the port confirguration.