Write code
Write your own code
Type code for the board, press Run, and watch what happens.
New to code? Start with Mission 1, or see all missions.
Getting ready to run your code…
A problem
Show everything the compiler said
If your code runs but does the wrong thing, the compiler can’t spot that for you. Read it again line by line, and watch the board.
Messages from the board (Serial)
How this page works
When you press Run, a compiler turns your code into chip language: the numbers the board’s chip understands. It is the same compiler program the Arduino software uses for the UNO (GCC 7.3.0 with Arduino’s changes), and here it runs inside your browser.
Then a pretend UNO runs that chip language, with three lights on pins 9, 10 and 11, a button on pin 2, a knob on pin A0, and the board’s own light on pin 13. The button is wired like Arduino’s Button example: pressing it puts 5 volts on pin 2, so digitalRead(2) reads HIGH while you hold it. Use pinMode(2, INPUT).
The first time, this page downloads about 6.8 MB once. Your code stays in this browser: nothing you type is sent anywhere.