Log in

View Full Version : GRIP (PI) to arduino?


cad321
14-04-2016, 21:16
I'd like to be able to use GRIP running on a pi to send the coordinates of the object being tracked to an arduino. I'm trying to make a small servo gimbal with a Webcam attached to track things in grip.

The idea is that I'm using GRIP as I would on a normal FRC robot but using the arduino in place of the roborio (arduino's are far more accessible to me than a roborio). This would then function as a test platform for our vision tracking code.

I know GRIP outputs the center of a detected contour via network tables, is there a way for a network enabled arduino to receive these network table values? How else might I go about receiving the data from the pi?

nickbrickmaster
14-04-2016, 22:15
Unless one exists, you would need to write a NetworkTables lib for Arduino. Instead, what I would do is have a program on the pi that reads networktable values and sends them over i2c or serial to the arduino. You can use python and pynetworktables, or some other lib.

billbo911
14-04-2016, 23:38
You could set up a UDP client on the PI and a UDP server on the Arduino. Then just send the target info as a simple string.