By the end of week 6, you will be able to:
Program an Arduino to control a single action component (LED, Motor...etc), using Code Blocks
Program an Arduino to read signals from a single input component (Sensor, switch, and variable resistor), using Code Blocks
Differentiate between digital and analog signals and use them efficiently to program smarter devices
Understand how code blocks translate into Arduino C programming language
Tinker existing code in order to achieve a different/desired outcome
Play music by controlling a Buzzer with an Arduino board. (For this activity you are required to build and simulate the circuit on TinkerCad ONLY)
Type: Individual Activity
Tools & Materials
TinkerCad
Components: Arduino Uno + 1 Buzzer + 1 slide Switches + 1 Breadboard
Description
Follow the wiring diagram above to complete your circuit
Now, it is time to write your first Arduino Code! Watch this Video Tutorial to know where and how to build the code to program an Arduino in TinkerCAD
Choose one of these two soundbites to play using the Arduino: Soundbite #1 - Soundbite #2
Drag and drop the Code blocks by following the coding order
Once you are done with "building" the code, click the simulate button
Open the ON/OFF switch and listen to the soundbite that you chose! Can you guess the name of the music/song?
[OPTINAL ] Tryout the other soundbites and guess the name of the music
[OPTINAL ] create your own symphony! Play around with the code and change the tones to create your own music.
Reflect & Share
Can you guess the name of the music/song?
What are the blocks of code that relate to the input action (ON/OFF Switch)?
What are the blocks of code that relate the output action (Buzzer changing of tones)?
Do you think that this outcome was possible using electronics components only without an Arduino?
Follow the video tutorials below (in order) to learn how to program an Arduino to control a single action component: LED, Buzzer, DC Motor, and Servo Motor using Code Blocks. View the Code blocks and wiring to follow along.
Arduino Installation
Digital & Analog Output
FILL MID ROUND SURVEY 📃
Deadline: Before Midweek Session
Mode: Online Via Google Meet
Session Outcomes
Discuss video tutorials and address challenges or problems with the instructor
Participate in a pair learning activity to practice controlling electronics with Arduino
Take a walkthrough week assignment description and requirements
Session Exercise
Exercise 1: Program your Arduino board to control one 7-segment display so that it counts down from 9 to 1
Expand to show requirements
Requirements
Use Google Search to see how other people have done a similar project to using Code Blocks in TinkerCad
Use TinkerCad to design the circuit
Use Code Blocks PRIMARILY to build your code in TinkerCad
Simulate your circuit and code in Tinkercad. Does it work?
[Extra] Build the circuit and make your connections on a physical breadboard with an Arduino UNO Board. View and copy the Arduino C code from Tinkercad and paste it into Arduino IDE, then Upload it to your Arduino Board. Does it work?
[Solution] Controlling a 7-segment: Solution Tutorial - Wiring & Code
Exercise 2: Program your Arduino board to control one RGB LED so that it lights up with the following colors in order: Red, Blue, Green, Purple, Orange, and White
Expand to show requirements
Requirements
Use Google Search to see how other people have done a similar project to using Code Blocks in TinkerCad
Use TinkerCad to design the circuit
Use Code Blocks PRIMARILY to build your code in TinkerCad
Simulate your circuit and code in Tinkercad. Does it work?
[Extra] Build the circuit and make your connections on a physical breadboard with an Arduino UNO Board. View and copy the Arduino C code from Tinkercad and paste it into Arduino IDE, then Upload it to your Arduino Board. Does it work?
[Solution] Controlling an RGB LED: Video Tutorial - Wiring & Code
Follow the video tutorials below (in order) to learn how to program an Arduino to read a single Input component: Switches, sensors, and variable resistors using Code Blocks. View the Code blocks and wiring to follow along.
Digital Input
Analog Input
Deadline: Before EOWeek Session
Mode: Face-to-face @ Fab Lab
Session Outcomes
Discuss video tutorials and address challenges or problems with the instructor
Participate in a group activity where you use Arduino to create a smart project
Discuss assignment progress: concept and execution
Session Exercise
Build a Smart Waving Hand using Arduino. When you wave at the smart hand, it waves back at you! 👋
Expand to show requirements
For inspiration: Marvin the Waving Bot - A simple Waving Hand
Description: You are required to build and program two modes separately
Manual Mode: In this mode, a single servo motor (One Hand) at the output is controlled manually by a human using a potentiometer (knob) at the input of an Arduino board (Hint: Map 😉)
Automatic Mode: In this mode, a single servo motor (One Hand) connected at the output is controlled via signals received from an ultrasonic sensor at the input of the Arduino board
Tools & Materials: 1 Potentiometer - 1 or 2 Servo Motors - 1 Ultrasonic Sensor - Jumper Wires - 5V Adapter - Avometer - 1 Large-sized Breadboard - 1 Cardboard Sheet - 1 Cutter or scissors - 1 Glue Gun + Glue - 1 Ruler - 1 Pencil - 1 Sellotape
Requirements for Electronics:
Build and code the Two Modes on Tinkercad using Code Blocks ONLY
Build and test the circuits for each of the Two Modes with a physical breadboard and an Arduino Board
[Extra] Add a second servo motor, doubling the hands means doubling the FUN! Program the second servo motor to rotate in an opposite direction to the first one, in order to give a realistic waving effect
Requirements for Mounting & Enclosure:
Make a simple hand cutout using Cardboard or Paper and fix it on the Servo Motor horn using sellotape or double sided tape (DON’T use Hot Glue!)
Fix the servo motor (with the Hand) on the edge of a table or box using sellotape (DON’T use Hot Glue!)
[Extra] Build simple enclosure to contain all electronics and Arduino Board
[Extra] Mount your input components (Potentiometer knob and/or Ultrasonic sensor) on the outside of the enclosure INSTEAD OF the breadboard. Use jumper wires to extend your wiring connections from the Arduino Board to the face of the enclosure (DON’T use Hot Glue!)
[Solution]
Manual Mode: Video Tutorial - Wiring & Code
Automatic Mode: Video Tutorial - Wiring & Code
Build and Program a smart circuit using an Arduino UNO which reads a signal from an input component (Sensor, Switch, or variable resistor) to control an action component (Motor, Buzzer, LED...etc) using Code Blocks
Description:
Find any exciting idea to do for the assignment: you may find cool ideas on Instructables and Arduino Project Hub or try to implement your final project idea 😉
(Please DON't repeat any of the ideas from week tutorial examples or exercises, as it will not be accepted)
Google your idea and see how other people have wrote their code, and provide links to other codes that you've tweaked or reused in your assignment
Use Code Blocks PRIMARILY to build your code in TinkerCad. Then, view and copy the Arduino C code into Arduino IDE, and Upload it to your Arduino Board
Technical Requirements:
The smart circuit utilizes the Arduino UNO board to control the input and output
The smart circuit includes one input component (at least) and one action component (at least) (DON'T repeat any of the input and output combinations that were provided in the tutorials and exercises, you are encouraged to try new ones, you may also use new input and output components from your electronics kit)
The smart circuit is programmed using Code Blocks (Provide a screenshot of your code blocks)
The smart circuit is wired and tested with code blocks in TinkerCad (Provide a wiring diagram and simulation outcome)
The smart circuit is wired and tested with an actual Arduino board and electronic components on a breadboard (Provide *.ino code file that is uploaded on the Arduino board and a video recording of the final outcome)
The smart circuit is functional and does its intended objective
Make sure to document your Assignment for Week 6 in the Maker Journal covering the following requirements:
Process Documentation:
Ideation: Describe how you came up with the idea for the smart circuit. Were you inspired by a certain reference? or did you customize design it to fulfil a certain objective?
Tools: Describe software, components, materials, and tools that you used in your assignment
Design: Describe the design of your smart circuit. What are the input and action components that you used? Make sure to include a screenshot of your circuit wiring on Tinkercad. Explain your code in detail, why did you use each code block and how did sequence them to achieve the final outcome?
Implementation/Fabrication: Describe how you implemented your smart circuit on a breadboard. How did you transfer the code from Tinkercad to your Arduino board? And most importantly, show us the final outcome of the assignment, make sure to include a video recording for your complete smart circuit in action
Media: Provide supporting images and videos to demonstrate the design and implementation processes
Learning Documentation:
Learning from Mistakes: Describe problems and challenges that you faced, and briefly describe solutions.
Community of Learning: Highlight an advice or idea provided by a peer or an instructor that helped in solving a problem or a challenge. Or an advice that YOU provided to help your peer(s)
Progress Review Deadline: February 3rd, 2025 @4:00 PM