How to access ttyS0 and ttyS1 from Debian

Started by vik, April 18, 2014, 12:07:01 AM

Previous topic - Next topic

vinifr

Glad I could help you. ;D And I found a very good explanation.

I live a bit far from Colorado, i live in Brazil.  :D

vinifr

Hi vik,

Did you test the UART3 successfully? TX and RX works?

vik

Yes, it is working fine. It kept controlling several Modbus slaves during the weekend. Not a single error in the log.

Here is another trick for those who might be interested. I have seen many people inquiring about RS485 and the half duplex control. While it is possible to use the MOD-RS485, but to do so one has to write a custom driver to switch the device from transmitting to receiving and back. This is not too convenient if you want to write software running on multiple platforms.

Instead you can use the MOD-RS232 and buy from eBay an RS232 to RS485 converter. There are some that have internal logic to automatically switch the data direction. I have found that the ones that have the word "HEXIN" written on them work the best. I have not been able to locate the actual manufacturer, but they are available from multiple vendors. The price is usually very reasonable.

Yet another trick, may not belong in this thread, but it is not important enough to start a new topic. Just to let you know that if you forgot to order the 40 pin cable connector for the LCD you can simply use an old IDE hard drive cable. Works just as well. If you are like me and don't throw away the old computer junk you might have some old IDE cables laying around.

Enjoy!

vinifr

Hi vik,

I managed to successfully test UART3. And I made ​​a video tutorial: https://www.olimex.com/forum/index.php?topic=3138.0

I used your instructions, I hope you do not mind. ;D

Thanks