...
An example for testing RS485 communication:
1. Open a test file “rs485_test”
Code Block |
---|
rs485conf -e 1 /dev/ttymxc1
touch /tmp/rs485_test
stty -F /dev/ttymxc1 raw -echo -echoe -echok
|
2. Print received data to “rs485_test” file:
Code Block |
---|
cat /dev/ttymxc1 > /tmp/rs485_test & echo "rs485" > /dev/ttymxc1 |
For more information, please refer to HummingBoard CBi RS485 and CANBus pin mapping .