# RF remote control robot for school project

**URL:** <https://forum.arduino.cc/t/rf-remote-control-robot-for-school-project/1438682>\
**Category:** Networking, Protocols, and Devices\
**Created:** [April 6, 2026, 3:04pm UTC](https://forum.arduino.cc/t/rf-remote-control-robot-for-school-project/1438682 "2026-04-06T15:04:24Z")\
**Posts on this page:** 14\
**Page:** 1

<div class="post-metadata">

**Author:** ![hmh19](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/hmh19/32/1112310_2.png) [@hmh19](https://forum.arduino.cc/u/hmh19)\
**Post date:** [April 6, 2026, 3:04pm UTC](https://forum.arduino.cc/t/rf-remote-control-robot-for-school-project/1438682/1 "2026-04-06T15:04:24Z")

</div>

Hello I am a 8th grade student and I like working with Arduino so for my school project I decided to make a remote control car with RF and a Husky lens 2. I am having trouble coding the RF and huskgylens to work with my robot so I made sure it worked first and it could go forwards and backwards fine, but then when I tried to use a IR remote it did not work. I am using 2 tt motor driven by a 9v battery through a l293D Please help.

---

<div class="post-metadata">

**Author:** ![sterretje](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/sterretje/32/391294_2.png) [@sterretje](https://forum.arduino.cc/u/sterretje)\
**Post date:** [April 6, 2026, 3:14pm UTC](https://forum.arduino.cc/t/rf-remote-control-robot-for-school-project/1438682/2 "2026-04-06T15:14:20Z")

</div>

RF and IR are not the same thing. So you need to give some more details.

It might help if you showed a schematic / wiring diagram (you can drag an image into a reply) and your code (using code tags as described in [https://forum.arduino.cc/t/how-to-get-the-best-out-of-this-forum/679966#posting-code-and-common-code-problems](https://forum.arduino.cc/t/how-to-get-the-best-out-of-this-forum/679966#posting-code-and-common-code-problems).

---

<div class="post-metadata">

**Author:** ![UKHeliBob](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/ukhelibob/32/215663_2.png) [@UKHeliBob](https://forum.arduino.cc/u/UKHeliBob)\
**Post date:** [April 6, 2026, 3:14pm UTC](https://forum.arduino.cc/t/rf-remote-control-robot-for-school-project/1438682/3 "2026-04-06T15:14:22Z")

</div>

Welcome to the forum

Please post your best effort at writing the test sketch, using code tags when you do, and describe the problems that you have

Please post a schematic of your project showing how each of the components of it are connected and powered. A 'photo of a hand drawn circuit diagram is good enough

To post images etc. you need trust level 1, you can get there by:

- Entering at least **5** topics
- Reading at least **30** posts
- Spend a total of **10** minutes reading posts

Users at trust level 1 can...

- Use all core Discourse functions; all new user restrictions are removed
- Send PMs
- Upload images and attachments

---

<div class="post-metadata">

**Author:** ![hmh19](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/hmh19/32/1112310_2.png) [@hmh19](https://forum.arduino.cc/u/hmh19)\
**Post date:** [April 6, 2026, 6:23pm UTC](https://forum.arduino.cc/t/rf-remote-control-robot-for-school-project/1438682/4 "2026-04-06T18:23:28Z")

</div>

I am currently using this code for IR before I try RF but it is not working

```arduino
#include <IRremote.h>

// Motor 1
const int motor1Pin1 = 8;
const int motor1Pin2 = 7;
const int enable1Pin = 9;

// Motor 2
const int motor2Pin1 = 5;
const int motor2Pin2 = 4;
const int enable2Pin = 3;

// IR Receiver
const int RECV_PIN = 6;
IRrecv irrecv(RECV_PIN);
decode_results results;

void setup() {
  pinMode(motor1Pin1, OUTPUT);
  pinMode(motor1Pin2, OUTPUT);
  pinMode(enable1Pin, OUTPUT);
  pinMode(motor2Pin1, OUTPUT);
  pinMode(motor2Pin2, OUTPUT);
  pinMode(enable2Pin, OUTPUT);

  irrecv.enableIRIn(); // Start the receiver
}

void loop() {
  if (irrecv.decode(&results)) {
    unsigned long value = results.value;
    
    // Replace hex codes with those from your remote
    if (value == 0xFF18E7) { // Forward
      moveForward();
    } else if (value == 0xFF4AB5) { // Backward
      moveBackward();
    } else if (value == 0xFF38C7) { // Stop
      stopMotors();
    }
    
    irrecv.resume(); // Receive the next value
  }
}

void moveForward() {
  digitalWrite(motor1Pin1, HIGH);
  digitalWrite(motor1Pin2, LOW);
  analogWrite(enable1Pin, 200); // Speed
  
  digitalWrite(motor2Pin1, HIGH);
  digitalWrite(motor2Pin2, LOW);
  analogWrite(enable2Pin, 200);
}

void moveBackward() {
  digitalWrite(motor1Pin1, LOW);
  digitalWrite(motor1Pin2, HIGH);
  digitalWrite(enable1Pin, 150);

  digitalWrite(motor2Pin1, LOW);
  digitalWrite(motor2Pin2, HIGH);
  analogWrite(enable2Pin, 150);
}

void stopMotors() {
  digitalWrite(motor1Pin1, LOW);
  digitalWrite(motor1Pin2, LOW);
  digitalWrite(motor2Pin1, LOW);
  digitalWrite(motor2Pin2, LOW);
}

```

---

<div class="post-metadata">

**Author:** ![UKHeliBob](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/ukhelibob/32/215663_2.png) [@UKHeliBob](https://forum.arduino.cc/u/UKHeliBob)\
**Post date:** [April 6, 2026, 6:27pm UTC](https://forum.arduino.cc/t/rf-remote-control-robot-for-school-project/1438682/5 "2026-04-06T18:27:48Z")

</div>

> [@hmh19](#):
>
> it is not working

More details needed.

Add some Serial.print()s to see what, if anything, is being received. What are you using to transmit the IR ? Which Arduino board are you using ?

> [@hmh19](#):
>
> a 9v battery

Is the battery a PP3 by any chance ? They are designed for use by low current devices. Have you tried measuring its voltage whilst under load ?

---

<div class="post-metadata">

**Author:** ![hmh19](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/hmh19/32/1112310_2.png) [@hmh19](https://forum.arduino.cc/u/hmh19)\
**Post date:** [April 6, 2026, 6:53pm UTC](https://forum.arduino.cc/t/rf-remote-control-robot-for-school-project/1438682/6 "2026-04-06T18:53:54Z")

</div>

The IR receiver seems to be working, and the light turns on, but the motors do not turn on. The battery I am using is an Amazon Basics 9V battery.

---

<div class="post-metadata">

**Author:** ![UKHeliBob](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/ukhelibob/32/215663_2.png) [@UKHeliBob](https://forum.arduino.cc/u/UKHeliBob)\
**Post date:** [April 6, 2026, 6:56pm UTC](https://forum.arduino.cc/t/rf-remote-control-robot-for-school-project/1438682/7 "2026-04-06T18:56:46Z")

</div>

As I suspected, a PP3

Totally unsuited to power the car

Have you measured its voltage under load ?

---

<div class="post-metadata">

**Author:** ![hmh19](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/hmh19/32/1112310_2.png) [@hmh19](https://forum.arduino.cc/u/hmh19)\
**Post date:** [April 6, 2026, 7:00pm UTC](https://forum.arduino.cc/t/rf-remote-control-robot-for-school-project/1438682/8 "2026-04-06T19:00:42Z")

</div>

I have not, no.  
What battery should I use

---

<div class="post-metadata">

**Author:** ![HazardsMind](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/hazardsmind/32/215209_2.png) [@HazardsMind](https://forum.arduino.cc/u/HazardsMind)\
**Post date:** [April 6, 2026, 7:52pm UTC](https://forum.arduino.cc/t/rf-remote-control-robot-for-school-project/1438682/9 "2026-04-06T19:52:48Z")

</div>

You could still use the 9v battery, but you would need at least 3 of them in **parallel** to provide the needed current. OR if you have time, get yourself a 9.6V rechargeable battery pack like this [HERE](https://a.co/d/02Zhns3z)

You can use that battery pack alone to power the whole project or use a separate 9V for just the arduino. Just make sure if you go with the separate batteries, that the ground wires are connected.

---

<div class="post-metadata">

**Author:** ![xfpd](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/xfpd/32/1120236_2.png) [@xfpd](https://forum.arduino.cc/u/xfpd)\
**Post date:** [April 7, 2026, 3:28am UTC](https://forum.arduino.cc/t/rf-remote-control-robot-for-school-project/1438682/10 "2026-04-07T03:28:33Z")

</div>

> [@hmh19](#):
>
> `<IRremote.h>`

You are using an old library header. Read the warning here: [Arduino-IRremote/src/IRremote.h at master · Arduino-IRremote/Arduino-IRremote · GitHub](https://github.com/Arduino-IRremote/Arduino-IRremote/blob/master/src/IRremote.h)

The new one is `IRremote.hpp` and it has changed the call to decode to: `if (IrReceiver.decode())` (removing the ampersand)

---

<div class="post-metadata">

**Author:** ![hmh19](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/hmh19/32/1112310_2.png) [@hmh19](https://forum.arduino.cc/u/hmh19)\
**Post date:** [April 7, 2026, 11:42am UTC](https://forum.arduino.cc/t/rf-remote-control-robot-for-school-project/1438682/11 "2026-04-07T11:42:13Z")

</div>

Could I use a rechargeable lithium polymer power bank, with these specs?  
Input: DC 5.0V/2.0A · Output: DC 5.0V/2.1A · Capacity: 3.7V/3000mAh.

---

<div class="post-metadata">

**Author:** ![jim-p](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/jim-p/32/922840_2.png) [@jim-p](https://forum.arduino.cc/u/jim-p)\
**Post date:** [April 7, 2026, 11:45am UTC](https://forum.arduino.cc/t/rf-remote-control-robot-for-school-project/1438682/12 "2026-04-07T11:45:01Z")

</div>

> [@HazardsMind](#):
>
> You could still use the 9v battery, but you would need at least 3 of them in **parallel** to provide the needed current.

**Never** put batteries in parallel.

---

<div class="post-metadata">

**Author:** ![jim-p](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/jim-p/32/922840_2.png) [@jim-p](https://forum.arduino.cc/u/jim-p)\
**Post date:** [April 7, 2026, 12:19pm UTC](https://forum.arduino.cc/t/rf-remote-control-robot-for-school-project/1438682/13 "2026-04-07T12:19:46Z")

</div>

> [@hmh19](#):
>
> Could I use a rechargeable lithium polymer power bank, with these specs?  
> Input: DC 5.0V/2.0A · Output: DC 5.0V/2.1A · Capacity: 3.7V/3000mAh.

The capacity spec makes no sense.  
Most people use two 18650 batteries in **series** to power the motors.

 ![image](https://europe1.discourse-cdn.com/arduino/original/4X/f/f/c/ffcbd3a7a44a1aff3c5ce02d04640392f7c11324.jpeg)

---

<div class="post-metadata">

**Author:** ![system](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/system/32/1140315_2.png) [@system](https://forum.arduino.cc/u/system)\
**Post date:** [October 4, 2026, 12:20pm UTC](https://forum.arduino.cc/t/rf-remote-control-robot-for-school-project/1438682/14 "2026-10-04T12:20:24Z")

</div>

Closed on October 4, 2026, 12:20pm UTC

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.
