View Single Post
  #3   Spotlight this post!  
Unread 10-01-2016, 01:03
team-4480's Avatar
team-4480 team-4480 is offline
Debug? What's that?
FRC #4480
 
Join Date: Jan 2015
Rookie Year: 2013
Location: Minnesooota
Posts: 229
team-4480 will become famous soon enoughteam-4480 will become famous soon enough
Re: Can you view the webcam from the TCP connection?

Quote:
Originally Posted by Thad House View Post
In your robot code, you have to use the CameraServer class, which will stream the images from your camera to your driver station. The robot does not do this by default.
Yep, I should have added that I am currently using this code(It is in Python but it isn't any different then Java/C++)
Code:
        try:
            self.camera = wpilib.USBCamera()
            self.camera.startCapture()
            self.camServ = wpilib.CameraServer()
            self.camServ.startAutomaticCapture(self.camera)
        except:
            self.camera = None
I put this in the startup __init__ code.