Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   Programming (http://www.chiefdelphi.com/forums/forumdisplay.php?f=51)
-   -   Light Sensors (http://www.chiefdelphi.com/forums/showthread.php?t=45524)

Darb12000 16-03-2006 23:05

Light Sensors
 
I just bought quite a few omni-wheels and light sensors, and was wondering if a robot able to move toward light is possinle at all.

Kingofl337 21-03-2006 10:02

Re: Light Sensors
 
Yes you can do that you just need to program it to do so.

basicly if the light gets brighter drive in that direction.

irishninja 03-04-2006 17:35

Re: Light Sensors
 
What you need to do is buy two light sensors. You put one on the right, one on the left. This enables you to see which value is greater and turn towards that side. Once you have turned to that side and the light is bright enough, which you can do with a simple if statement if a variable with the analog light input is > a number of your choice you drive forward.

If you only have one, you must turn until you have a light input > a numbe rof your choice and then drive forward.


All times are GMT -5. The time now is 03:16.

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