IR Detecting to execute alterate movements
Tim U
Posts: 9
I am using a BS2 with a single IR Detector in a boe-bot.
What I am trying to do is to make the Boe-Bot execute movements (right turn & Left Turn)·when the IR Detector sees a signal from a hand held remote control.
I want to alternate the movements, however I don't know how to write the PBasic code to tell the difference between the first button press and the second button press and·how can I tell the stamp the 3rd button press·should act like the first.
Any ideas???· I think is a matter ov naming a variable and incrementing it when the button is pressed.
Thanks
Tim
What I am trying to do is to make the Boe-Bot execute movements (right turn & Left Turn)·when the IR Detector sees a signal from a hand held remote control.
I want to alternate the movements, however I don't know how to write the PBasic code to tell the difference between the first button press and the second button press and·how can I tell the stamp the 3rd button press·should act like the first.
Any ideas???· I think is a matter ov naming a variable and incrementing it when the button is pressed.
Thanks
Tim
Comments
http://www.parallax.com/Store/Books/EducationalTexts/tabid/181/CategoryID/66/List/0/Level/a/ProductID/149/Default.aspx?SortField=ProductName%2cProductName
Dave
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Dave Andreae
Parallax Tech Support·