Scratch for Arduino Workshop - 1.5h

From CommonsLab
Jump to navigation Jump to search

This workshop is designed for secondary education pupils with the goal to introduce them to the world of physical computing by using visual programming. The workshop uses for these purposes the Arduino UNO and some simple electronic components programming it with Scratch for Arduino (S4A).

Setting Up

It is recommended to have a PC/Laptop and Arduino UNO plus the components for every 3-4 pupils. Equipment:

  • Laptop or PC workstation with speakers
  • Pre-installed Arduino IDE and S4A.
  • Arduino UNO
  • USB Cable type B
  • Breadboard
  • 5 male to male jumper wires
  • Photoresistor
  • 10kOhm resistor
  • LED 5V

Introduction

What is Arduino?

Arduino is an open-source electronics platform based on easy-to-use hardware and software. It is possible to read inputs from the physical or digital world, a light sensor, a button or a tweet, and translate it to an output, lighting a LED, moving a motor or sending an email. The electronics board is using pins where jumper wires can be easily connected to form electronic circuits with the use of breadboards. The board can be programmed using the Arduino IDE with a simplified version of C++ or with visual programming by using Scratch for Arduino.

More information

Scratch for Arduino

S4A is a Scratch modification that allows for simple programming of the Arduino open source hardware platform. It provides new blocks for managing sensors and actuators connected to Arduino. There is also a sensors report board similar to the PicoBoard one.

More information

Using the breadboard

A breadboard is a construction base for prototyping of electronics. Because the solderless breadboard does not require soldering, it is reusable. This makes it easy to use for creating temporary prototypes and experimenting with circuit design. For this reason, solderless breadboards are also extremely popular with students and in technological education.

More information on how to use a breadboard

Exercise 1: Blink

Building the circuit

Schematic for Blink exercise
Fritzing Arduino Blink Schematic

Building the logic

Blink noVar el.png Blink noVar en.png

Adding a variable

Scratch blink+delay BlocksOnly.png Scratch blink+delay BlocksOnly en.png

Exercise 2: Led with button

NOTE: Doing this exercise may require expanding the workshop to 2 hours depending on the previous experience of the pupils with Scratch or Arduino. If both subjects are presented for the first time it is recommended to skip this in the 1.5h format.

Exercise 3: Theremin