So I purchased a Axon controller and started messing around with it. So far its works great. I have looked around on the forums and have yet to find a topic about IR sensors and how they could control a motor or Solenoid. I have tried to program the controller by modifying some existing code and needless to say it didn't work. I have purchased a IR sensors listed below
http://www.acroname.com/robotics/parts/R185-SINGLE-LINE-IR.htmlI have used this type of sensor for data logging on cars before and had a great experience with it.
I would like to have the IR sensor pick up off a rotating object and activate a solenoid every time the white line comes around. I am very new to programming and have read many tutorials, but still haven't gotten the hang of it.
My Pseudo code looks like this
"
read IR sensor PORT,F1
if IR sensor detects line
then activate relay on PORT E2 for 30ms
"
Can someone lead me in the right direction on how to solve this problem. If there is a tutorial out there that is similar to this that would help tremendously.
Thanks
Jesse