![]() |
GRIP Deploy Not Working
Hello everyone,
My team is trying to use GRIP on our Raspberry Pi 3 to run the vision code for our robot. Each time we deploy, we keep recieving an error that I have pasted at the bottom of this post. We've followed all of the steps at https://github.com/WPIRoboticsProjec...Raspberry-Pi-2 and have copied over the shared libraries. Each time we deploy, it keeps saying that it can't instantiate files related to network tables. I'm sure that we have placed the shared libraries in the right folders and have deployed the project to the right folder, so do you know why this isn't working? I'm using GRIP 1.2 on Raspbian. Thanks, Jonathan Code:
/usr//bin/java -Xmx50m -XX:-OmitStackTraceInFastThrow -XX:+HeapDumpOnOutOfMemoryError -jar '/home/pi/code/grip/grip.jar' '/home/pi/code/grip/project.grip' |
Re: GRIP Deploy Not Working
I had this issue too. The Deploy page won't properly run GRIP, you have to use a custom script to do it. On this page it has this command:
Code:
$ env LD_LIBRARY_PATH=/home/pi/vision/grip:$LD_LIBRARY_PATH java -jar /home/pi/vision/grip/grip.jar /home/pi/vision/grip/project.grip |
Re: GRIP Deploy Not Working
I tried that but now it can't create a JVM. I'm just going to run GRIP on the driver station and stream the camera through the RIO USB port. Maybe we can get openCV running on the Pi next season. Is there a guide you followed for getting it to work with Network Tables?
|
I really recommend doing OpenCV and network tables. Here is a guide for integrating network tables. http://pynetworktables.readthedocs.io/en/latest/
Sent from my SM-N920G using Tapatalk |
Re: GRIP Deploy Not Working
I recently finished up the OpenCV code for my Raspi 3, if you want to take a look, or copy it completely, here it is. I'll be updating it with a tuning window tomorrow, so keep an eye out for that. I'll admit, its definitely not the best code, but it works very well with little latency.
There are instructions in the README.md on the process I went through to install everything. I cannot recommend running this on anything but the Pi 3. I tried it on the Pi 2 and it took too long, and left me with a very low framerate. I can't imagine how the Pi 1 would handle it, if at all. If you have any questions, please PM me. Even better, if you have any improvements, pull request me! |
Re: GRIP Deploy Not Working
Quote:
|
Re: GRIP Deploy Not Working
You need to set the "LD_LIBRARY_PATH" environment variable to have the directory you put the ntcore libraries. You can do this either by the method on the wiki:
Code:
$ env LD_LIBRARY_PATH=/home/pi/vision/grip:$LD_LIBRARY_PATH java -jar ...Code:
export LD_LIBRARY_PATH=/home/pi/vision/grip:$LD_LIBRARY_PATH |
Re: GRIP Deploy Not Working
Quote:
I think we missed this line in the wiki guide: "From the deploy window, click deploy. Once it's finished deploying just hit stop as GRIP will fail to run properly due to library issues." We're supposed to get the errors when we deploy, its normal, we should ignore it, and continue down the wiki where we run GRIP from the command line using the "env". I understand this is an RTFM error on mine and others' parts, but it might eliminate some questions if this was highlighted a bit more in the wiki. Correct? Well, I did that, and from the command line I'm getting: Code:
terminate called after throwing an instance of 'std::logic_error' |
Re: GRIP Deploy Not Working
Yeah, the wiki could be better.
Can you post the full stacktrace? |
Re: GRIP Deploy Not Working
Quote:
|
Re: GRIP Deploy Not Working
It's the entire output you got when you tried to run it from the command line, not just that one line. There should be a lot of lines that look like
"at edu.wpi.grip....(123)" |
Re: GRIP Deploy Not Working
That's not a Java stack trace (it appears to be something in libstdc++), so I doubt there's anything else. I would recommend double-checking and making sure the correct libstdc++ is in the same folder you have in LD_LIBRARY_PATH, but I'm not really familiar enough with GRIP, so I can't offer much more than that.
|
Re: GRIP Deploy Not Working
Quote:
I definitely have the files linked to on the wiki there. Only difference is that I ftp'd them there and not scp. The only reason I can think that might make a difference is if the file permissions don't set the same. |
Re: GRIP Deploy Not Working
Quote:
I did alter the start_vision.sh from the wiki to include a -b to run in the background. Without it, I found the mjpg_streamer sat there and grip never started. Any help would be appreciated. Combined Vision Starting Script Start mjpg streamer enabling daemon modeforked to background (776) /home/pi/vision/start_vision.sh: line 5: pause: command not found Starting GRIP processing pi@pulsatrix:~ $ Nov 19, 2016 6:28:58 PM java.util.logging.LogManager$RootLogger log CONFIG: Configuration done. Nov 19, 2016 6:28:58 PM java.util.logging.LogManager$RootLogger log CONFIG: GRIP Version: 1.5.0-rc3 2016-11-19 18:29:02.026:INFO::main: Logging initialized @3761ms platform: /Linux/arm/ terminate called after throwing an instance of 'std::logic_error' what(): basic_string::_S_construct null not valid Edit: Seeing the pause error, I changed that line to read-p "--" and just counted to 5 before continuing. Same result. Edit2: pulsatrix is the name of the pi. Its the species name of the spectacled owl |
Re: GRIP Deploy Not Working
That's bizarre. I'll see if I can reproduce this tonight. If not, you can use 1.5 and generate OpenCV code to run on the Pi without needing to deploy GRIP
|
Re: GRIP Deploy Not Working
Quote:
|
Re: GRIP Deploy Not Working
1 Attachment(s)
Quote:
Code:
/usr/bin/java -Xmx50m -XX:-OmitStackTraceInFastThrow -XX:+HeapDumpOnOutOfMemoryError -jar '/home/pi/vision/grip/grip.jar' '/home/pi/vision/grip/project.grip'I have also attached the GRIP log. I'm 90% sure this is the newly generated file from last night running from command line, but I just realized the date is wonky on my pi so I am not 100% sure. (file format changed to txt for cd post) |
Re: GRIP Deploy Not Working
Worth noting I've got the RIO on the network now, no change.
I've also changed the GRIP to not report out to network tables. No change from either. Worth noting Driver Station gives a DNS error, though I can ping the RIO. I think this is a Win10 network problem. |
Re: GRIP Deploy Not Working
It seems like the interwebs think this error, in an OpenCV context, comes from failing to provide a required argument.
Anyone? Anyone? Bueller? |
| All times are GMT -5. The time now is 17:47. |
Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi