Python5 tutorials

Getting Started with Python

Write your first MicroPython programs using the PyBot API. Learn to print output, control LEDs, and read switches.

Hello, Python!

BeginnerPython

Write your first Python program on the Beaver Board: show a message on the OLED, use a variable to store your name, and watch the display update instantly. No sensors required — just you, the Python editor, and the OLED screen.

PythonOLEDVariablesBeginner

Blink an LED with Python

BeginnerPython

Control the RED LED from Python code. Learn to import the pybot library, turn an LED on and off, add a delay, and loop forever with while True.

LEDPythonWhile LoopBeginner

Make a Sound with Python

BeginnerPython

Play a tone on the Beaver Board buzzer from Python, then stack notes together to make a short melody that loops forever.

BuzzerSoundPythonBeginner

Read a Switch with Python

BeginnerPython

Use an if/else statement to light the GRN LED whenever you hold down Switch A. Your first Python program that reacts to the physical world in real time.

SwitchLEDIf/ElsePythonBeginner

Variables and Display

BeginnerPython

Store a live sensor reading in a variable, show it on the OLED screen, and watch it update in real time. See how variables connect hardware input to output.

VariablesOLEDSensorsPythonBeginner