LabVIEW for LEGO MINDSTORMS and LabVIEW for Education

cancel
Showing results for 
Search instead for 
Did you mean: 

Measure distance using Color Sensor 2.0

Solved!
Go to solution

Hello everyone!

 

I'd like to know if there's any way to measure the distance to an object using the color sensor that comes with the Mindstorms 2.0. I acquire some lectures from the sensor but I don't know how to convert this values to distance.

 

Any reference or link would be appreciated!

 

Thanks!

Francisco José Gómez López
Software Engineer
0 Kudos
Message 1 of 3
(8,337 Views)
Solution
Accepted by topic author fran_jo

Hi fran_jo,


Here's an article that offers a good method for calculating the correct scaling values to convert the intensity measurements to distance:  http://www.hitechnic.com/blog/eopd-sensor/eopd-how-to-measure-distance/.  Keep in mind that this relates to a third party sensor, but the concepts should still apply.

 

Also, note that the color sensor will be affected by ambient light.  You could try using a 2nd sensor to factor any ambient light.  What are you trying to accomplish with this application?  Is there a reason you aren't using the Ultrasonic sensor?

0 Kudos
Message 2 of 3
(8,333 Views)

Thanks Kyle,

 

I've followed this link already, with the EOPD sensor, also. My doubt was if I have to apply the same steps to calculate the scale value for the Color Sensor.

The main objective for this experiments is sensor information fusion. So I'm studying what all mindstorms sensors and third party sensors can do. 

At the end, I will have to choose the best combination of sensors to achieve a succesfull information fusion. 

 

Thanks for your help!

 

Best Regards,

 

Francesc Gómez

Software Engineer

Francisco José Gómez López
Software Engineer
0 Kudos
Message 3 of 3
(8,331 Views)