Arduino UNO-Based Smart Power Window with Color Sensor and Servo Control
View and Edit Project In Cirkit Designer
Circuit Documentation
Summary
This document provides a detailed overview of a circuit that includes an Arduino UNO microcontroller, a TCS230 color sensor, a Tower Pro SG90 servo motor, a power window, a 12V battery, and an L298N DC motor driver. The circuit is designed to control a power window using the Arduino UNO, with additional functionalities provided by the TCS230 color sensor and the servo motor.
Component List
Arduino UNO
- Description: A microcontroller board based on the ATmega328P.
- Pins: UNUSED, IOREF, Reset, 3.3V, 5V, GND, Vin, A0, A1, A2, A3, A4, A5, SCL, SDA, AREF, D13, D12, D11, D10, D9, D8, D7, D6, D5, D4, D3, D2, D1, D0
TCS230
- Description: A color sensor that can detect and measure the color of light.
- Pins: GND, OE, S1, S0, VCC, OUT, S2, S3
Tower Pro SG90 Servo
- Description: A small servo motor commonly used in robotics.
- Pins: Signal, +5V, GND
Power Window
- Description: A motorized window mechanism.
- Pins: Neutral, Power
12V Battery
- Description: A power source providing 12V.
- Pins: VCC, GND
L298N DC Motor Driver
- Description: A dual H-Bridge motor driver that allows control of the speed and direction of two DC motors.
- Pins: OUT1, OUT2, 12V, GND, 5V, OUT3, OUT4, 5V-ENA-JMP-I, 5V-ENA-JMP-O, +5V-J1, +5V-J2, ENA, IN1, IN2, IN3, IN4, ENB
Wiring Details
Arduino UNO
- IOREF connected to +5V of Tower Pro SG90 Servo
- 5V connected to VCC of TCS230
- GND connected to GND of TCS230
- GND connected to GND of Tower Pro SG90 Servo
- D11 connected to IN2 of L298N DC Motor Driver
- D10 connected to IN1 of L298N DC Motor Driver
- D8 connected to OUT of TCS230
- D7 connected to S3 of TCS230
- D6 connected to S2 of TCS230
- D5 connected to S1 of TCS230
- D4 connected to S0 of TCS230
- D2 connected to Signal of Tower Pro SG90 Servo
TCS230
- VCC connected to 5V of Arduino UNO
- GND connected to GND of Arduino UNO
- OUT connected to D8 of Arduino UNO
- S3 connected to D7 of Arduino UNO
- S2 connected to D6 of Arduino UNO
- S1 connected to D5 of Arduino UNO
- S0 connected to D4 of Arduino UNO
Tower Pro SG90 Servo
- +5V connected to IOREF of Arduino UNO
- GND connected to GND of Arduino UNO
- Signal connected to D2 of Arduino UNO
Power Window
- Neutral connected to OUT1 of L298N DC Motor Driver
- Power connected to OUT2 of L298N DC Motor Driver
12V Battery
- VCC connected to 12V of L298N DC Motor Driver
- GND connected to GND of L298N DC Motor Driver
L298N DC Motor Driver
- IN2 connected to D11 of Arduino UNO
- IN1 connected to D10 of Arduino UNO
- OUT1 connected to Neutral of Power Window
- OUT2 connected to Power of Power Window
- 12V connected to VCC of 12V Battery
- GND connected to GND of 12V Battery
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:
}
Additional Documentation (documentation.txt)
This document provides a comprehensive overview of the circuit, including the components used, their wiring details, and the code for the Arduino UNO microcontroller.