Arduino Nano-Based Ultrasonic Distance Measurement System with Audio Alerts
View and Edit Project In Cirkit Designer
Circuit Documentation
Summary
The circuit in question appears to be designed for distance measurement and alerting purposes, utilizing multiple HC-SR04 Ultrasonic Distance Sensors and Piezo Buzzers, all controlled by an Arduino Nano microcontroller. The circuit is powered by a USB power source or a Lipo Battery, as indicated by the electrical net list. The Arduino Nano is responsible for triggering the ultrasonic sensors and processing their echo signals to determine the distance to objects. Depending on the sensor readings, the Piezo Buzzers may be activated to provide an audible alert.
Component List
Microcontroller
- Arduino Nano: A compact microcontroller board based on the ATmega328P, featuring digital and analog I/O pins.
Sensors
- HC-SR04 Ultrasonic Distance Sensor (Wokwi Compatible): These sensors are used to measure distances by emitting ultrasonic waves and measuring the time taken for the echo to return.
Actuators
- Piezo Buzzer: These buzzers can generate sound at different frequencies based on the input signal.
Power Sources
- USB power: Provides power to the circuit through a USB connection.
- Lipo Battery: A rechargeable battery that can also supply power to the circuit.
Miscellaneous
- Comment: Placeholder components that may represent annotations or notes within the circuit design.
Wiring Details
Arduino Nano
- Digital Pins:
- D2, D3, D4, D5, D6, D7, D8, D9: Connected to Piezo Buzzers and HC-SR04 Ultrasonic Distance Sensors for control signals.
- Analog Pins:
- A0, A1, A2, A3: Connected to HC-SR04 Ultrasonic Distance Sensors for receiving echo signals.
- Power Pins:
- 5V: Supplies power to the HC-SR04 Ultrasonic Distance Sensors.
- GND: Common ground for Piezo Buzzers and HC-SR04 Ultrasonic Distance Sensors.
HC-SR04 Ultrasonic Distance Sensors
- VCC: Connected to the 5V output from the Arduino Nano.
- GND: Connected to the ground (GND) on the Arduino Nano.
- TRIG: Connected to various digital pins on the Arduino Nano for triggering the ultrasonic pulse.
- ECHO: Connected to various analog pins on the Arduino Nano to receive the echo signal.
Piezo Buzzers
- pin 1: Connected to various digital pins on the Arduino Nano to control the buzzer sounds.
- pin 2: All buzzers share a common ground connection with the Arduino Nano.
Power Sources
- USB power: The positive and negative terminals are connected to the corresponding terminals of the Lipo Battery.
- Lipo Battery: The VCC and GND are connected to the USB power source for charging or powering the circuit.
Documented Code
Arduino Nano Code (sketch.ino)
void setup() {
// put your setup code here, to run once:
}
void loop() {
// put your main code here, to run repeatedly:
}
This code template provides the basic structure for an Arduino sketch, with setup() and loop() functions defined. The setup() function is intended for initialization code that runs once when the microcontroller is powered on or reset. The loop() function contains the main logic of the program, which runs repeatedly as long as the microcontroller is powered.
Additional Documentation (documentation.txt)
There is no additional code documentation provided for this file.