cancel
Showing results for 
Search instead for 
Did you mean: 

HowTo: UART with RS485 direction-signal?

markusmueller19
Associate II
Posted on November 01, 2008 at 17:06

HowTo: UART with RS485 direction-signal?

3 REPLIES 3
markusmueller19
Associate II
Posted on May 17, 2011 at 12:50

I want use to communicate with RS485. This device have a direction signal.

Can the processor automaticly set/reset this direction signal?

I have not foud a example or help in documentation.

I do not want use a interrupt for set/reset a IO pin, I think it must go by hardware. Witch configuration need I and witch pin must I connect to the direction input (like IC MAX485 line driver)?

Thank you for help.

picguy
Associate II
Posted on May 17, 2011 at 12:50

Simple answer: no.

Use a GPIO pin for xmit

For output:

Set the RS485 xmit bit

After all data is sent wait for (or interrupt on) Tx Shifter empty.

Reset xmit bit.

For read leave the xmit bit off.

At worst one extra interrupt per message sent. If you are sending multiple messages only set xmit off after the last one.

‘Tiz not exactly what you wanted. An external h/w solution has got to cost more.

markusmueller19
Associate II
Posted on May 17, 2011 at 12:50

Thx for answer.

I have think a RS485 direction control is today standard on new processors ... but it's not.