2 ms·
I do something very similar, how do you deal with random serial port data loss (dropped bytes)? Maybe it is specific to my environment, but I get mangled comman
by PhilipRoman 2y ago
I do something very similar, how do you deal with random serial port data loss (dropped bytes)? Maybe it is specific to my environment, but I get mangled commands about 1% of time, which really sucks for automated workflows. I mostly countered this by writing commands to a tmp file, verifying md5sum and then executing the file on the device side.
- orev 2y agoSerial is slow but typically very reliable. If you’re seeing random dropped bytes, I’d take a look at your wiring and PC interface UART which might be low quality. FTDI UARTs in particular are often counterfeit (the real ones are good).
- nrclark 2y agoAcross a large enough sample set, I definitely see occasional serial errors (although they're rare). For me, I detect them by checking the exit-code on each command that I run, and also by looking for expected output in response to the commands. Corrective action is usually a full-stage retry.