|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
|
|
Thread Tools | Rate Thread | Display Modes |
|
|
|
#1
|
|||
|
|||
|
Image Processing
Alright, I'm trying something new this year.
Attached is a chunk of code I've written to perform vision processing. The idea behind this is to allow teams to utilize a coprocessor running on the robot (e.g. Raspberry Pi). I have also attached our lessons learned from last year with the Axis Cameras. Currently: It can only read data from the Kinect and provides access to both the RGB and Depth Camera. I hope to add the Axis camera to this in the future along with many more features. I have incorporated code from FIRST FRC Team 341 Driving Miss Daisy am working on code based on a description from 987. (Thank you both) Future: I hope to maintain this code going forward. I have listed a few things I plan to add in the code itself. Do not expect major changes until after May 2013. I have seven robotics qualifiers this year. I do plan to add a few more features to the code in the next few weeks, such as access to the remaining Kinect features (other than audio) and a function based on what Team 987 posted. Operating System: Linux, Ubuntu 12.04 (Long Term Support) Hardware Programmed On: Intel Centrino/Pentium-M 1.73 Ghz, 2GB ram (2005 Laptop) IDE: I used CodeBlocks to write this (Thank you Team 987). Details: The code provides access to the Kinect Sensors using libfreenect. Image processing is performed using OpenCV and related libraries. The code can also send processed images from the Kinect to the Dashboard over the network (see attached sample labview code). I know a few things will have to change in order for this to work on the field, the key thing being the ports used. (I can not find a copy of last years game manual to fix this). Last edited by adciv : 27-12-2012 at 20:39. Reason: Forgot a file. |
|
#2
|
||||
|
||||
|
Re: Image Processing
Excellent write up!! Thanks for sharing. Depending on the game this year, this WILL help a lot of teams.
May I make one suggestion to help handle and even negate problems with different lighting conditions? Using "Florescent1" as a default is a good compromise, but there is a better option. It entails setting and locking the camera's White Balance to the actual environment. All that is required it creating a simple vi that places the camera in "Auto" White Balance mode. The hold a white piece of paper in front of the camera close enough that it completely fills the image. Hold it steady for 15+ seconds. Then once the camera has adjusted it's self to that lighting condition, exit the loop and have the last step set the camera to "Hold Current" for the White Balance just before the vi ends. Now, whenever you power up, have the camera set to use "Hold Current" and it will use the calibrated value for White Balance. This can be useful in any environment and will also allow you to calibrate for the exact lighting on the playing field as long as you take advantage of the time provided at each tournament. |
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|