Setting Up Linux RS-485 Display Module Connectivity

G2C1 Display Modules have two RS-485 ports, one port on J11 and the second port on J7. These may be used in either full-duplex mode (4-wire) or in half-duplex mode (2-wire).

RS-485 Full-Duplex Mode

To use the RS-485 ports in full-duplex mode, you only need to change the SIO-agent’s TTY port by editing the file /etc/init.d/sio-agent. You can edit the file manually. Log into the display module and use the ‘vi’ command or use the “Edit SIO settings” button in G2Link’s Advanced View.

If editing the file manually, replace the current setting of SIO_TTY with “/dev/ttySP0” to use J11 or “/dev/ttySP4” to use J7. If using G2Link, select the appropriate TTY port from the pulldown, then click “OK.”

Then send ASCII strings from your application as you would when using the RS-232 port.

RS-485 Half-Duplex Mode

To use the RS-485 ports in full-duplex mode, change the SIO-agent file as described above, using the manual edit method. You will also need to add a command-line parameter “-f” to tell the SIO-agent to use half-duplex control on the transceiver. Add the “-f” parameter in the same two locations that the baud rate and TTY port are set.

Custom Half-Duplex Mode

If you are using a custom application to talk to the serial port instead of using the standard SIO-agent, the custom application can use the RS-485 code snippet below as an example of how to put the Linux RS-485 port into the half-duplex mode. This will result in the signals shown in the scope trace screen capture below for each character transmitted.

Linux RS-485 Screen Capture

Linux RS-485 Help

Please feel free to contact one of our engineers if you need more RS-485 information or clarification.

Embedded Touchscreens Made Easy:
Up in Days, Smoothly to Production. Get started with a Development Kit.

Reach Technology is now a part of Novanta.

Sales and Engineering
545 First Street
Lake Oswego, OR 97034
503-675-6464
sales@reachtech.com
techsupport@reachtech.com

Manufacturing
4600 Campus Place
Mukilteo, WA 98275
service@reachtech.com

Please send payments to:
Novanta Corporation
PO Box 15905
Chicago, IL 60693
accounts.receivable
@novanta.com