|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
|
|
Thread Tools | Rate Thread | Display Modes |
|
|
|
#1
|
|||
|
|||
|
Re: Help: Raspberry pi and GRIP
Do you log into the pi and start up grip with ./vision/start_grip.sh? Do you see the program boot and run? In top do you see a java program running and using lots of cpu? If GRIP runs do you see it say that it connected to a server?
|
|
#2
|
||||
|
||||
|
Re: Help: Raspberry pi and GRIP
Hey there!
OpenCV is a better and more stable option. Since it's already late in build season, you may not have time to write new code. You should be able to directly port your GRIP code into OpenCV. It will take some time to port but is definitely doable since OpenCV is the backbones for GRIP. Now if you want some code to sample or look at. I would recommend taking a look at Fauge7's TowerTracker. Our team has been able to run it on a Pi. It is Java though and so you have to install the JDK and make it your default JDK in order to install the library properly. Or you can check out Team 2053's TowerTracker C++ port, which is a direct port of Fauge7's code but instead in the faster and more documented, C++. If you need any help, feel free to PM ![]() |
|
#3
|
|||
|
|||
|
Re: Help: Raspberry pi and GRIP
Team 4678 was able to use grip on the Rpi 2. To get it working reliably, there were a few key things that needed to be done. We used the Rpi camera because it had almost no lag compared to the USB camera. mjpg-streamer was used to get the stream from the camera. The key here is to use -x 320 -y 240 in the execution of mjpg-streamer to make sure a 320 x 240 image is sent to grip. Sending a 640 x 480 image caused grip to crash and run slow. Also handy for mjpg-streamer was the -rot 90 option which allowed the image to be rotated after we mounted the pi camera at the wrong rotation. When it comes to grip, the 1.3.0 version started every time while the 1.2.0 version started most of the time but was not as reliable. We were able to just copy the 1.3.0 jar file on to the pi as grip.jar and it worked with the grip.project file that we created on the laptop using 1.2.0 and deployed to the pi. mjpg-streamer and grip are started up using systemd. We can provide more details if someone needs them for start on boot. At the competition, in order to work with the FMS, we did need to give the pi a static ip address. It did not seem to be able to use dhcp services to get an address that would allow it to talk to the roborio using network tables. Raspbian Jessie doesn't do static IP like we were used to. It's easiest using the gui through startx then right-click on the network icon to set a static IP. The other method is to edit /etc/dhcpcd.conf. Editing /etc/network/interfaces won't get you to far. We used the static IP 10.46.78.15 and had no problems getting the Rpi to talk to the roborio using the host name roborio-4678-frc.local in the grip configuration.
|
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|