Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   Java (http://www.chiefdelphi.com/forums/forumdisplay.php?f=184)
-   -   Processing video feed with GRIP on DS Laptop (http://www.chiefdelphi.com/forums/showthread.php?t=153646)

RileyC3826 14-01-2017 13:26

Processing video feed with GRIP on DS Laptop
 
Our team wants to pursue vision processing this year. So far, I have been able to create a GRIP pipeline able to detect the position of the retro-reflective tape, and generate code to use with our main program. When running our robot, we can print the position of the tape to the smartdashboard, but we believe processing on the rio itself is causing problems (Too much CPU usage which causes motors to stutter when trying to drive them based on tape's position). We can view the cam's feed on the smartdashboard, but I don't know how to get the video feed into GRIP to process it.
We are using the Microsoft HD Lifecam 3000 and I believe have all the latest software installed, but I could have missed something.

AustinShalit 14-01-2017 21:28

Re: Processing video feed with GRIP on DS Laptop
 
Quote:

Originally Posted by RileyC3826 (Post 1631115)
Our team wants to pursue vision processing this year. So far, I have been able to create a GRIP pipeline able to detect the position of the retro-reflective tape, and generate code to use with our main program. When running our robot, we can print the position of the tape to the smartdashboard, but we believe processing on the rio itself is causing problems (Too much CPU usage which causes motors to stutter when trying to drive them based on tape's position). We can view the cam's feed on the smartdashboard, but I don't know how to get the video feed into GRIP to process it.
We are using the Microsoft HD Lifecam 3000 and I believe have all the latest software installed, but I could have missed something.

Hi there! You can stream the USB camera to your dashboard by following the "Simple camera server program" example here:
https://wpilib.screenstepslive.com/s...e-roborio-2017

In GRIP you can then add an IP camera with the URL of the video stream that the robot creates. You can find this URL in OutlineViewer ({user.home}/wpilib/tools/OutlineViewer.jar).

Also, do you mind posting (or PMing me) your code? I would like to see if there is a way to get your code to run on the roboRIO without issue.

grainne 15-01-2017 10:41

Re: Processing video feed with GRIP on DS Laptop
 
Our team had this problem last year. We fixed it by running our grip file on a raspberry pi that we put on the robot so as to not overload the roborio. We were then able to stream our video feed to the driver station by connecting an IP camera through smart dashboard.

SamCarlberg 15-01-2017 11:03

Re: Processing video feed with GRIP on DS Laptop
 
Quote:

Originally Posted by AustinShalit (Post 1631330)
You can find this URL in OutlineViewer ({user.home}/wpilib/tools/OutlineViewer.jar).

You can also run OutlineViewer directly from Eclipse if you have the WPILib plugins installed. Just go to the WPILib menu and hit "Run OutlineViewer"

RileyC3826 16-01-2017 15:04

Re: Processing video feed with GRIP on DS Laptop
 
Thanks for the replies, the stuttering-motor issue was not due to RoboRio CPU usage, but from motor controllers receiving multiple signals due to a couple misplaced brackets.

Quote:

Originally Posted by AustinShalit (Post 1631330)
Also, do you mind posting (or PMing me) your code? I would like to see if there is a way to get your code to run on the roboRIO without issue.

The code was nothing special, just our original code with the code used in the wpilib tutorials:
https://wpilib.screenstepslive.com/s...raserver-class
and
https://wpilib.screenstepslive.com/s...-robot-program
The GRIP code was just a simple pipeline to find retro-reflective tape.


All times are GMT -5. The time now is 12:34.

Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi