Arduino UNO Based Distance Measurement and Display System with Alerting Buzzer and Servo Control
View and Edit Project In Cirkit Designer
Circuit Documentation
Summary
This circuit integrates various components with an Arduino UNO microcontroller to create a system capable of interfacing with sensors, actuators, and an I2C LCD display. The system includes an HC-SR04 Ultrasonic Sensor for distance measurement, a buzzer for audio feedback, a Servomotor SG90 for actuation, and an I2C LCD 16x2 Screen for data display. The Arduino UNO serves as the central processing unit, controlling the flow of data and the interaction between the components.
Component List
HC-SR04 Ultrasonic Sensor
- Description: A sensor that measures distance by emitting ultrasonic waves and measuring the time taken for the echo to return.
- Pins: VCC, TRIG, ECHO, GND
Buzzer
- Description: An audio signaling device that can be used to provide audible feedback or alerts.
- Pins: PIN, GND
Arduino UNO
- Description: A microcontroller board based on the ATmega328P, widely used for building digital devices and interactive objects.
- Pins: UNUSED, IOREF, Reset, 3.3V, 5V, GND, Vin, A0-A5, SCL, SDA, AREF, D0-D13
I2C LCD 16x2 Screen
- Description: A liquid crystal display capable of showing 16 characters per line across 2 lines, with an I2C interface for communication.
- Pins: SCL, SDA, VCC (5V), GND, VDD, VO, RS, RW, E, D0-D7, BLA, BLK
Servomotor SG90
- Description: A small and lightweight servo motor capable of precise angular positioning.
- Pins: SIG, VCC, GND
Wiring Details
HC-SR04 Ultrasonic Sensor
- VCC connected to Arduino UNO 5V
- GND connected to Arduino UNO GND
- TRIG connected to Arduino UNO D11 (for one sensor) and D9 (for the other sensor)
- ECHO connected to Arduino UNO D12 (for one sensor) and D10 (for the other sensor)
Buzzer
- PIN connected to Arduino UNO D7
- GND connected to Arduino UNO GND
Arduino UNO
- 5V and GND pins provide power to the other components
- A4 (SDA) and A5 (SCL) are used for I2C communication with the LCD screen
- Digital pins D3, D7, D9, D10, D11, and D12 are used to interface with the servomotor, buzzer, and ultrasonic sensors
I2C LCD 16x2 Screen
- SCL connected to Arduino UNO A5
- SDA connected to Arduino UNO A4
- VCC (5V) connected to Arduino UNO 5V
- GND connected to Arduino UNO GND
Servomotor SG90
- SIG connected to Arduino UNO D3
- VCC connected to Arduino UNO 5V
- GND connected to Arduino UNO GND
Documented Code
Arduino UNO Code (sketch.ino)
void setup() {
// put your setup code here, to run once:
}
void loop() {
// put your main code here, to run repeatedly:
}
Note: The provided code is a template and does not include specific functionality. It should be populated with the logic required to control the components based on the desired application.