IR Remote
Add IR Remote Blocks
1. Make sure "Codey" is selected and click "+" in the blocks area.

2. From the pop-up Extension Center page, click "+" to add IR Remote blocks.

3. Go back to Edit page. You can find IR Remote category added to the block palette.

Have Some Fun
1. Drag a when Codey starts up block from the Events category to the Scripts area.

2. When up arrow button is pressed, we want Codey Rocky to move forward. We need to a if () then () block from the Control category, a IR Remote () pressed? block from the IR Remote category, and a move forward at power ()% for () secs block from the Action category.



3. When down arrow button is pressed, we want Codey Rocky to move backward. We need to a if () then () block from the Control category, a IR Remote () pressed? block from the IR Remote category, and a move backward at power ()% for () secs block from the Action category.


4. When left arrow button is pressed, we want Codey Rocket to turn left. We need to a if () then () block from the Control category, a IR Remote () pressed? block from the IR Remote category, and a turn left at power ()% for () secs block from the Action category.


5. When right arrow button is pressed, we want Codey Rocky to turn right. We need to a if () then () block from the Control category, a IR Remote () pressed? block from the IR Remote category, and a turn right at power ()% for () secs block from the Action category.


6. Add a Control block forever.

7. Click "Upload" to upload the program to Codey.

8. Press the buttons of your IR Remote and see how Codey Rocky moves.
Last updated