View Full Version : IR Detecting to execute alterate movements

Tim U
10-28-2009, 06:17 PM
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.


10-28-2009, 09:00 PM
Yes, there is a book that you can download called "IR Remote for the Boe-Bot" that goes over this particular topic.· Here is a link for the download:·



Dave Andreae

Parallax Tech Support·