Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   Programming (http://www.chiefdelphi.com/forums/forumdisplay.php?f=51)
-   -   Change two color tracking vi from tracking pink AND green to orange OR grape balls (http://www.chiefdelphi.com/forums/showthread.php?t=74442)

star_lancer 14-02-2009 12:15

Change two color tracking vi from tracking pink AND green to orange OR grape balls
 
How do I change the tracking program given out on the first website from tracking the two colors together to just being able to track one color or the other color? We are trying to use the camera to track for balls, I've already changed the colors required, but I need to know how to make it track either color so it will fire the solenoid like I've wired it to. Basically I want to turn the camera into an all purpose ball detector. I chose purple and orange because all the balls contain at least one of these colors. I am doing this in labview, but I put it out here for all to see.

elfinn 14-02-2009 17:40

Re: Change two color tracking vi from tracking pink AND green to orange OR grape ball
 
Look at the VisionDemo example in Wind River. It calls FindColor() instead of FindTwoColors().

Greg McKaskle 14-02-2009 19:26

Re: Change two color tracking vi from tracking pink AND green to orange OR grape ball
 
There is also a LV example for finding a single color object. To update it to find a second color, you have two choices -- prioritize one and do the second only if you don't find the first, or search for them in parallel and take the biggest/best one you find. The first version will duplicate some of the code, put it in a case, and only execute it if you don't find a good first target. The second approach will search for both, compare the results, and then decide on the outcome.

Greg McKaskle

Greg McKaskle 14-02-2009 19:27

Re: Change two color tracking vi from tracking pink AND green to orange OR grape ball
 
Another thought is that you really don't want to start from the two color tracker as it doesn't search for one or two, it searches for one and two touching each other in a vertical orientation. Those aren't a all the same thing.

Greg McKaskle

star_lancer 14-02-2009 20:26

Re: Change two color tracking vi from tracking pink AND green to orange OR grape ball
 
Quote:

Originally Posted by Greg McKaskle (Post 820816)
There is also a LV example for finding a single color object.

Where is that example? I couldn't find it.

Greg McKaskle 14-02-2009 20:58

Re: Change two color tracking vi from tracking pink AND green to orange OR grape ball
 
I think it is called Single Color Tracking for the one that does the servo, there is another single color.

The disk location for both is LV8.5/examples/FRC/vision/...

Greg McKaskle


All times are GMT -5. The time now is 01:12.

Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi