Vision - Connecting Raspberry Pi to Network Tables

My team is using a RPi to handle vision this year, and while we have a vision program working, we are unable to connect to the network tables.

While we can connect the Pi to the robot’s network, and can ping everything from the Pi, when we attempt to initialize the NetworkTables and connect it doesn’t work. Through use of wireshark on the pi we have found that when the code functions there is nothing for it to see between the pi and the rio or d-link.

Has anyone else come across this problem, or know how it might be solved?

We are using the pynetworktables github repository: https://github.com/robotpy/pynetworktables,
and using the code from http://pynetworktables.readthedocs.io/en/stable/api.html#networktables-api

code(python 3.5):


from networktables import NetworkTables
import logging

logging.basicConfig(level=logging.DEBUG)
while True:

     NetworkTables.initialize(server = 'roborio-203-frc.local')
     print(NetworkTables.isConnected())
     sd = NetworkTables.getTable("SmartDashboard")
     sd.putNumber("someNumber",1234)#doesn't show up in table
     #print(sd.getNumber("DB/String 4"))#causes key error when ran
     NetworkTables.shutdown()



1 Like