Tracked Robot IR Remote Control by Arduino





Introduction: Tracked Robot IR Remote Control by Arduino

Many years ago,I had studied Dual H-bridge motor drive control by hacking cheap 4 channals toy remote control board and applied it to remote twin motors track and wheel set.Now I try to use Arduino controller with IR remote to control it again.That's also work.

Step 1: Materials and Tools

1.Track and wheel set.

2.Gear box - Individual drive-two motors

3.Arduino UNO

4.Dupont wires 200mm.

5.VS1838B IR reciever.

6.Battery 5-12V.

7.IR remote (Can use also old TV remote)

8.L298N Dual H-Bridge motor drive module.

Step 2: Mechanical Assembly & Electrical Connecting

1.Assembly Track and wheel set as manual instruction.

2.Install Arduino UNO controller ,IR reciever , L298N motor drive module and battery on chassis.


Arduino pins to IR reciever :

11 - IR reciever o/p signal

5V - IR reciever Vcc

GND - IR reciever ground

Arduino pins to L298N motor drive module :

10 - ENA

9 - IN1

8 - IN2

7 - IN3

6 - IN4

5 - ENB

Connect Arduino GND pin and L298N motor drive module GND.

L298N motor drive module :

Connect power o/p to Motor A and B

Connect battery to Arduino controller and L298N drive module (can use battery up to 12V.)

Step 3: Collect IR Remote Code

Use Arduino UNO IR remote button decode sketch to decode your each IR remote buttons' hexa code.You can apply any type of IR remotes TV,LCD, DVD player,etc.

(Refer to )

Collect each IR remote button's hexa code.We will use 7 buttons' hexa codes for main sketch.

In this instruction ,My own IR remote ,I selected :

Button 2 - forward direction - Hexa code FF18E7

Button 8 - backward direction - Hexa code FF5AA5

Button 4 - turn left direction - Hexa code FF10EF

Button 6 - turn right direction - Hexa code FF5AA5

Button 3 - rotating right direction - Hexa code FF7A85

Button 1 - rotating left direction - Hexa code FF18E7

Button 5 - stop all direction - Hexa code FF38C7

Step 4: Modify Dual H-bridge Motor Drive Control Sketch and Comply.

Download the main sketch.Before complying ,modify the 7 control buttons' hexa codes in attached sketch to be your own IR remote hexa codes.Then comply and upload it.

Test the robot is running correctly or not by pushing button as wanted direction.If :-

1.Motor turn on wrong direction - interchange power o/p of motor drive module.

2.Sleep L298N motor drive module - check GND connection between Arduino controller and motor drive module.

3.Speed of each motor can be adjusted by changing value in sub-sketch from 0-255.In the attached sketch default = 100

Thank to L298N dual H-bridge motor drive control sub-sketch from Tronixlabs.

And thank to vigneshraja for IR remote sub-sketch.



    • Creative Misuse Contest

      Creative Misuse Contest
    • Clocks Contest

      Clocks Contest
    • Oil Contest

      Oil Contest

    15 Discussions

    Do I need to use two power sources one for Arduino board and one for the motor controller? (I am a total noob)

    1 reply

    This sketch had been run without problem.I guess you have problem with compiling error.Try to re-add IRremote library to you Arduino software from the errors still exist,try to delete the files that have errors.

    I have another question, I got troubles with the IR remote control part of the sketch, could you please upload you sketch complete? please bro

    This project run with L298N no need to modify,but if you want to change pin number,it's possible.

    This project run with L298N no need to modify,but if you want to change pin number,it's possible.

    can i make it with l298n,if yes do i need to chang the code.

    Great job! but does it work whit L298 Dual H-Bridge motor drive module?

    6 replies

    Yes,it works.It can drive step motors by leaving the small clips on enable motor A and B pins.When driving ordinary motors,take it off.And enable PWM by program.

    ajajja how can I be so blind? thanks a lot! but how can I enable PWM by program? I m new on the arduino world

    Let see the attached sketch,enA enB o/p pin 10,5.

    HI! well I have troubles, starting for the IR receiver stop working and I dont know why

    Perhap your batt out,just a joke.You can use serial monitor to see which step it stop,You can modify sketch by add serialprnt to check that it pass your point or not.For hardware you can check circuit ,there're something wrong or not.

    ajjaja when I read was like WTF? ok I will try, thanks for your time

    the TV remote controlled modified car sounds amazing actually, but were do I buy the materials for the cheapest price.