We are trying to receive data from a Raspberry Pi 3 over the on-board serial port on the RoboRio. I know that the pi is sending data over serial because I have connected to it through a COM port with putty. This is probably just a case of me not knowing how to use the SerialPort class included in WPILib but any resources I have found do not seem to work.
Any source code using the SerialPort class or other methods would be greatly appreciated.
Have you confirmed that you can Transmit with the RS232 Port on the RoboRio?
Did you check that you are crossing the TX/RX lines?
We are using Network Tables over Ethernet to talk to the Pi.
Like rich2202 said, you need to swap RX and TX between destination and target (you may have already done, it’s just such a common pitfall with UART, that it is worth mentioning again.).
Pin 8 should be connected to the middle pin on the 232 port, Pin 9 should be connected connected to the inside pin on the 232 port (with the outside pin being ground).
Start with trying the attached vi - it should just read whatever the pi sends and print it to the control where you can see it.
Private message or email me and I’ll send you my contact info, we should be able to get on the phone and get this figured out.
here is a link to a project I did that read a ps3 controller on the host computer and built up a string of commands to send over a comm port to an arduino (there’s a lot of overhead, and I directly used the Visa library - what the Serial palette calls into - so there’s not a lot of obvious parallel, but this is also not the only project I’ve done with LabVIEW talking over serial, just the most relevant, since I had communications going both ways).
rs232Example.vi (14 KB)
rs232Example.vi (14 KB)