Click here to access the Canvas page with the repository for this studio.
This is a pretty complex question, and there are many other topics needed to give a good answer.
Here are some resources:
We do not expect anyone to be an electrical engineer. We do, however, need you to understand the very basics of circuits and electricity so you can better understand your Arduino.
Please know the basics of these subjects before moving on:
Armed with your new circuit knowledge, you will be modeling studio 1’s Binary Counter with 3 LEDs. We’ll then follow that with the construction and exercising of the LCD display.
By the end of studio, you should know:
Important: for your first couple of circuits, let a TA check over them before plugging in your Arduino
circuits
package that contains an empty circuits.ino
. Open it and use this file for your work.
Warning messing with electricity is never a good idea. The Arduino is a pretty safe place to start but you should develop a healthy respect for electricity.
Warning: always disconnect power from the Arduino before doing (or changing) any wiring. An accidental mis-connection can damage either/both your Arduino and/or the parts you are connecting. Double check work before applying power
Here is your RedBoard:
Here is how to wire up one LED:
If you were to issue the command digitalWrite(3,HIGH);
after wiring one LED as indicated in the video, would the LED light up, or be dark?
Check with a TA before moving on
The Code to make an LED at Pin3 Light up:
void setup() {
pinMode(3,OUTPUT);
digitalWrite(3,HIGH); //HIGH => On and LOW => Off
}
Studio 1
, modify your code to use those 1s and 0s to determine if LED 1, 2 ,or 3 should be lit.
Here is what your LEDs should do:
In subsequent assignments, we will want to display text locally (rather than on the PC). Following the directions in SparkFun’s tutorial, construct the LCD display circuitry and make it operational.
In Studio 1, the binary counter sent output to the Serial Monitor on the PC. Add lcd.print()
statements to your Arduino sketch to display the current count on the LCD display.
Make sure to commit and push your project.
Eclipse may not be aware of changes to files that were made outside of Eclipse, such as changes you make in the Arduino IDE. Right click on the project and select Refresh
to force Eclipse to search for updates.
In Eclipse’s package explorer, any files you have modified since your last commit are prefixed with a >
.
Right-click the outer-most folder (you want to commit everything within), and choose Team > Commit...
. Write a helpful message and press OK
.
You can verify that your changes went to the server by opening the repository URL at GitHub in any web browser. Browse the files to make sure your changes committed.
Get checked out by a TA.
Repository structure for this studio:
circuits/
circuits.ino
This is a mental checklist for you to see what the Studio is designed to teach you.
pinMode()
digitalWrite()
Team > Commit...
Generated at 2022-07-20 19:49:20 +0000.
Page written by Ben Stolovitz and Sean Schaffer.