So I am ordering a syringpump that normally communicates over RS323, but also comes in a RS485 version. I see that my RevPi Connect 4 have RS485 com, so i naturally gravitates towards ordering that version.
In the manual there is a long list with commands example:
"RPnnn", makes the pump run nnn steps in inwards direction ("RP350" makes it go 350 steps in inwards direction).
Am I correct to assume that I need RS485 with ASCII com to operate this device?
How do I go about doing this with the pi connect in node red, can I use the serial node and then just point to something like /dev/ttyRS485?
Best regards
RS485 ASCII communication
Re: RS485 ASCII communication
Hi palmhoej that's an interesting question and you can see the versatility of the Revolution Pi in practical everyday life.
I have created a test setup for this with USB-RS485 to RS485. With the help of two wires, which function for the transmission via RS485, you can already see here how easy it works. There are more things on the photo but the important part is the Module in the middle - a RevPi Connect5 with the USB-RS485 interface connected.
It is important that the two interfaces use the same parameters for the transmission. This is how it works on a example configuration 115200 baud, 8 data bits no parity one stop bit:
Then you can listen on one RS485 interface and send something via the other line. Here is a full example how it shows up on my terminal and device RevPi94369:
In your case, you can take an interactive test with:
I have created a test setup for this with USB-RS485 to RS485. With the help of two wires, which function for the transmission via RS485, you can already see here how easy it works. There are more things on the photo but the important part is the Module in the middle - a RevPi Connect5 with the USB-RS485 interface connected.
It is important that the two interfaces use the same parameters for the transmission. This is how it works on a example configuration 115200 baud, 8 data bits no parity one stop bit:
Code: Select all
stty -F /dev/ttyUSB0 115200 cs8 -parenb -cstopb
stty -F /dev/ttyRS485 115200 cs8 -parenb -cstopb
Code: Select all
pi@RevPi94369:~$ stty -F /dev/ttyUSB0 115200 cs8 -parenb -cstopb
pi@RevPi94369:~$ stty -F /dev/ttyRS485 115200 cs8 -parenb -cstopb
pi@RevPi94369:~$ tail -f /dev/ttyRS485 &
pi@RevPi94369:~$ echo 'Happy 13th Birthday Raspberry Pi via RS485' > /dev/ttyUSB0
Happy 13th Birthday Raspberry Pi via RS485
Code: Select all
stty -F /dev/ttyRS485 115200 cs8 -parenb -cstopb # adapt the parameters according to your needs
echo RP1 > /dev/ttyRS485 # should move one step
Re: RS485 ASCII communication
Thank you for the quick reply, I will order it with the rs485 
