Using Thimble Blockly

### Setup

First, you'll need a Thimble account to build and upload sketches from inside Blockly. You can create an account through the learning app.

Once you have your account you'll want to install the Thimble Upload Agent. This program allows Thimble Blockly to connect to your board and upload programs to it. The installer that you want to use depends on your operating system.

#### Windows

Download and run the windows installer and then start the agent from the desktop or the start menu.

#### Linux

Download and unpack the installer package and run install.sh , then start it from your applications menu.

#### Verification

Blockly programs are built by connecting blocks together. Blocks that are connecten one below another are run one after the other. All blocks have to be connected to the start block to be included in the program. The blocks are stored in the menu on the left.

Find the "DigitalWrite" block in the Input/Output menu and the "wait ms" block in the "Control" menu. Drag the blocks into position so they look like the image below. Make sure to change the values connected to the DigitalWrite blocks so that one is true and one is false.

Once you're done, press the Upload button. Once you see the word "Done" next to the device dropdown your code has been uploaded. You should see the light on your Arduino blinking slowly. Try changing the program to make the light blink faster, or in different patterns.

### Looking at the code

Blockly means that you don't have to worry about the code, but if you want to see how your program is being turned into code you can select "View Code" in the menu. You can copy this code and paste it into the Arduino IDE. Then you can modify it and upload it. You don't have to worry about the code right now, but if you want to make really advanced programs later on you'll have to write the code yourself, so take a look and see if you can figure out how it all works!