Unstable reading on /dev/rs485, TRB246


I having trouble with cat /dev/rs485. Sometimes it works, sometimes not.
When it works, it never reads all incoming messages (raw hx data, without \n or \r).
I am in half duplex (D+ and R+ connected, D- and R- connected).

Do you have an idea for a reliable way to read /dev/rs485?

Thank you very much for your help!

Additionnal tests:
This morning, everything starts fine:
using trb246 rs485 in half duplex (D+ connected with R+, D- with R-) and PC as an emitter/receiver
Sans titre
Issuing a few echo “hello” > /dev/rs485, received on PC
Sans titre
Now go back to cat /dev/rs485: nothing is read by trb246, but everything is strangly echoed to PC:
Sans titre
When I kill the cat, no stange echo anymore on PC:
Sans titre
Now I disconnect R+ and R- from D+ and D-. No strange echo anymore while cat /dev/rs485. But nothing read with cat.

How can it be?

Here is another test. Not sure yet if it is reproductible.

I send ‘A’ with carriage return and line feed from Docklight (PC)
cat /dev/rs485 displays all ‘A’ sent, nothing lost.
But there is an echo that can be seen on PC:
in hex:



This topic was automatically closed after 15 days. New replies are no longer allowed.