Arduino Nano-Based Battery-Powered Smart Motor Controller with RGB LED and IR Receiver
View and Edit Project In Cirkit Designer
Circuit Documentation
Summary
This document provides a detailed overview of a circuit design that includes an Arduino Nano microcontroller, various sensors, actuators, and other components. The circuit is designed to perform specific tasks as defined by the embedded code running on the Arduino Nano. The document includes a component list, wiring details, and the embedded code.
Component List
Arduino Nano
- Description: A small, complete, and breadboard-friendly board based on the ATmega328P.
- Pins: D1/TX, D0/RX, RESET, GND, D2, D3, D4, D5, D6, D7, D8, D9, D10, D11/MOSI, D12/MISO, VIN, 5V, A7, A6, A5, A4, A3, A2, A1, A0, AREF, 3V3, D13/SCK
RGB LED (Wokwi compatible)
- Description: A common anode RGB LED.
- Pins: R, COM, G, B
MT3608
- Description: A DC-DC step-up converter.
- Pins: VOUT+, VIN+, VOUT-, VIN-
LM2596
- Description: A DC-DC step-down converter.
- Pins: IN, OUT
nMOS Transistor (MOSFET)
- Description: A type of transistor used for switching and amplifying electronic signals.
- Pins: gate, drain, source
Resistor (220 Ohms)
- Description: A resistor with a resistance of 220 Ohms.
- Pins: pin1, pin2
Resistor (10k Ohms)
- Description: A resistor with a resistance of 10k Ohms.
- Pins: pin1, pin2
Resistor (1k Ohms)
- Description: A resistor with a resistance of 1k Ohms.
- Pins: pin1, pin2
VS1838B IR Receiver
- Description: An infrared receiver module.
- Pins: OUT, GND, VCC
Diode
- Description: A semiconductor device that allows current to flow in one direction only.
- Pins: cathode, anode
Solenoid
- Description: An electromechanical device that converts electrical energy into linear motion.
- Pins: pin1, pin2
16x2 I2C LCD
- Description: A 16x2 character LCD with I2C interface.
- Pins: GND, VCC, SDA, SCL
TP4056
- Description: A lithium battery charger module.
- Pins: OUT-, B-, B+, OUT+, IN-, IN+
DC Mini Metal Gear Motor
- Description: A small DC motor with metal gears.
- Pins: IN1, IN2
Polymer Lithium Ion Battery - Generic
- Description: A generic lithium-ion battery.
- Pins: GND, VCC
Rocker Switch
- Description: A switch that rocks back and forth to open or close a circuit.
- Pins: 1, 2
Pushbutton
- Description: A simple pushbutton switch.
- Pins: Pin 2, Pin 1, Pin 3, Pin 4
Wiring Details
Arduino Nano
- D13/SCK connected to gate of nMOS Transistor (MOSFET)
- D12/MISO connected to pin1 of Resistor (1k Ohms)
- D11/MOSI connected to pin1 of Resistor (1k Ohms)
- D8 connected to Pin 1 of Pushbutton
- D7 connected to pin2 of Resistor (220 Ohms)
- D6 connected to pin2 of Resistor (220 Ohms)
- A4 connected to SDA of 16x2 I2C LCD
- D5 connected to pin2 of Resistor (220 Ohms)
- A5 connected to SCL of 16x2 I2C LCD
- D4 connected to pin2 of Resistor (10k Ohms)
- GND connected to GND of 16x2 I2C LCD, VOUT- of MT3608, GND of VS1838B IR Receiver, source of nMOS Transistor (MOSFET), OUT of LM2596, source of nMOS Transistor (MOSFET), source of nMOS Transistor (MOSFET), VIN- of MT3608, IN of LM2596, Pin 3 of Pushbutton, OUT- of TP4056
- VIN connected to VCC of VS1838B IR Receiver, COM of RGB LED (Wokwi compatible), VCC of 16x2 I2C LCD, VOUT+ of MT3608
RGB LED (Wokwi compatible)
- R connected to pin1 of Resistor (220 Ohms)
- G connected to pin1 of Resistor (220 Ohms)
- B connected to pin1 of Resistor (220 Ohms)
MT3608
- VIN+ connected to IN of LM2596
- VOUT+ connected to VIN of Arduino Nano
LM2596
- OUT connected to IN1 of DC Mini Metal Gear Motor
nMOS Transistor (MOSFET)
- drain connected to IN2 of DC Mini Metal Gear Motor
Resistor (220 Ohms)
- pin1 connected to R of RGB LED (Wokwi compatible)
- pin1 connected to G of RGB LED (Wokwi compatible)
- pin1 connected to B of RGB LED (Wokwi compatible)
Resistor (10k Ohms)
- pin1 connected to OUT of VS1838B IR Receiver
Resistor (1k Ohms)
- pin1 connected to D12/MISO of Arduino Nano
- pin1 connected to D11/MOSI of Arduino Nano
VS1838B IR Receiver
- OUT connected to pin1 of Resistor (10k Ohms)
Diode
- cathode connected to pin2 of Solenoid
- anode connected to drain of nMOS Transistor (MOSFET)
Solenoid
- pin1 connected to anode of Diode
- pin2 connected to cathode of Diode
16x2 I2C LCD
- GND connected to GND of Arduino Nano
- VCC connected to VIN of Arduino Nano
- SDA connected to A4 of Arduino Nano
- SCL connected to A5 of Arduino Nano
TP4056
- OUT+ connected to 2 of Rocker Switch
- B- connected to GND of Polymer Lithium Ion Battery - Generic
- B+ connected to VCC of Polymer Lithium Ion Battery - Generic
DC Mini Metal Gear Motor
- IN1 connected to OUT of LM2596
- IN2 connected to drain of nMOS Transistor (MOSFET)
Polymer Lithium Ion Battery - Generic
- GND connected to B- of TP4056
- VCC connected to B+ of TP4056
Rocker Switch
- 1 connected to cathode of Diode
- 2 connected to OUT+ of TP4056
Pushbutton
- Pin 1 connected to D8 of Arduino Nano
- Pin 3 connected to GND of Arduino Nano
Documented Code
Arduino Nano Code
void setup() {
// put your setup code here, to run once:
}
void loop() {
// put your main code here, to run repeatedly:
}
This concludes the documentation for the circuit. Each component and its connections have been detailed, along with the embedded code for the Arduino Nano.