|
RobotCore 1.0
WPILib port to raspberry Pi
|
The PiCamera class handles communication with the Raspberry Pi Camera. More...
Classes | |
| class | PiCameraStats |
| The PiCameraStats class collects the current camera performance statistics. More... | |
| class | PiCameraPoint |
| The PiCameraPoint specifies an (x,y) position. More... | |
| class | PiCameraRect |
| The PiCameraRect specifies an rectangular region. More... | |
| class | PiCameraRegion |
| The PiCameraRegion specifies a single detected region. More... | |
| class | PiCameraRegions |
| The PiCameraRegions specifies list of detected regions. More... | |
Public Member Functions | |
| boolean | isConnected () |
| void | dumpFrames (int count) |
| void | startLogging (String path) |
| void | endLogging () |
| void | setLight (int value) |
| void | setProfile (int profile) |
| void | startPiLog () |
| void | endPiLog () |
| void | connect (String host, int port) |
| PiCameraStats | getStats () |
| void | clearStats () |
| PiCameraRegions | getRegions () |
| Public Member Functions inherited from robotCore.Network.NetworkReceiver | |
| void | processData (String command) |
| void | connected () |
| void | disconnected () |
The PiCamera class handles communication with the Raspberry Pi Camera.
This class allows you to connect to the Data server of the Raspberry Pi and receive information about the image frames processed by the camera. It also implements a time sync protocol to synchronize the clocks and performs keep-alive functions that detect a disconnect.
Definition at line 44 of file PiCamera.java.
| robotCore.PiCamera.PiCamera | ( | ) |
Definition at line 204 of file PiCamera.java.
| void robotCore.PiCamera.clearStats | ( | ) |
Clears the camera performance stats
Definition at line 467 of file PiCamera.java.
| void robotCore.PiCamera.connect | ( | String | host, |
| int | port ) |
Connects to the Raspberry Pi Data server
| host | - Specifies IP for the host |
| port | - Specifies the port (default is 5800) |
Definition at line 396 of file PiCamera.java.
| void robotCore.PiCamera.dumpFrames | ( | int | count | ) |
Instructs the Raspberry Pi to dump the last N frame to disk. This can be useful in debugging to obtain a record of what the camera saw.
| count | - Count of frames to dump (max 120) |
Definition at line 300 of file PiCamera.java.
| void robotCore.PiCamera.endLogging | ( | ) |
Ends logging and closes the log file
Definition at line 338 of file PiCamera.java.
| void robotCore.PiCamera.endPiLog | ( | ) |
Ends the Raspberry Pi logging
Definition at line 386 of file PiCamera.java.
| PiCameraRegions robotCore.PiCamera.getRegions | ( | ) |
Returns the latest set of camera regions. Note that the data is received from the camera in a separate thread so calling this twice in a row can generate a different result. Once you retrieve and instance of PiCameraRegions however, you can be assured that it will NOT be modified when a new frame is received.
Definition at line 525 of file PiCamera.java.
| PiCameraStats robotCore.PiCamera.getStats | ( | ) |
Returns the current camera performance stats
Definition at line 456 of file PiCamera.java.
| boolean robotCore.PiCamera.isConnected | ( | ) |
Returns true if connected to the camera
Definition at line 227 of file PiCamera.java.
| void robotCore.PiCamera.setLight | ( | int | value | ) |
if the Raspberry Pi is configured to controll the camera lights using pins 11 and 12, this command will turn the lights on or off
| value | - Bit zero controls pin 11 and bit one controls pin 12 |
Definition at line 353 of file PiCamera.java.
| void robotCore.PiCamera.setProfile | ( | int | profile | ) |
Specifies which capture profile should be used.
| profile | - Specifies the profile to use (0-3) |
Definition at line 367 of file PiCamera.java.
| void robotCore.PiCamera.startLogging | ( | String | path | ) |
Starts logging the data received from the Raspberry Pi locally
| path | - Specifies the path for the log file. |
Definition at line 313 of file PiCamera.java.
| void robotCore.PiCamera.startPiLog | ( | ) |
Instructs the Raspberry Pi to start logging the camera data on the Pi's disk This can be useful for debugging
Definition at line 378 of file PiCamera.java.