Advantage of using raspberry pi with pixy

Hello all,

I have been looking online for quite a while and there is a lot of resources on using pixy for vision either on java or python with raspberry pi. However, I don’t understand the advantage of using a raspberry pi in between pixy and roborio. Is it just for communication purpose? From my understanding pixy communicate with roborio pretty well using SPI or I2C.

And can I use the code generated from GRIP if I am using pixy? It seems like pixy is unable to serve as a webcam to send raw pictures.

One way to consider pro/con is what your team is capable of. The Pixy cams(v1 and v2) have code available that runs on raspberry pi courtesy of Charmed Labs. See

Similar case for arduino:

In the case of connecting pixy directly to roborio you need to have some code that can talk pixy protocol on the roborio. There are choices:
For cross compiling libpixyusb to roboRIO see this thread: Using pixy
Or search on github or ask on CD for code that teams that written themselves.

So if your team feels comfortable enough with Java/C++ and either implementing the pixy protocol yourself or using other teams code you can certainly connect pixy directly to roborio. If you don’t then go the arduino/raspberry pi route. But then you need to figure out how to connect the arduino/raspberry pi and have your robot code talk to something running on the coprocessor to get info about what pixy sees.

Pixy only has video available when using usb to connect it. Pixymon is the only program I have seen/used that can provide a video when using pixy. You can look at the code for it here:
My guess is whatever makes a webcam a webcam is not in the code for pixymon or any other dirs/projects in the charmed labs github repo. That’s just a guess. I have no idea how webcams work.

Webcams, on windows, have a specific driver to connect to the computer. On linux, there is the Video-for-linux driver, v4l-utils, to get webcams to connect to the computer. The Pixy camera has its own special driver to receive images.

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.