Arduino UNO Controlled DC Motor with L298N Driver and 12V Power Supply
View and Edit Project In Cirkit Designer
Circuit Documentation
Summary
This circuit involves an Arduino UNO microcontroller controlling a DC motor through an L298N motor driver. The motor driver is powered by a 12V power supply, which is connected to a 220V AC power source. The Arduino UNO sends control signals to the motor driver to regulate the motor's operation.
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
DC Motor
- Description: A simple DC motor with two connection pins.
- Pins: pin 1, pin 2
L298N DC Motor Driver
- Description: A dual H-Bridge motor driver that allows speed and direction control 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
POWER SUPPLY 12V 5AMP
- Description: A power supply unit that converts 220V AC to 12V DC.
- Pins: 220V Positive Pole (AC), 220V Negative Pole (AC), GND, GND (DC), 12V-24V Output (DC)
Power 220V
- Description: A 220V AC power source.
- Pins: hot wire, neutral wire
Resistor
- Description: A resistor with a resistance of 200 Ohms.
- Pins: pin1, pin2
- Properties: Resistance: 200 Ohms
LED: Two Pin (red)
- Description: A red LED with two connection pins.
- Pins: cathode, anode
Electrolytic Capacitor
- Description: A capacitor with a capacitance of 0.000001 Farads.
- Pins: -, +
- Properties: Capacitance: 0.000001 Farads
Servo
- Description: A servo motor with three connection pins.
- Pins: gnd, vcc, pulse
Wiring Details
Arduino UNO
- Pin D6 is connected to ENA on the L298N DC motor driver.
- Pin D5 is connected to IN1 on the L298N DC motor driver.
- Pin D4 is connected to IN2 on the L298N DC motor driver.
DC Motor
- Pin 1 is connected to OUT4 on the L298N DC motor driver.
- Pin 2 is connected to OUT3 on the L298N DC motor driver.
L298N DC Motor Driver
- Pin ENA is connected to D6 on the Arduino UNO.
- Pin IN1 is connected to D5 on the Arduino UNO.
- Pin IN2 is connected to D4 on the Arduino UNO.
- Pin OUT4 is connected to pin 1 on the DC Motor.
- Pin OUT3 is connected to pin 2 on the DC Motor.
- Pin 12V is connected to 12V-24V Output (DC) on the POWER SUPPLY 12V 5AMP.
- Pin GND is connected to GND (DC) on the POWER SUPPLY 12V 5AMP.
POWER SUPPLY 12V 5AMP
- Pin 12V-24V Output (DC) is connected to 12V on the L298N DC motor driver.
- Pin GND (DC) is connected to GND on the L298N DC motor driver.
- Pin 220V Positive Pole (AC) is connected to neutral wire on the power 220V.
- Pin 220V Negative Pole (AC) is connected to hot wire on the power 220V.
Power 220V
- Neutral wire is connected to 220V Positive Pole (AC) on the POWER SUPPLY 12V 5AMP.
- Hot wire is connected to 220V Negative Pole (AC) on the POWER SUPPLY 12V 5AMP.
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 documentation provides a comprehensive overview of the circuit, including a summary, detailed component list, wiring details, and the code used in the Arduino UNO microcontroller.