RoboTek Arduino Level 2
RoboTek Arduino Level 2
and Display
Arduino Level 2
After completing this module, a student
should be able to construct robotics projects
with different input and output devices using
sensors and motors controlled and program in
an Arduino microcontroller.
How to establish a workplace safety?
Always remember and make sure that your hands are dry
(use gloves if necessary).
Target Outcomes
Engage
Guess the words:
+ + +
D
____ _________ TechFactors Copyright 2020
Lesson 1: The Soldering Iron and Other Basic Electronics Tools
+ + +
D
BIND SOLDERING
IRON
TechFactors Copyright 2020
Lesson 1: The Soldering Iron and Other Basic Electronics Tools
Explore
Explain
Explain
Explain
PCB (Printed Circuit Board) is a board that connects various points together, it
has layers of copper laminated onto sheet layers of a non-conductive substrate.
TechFactors Copyright 2020
Lesson 1: The Soldering Iron and Other Basic Electronics Tools
Elaborate
USES AND APPLICATIONS FOR A SOLDERING IRON
Roofers use solder to fuse galvanized metal for flashing. They also
use it to fuse components of copper roofs. Because accuracy is less
important than it is in other trades, roofing soldering irons have broad
tips that heat up quickly and the ability to retain heat in windy
conditions.
TechFactors Copyright 2020
Lesson 1: The Soldering Iron and Other Basic Electronics Tools
Elaborate
USES AND APPLICATIONS FOR A SOLDERING IRON
Elaborate
USES AND APPLICATIONS FOR A SOLDERING IRON
Elaborate
USES AND APPLICATIONS FOR A SOLDERING IRON
Soldering pencils, guns and irons that are adequate for home use are
made in abundance. Most are heated electrically and have tips that can be
used with a propane torch. The proper tool depends on the project, but
tasks like joining wires and circuit-board repairs may call for varying
amounts of heat or more control.
TechFactors Copyright 2020
Lesson 1: The Soldering Iron and Other Basic Electronics Tools
Elaborate
USES AND APPLICATIONS FOR A SOLDERING IRON
Elaborate
USES AND APPLICATIONS FOR A SOLDERING IRON
Solder isn't strong enough to make engine repairs but is used to fill
irregular cavities, smooth rough surfaces and tighten joints. It's also
used to tin the edges of metal sheets, fill up holes and fuse metal
panels when doing auto body repair.
Evaluate
Direction: Fill in the table with the information needed.
Evaluate
Direction: Give instances when soldering is necessary and how you use it.
1.
2.
3.
4.
5.
Additional Assessment
Direction: Describe each material shown below:
1. 2. 3.
4. 5. 6.
Target Outcomes
Engage
Watch the video for a basic soldering guide. Take note of the important
details in the video then answer the questions.
https://www.youtube.com/watch?time_continue=279&v=BLfXXRfRIzY
Explore
Group Activity:
Explain
- Stranded Wire
- Solid Wire
Explain
SAFETY PRECAUTIONS IN SOLDERING
Do not play with the soldering iron either if it’s plug in or not.
Be very careful while handling the soldering iron and soldering lead.
Use a medical mask to cover your nose and mouth while using it.
Make sure to place the hot soldering iron in a soldering
stand or in a flat surface.
Do not inhale the melted lead or the smoke.
Do not touch the tip of the soldering iron or melted lead.
Clean the tip of the soldering iron before reusing it.
TechFactors Copyright 2020
Lesson 2: Using Soldering Iron
Elaborate
Here are some examples of how the joint should look and common
problems:
Elaborate
Follow the steps in soldering a wire.
1. Trim the wire – remove the insulator of the wire using pliers.
Elaborate
Follow the steps in soldering a wire.
2. Tin your wires – melt some solder into the filaments with your soldering
iron.
Elaborate
Follow the steps in soldering a wire.
3. Apply lead – melt the lead to coat the end of the wire.
Elaborate
Follow the steps in soldering a wire.
4. Connect a soldered wire together – re-apply the soldering iron and solder
the wires to each other.
Evaluate
My Own Creation: Design and create your own project through soldering
using any materials that can be joined through soldering. Be creative in your
design and in choosing the materials you will use.
Additional Assessment
My Own Creation 2: Design and create your own project through
soldering using any materials that can be joined through soldering. Create a 3D
art figure using wires connected to each other. Example: stick figures, chair,
table, etc.
Target Outcomes
Use the soldering iron to connect wires into the printed circuit
board; and
Explore
Discussion of the KWL Chart:
Explain
Explain
Elaborate
Try this!
Materials:
Soldering iron
Soldering Lead
Soldering Pump
Wire
PCB
Switch
Elaborate
Try this!
Evaluate
Procedure
1. Prepare all the
materials needed.
2. Trim and tin the wire.
3. Add lead into the
switch terminal end.
4. Solder the wire into
the switch.
Procedure
1. Prepare all the
materials needed.
2. Trim and tin the wire.
3. Add lead into the
switch terminal end.
4. Solder the wire into
the switch.
Additional Assessment
Based on the activity you did last lesson, solder your 3D artwork on a piece
of PCB to make it as a stand. You can display your work inside your classroom
and put your name on it.
Based on the activity you did last lesson, solder your 3D artwork on a piece
of PCB to make it as a stand. You can display your work inside your classroom
and put your name on it.
Target Outcomes
Engage
What is your
favorite color?
TechFactors Copyright 2020
Lesson 4: RGB Module
Engage
Explore
Poking Fun at Color Mixing
Assembly
Put together your light source:
Orient the viewer so the foil side is facing the light source and
the wax paper side is facing you. Hold the viewer up to the
light, about 8-10 inches (20 centimeters) from your face, and
look at the light being projected onto the wax paper.
Try to get the light from the green and red bulbs to overlap.
What do you notice? What techniques or modifications produce
overlapping colors? Make sure you can get the colors to overlap
before continuing.
Next, ask your partner to switch off the green light and turn on
the blue light (leaving the red light on). What do you notice?
TechFactors Copyright 2020
Lesson 4: RGB Module
Explore
Data Collection for Poking Fun at Color Mixing
Explain
Explain
Explain
Elaborate
Materials
Microcontroller USB Cable Jumper Wire
Breadboard 3 pc. 220 Ohms Resistors 1 pc. RGB Module
Procedure
1. Examine the RGB module prepared by your teacher.
2. Study the code that turns the RGB module light into RED.
Elaborate
RED
digitalWrite(RED_PIN, HIGH);
digitalWrite(GREEN_PIN, LOW);
digitalWrite(BLUE_PIN, LOW);
delay(1000);
GREEN BLUE
digitalWrite(RED_PIN, LOW); digitalWrite(RED_PIN, LOW);
digitalWrite(GREEN_PIN, HIGH); digitalWrite(GREEN_PIN, LOW);
digitalWrite(BLUE_PIN, LOW); digitalWrite(BLUE_PIN, HIGH);
delay(1000); delay(1000);
TechFactors Copyright 2020
Lesson 4: RGB Module
Elaborate
YELLOW PURPLE
digitalWrite(RED_PIN, HIGH); digitalWrite(RED_PIN, HIGH);
digitalWrite(GREEN_PIN, HIGH); digitalWrite(GREEN_PIN, LOW);
digitalWrite(BLUE_PIN, LOW); digitalWrite(BLUE_PIN, HIGH);
delay(1000); delay(1000);
CYAN WHITE
digitalWrite(RED_PIN, LOW); digitalWrite(RED_PIN, HIGH);
digitalWrite(GREEN_PIN, HIGH); digitalWrite(GREEN_PIN, HIGH);
digitalWrite(BLUE_PIN, HIGH); digitalWrite(BLUE_PIN, HIGH);
delay(1000); delay(1000);
TechFactors Copyright 2020
Lesson 4: RGB Module
Elaborate
3. Key in the code for each color using your RGB module.
Evaluate
1. Manipulate your RGB module and determine the code to produce RED, BLUE
and GREEN colors with different levels of brightness.
2. Complete the table by supplying the missing code for each level of
brightness.
3. Answer the question: How will you set up the color intensity of your RGB
module? (Type in the specific value for each color).
Additional Assessment
Using the RGB LED, use these following RGB codes to program the
microcontroller to see what color that was programmed:
Using the RGB LED, use these following RGB codes to program the
microcontroller to see what color that was programmed:
Target Outcomes
Engage
RGB Color Model
https://www.khanacademy.org/partner-content/pixar/color/color-101/v/color-2
Explore
1. What are the special color receptor in our
eyes that we use in order to see colors?
2. How many color receptors do we have?
What color are they sensitive with?
3. How can we create different colors using
Red, Green, and Blue?
TechFactors Copyright 2020
Lesson 5: Mixing Colors Using RGB Module
Explain
The value of intensity of colors for each LED ranges from 0-255. By
adjusting the value for each color using the analogWrite function in
programming.
TechFactors Copyright 2020
Lesson 5: Mixing Colors Using RGB Module
Explain
digitalWrite
Example: blinking LED
int led = 13;
The digital pins have only two
modes - ON (1) or OFF (0). We void setup() {
pinMode(led, OUTPUT); //digital pin as an output
use the constants HIGH (on) }
and LOW (off) since this makes
it easier to read code. Digital pin void loop() {
digitalWrite(led, HIGH); //tum the LED on
always gives the output power of delay(1000); //wait for a second
5V when HIGH and 0V when LOW. digitalWrite(led. LOW); // turn the LED off by making the
voltage LOW
The pin need to be configured with delay(1000); //wait for a second
pinMode(). digitalWrite(pin,value) }
//sets pin to value (LOW or HIGH)
TechFactors Copyright 2020
Lesson 5: Mixing Colors Using RGB Module
Explain
analogWrite
The digital pins 3,5,6,9, 10 and 11 have a special function called PWM(). For these pins we are
using the command analogWrite(). With the PWM mode we can transform the 5V output into a
range of 255 possible levels. Instead of going from 0V to 5V in one instance it goes from 0V to 5V
in 255 steps.
analogWrite(pin, value); //writes 'value' to analog 'pin' //value = between 0(off) and 255 (on)
A value of 0 generates a steady 0 volts output at the specified pin; a value of 255 generates a
steady 5 volts output at the specified pin. For values in between 0 and 255, the pin rapidly
alternates between 0 and 5 volts – the higher the value, the more often the pin is HIGH (5 volts).
For example, a value of 64 will be 0 volts three-quarters of the time, and 5 volts one quarter of
the time; a value of 128 will be at 0 half the time; and a value of 192 will be 0 volts one quarter of
the time and 5 volts three-quarters of the time.
TechFactors Copyright 2020
Lesson 5: Mixing Colors Using RGB Module
Elaborate
By mixing and adjusting the intensity of Red, Green, and Blue light, different colors
can be produced through the RGB module. Our knowledge in producing different colors
with different intensities can be used in lighting and can be beneficial to our lives.
1. RGB lighting is great for performance lighting. It’s bright, beautiful and
enticing. It can be placed in the kitchen and laundry room simply for the
presence of color. They’re also great in a kid’s playroom or bedroom for
accent lighting.
2. Working as mood lighting, RGB lights are great for relaxation in a bedroom.
For example, the emission of green light is said to bring the sense of serenity
and low stress of calmness while blue light offers the feeling of calmness and
blue rooms makes people more productive.
TechFactors Copyright 2020
Lesson 5: Mixing Colors Using RGB Module
Elaborate
3. An article on Well + Good (https://www.wellandgood.com/good-looks/color-
bathing-led-lights-in-the-shower/) covers the benefits of having colored LEDs in
the shower. It says they are “emotionally therapeutic and potentially beneficial
to your skin.” They’re explained to have anti-inflammatory and antibacterial
effects. This reason alone sounds good enough! Green light supposedly
reduces tension while pink is great for drawing in the feeling of love.
4. You would think since RGB lighting is so vibrant and strong that they would
emit a lot of heat. Well, you’d be surprised to know that it’s actually the
opposite. LEDs use less energy, so naturally emit less heat (and are cheaper!)
There’s always a benefit of knowing you’re saving money and resources.
Evaluate
Changing Random Colors
Materials
Microcontroller
USB Cable
Jumper Wire
Breadboard
3 pc. 220Ω Resistors
1 pc. RGB Module
Create a code that will display random colors for every 30 seconds with ten
(10) repetition.
Evaluate
Changing Random Colors
Key in the code for changing random colors
Evaluate
Changing Color Spectrum
Materials
Microcontroller
USB Cable
Jumper Wire
Breadboard
3 pcs. 220 Ohms Resistor
1 pc. RGB Module
Evaluate
Changing Color Spectrum
Key in the code for a changing random colors with different intensity
Additional Assessment
Target Outcomes
Engage
Engage
A seven-segment display
(SSD), or seven-segment indicator,
is a form of electronic display
device for displaying decimal
numerals.
Explore
Explore
Explain
Explore
Enrichment Activity
Activity: Displaying Same Numbers in 4 Digital Tube
Materials
Microcontroller
USB Cable
Jumper Wire
Breadboard
4 pc. 220Ω Resistors
1 pc. 4 Digital Tube
Evaluate
Key in the code for the assigned numbers/letters in a 4 digital tube.
Additional Assessment
Target Outcomes
Determine the correct code to produce numbers and letters in a 4
digital
tube; and
Explore
Discussion of the KWL Chart:
Explain
4 digital tubes are widely used in digital clocks, electronic meters, basic
calculators, and other electronic devices that display numerical information.
Elaborate
Activity 1: Type a Number to Display
Materials
Microcontroller
Breadboard
USB Cable
4 pcs. 220 Ohms Resistors
Jumper Wire
1 pc 4 Digital Tube
Elaborate
Activity 1: Type a Number to Display
Procedure:
1. Each group must form a circle.
2. Prepare your 4 digital tube.
3. Your teacher will ask questions. Display your answer using your 4 digital
tube.
4. The first group to give the correct answer will get the corresponding
score.
5. The group with the highest accumulated score will get 30 points, the
second
highest will get 25 points followed by 20, 15, and 10 points.
TechFactors Copyright 2020
Lesson 7: Working with 4 Digital Tube
Elaborate
Answer the following questions using your 4 digital tube:
1. Ten apples was divided by five children. How many apples will each child
have?
Evaluate
Using your 4 digital tube, code a two/three/four letter word. Write
the code on the space provided then share it with the class.
Additional Assessment
Solve the following math equations using your 4 digital tube:
1. 378 x 24 = ?
2. 89 x 51 - 706 = ?
2. 89 x 51 - 706 = 3833
Target Outcomes
Engage
Explain
Explain
Explain
Explain
Parts of LDR
Explain
Target Outcomes
Engage
Modified True or False: Write TRUE if the statement is true. If
FALSE, change the underlined word to make the statement correct.
1. FALSE, Resistor
2. TRUE
3. TRUE
4. FALSE, light
5. FALSE, decreases
Explore
Activity 1: LDR as a Light Sensor
Materials
Microcontroller
USB Cable
Jumper Wire
Breadboard
1 pc. 220Ω Resistors
1 pc. LDR Sensor
1 pc. LED (Any Color)
Explore
1. What happens to the LED when the level of light that hits the
surface of the LDR decreases?
2. What happens to the LED when the level of light that hits the
surface of the LDR increases?
3. How will you describe the relationship between the amount of light
that hits the LDR to resistance based on LED’s response?
Explain
A Light Dependent Resistor may turn on and off when light changes its
intensity. Thus, it may be used as a light sensor. An LDR may also be used as a
switch according to the ambient light.
Light Sensors are photoelectric devices that convert light energy (photons)
whether visible or infra-red light into an electrical (electrons) signal.
Explain
Explain
Explain
int inPin = AO; //Pin the sensor is connected to
int sensorVal = 0; //Variable to store sensor data
void setup () {
Serial.begin(9600);
Serial.println("Serial Communication started... \n");
}
void loop () {
sensorVal = analogRead(inPin);
//analogRead will read the voltage on the pin specified and return it as a value between 0 and 1024.
Serial.printin(sensorVal);
//Print the sensor reading to the serial window so we can view the data.
}
TechFactors Copyright 2020
Lesson 9: Working with LDR
Explain
Evaluate
Activity 2: LDR Sensor with LED (Light Level Sensor)
Materials
Microcontroller
Jumper Wire
Breadboard
5 pcs. 220Ω Resistors
4 pcs. LED (Any Color)
1 pc. LDR Sensor
Procedure
1. Form a group with ___ members.
2. Follow the setup in the schematic and key in the code for this activity.
TechFactors Copyright 2020
Lesson 9: Working with LDR
Additional Assessment
Write something about what you have learned from the differences
in LDR when there is light and when there is none.
Write something about what you have learned from the differences
in LDR when there is light and when there is none.
Target Outcomes
Engage
Explore
Target Outcomes
Create a combined project using the RGB with Buzzer and the
LDR with Buzzer.
Engage
Explore
Complete Turn Taking Activity
1. Have the entire class arrange themselves by group.
2. One student reads a question aloud. The student to their left then
has one minute of uninterrupted time to speak and give their thoughts.
This person signals that they are done speaking by saying, “OK, I’m
done.”
3. The next person to the left goes, has one minute of uninterrupted
time to speak, and signals they are done by saying, “OK I’m done.”
Finally, the third student to the left goes, following the same pattern.
4. After three people have had a chance to speak, the conversation is
opened up to the whole group for two minutes of discussion.
The next student gets to ask a question, and this cycle continues.
TechFactors Copyright 2020
Lesson 11: Combination Project: RGB + Buzzer + LDR
Explain
The LDR may act as a switch for the buzzer in which the presence
of light will act as a sensor for the buzzer to turn ON or OFF.
Explain
Explain
Elaborate
Applications of LDRs
Lighting switch
The most obvious application for an LDR is to automatically turn on a
light at a certain light level. An example of this could be a streetlight or a
garden light.
Elaborate
Activity 1: RGB Module with Buzzer (Alarm System Red +
Green)
Materials
Microcontroller
USB Cable
Jumper Wire
Breadboard
4 pcs. 220Ω Resistors
1 pc. RGB Module
1 pc. Buzzer
Evaluate
Activity 2: LDR with Buzzer (Light Identifier)
Materials
Microcontroller
USB Cable
Jumper Wire
Breadboard
4 pcs. 220Ω Resistors
1 pc. Buzzer
1 pc. LED (Any Color)
void loop() {
Evaluate – Answer Keys int ldrStatus = analogRead(ldrpin);
// check if the ldr status is <=300
int buzzer= 2; //if it is , the LED is HIGH
int ledpin = 5; if (ldrStatus <=300) {
int ldrpin = A0; digitalWrite(ledpin, HIGH); //turn LED on
digitalWrite(buzzer, LOW); // NO Sound
void setup() { Serial.println("LDR is DARK, LED is ON");
pinMode(ledpin, OUTPUT); }
pinMode(buzzer, OUTPUT); else {
pinMode(ldrpin, INPUT); digitalWrite(ledpin, LOW); //turn LED off
digitalWrite(buzzer, HIGH); //produce sound
Serial.begin(9600);
Serial.println("--LED OFF—SOUND ON--");
// set baud rate at “9600”
}
} }
Additional Assessment
Target Outcomes
Recall the codes and commands about LDR and LED to be able to
create a combined project using the LDR + LED + buzzer.
Engage
Kapitang Kulay
Explore
Explore
Write down the steps in creating a project using LDR+LED+Buzzer
based on the pictures.
1. 2.
Explore
Write down the steps in creating a project using LDR+LED+Buzzer
based on the pictures.
3. 4.
Explain
The LDR can act as a light sensor in the project; when light shines
on the LDR, the buzzer will alarm and the led will start flashing.
Elaborate
Evaluate
Activity 1: LDR with Buzzer (Light Identifier)
Materials
Microcontroller
USB Cable
Jumper Wire
Breadboard
4 pcs. 220Ω Resistors
1 pc. Buzzer
5 pcs. LED (Any Color)
Additional Assessment
Create a program that will make a siren-like circuit. The lights will
alternatively blink while the buzzer will produce a sound with different
intensities.
Create a program that will make a siren-like circuit. The lights will
alternatively blink while the buzzer will produce a sound with different
intensities.
Target Outcomes
Engage
Activity 1: Recall the previous lesson about digital tube by
completing the table below.
Explore
Describe me!
Explain
Schematic Symbol of a
Potentiometer TechFactors Copyright 2020
Lesson 13: Combination Project: 4 Digital Tube + Potentiometer
Explain
Elaborate
Evaluate
Activity 1: Adding Number with Potentiometer Control
Materials
Microcontroller
USB Cable
Jumper Wire
Breadboard
4 pc. 220Ω Resistors
1 pc. 4 Digital Tube
Potentiometer
displayNumber(val); case 4:
Lesson 13: Combination Project: 4 Digital Tube + Potentiometer
digitalWrite(segC,
Evaluate – Answer Keys SEGMENT_OFF);
digitalWrite(segD, SEGMENT_ON);
digitalWrite(segF, SEGMENT_ON); digitalWrite(segE, SEGMENT_ON);
digitalWrite(segG, SEGMENT_OFF); digitalWrite(segF,
break; SEGMENT_OFF);
case 1: digitalWrite(segG, SEGMENT_ON);
digitalWrite(segA, SEGMENT_OFF); break;
digitalWrite(segB, SEGMENT_ON); case 3:
digitalWrite(segC, SEGMENT_ON); digitalWrite(segA, SEGMENT_ON);
digitalWrite(segD, SEGMENT_OFF); digitalWrite(segB, SEGMENT_ON);
digitalWrite(segE, SEGMENT_OFF); digitalWrite(segC, SEGMENT_ON);
digitalWrite(segF, SEGMENT_OFF); digitalWrite(segD, SEGMENT_ON);
digitalWrite(segG, SEGMENT_OFF); digitalWrite(segE,
break; SEGMENT_OFF);
case 2: digitalWrite(segF,
digitalWrite(segA, SEGMENT_ON); SEGMENT_OFF);
digitalWrite(segB, SEGMENT_ON); digitalWrite(segG, SEGMENT_ON);
break;
TechFactors Copyright 2020
case 4:
Lesson 13: Combination Project: 4 Digital Tube + Potentiometer
case 6:
Evaluate – Answer Keys digitalWrite(segA, SEGMENT_ON);
digitalWrite(segB,
digitalWrite(segC, SEGMENT_ON); SEGMENT_OFF);
digitalWrite(segD, SEGMENT_OFF); digitalWrite(segC, SEGMENT_ON);
digitalWrite(segE, SEGMENT_OFF); digitalWrite(segD, SEGMENT_ON);
digitalWrite(segF, SEGMENT_ON); digitalWrite(segE, SEGMENT_ON);
digitalWrite(segG, SEGMENT_ON); digitalWrite(segF, SEGMENT_ON);
break; digitalWrite(segG, SEGMENT_ON);
case 5: break;
digitalWrite(segA, SEGMENT_ON); case 7:
digitalWrite(segB, SEGMENT_OFF); digitalWrite(segA, SEGMENT_ON);
digitalWrite(segC, SEGMENT_ON); digitalWrite(segB, SEGMENT_ON);
digitalWrite(segD, SEGMENT_ON); digitalWrite(segC, SEGMENT_ON);
digitalWrite(segE, SEGMENT_OFF); digitalWrite(segD,
digitalWrite(segF, SEGMENT_ON); SEGMENT_OFF);
digitalWrite(segG, SEGMENT_ON); digitalWrite(segE,
break; SEGMENT_OFF);
digitalWrite(segF,
TechFactors Copyright 2020
SEGMENT_OFF);
Lesson 13: Combination Project: 4 Digital Tube + Potentiometer
SEGMENT_OFF);
Lesson 13: Combination Project: 4 Digital Tube + Potentiometer
Additional Assessment
Target Outcomes
Engage
Pictionary
Explore
Explore
Explore
The basic parts of a tilt switch:
Explore
Explain
The Uses and Applications of Tilt Switch
Roll Sensing
Explain
The Uses and Applications of Tilt Switch
Automotive Uses
Explain
The Uses and Applications of Tilt Switch
Fall Alarm
Explain
The Uses and Applications of Tilt Switch
Air Craft
Explain
The Uses and Applications of Tilt Switch
Thermostat
Explain
The Uses and Applications of Tilt Switch
Doorbells
Explain
The Uses and Applications of Tilt Switch
Vending Machines
Explain
The Uses and Applications of Tilt Switch
Bombs
Elaborate
To what fields can you apply the concept of tilt switch? How tilt
switches can be used in the following fields?
Evaluate
Activity 1: Enumerate the uses, features and safety measures in
handling a tilt or mercury switch. Use the image below as your guide.
Features and Safety Measures in
Structure of Tilt Handling Tilt
Switch Switch
Evaluate
Activity 2: Answer the given questions:
Additional Assessment
Describe each part of a tilt switch:
Target Outcomes
Engage
The Mystery Word
1. ATAAIAALAAT ASAAAWAAIAATACAAAH
2. QQQLQQQEQQAQQQD
3. MAIACAARAAOACAAOAANATRAOALAALAAEAARA
4. QQAQRQQDQQQUQQIQQQNQQO
2. QQQLQQQEQQAQQQD
3. MAIACAARAAOACAAOAANATRAOALAALAAEAARA
4. QQAQRQQDQQQUQQIQQQNQQO
Explore
Explain
Elaborate
Draw a simple circuit. Apply the concept of tilt switch in your
illustrated circuit and explain your work.
Evaluate
Activity 1: Tilt Switch with LED
Materials
Microcontroller
USB Cable
Jumper Wire
Breadboard
2 pcs. 220Ω Resistors
1 PC Tilt switch
LED
void loop() {
if (digitalRead(tpin) == true) {
digitalWrite(led, HIGH);
Additional Assessment
Target Outcomes
Engage
Explore
Servo Library
attach() - Attach the Servo variable to a pin.
write() - Writes a value to the servo, controlling the shaft
accordingly.
writeMicroseconds() - Writes a value in microseconds (uS) to
the servo, controlling the shaft accordingly.
read() - Read the current angle of the servo (the value passed
to the last call to write().
attached() - Check whether the Servo variable is attached to a
pin.
detach() - Detach the Servo variable from its pin. TechFactors Copyright 2020
Lesson 16: Managing and Adding Library
Explore
SD Library
exists() - Tests whether a file or directory exists on the SD card.
mkdir() - Create a directory on the SD card.
Explain
Libraries are a collection of code that makes it easy for you to connect to a
sensor, display, module, etc.
It allows you to call functions that are already written. For example, the
Stepper Motor library contains all of the raw code to access the hardware, all
you need to do is initialize it and call the functions. A library does all the heavy
lifting so you can use your modules quickly and easily.
Through the use of libraries, the Arduino can be extended just like most
programming platforms. It provides extra functionality for use in working with
hardware or manipulating data.
TechFactors Copyright 2020
Lesson 16: Managing and Adding Library
Elaborate
Steps on How to Locate the Liquid Crystal Library
1. On the tool bar, navigate Sketch then click Include Library Menu.
Elaborate
Steps on How to Locate the Liquid Crystal Library
2. Click on Manage Library then choose Library Manager and the
following window will appear:
Elaborate
Steps on How to Locate the Liquid Crystal Library
You can then search by keyword for a library. For an example searched
for Stepper Motor. Once located it will now install into the library of your
Arduino directory and once it is all install completely into your Arduino directory
you can use it any time.
Elaborate
Another Steps on How to Locate the Liquid Crystal Library
1. On the tool bar navigate Sketch click Include Library then
choose Add .zip Library.
Elaborate
Another Steps on How to Locate the Liquid Crystal Library
2. Locate and select the .zip File that will be added to the
Arduino Directory and then click Open.
Elaborate
Another Steps on How to Locate the Liquid Crystal Library
3. Once done go to File click Example Menu then locate the
Added zip file you included.
Evaluate
Activity: LCD Display
Materials
Microcontroller
USB Cable
Jumper Wire
Breadboard
1 pc. 220Ω Resistors
1 pc. Potentiometer
1 pc. 1602 LCD
}
Lesson 16: Managing and Adding Library
Evaluate
Complete the table by keying in the correct code for the given
emoticons.
Additional Assessment
Write an essay about each function of the SD Library and the Servo
Library.
Write an essay about each function of the SD Library and the Servo
Library.
Target Outcomes
Engage
Explain
Explain
Elaborate
The LCD Pinout Pin Symb Name Function
No. ol
Evaluate
Activity 1: LCD Display (Hello World!)
Materials
Microcontroller
USB Cable
Jumper Wire
Breadboard
1 pc. 220Ω Resistors
1 pc. Potentiometer
1 pc. 1602 LCD
How does the 1602 LCD differ from the LCD of the televisions,
projectors, and modern mobile phones?
Additional Assessment
Using a 1602 LCD, create a program that will (1) show your first
name, (2) last name, and (3) your age.
Using a 1602 LCD, create a program that will (1) show your first
name, (2) last name, and (3) your age.
Target Outcomes
Engage
Explore
Activity:
Materials:
I2C LCD adapter module
LCD display 16x2
Arduino Uno
Arduino IDE
Procedure: Make a connection from the LCD module to the Arduino board.
Set the hardware connections using the I2C adapter module. Connect the I2C
LCD adapter to LCD display by simply soldering the I2C adapter as shown in the
image. Then, connect the adapter to Uno as follows: Vcc to 5V, Gnd to Gnd, SDA
to A4, SCL to A5. TechFactors Copyright 2020
Lesson 18: LCD Display and the IIC I2C Adapter Module
Explore
What do you think is the main function of the I2C adapter module?
What do you noticed about the connections between Arduino and its LCD
display when using the I2C Module? Compare the number of connections in
normal LCD display and I2C LCD display.
Explain
When the I2C adapter module is not present, the connection should
be from the LCD module to the Arduino board. With I2C adapter
module, the LCD Module and Arduino should be connected through the
I2C Module.
Explain
Explain
Elaborate
Make a comparison on the circuit connections when we wire up the
LCD to Arduino without the I2C adapter and with the adapter.
Evaluate
Activity 1: LCD Display (Hello World!)
Materials
Microcontroller
USB Cable
Jumper Wire
Breadboard
1 pc. 1602 LCD with IIC
I2C Adapter Module
void setup() {
lcd.init(); //initialize the lcd
lcd.backlight(); //open backlight
lcd.print(" Hello World! "); //words will display at first line
lcd.setCursor (0, 1);
lcd.print(" welcome "); //words will display second line
delay(2000);
}
Evaluate
Activity 2: Answer the given question.
How does 1602 LCD with IIC I2C Adapter Module differ from the
LCD of the televisions, projectors, and modern mobile phones?
How does 1602 LCD with IIC I2C Adapter Module differ from the
LCD of the televisions, projectors, and modern mobile phones?
It uses the PCF8574T IC chip which converts I2C serial
data to parallel data for the LCD display.
Additional Assessment
Using the 1602 LCD with IIC I2C Adapter Module, create a program
that will show and replace “world” in “Hello world” with your pet’s
name.
Using the 1602 LCD with IIC I2C Adapter Module, create a program
that will show and replace “world” in “Hello world” with your pet’s
name.
Target Outcomes
Engage
Explore
Activity: Build Circuit
Materials
Microcontroller
USB Cable
Jumper Wire
Breadboard
Arduino IDE
1 pc. 1602 LCD with IIC
I2C Adapter Module
Explore
Activity: Build Circuit
The Code
Explain
Elaborate
Extra Functions
These are almost all of the current methods that you’re able to
call for the Arduino LCD display:
Auto-scroll: Shift text right and left.
autoscroll(); This will move the text one space to the left
whenever a new character is added.
noAutoscroll(); Turns off auto scrolling.
Cursor: This allows you to turn off and on the underscore
cursor.
noCursor(); Turns off the underscore cursor.
Cursor(); Turns on the underscore cursor. TechFactors Copyright 2020
Lesson 19: Making the LCD Characters Move
Elaborate
Extra Functions
Blink: Turns on and off the blinking of the block cursor.
noBlink(); Turns off the blinking cursor.
blink(); Turns on the blinking cursor.
Display: Make the display go blank without losing the current
text.
noDisplay(); Turns off the display.
display(); Turns on the display.
Scroll: Allows you to scroll the text both left and right.
scrollDisplayLeft(); Will scroll one position to the left.
scrollDisplayRight(); Will scroll one position to the right.
TechFactors Copyright 2020
Lesson 19: Making the LCD Characters Move
Elaborate
Extra Functions
Serial Display: You can print the text sent through the serial port on
the screen.
write(Serial.read());
Set Cursor: Sets the cursor to a specific position. (Location, Line)
setCursor(0, 0); Will set the cursor to be at the top left.
setCursor(15, 1); Will set the cursor to be at the bottom right.
Text Direction: Allows you to tell which way the text should flow from
the
cursor.
rightToLeft(); Forces the text to flow from the left of the cursor.
leftToRight(); Forces the text to flow from the right of the cursor.
TechFactors Copyright 2020
Lesson 19: Making the LCD Characters Move
Evaluate
Activity 1: LCD Display (Serial Display)
Materials
Microcontroller
USB Cable
Jumper Wire
Breadboard
1 pc. 1602 LCD with IIC
I2C Adapter Module
Evaluate
Activity 2: LCD Display (Scroll Display)
Materials
Microcontroller
USB Cable
Jumper Wire
Breadboard
1 pc. 1602 LCD with IIC
I2C Adapter Module
Additional Assessment
Target Outcomes
Engage
Activity: Staring Contest
Explore
Study the other functions (Blink, cursor and display function) of the Liquid
Crystal I2C library below. Then try displaying your own name in the LCD. Apply
the following concepts for your work.
#include
<LiquidCrystal_I2C.h> void loop() {
Cursor lcd.cursor();
LiquidCrystal_I2C
cursor(); Displays the LCD lcd(0x27,20,4); delay(500);
cursor: an underscore (line) at the //Change to (0x27,16,2) for
position of the next character to be 16x2 LCD. lcd.noCursor();
delay(500);
printed. }
void setup() {
noCursor(); Hides the LCD cursor. lcd.init();
The following example creates a blinking lcd.backlight();
cursor at the end of “Hello World!”. lcd.print("Hello
World!");
TechFactors Copyright 2020
}
Lesson 20: Project: Disappearing Display
Explain
Elaborate
Activity:
Evaluate
Activity 1: LCD Display (Blink and Line Cursor!)
Materials
Microcontroller
USB Cable
Jumper Wire
Breadboard
1 pc. 220Ω Resistors
1 pc. Potentiometer
1 pc. 1602 LCD
Evaluate
Activity 2: LCD Display (Display _ No Display Text)
Material
Microcontroller
USB Cable
Jumper Wire
Breadboard
1 pc. 220Ω Resistors
1 pc. Potentiometer
1 pc. 1602 LCD
Additional Assessment
a. Cursor
b. Blink
c. Display
Target Outcomes
Engage
Explore
Inside the RGB led, there are three more LED’s. So by changing the
brightness of these LED’s, we can obtain many other colors. To change
brightness of RGB LED, we can use the PWM pins of Arduino. The PWM
pins will give signal different duty cycles to the RGB LED to obtain
different colors.
Explore
Activity 1:
Students will set up in the circuit
diagram and program or key in the code
for this activity. Students will configure
various colors by playing with different
values. Let students configure colors
generated from combined PWM values on
the 3 LEDs. They will adjust the RGB LED to
change to different colors by assigning different
values of brightness levels to 3 primary colors
using the function analogWrite(value).
Explore
Activity 1:
COLOR RED GREEN BLUE
RED
GREEN
BLUE
YELLOW
ORANGE
VIOLET
RASPBERRY
TURQUOISE
WHITE
TechFactors Copyright 2020
Lesson 21: Combination Project: RGB Module + LCD Display
Explore
Explain
An RGB LED is basically three LEDs’
in one. It has 4 leads, the red, green, blue
LED and the long lead in which all three LEDs
are connected through the same pin is the
common ground. The color can be controlled
based on the voltages you write to the different
control pins, they make a mixture and produce
several thousands of colors.
Explain
Two Types of RGB LEDS
Anode RGB LEDs -In a common anode RGB LED, the three
LEDs share a positive connection.
Common cathode RGB LEDs - all three LEDs share a
negative connection.
Elaborate
Elaborate
Activity: In Between Colors
Using the same group of students, try the “in between colors”.
try mixing colors play around with a program that will independently
turn on and achieving the following colors. Program the Arduino and
RGB LED to display even more colors.
Cyan
Magenta
Yellow
Orange
Purple
TechFactors Copyright 2020
Lesson 21: Combination Project: RGB Module + LCD Display
Evaluate
Activity 1: RGB Module with LCD Display (Tri – Color Display)
Materials
Microcontroller
USB Cable
Jumper Wire
Breadboard
4 pcs. 220Ω Resistors
1 pc. Potentiometer
1 pc. 1602 LCD
1 pc. RGB Module
Additional Assessment
Explain and write in a sheet of paper what is RGB and its two types.
Explain and write in a sheet of paper what is RGB and its two types.
Target Outcomes
Engage
1. What are tilt sensors?
5. If tilt switch are used with LEDs, what is the main function of a tilt switch?
5. If tilt switch are used with LEDs, what is the main function of a tilt switch?
Explore
Think-Pair-Share.
What factors influence the functionality of tilt sensors?
Enumerate and explain its specification.
Explore
Think-Pair-Share.
Enumerate the different key applications of a tilt sensors
Explore
Think-Pair-Share.
Explain
Explain
Elaborate
Activity:
Evaluate
Activity 1: Tilt Switch with LCD Display
Materials
Microcontroller
USB Cable
Jumper Wire
Breadboard
1 pc. 220Ω Resistor
1 pc. Tilt Switch
1 pc. I2C with LCD 1602
Additional Assessment
Create a program using tilt switch that when you switch on, the
LCD will show a happy reaction and when you switch off, the LCD will
show a sad reaction.
Create a program using tilt switch that when you switch on, the
LCD will show a happy reaction and when you switch off, the LCD will
show a sad reaction.
Target Outcomes
Engage
Activity 1
Solve the following to reveal words that you might encounter
during the lesson.
1. Microscope – scope + contact – act + roller =
Engage
Activity 2: Bring Me
Explain
Activity 3:
Elaborate
Evaluate
Activity 1: LCD Display with LED Light
Materials
Microcontroller
USB Cable
Jumper Wire
Breadboard
2 pcs. 220Ω Resistors
1 pc. I2C with LCD 1602
2 pcs. LED (Red and Green)
Additional Assessment
Target Outcomes
Create a project that can count number per digit with tic sound
and flashing light
Engage
Pass Me The Box
Explore
Our Project
Explain
Elaborate
How will you relate the lesson about combination project using 4
digital tube, LED, and buzzer in digital counter?
Evaluate
Activity 1: Counting Number per Digit with TIC Sound and
Flashing Light
Materials
Microcontroller
USB Cable
Jumper Wire
Breadboard
5 pc. 220Ω Resistors
1 pc. 4 Digital Tube
1 pc. Passive buzzer
1 pc. LED (Any Color)
TechFactors Copyright 2020
Lesson 24: Combination Project: Buzzer + 4 Digital Tube + LED
} digitalWrite(g, LOW);
Lesson 24: Combination Project: Buzzer + 4 Digital Tube + LED
void five() {
//the 7-segment led display
Evaluate – Answer Keys
digitalWrite(c, HIGH);
5
digitalWrite(a, HIGH);
digitalWrite(d, HIGH); digitalWrite(b, LOW);
void two() { digitalWrite(e, LOW); digitalWrite(c, HIGH);
//the 7-segment led display 2 digitalWrite(f, LOW); digitalWrite(d, HIGH);
digitalWrite(a, HIGH); digitalWrite(g, HIGH); digitalWrite(e, LOW);
digitalWrite(b, HIGH); } digitalWrite(f, HIGH);
digitalWrite(c, LOW);
digitalWrite(g, HIGH);
digitalWrite(d, HIGH); void four() { }
digitalWrite(e, HIGH); //the 7-segment led display
digitalWrite(f, LOW); 4 void six() {
digitalWrite(g, HIGH); digitalWrite(a, LOW); //the 7-segment led display
} digitalWrite(b, HIGH); 6
digitalWrite(c, HIGH); digitalWrite(a, HIGH);
void three() { digitalWrite(d, LOW); digitalWrite(b, LOW);
//the 7-segment led display 3 digitalWrite(e, LOW); digitalWrite(c, HIGH);
digitalWrite(a, HIGH); digitalWrite(f, HIGH); digitalWrite(d, HIGH);
digitalWrite(b, HIGH); digitalWrite(g, HIGH); digitalWrite(e, HIGH);
} digitalWrite(f, HIGH);
TechFactors Copyright 2020
digitalWrite(g, HIGH);
Lesson 24: Combination Project: Buzzer + 4 Digital Tube + LED
Additional Assessment
a. Buzzer
b. 4 Digital Tube
c. LED