Cirkit Designer Logo
Cirkit Designer
Your all-in-one circuit design IDE
Home / 
Project Documentation

Arduino-Controlled Robotics Platform with Servo Motors and Sensors

Image of Arduino-Controlled Robotics Platform with Servo Motors and Sensors

Circuit Documentation

Summary

This circuit is designed to interface an Arduino UNO with multiple sensors and actuators, including IR sensors, an ultrasonic sensor, servo motors, and DC gearmotors through an L298N motor driver. The circuit is powered by a 12V battery, which also supplies power to the motor driver. The Arduino UNO controls the servo motors and reads signals from the IR sensors and the ultrasonic sensor. The motor driver controls the gearmotors based on the signals from the Arduino UNO.

Component List

Arduino UNO

  • Microcontroller board based on the ATmega328P
  • It has 14 digital input/output pins, 6 analog inputs, a 16 MHz quartz crystal, a USB connection, a power jack, an ICSP header, and a reset button.

SG90 Servo Motor (4x)

  • Small and lightweight servo motor
  • Operating voltage: 4.8V to 6V
  • Interface: PWM signal

HC-SR04 Ultrasonic Sensor

  • Ultrasonic ranging module
  • Operating voltage: 5V
  • Interface: Trigger and Echo pins

IR Sensor (2x)

  • Infrared sensor for detecting proximity and object presence
  • Operating voltage: 3.3V to 5V
  • Interface: Digital output

Battery 12V

  • Power source for the circuit
  • Provides 12V output

L298N DC Motor Driver

  • Dual H-bridge motor driver
  • Operating voltage: Up to 35V
  • Control for two DC motors or one stepper motor

Hobby Gearmotor with 48:1 Gearbox (4x)

  • DC gearmotor for driving wheels or other mechanical parts
  • Operating voltage: Typically around 6V to 12V

Wiring Details

Arduino UNO

  • Digital pins D2 to D9 are used to control servo motors and to read signals from the IR sensors and the ultrasonic sensor.

SG90 Servo Motors

  • Each servo motor's PWM pin is connected to one of the Arduino's digital pins (D2 to D5).
  • The 5V and GND pins of all servo motors are connected to the common 5V and GND lines, respectively.

HC-SR04 Ultrasonic Sensor

  • TRIG pin connected to Arduino's D6
  • ECHO pin connected to Arduino's D7
  • VCC and GND pins connected to the common 5V and GND lines, respectively.

IR Sensors

  • OUT pin of each sensor is connected to Arduino's D8 and D9.
  • VCC and GND pins of both sensors are connected to the common 5V and GND lines, respectively.

Battery 12V

  • The positive terminal (+) is connected to the 12V input of the L298N motor driver.
  • The negative terminal (-) is connected to the common GND line.

L298N DC Motor Driver

  • OUT1 to OUT4 are connected to the pins of the gearmotors.
  • The 12V pin is connected to the positive terminal of the battery.
  • The GND pin is connected to the common GND line.
  • The 5V pin is connected to the common 5V line.

Hobby Gearmotors

  • Each gearmotor has two pins connected to the L298N motor driver's output pins (OUT1 to OUT4).

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 Notes

  • The provided code is a template and does not contain any functional code to control the circuit components.
  • The user should implement the setup and loop functions to initialize the pins and define the behavior of the circuit, respectively.