Connect-Me + RS485

Hi Steve,

Perhaps the CRTSTOGGLE mode and the RTSEN feature are simulated by software under NETOS. ??

If you’re configuring your port as 2-wire and you’re able to drive CTS as a simple gpio, then I think that the hardware flow control is not working in fact. Just an idea.


The serial driver for the Digi Connect ME 9210 in NET+OS uses RTS toggle in the hardware. The driver sets up the appropriate bits in the UART register when the user sets CRTSTOGGLE cflag in the termios structure.

I should also mention the errata mentioned above only affects RTS when used as a hardware flow control signal, not when used to encapsulate transmitting data.

Does “RTS encapsulation” mean that RTS remains active only during transmissions? Does this CRTSTOGGLE function work by hardware? This is exactly what I need in order to control the external RS485 driver!! How can I enable this feature without activating the automatic flow control?

Linux does not support the CRTSTOGGLE option. Should I just set RTSEN = 1 whilst configuring RTS as gpio?


I’ve just tried setting RTSEN = 1 from the Wrapper Control Register after having configured the serial port as TX/RX only. Unfortunately this doesn’t change anything. Just one thing: with memwatch I could only change the RTSEN bit after running my application (port busy). Otherwise, the Wrapper Configuration Register stays with value 3 unaltered.

Message was edited by: estratos

‘RTS Encapsulation’ does indeed mean what you say, and is also a hardware-supported function in the ME9210 UART.

Try setting 2-wire UART, the RTS pin to be an output. Then ‘OR’ the RTSEN value of ((1 << 19) | 0xf) into the wrapper control register.

Thanks Steve for your help… but… no luck…

I’ve thought that you could maybe post the value of the registers involved in the serial communications on your RS485 running board:

GPIO 5 config register (address 0xa0902014)
Wrapper Control Register (address 0x90011000)
UART Modem Control Register (address 0x90011110)

I could then try to reproduce your configuration.

Thank you very much!!



The RTSEN flag of the WC register can be easily enabled in the driver. See the patch attached.
Configure the serial port as 4-wire (RX/TX/CTS/RTS) in the linux kernel configuration.

With this flag enabled. Line #RTS is driven high when the serial port is sending, and it is driven low when it can receive data.

I think this is what you wanted.

Héctor Palacios

Thank you very much Hector!!

This was exactly what I needed. I hope this thread will help others work with RS485 too :slight_smile:




In the following days we will post a new Hotfix package (HF4) for DEL-4.2 which will integrate this support into the kernel configuration.
Selecting the RS485 configuration for the serial port will only reserve three GPIOs (RXD,TXD,RTS).

Hector Palacios

Did anyone figure this out?

Could you guys please check MAX13487E and let me know if this max chip can work without the use of RTS anymore? therefore we can only use RX and TX from Connect me and thats it!

MAX13487E offers “AutoDirection Control”