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

Bluetooth-Controlled Robotic Vehicle with IR Obstacle Detection

Image of Bluetooth-Controlled Robotic Vehicle with IR Obstacle Detection

Circuit Documentation

Summary

This circuit is designed to control two DC Mini Metal Gear Motors using an L298N DC motor driver, which is interfaced with an Arduino Nano microcontroller. The Arduino Nano also connects to a 5 channel IR array for input and an HC-05 Bluetooth Module for wireless communication. Power is supplied by a 7.4v battery, which is controlled by a Rocker Switch and regulated by an XL6009E1 Boost Converter to ensure stable operation of the motor driver and the microcontroller.

Component List

7.4v Battery

  • Description: A 7.4-volt battery providing the main power source for the circuit.
  • Pins: +, -

L298N DC Motor Driver

  • Description: A motor driver module capable of driving 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

5 Channel IR Array

  • Description: An array of 5 infrared sensors used for line tracking or obstacle detection.
  • Pins: A5, A4, A3, A2, A1, VCC, GND

Arduino Nano

  • Description: A compact microcontroller board based on the ATmega328P, used for controlling the logic of the circuit.
  • 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

DC Mini Metal Gear Motor

  • Description: A small DC motor with a gearbox for increased torque.
  • Pins: IN1, IN2

HC-05 Bluetooth Module

  • Description: A Bluetooth module for wireless communication with the microcontroller.
  • Pins: Key, VCC, GND, TXD, RXD, State

Rocker Switch

  • Description: A switch to control the power supply to the circuit.
  • Pins: 1, 2

XL6009E1 Boost Converter

  • Description: A DC-DC boost converter to step up the voltage to a required level.
  • Pins: IN+, IN-, OUT-, OUT+

Wiring Details

7.4v Battery

  • + connected to Rocker Switch pin 1
  • - connected to GND net (common ground)

L298N DC Motor Driver

  • OUT1 connected to DC Mini Metal Gear Motor (1) IN2
  • OUT2 connected to DC Mini Metal Gear Motor (1) IN1
  • 12V connected to XL6009E1 Boost Converter OUT+
  • GND connected to GND net (common ground)
  • 5V connected to Arduino Nano VIN
  • OUT3 connected to DC Mini Metal Gear Motor (2) IN2
  • OUT4 connected to DC Mini Metal Gear Motor (2) IN1
  • ENA connected to Arduino Nano D3
  • IN1 connected to Arduino Nano D4
  • IN2 connected to Arduino Nano D5
  • IN3 connected to Arduino Nano D7
  • IN4 connected to Arduino Nano D8
  • ENB connected to Arduino Nano D9

5 Channel IR Array

  • A5 connected to Arduino Nano A4
  • A4 connected to Arduino Nano A3
  • A3 connected to Arduino Nano A2
  • A2 connected to Arduino Nano A1
  • A1 connected to Arduino Nano A0
  • VCC connected to Arduino Nano D2
  • GND connected to GND net (common ground)

Arduino Nano

  • GND connected to GND net (common ground)
  • VIN connected to L298N DC Motor Driver 5V
  • D3 connected to L298N DC Motor Driver ENA
  • D4 connected to L298N DC Motor Driver IN1
  • D5 connected to L298N DC Motor Driver IN2
  • D7 connected to L298N DC Motor Driver IN3
  • D8 connected to L298N DC Motor Driver IN4
  • D9 connected to L298N DC Motor Driver ENB
  • A4 connected to 5 Channel IR Array A5
  • A3 connected to 5 Channel IR Array A4
  • A2 connected to 5 Channel IR Array A3
  • A1 connected to 5 Channel IR Array A2
  • A0 connected to 5 Channel IR Array A1
  • D2 connected to 5 Channel IR Array VCC
  • D1/TX connected to HC-05 Bluetooth Module RXD
  • D0/RX connected to HC-05 Bluetooth Module TXD
  • 5V connected to HC-05 Bluetooth Module VCC

HC-05 Bluetooth Module

  • GND connected to GND net (common ground)
  • VCC connected to Arduino Nano 5V
  • TXD connected to Arduino Nano D0/RX
  • RXD connected to Arduino Nano D1/TX

Rocker Switch

  • 1 connected to 7.4v Battery +
  • 2 connected to XL6009E1 Boost Converter IN+

XL6009E1 Boost Converter

  • IN+ connected to Rocker Switch 2
  • IN- connected to GND net (common ground)
  • OUT+ connected to L298N DC Motor Driver 12V
  • OUT- connected to GND net (common ground)

Documented Code

Arduino Nano (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 contain any functional code. It is expected that the user will fill in the setup and loop functions with the necessary code to control the motors via the L298N driver, read inputs from the IR array, and communicate with the HC-05 Bluetooth module.