“Anyone can (and should) play around with electronics”
I began developing my prototyping skills by experimenting with interactive paper prototypes and physical thermoplastic material. From there, I followed SparkFun Inventor’s kit to build five projects encompassing circuity and micro-controllers like an Arduino, where I further developed my problem solving and making skills. These five projects experimented with light, sound, motion, display, and an autonomous robot with an Arduino and a breadboard.
I created digital experiences using hardware and software components. The first project involved controlling LED lights through their color, intensity, and presence. To introduce myself to LEDs, I set up a single LED and programmed the flash to turn on for two seconds then off for two seconds.
Using the algorithmic design, I created an RGB night light that turns on when the photoresistor value drops past a threshold, triggering the LED to turn off. With a photoresistor, we can control if the LED turns on or off based on if the sensor passes a light level threshold, stored in a variable. If the photoresistor value drops below the threshold (meaning it is dark in the room), the LED will turn on. The value was set to react when the room lighters were off. By following step-by-step instructions, the potentiometer in the circuit allows us to change the LED colors to RGB based on the level of the trimpot value.
The most rewarding part of generating light with an Arduino was seeing the LED turn on and follow the code written on the Arduino program. I enjoyed using my hands to insert components into the Arduino and the breadboard. Watching the LED change colors from red to green to purple in the last circuit using a potentiometer.
The second element I explored using microcontrollers is how to generate sound. A piezo buzzer generates sound. The buzzer is made up of a small magnetic coil to vibrate on a desk. When electricity is passed through the coil at different rates, the sound is produced at a variety of frequencies. I explored generating different sounds associated with respective buttons, controlling the volume with a potentiometer.
To take it a step further, I used pattern recognition combine light with sound to build an LED keyboard. I followed the same pattern of programming an LED light to turn on and used this skill to alter the code to connect the on/off states of the LED to be dependent on if a button is clicked. Therefore, each button generates a sound and lights up an LED.
Since I am not a piano player, the LED keyboard was of little use of. Therefore, I collaborated with a friend to generate a sequence of notes that reminds me of electronic video game music. Using an aspect of computational thinking, abstraction, I focused on generating music rather than cluttering the experience to require constant interaction with buttons to generate.
My last mini project with light and sound warranted a bit more interaction. I created a Simon Says game that uses LEDs to flash a pattern, then a player must remember and repeat the pattern using four buttons. If a player enters the pattern incorrectly, they lose and a sad electronic theme song is programmed to play. With many moving parts, I used decomposition as a skill to break down different components required and their respective functionalities. This project required the use of for loops and custom functions in the code to program the game.
I found it difficult, at first, to understand how the Arduino code is structured to program certain input and output functionalities. Arduino code is very similar to Python. After some time, I was able to program an LED to light up when a button is pressed, and a buzzer sound plays.
The most rewarding part of learning about sound in microcontrollers is realizing the potential of the Arduino. I never thought that a game or a piano-like instrument would come out of electronics, so learning more about what an Arduino can do and all the possibilities of projects you could make with microcontrollers was satisfying.
Motion is another concept resulting from an Arduino controlled motor. To explore the concept of motion, I worked with a servo motor to build a Mood Cue. Servo motors can host various motor mounts that rotate over a range of 0-180 degrees than I controlled with a potentiometer. Based on previous mini projects, I am comfortable with identifying pattern recognition of microcontrollers and their capabilities. A potentiometer has previously been used to control settings. Similarly, I programmed a potentiometer to control the rotation angle of the servo motor mount when twisted.
Since now, printing output data has only been generated to the Arduino Serial Monitor on my computer. However, using a Liquid Crystal Display (LCDs), I can print data or text on a portable screen away from my computer. The screen is made up of tiny squares called pixels; each character size is made up of a height and width of pixels. A new concept learned with the display is contrast. Pin 3 on the LCD controls the brightness of the screen which can be adjusted with a potentiometer. Therefore, twisting the potentiometer will make the content brighter or fade away. To practice displaying text on the LCD screen, I programmed with Ardunio to print “Hello, World!”.
Next, I wanted to generate evolving data on the LCD screen. I made a DIY weather station that would display the temperature of an environment. To capture real-time temperature, I need to use a temperature sensor, a component that reminds me of a photoresistor (a component that senses light). The temperature sensor will capture the voltage output that is calculated to find the temperature in Celsius or Fahrenheit. By programming a series of algorithmic formulas, the output converts the voltage to a degree Fahrenheit. The temperature will update every second.
The last project using the LCD is DIY Who Am I? interactive game. Sparkfun defines this game as “a fun party game in which a player holds an LCD screen to their forehead while other players have to give hints, act out charades or make noises that will make the player with the LCD guess the word”.
A battery holder is directly connected to the Arduino to allow for portable transportation of the project!
The final project I explored with microcontrollers are robots. I was able to bring together all of the computational thinking skills I developed from previous projects to tackle this last hurdle of a project. Some elements were repeated components used in previous challenges while others were variations.
The robot requires a strong motor to drive the structure. Therefore, I had to use a DC gear motor to move my robot. Since motors require a lot of current, I used a motor controller board to power and spin the motor using a coded program. I also needed to control the on and off state of the motor. Therefore, I used a switch, rather than a potentiometer that offers range, to turn the motor on or off.
Now that I had a better understanding of a DC gearmotor, I was able to attach wheels to the motor and build my robot following algorithmic thinking. Building an autonomous robot was really satisfying to see completed! Using a distance sensor, I programmed the robot to identify and avoid obstacles. I, again, used a battery holder attachment to power the Arduino. Therefore, the robot could move freely without having to be connected to my computer.
The most challenging portion was troubleshooting why only one wheel on the robot was rotating/turning on while the other was turned off. I wondered if some of my jumper wires were crooked or something was not connected correctly. I made sure my wires were properly pushed in and everything was correctly connected. That didn't work so I ended up having to start from scratch since I didn't know what the error was. This assignment was the most complex thus far and I was able to approach the task and not be overwhelmed by all the parts. I knew how the wires connected the Arduino to the breadboard, how the motor basics functions, and what the distance sensor does. This greater understanding increased my confidence while working with microcontrollers.
After completing a series of five Arduino based projects to explore light, sounds, motion, display, and robot, I have gained a better understanding of the full potential for embedded electronics. Microcontrollers and electronics are used in many of our everyday devices, from a basic computer mouse to a complex home security system. The same components I used in these mini projects are also applied to more sophisticated applications. For example, when backing out of a parking space, modern cars now have a motion sensor that triggers a beeping noise that has a potential to mitigate a car accident and maybe save a life. When hardware and software work together, a door of problem-solving opportunities open.
The exploration of light, sounds, motion, display, and robots all had purpose in solving a problem. In building the solutions, I strengthened my computational thinking skills by applying decomposition, pattern recognition, algorithmic thinking, and abstraction to each of my projects. With each challenge, these computational thinking skills helped me to analyze complex information issues with the technologies I was working with.