Hello, Blink!

Beginner

Make the onboard LED blink on and off — your first robot program.

10 min5 steps
LEDEventsBeginner
0 of 5 steps

Step 1 of 5

Connect your board

Plug your PyBot board into your computer with a USB cable. Click the Connect button in the toolbar and select your board from the list.
Step image
# this is test code
import pybot
import time

while True:
    pybot.led.on(1)
    time.sleep(0.5)
    pybot.led.off(1)
    time.sleep(0.5)
    test()

Ready to code? Practice this tutorial in the Blockly IDE.