Instructables

Arduino controls cheap RC car transmitter


OBJECTIVE

Cheap Chinese RC toy cars can be had for about 5 Euros in the local market. The wireless brains behind the majority of these cheap RC toys is a pair of very cheap ICs the TX2 and the RX2. Yup, that's what they are called. So this tutorial is focused on the TX2/RX2 based remote controlled toys. 

I bought one RC toy car a while ago and used the Arduino with an IR sensor to drive it. Then I figured why not use the Arduino to drive the radio control mechanism of the car. You can see a video of the steps involved and the final  operational circuit here:



WHY?

I mentioned in my other projects how hard it is for most people in Jordan to afford buying electronic components because of the very low income,  absurdly high tariffs (mostly to feed rampant government corruption), and arbitrary security procedures. So scavenging parts from cheap gadgets is the way for most young makers I know to sustain their passion for electronic innovation.

CREDITS
Special thanks to Eng. Jafar Quttaineh for his invaluable assistance.

FEEDBACK
Your feedback is most welcome to help me improve my future projects.

Let's get started...
 
Remove these adsRemove these ads by Signing Up

Step 1: Getting started

APPROACH

In this project, I will use the Arduino to drive the transmitter's LEFT and RIGHT functions. So instead of the user pushing the remote control's joystick to turn the car (or my test rig) , the Arduino can be connected and programmed instead to send these commands via the RC car's transmitter. The same steps can be duplicated to enable the Arduino to drive the transmitter's BACK and FORWARD function pins.

I extracted both receiver and controller circuits from the RC car but you may find it easier to just work with the transmitter + Arduino while leaving the receiver and the car intact. This might be simpler for some of you since you have to only worry about dissecting and wiring the transmitter to the Arduino. Also, the intact receiver + car will act as your test platform. It's also more fun to end your project with your Arduino controlling your RC car instead of just looking at two naked circuits and a blinking LED. Your call.


COMPONENTS

The car has three main components.

1) Mechanical: For steering and locomotion, the car has 2 DC motors and associated gear. One motor provides locomotion from the back of the car, the other DC motor in the front provides steering left and right. I won't be using the motors in this project but these toy cars are a great source of motors, gears, h-bridges, and other parts. So I am not throwing anything away.

2) Electronic: There are three main circuits. a) the transmitter b) the receiver c) the H-bridge. The transmitter and receiver are driven by the venerable TX2 encoder and RX2 decoder ICs. The h-bridge to drive the DC motors uses power transistors. Refer to the datasheet for more details.

3) Power: The transmitter is powered by 2 AA batteries (3V) and the receiver/car comobo is powered by 4 AA batteries (6V).

PARTS NEEDED FOR THIS PROJECT

- Arduino Uno or clone.

- 2 X  10K Ohm resistors. I use each in a series to connect the transmitter's pin to the Arduino's digital pin.  If you want to connect all steering functions (Left, Right, Back, Front) to the Arduino you will need 4 of those. 10K might be overkill but the circuit works.

- 2 X breadboards to place the transmitter and receiver for wiring. It just makes for easier handling and wiring. But you can do without the breadboard.

- Wires and alligator clips.

- 4 X AA (6V) battery source to supply the receiver.

- Multimeter to test your connections.

- DC motors, small DC lamps, or relays to test your final TX2/RX2 system depending on what you plan to use it for.

OPTIONAL LED TESTBED

I know some of you will be tempted to just use LEDs to test the rig. LEDs are nice and cheap and accessible. Since the receiver's h-bridge (geek term for circuit that drives motors) switches between positive and negative voltage depending on whether it's driving the motor in one direction or the other (e.g. Forward vs Back), we can't just use LEDs as-is since an LED passes current in one direction only but not the other. But if you insist on using LED's , I came up with a quick and dirty test circuit based on LEDs. I won't describe it in detail because it's not relevant to his project.

My LED testing circuit was put together on the fly. It's a mini breadboard made up of two LEDs, two diodes, and two resistors both in parallel but rigged for opposite polarities. When the voltage is positive, one LED will turn on, when it's negative, the other LED will turn on. 

This is to simulate a motor turning one way (e.g. Right) or the other (e.g. Left).  You don't need to do this test circuit. Just connect a small DC lamp or a DC motor to test your circuit. I am sure there are better ways of doing this but it was the quickest at the time. I might add two more LEDs to simulate the 2nd  motor's Forward and Backward functions.

WORKING WITH DIFFERENT RC GADGETS

There's a good chance your RX2/TX2 based RC gadget was made by a different vendor with different wire colors and based on different schematics. You should be able to apply the techniques from this project to other RX2/TX2 based RC projects with a modest effort.
emdarcher1 year ago
it looks like you could use this for cheap arduino to arduino control of you connected the reciever outputs to another arduino, and that arduino would have a code that translates those signals to a usable command. it would require a bit of coding, but is way cheaper than xbee.

that is what i plan to do. this is super useful none the same!

techbitar (author)  emdarcher1 year ago
It's possible with some additional tweaking and coding.
dempap4 months ago
Nice work! I 'm working on a similar project and your post is really helpful. My RC car makes use of the same TX2G-RX2G ICs. However, are you sure that they are manufactured from "Actions Semiconductor Co., Ltd."? I noticed the logo on the ICs and is not the same.
Yassine Atide9 months ago
Ramadan mobarak said ,it's always a pleasure to meet maker on the arab world, thanks for highlighting to me these sweet tx2/rx2 for little fun projects , it will be always nice to get some for really cheap.

I have been going though the datasheet , and i can't figure out how did you adapt the max input voltage from arduino output pin voltage , i think i will be using optocoupler to avoid any problem , but still interrested to know why using 10 k resistor.

Cheers , Yassine

I am making a voice recognition rc car. so would it be possibe to use this code?
gramhex1 year ago
Hi,

I have connected the forward and backward terminal of the TX2[TX-2B] to
respective digital pins TX2Pin05, TX2Pin04. Then added the following lines
of code to the existing code you have attached,

digitalWrite(TX2Pin05 , LOW);
delay(2000);

digitalWrite(TX2Pin05, HIGH);
delay(2000);

digitalWrite(TX2Pin04, LOW);
delay(2000);

digitalWrite(TX2Pin04, HIGH);
delay(2000);

After uploading the code to arduino, Only Right functionality in the car
is working other functionality are not working [Left/Forward/Backward].
Please help to solve this issue.

Regards,
Vicky
Pro

Get More Out of Instructables

Already have an Account?

close

PDF Downloads
As a Pro member, you will gain access to download any Instructable in the PDF format. You also have the ability to customize your PDF download.

Upgrade to Pro today!