Log in

View Full Version : Simple Camera code HELP PLEASE?


excel2474
15-02-2009, 20:54
I've spent hours reading and testing code to track the camera. I'm using windriver, and i'm not tying to do anything to complicated. I started with just compiling and downloading the example codes to the robot, but when I put the target in front of the camera, nothing happend. All I want to know, is how to find a color( green or pink or both) and if the camera sees it, turn on a motor. Can someone show me some commented code that will do this? Thanks a lot for the help because I'm desperate.

Billfred
15-02-2009, 21:22
For the record, I nudged this over to the WindRiver subforum to keep things orderly. :)

excel2474
15-02-2009, 21:33
For the record, I nudged this over to the WindRiver subforum to keep things orderly. :)

The problem with the subforums is that the post doesn't show on the portal page. At least that was my experience.

Billfred
15-02-2009, 21:51
The problem with the subforums is that the post doesn't show on the portal page. At least that was my experience.

That happens when forums get added--they don't get added to the portal lists by default. Click "Config" on the top of that list and it can be made to show. :)

Greg McKaskle
16-02-2009, 00:22
I'd say the vision example code is probably the most likely to work out of the box as anything. Next step is to put some print statements where the object center is found to try and determine if it is a watchdog, electrical, or code issue.

Greg McKaskle

excel2474
16-02-2009, 10:11
I'd say the vision example code is probably the most likely to work out of the box as anything. Next step is to put some print statements where the object center is found to try and determine if it is a watchdog, electrical, or code issue.

Greg McKaskle

OK, where is the printf displayed at. I couldn't figure this out.

Greg McKaskle
16-02-2009, 19:42
I haven't used WindRiver in a long time. I think there are two possible locations. The low level one is the terminal program hooked to the serial port. I think you can also open a terminal over enet in the Eclipse environment. Sorry, but I can't give you any details on that one.

Greg McKaskle

dboisvert
16-02-2009, 21:48
You can do it remotely by going connecting to the cRIO in the bottom left corner of the Remote Systems and after that right click "Wind River Target Debugger" go to > Target Tools > Target console.

A dialog box should open up, click ok and then you should see your printouts. They come rather quickly so be prepared for it.