|
Re: URL for MjpegServer from CameraServer/USB Camera
Quote:
Originally Posted by dmelcer9
I'm looking to use a USB camera connected to the robot for GRIP development. I know that GRIP doesn't accept the dashboard stream, but the MJPG stream supposedly works. However, I can't figure out what URL to point GRIP to if I want to actually use the stream.
Currently, our code looks something like this (forgot to commit to github so don't have the exact code):
Code:
//Robot.java -> RobotInit
UsbCamera c = CameraServer.getInstance().startAutomaticCapture();
MjpegServer s = CameraServer.getInstance().addServer("gripStream");
s.setSource(c);
What URL would I point the "Add IP Camera" source to in GRIP to get the camera to work properly?
|
You actually don't need that MjpegServer definition or the setSource line. startAutomaticCapture will automatically create the stream.
The way to access the code from GRIP would be
Code:
http://roborio-TEAM-frc.local:1181/?action=stream
__________________
All statements made are my own and not the feelings of any of my affiliated teams.
Teams 1510 and 2898 - Student 2010-2012
Team 4488 - Mentor 2013-2016
Co-developer of RobotDotNet, a .NET port of the WPILib.
|