Framing errors on ODROID C1+

71 views
Skip to first unread message

Martin Pettersson

unread,
Mar 7, 2017, 4:59:09 AM3/7/17
to libmodbus
We are using libmodbus on an ODROID C1+ together with an ADM2483 chip to communicate using RS485.

Since we need to use GPIO to control RTS on the ADM2483 chip we are using the fork made by dhruvvyas90 (https://github.com/dhruvvyas90/libmodbus).

Since we are experiencing the problems described here:
we also need to apply the fix described here to get the communication to work. Without this fix will not receive any data at all.

With these modifications we will get modbus communication to work BUT:

1. We are flooding the syslog with error messages like these:
Uart 0 Driver: Framing Error while receiving a character

2. The communication will hang up on a cyclic basis and when enabling debug in libmodbus we will recieve:
ERROR Connection timed out: select
<F0><01><04><02><FF><EE><78><8C>
As you can see we have some garbage attached in the beginning of the response even though we use modbus_flush() as described in issue 302 above.

What can we do to get rid of these problems?

BR,
Martin

Martin Pettersson

unread,
Mar 17, 2017, 4:01:22 AM3/17/17
to libmodbus
We have managed to handle problem 2. by adding an extra byte-delay before reading the response. But we still have: 


Uart 0 Driver: Framing Error while receiving a character

which is flooding our syslog (and seems to make it crash randomly).

My guess is that this is a matter of configuration of the UART as can be read about here:


But even though we have tried to configure the UART manually with stty, we still havent managed to get rid of the errors from the driver.
Reply all
Reply to author
Forward
0 new messages