source of inspiration
I'm working on developing a parking alarm system that uses ultrasonic sensors to detect objects. When an object is detected, the LED lights up, and a buzzer sounds. I'm particularly focused on understanding how to detect the signals and integrate them with the alarm system, as this will be essential for my final project.
Google: For searching and gathering inspiration
YouTube: For searching and gathering inspiration
project hub : inspiration
Tinkercad: A software to design and simulate electronic circuits and code blocks using
Electronic components: include an LED, buzzer, wires, Arduino, transistor, and a breadboard. For coding and implementation
The Arduino IDE versions 2, 3, and 4 will be used for writing and implementing the code for the project.
Components:
Ultrasonic Sensor (input): Detects objects at a distance of 3 cm or less.
LED (output): Emits light when triggered.
Buzzer (out put): Emits sound at a frequency of 150 Hz when triggered.
Arduino: Controls the components based on sensor input.
-Wiring
The ultrasonic sensor is connected to Arduino pins 6 ,7 , GND and 5v , the led is connected to Aruduino pin 13 and GND ,the buzzer is connected to Arudino pin 11 and GND
The code is written and implemented using Tinkercad’s block-based programming interface.
the code blocks :
-If the ultrasonic sensor detects objects at a distance ≤ 3 cm, then
-The LED pin is set to "HIGH", turning the LED on.
-The buzzer pin is set to emit sound at 150 Hz
The system waits for 1 second.,After 1 second:The LED pin is set to "LOW", turning off the LED.,The buzzer pin is set to "0", silencing the buzzer
Breadboard Setup:
Place the Arduino board on surface.
Connect the ultrasonic sensor to the breadboard. Ensure that the VCC and GND pins of the sensor are connected to the power rails on the breadboard.
Connect the TRIG pin of the ultrasonic sensor to pin 6 on the Arduino, and the ECHO pin to pin 7.
Insert the LED into the breadboard, connecting its long leg (anode) to a current-limiting resistor and the other end of the resistor on the Arduino.
Connect the buzzer to pin 11 on the Arduino, ensuring the correct orientation to emit sound.
Wiring:
Use jumper wires to connect the Arduino to the breadboard’s power rails.
Ensure that the ground (GND) of the Arduino is connected to the ground rail on the breadboard.
Check that the sensor and components are correctly placed and wired for power and signal flow.
Programming the Arduino:
Open the Arduino IDE and write the code to control the sensor and outputs. The code will read the ultrasonic sensor, trigger the LED to light up when an object is detected within 3 cm, and sound the buzzer.
Upload the code to the Arduino board by the IDE.
I asked my instructor about my assigmnet idea and he helped me and guide me specially about coding the circiuts
When writing code blocks in Tinkercad, I initially selected the block to set the buzzer to "HIGH." However, upon running and simulating the code, the buzzer did not function as expected. After some troubleshooting, I realized that when I changed the block to set the buzzer pin to a value of 150 (representing a frequency of 150 Hz), the code ran properly, and the buzzer worked as intended. This suggests that the "HIGH" command may not have been sufficient for triggering the buzzer correctly in the simulation, while specifying the frequency allowed it to operate as expected
The skills acquired this week will be valuable for my final project by helping me integrate components like ultrasonic sensors, LEDs, and buzzers with the Arduino. I’ve gained experience in programming with the Arduino IDE, using conditional statements to control outputs, and simulating circuits on Tinkercad for testing. Additionally, I’ve learned to implement time-based actions, which will be essential for managing delays in the system. These skills will help me build a functional, responsive final project.
Smart Waving Hand using Arduino
Capture the Moments
2
Title of Media