Video summary
Módulo 1: Arduinos e Sensores
Main summary
Key takeaways
Main ideas and lessons
-
Course kickoff + maker mindset
- The instructor (Yor Estev Sacano Ferreira) welcomes viewers to the “Arduino e Sensores” course/module and encourages participation in the maker community.
- The focus is practical motivation: using electronics and 3D printing to build real devices (example: a 3D-printed cup holder used on his own machine).
- Emphasizes learning for life, not memorization.
-
What an Arduino is and why it matters
- An Arduino is a microcontroller (a mini-computer) used in automation and robotics/home automation.
- Example board mentioned: Arduino Mega.
- Arduino uses pins to connect and control electronics.
- The maker workflow integrates Arduino + sensors + 3D-printed enclosures.
-
“Shield” concept (expansion boards)
- A shield plugs into the Arduino pins and provides pre-wired electronics for specific project types.
- Benefits: saves space, time, and materials.
- Mentions module vs. shield integration and gives ESP8266 as an example (including the idea of an ESP shield).
-
Tinkercad as the development/simulation environment
- Tinkercad is used to create circuits and run simulations.
- Encourages meaningful project naming (e.g., “maker course module 1”).
-
Arduino I/O fundamentals
- Power pins: examples include 3.3V, 5V, GND.
- Vin: described as an input concept (voltage entering the system).
- Digital vs Analog
- Digital: binary values (0/1) for on/off-like behavior.
- Analog: sensor readings that produce numeric ranges.
- PWM
- A special output type using a range 0 to 255, often used for motor control/speed.
- Serial communication ports
- RX/TX are for data transmission/reception between devices—not typical sensor input signals.
-
Building a first LED project
- Components:
- an LED (any color)
- a resistor to prevent burnout by limiting voltage/current
- LED polarity (conceptual):
- anode (positive) and cathode (negative)
- Simulation behavior:
- Turning the LED on/off correctly
- What happens without a resistor (overcurrent leads to burning in simulation)
- Basic programming flow:
- “beginning” and “forever” (loop concept)
- “Hello World” in the Serial Monitor as a programming ritual
- Components:
-
Timing and blinking
- Without delays, toggling is too fast because the loop runs quickly, causing flickering.
- Correct approach for blinking:
- set HIGH → wait → set LOW → wait
-
Multi-LED logic + traffic light challenge
- Build a traffic light using LEDs connected to different pins:
- red, yellow, green
- Timing rules:
- 5 seconds red
- 3 seconds green
- 2 seconds yellow
- Logic ensures only one LED is HIGH during each phase while others are forced LOW.
- Build a traffic light using LEDs connected to different pins:
-
Sensor integration: soil moisture sensor
- Add a soil moisture sensor and connect:
- VCC (positive supply)
- GND (ground)
- signal to an analog input
- Safety warnings:
- Don’t assume VCC is always 5V—it may vary by sensor.
- Avoid reversing pins (sensor can be burned).
- Reading ranges (as observed in simulation):
- discussed as within a range up to about 0 to ~876
- Threshold logic using if / else if:
- If humidity ≥ 800 → green LED ON
- Else if humidity < 300 → red LED ON
- Else → yellow LED ON
- Demonstration:
- “watering” (changing sensor value) and observing LED transitions.
- Add a soil moisture sensor and connect:
-
Adding an interface: I2C LCD display
- Add an I2C 16x2 LCD to display readings.
- I2C wiring concept:
- SDA and SCL, plus VCC and GND
- LCD workflow:
- initialize/configure LCD
- print text (including “Hello World” as baseline)
- use clear screen behavior to prevent overlapping text
- Display:
- show humidity value as sensor changes.
-
Mapping sensor values to percentages (“rule of three”)
- Use a map operation to convert sensor readings to 0–100%.
- Known issue:
- observed sensor max (~876) vs expected mapping range (mentioned input range like 0–1023), so percentages may not perfectly match yet.
- Plan to correct later.
-
User interface improvement: cursor positioning
- Move the LCD cursor to:
- e.g., column 0 row 0 and column 0 row 1
- Use it to print:
- a label like “Mini watering can”
- humidity percentage on the second line.
- Move the LCD cursor to:
-
Automation upgrade: servo motor as an irrigation valve
- Add a servo to act like a plumbing valve.
- Control approach:
- based on humidity thresholds, rotate the servo to open/close
- example: if in red zone (e.g., < 300), rotate to 0° (open valve), then close after the watering logic/timing completes (shown in simulation)
- End result:
- LEDs + LCD monitoring + servo-based irrigation working together.
-
Final explanation of the “raw code” structure
- The simplified blocks correspond to C++-style logic.
- Libraries:
- Arduino uses libraries for components
- LiquidCrystal for the LCD
- Servo for the servo motor (noting library considerations for ESP32 vs standard servo due to voltage differences)
- Key Arduino elements mentioned:
#include(libraries)- variables/objects for LCD and servo
pinModefor input/output setupSerial.begin(...)for Serial Monitor speed- output control using
digitalWrite(HIGH/LOW) - timing using
delay(milliseconds)inside the repeatingforeverloop.
-
Preview of next module
- Next classes cover IoT concepts and platforms like ESP8266 and ESP32.
- Mentions tutoring availability and a poll about tutoring timing.
Methodology / step-by-step instructions presented
A) Set up Tinkercad project and circuit
- Open Tinkercad.
- Create a new project:
- Click Create (top-right).
- Choose an Arduino board (Arduino Uno used in the example).
- Name the project meaningfully (e.g., “maker course module 1”).
- Use simulation controls:
- Start simulation
- Stop simulation
B) Build the first LED circuit safely
- Add:
- Arduino pin connection plan
- LED (any color)
- resistor in series with the LED
- Wire it:
- LED anode → Arduino digital output (via proper connection)
- LED cathode → GND
- Run the simulation and confirm LED on/off.
- Do not connect the LED directly without a resistor (simulation shows overcurrent burning).
C) Write first program concepts: Hello World + loop model
- Use Tinkercad blocks:
- setup/beginning block (runs once)
- forever block (repeats continuously)
- Print to Serial Monitor:
- “Hello World” with a new line
- Start simulation and verify “Hello World” appears.
D) Implement blinking with timing (avoiding too-fast toggling)
- In the loop:
- set LED HIGH
- wait (e.g., 1 second)
- set LED LOW
- wait (e.g., 1 second)
- Result: visible blinking instead of flicker.
E) Traffic light logic (multi-LED timed sequence)
- Add three LEDs (red/yellow/green) and at least one resistor (reused/copied).
- Assign pins:
- red → one digital pin
- green → another digital pin
- yellow → another digital pin
- Loop phases:
- Phase 1 (red): red HIGH, green LOW, yellow LOW → wait 5 seconds
- Phase 2 (green): green HIGH, others LOW → wait 3 seconds
- Phase 3 (yellow): yellow HIGH, others LOW → wait 2 seconds
F) Add and use soil moisture sensor (analog input)
- Place a soil moisture sensor component.
- Connect pins:
- VCC → appropriate supply (often 5V mentioned, but varies by sensor)
- GND → ground
- Signal → analog input A0
- Create variables (e.g.,
humiditySensor = 0). - Read analog values from A0.
- Use threshold logic:
- If humidity ≥ 800 → green LED HIGH
- Else if humidity < 300 → red LED HIGH
- Else → yellow LED HIGH
- Test by changing wet/dry in simulation and observing LED transitions.
G) Add I2C LCD (interface display)
- Place an I2C 16x2 LCD component.
- Connect I2C lines:
- SDA → SDA
- SCL → SCL
- plus VCC and GND
- Initialize LCD in code blocks (LCD type/address options depend on the tool’s variant).
- Print:
- start with a baseline “Hello World”
- then sensor-derived values repeatedly
- Avoid overlap:
- use LCD clear after delays (e.g., ~every 2 seconds).
- Display humidity values on screen.
H) Map sensor reading to a percentage (rule of three)
- Use a map block:
- input range (e.g., 0–1023 mentioned)
- output range 0–100%
- Print percentage instead of raw values.
- Note:
- if the observed sensor max differs, the mapped percentage may be off (to be corrected later).
I) Improve LCD formatting with cursor position
- Set cursor position:
- column 0, row 0
- then column 0, row 1 for the second line
- Print:
- a label line (e.g., “Mini watering can”)
- humidity percentage underneath
J) Automate irrigation using a servo valve
- Add a servo motor.
- Connect:
- GND → ground
- VCC → servo 5V (stated)
- servo signal/control → a digital pin (example uses pin 2 after correction)
- Define servo behavior:
- if humidity indicates the red zone (e.g., < 300) → rotate to open (e.g., 0°)
- otherwise → keep/close valve according to the project logic
- Simulate and verify:
- watering occurs when the servo opens
- servo closes based on the logic/timing.
Speakers / sources featured (as stated or implied)
- Yor Estev Sacano Ferreira — instructor/host; Federal Institute of Southern Minas Gerais (Campos Machado campus); works in Information Systems.
- Marcos — participant feedback (name appears in subtitles).
- Orlando — participant thanked (subtitles).
- Giovan — participant referenced (subtitles).
- Miguel — participant referenced (subtitles).
- Unnamed YouTube creator — referenced as a channel owner who built a home hydroponics/micropore-style system using a Raspberry Pi-type setup (not named in subtitles).
- Amazon assistant (“Alexa”) reference — mentioned indirectly (via “give a signal” type wording), not as a speaker in the video.