# I can't seem to get RF transmitter and receiver working

**URL:** <https://forum.arduino.cc/t/i-cant-seem-to-get-rf-transmitter-and-receiver-working/1203014>\
**Category:** General Guidance\
**Created:** [December 23, 2023, 7:48am UTC](https://forum.arduino.cc/t/i-cant-seem-to-get-rf-transmitter-and-receiver-working/1203014 "2023-12-23T07:48:45Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![daniu13](https://avatars.discourse-cdn.com/v4/letter/d/3ec8ea/32.png) [@daniu13](https://forum.arduino.cc/u/daniu13)\
**Post date:** [December 23, 2023, 7:48am UTC](https://forum.arduino.cc/t/i-cant-seem-to-get-rf-transmitter-and-receiver-working/1203014/1 "2023-12-23T07:48:45Z")

</div>

I'm trying to make a transmitter+receiver system using arduino. I'm using the 433Mhz Wireless transmitter and receiver, and the two boards that I'm using are Elegoo Uno, which is basically Arduino Uno. I followed [Insight Into How 433MHz RF Tx-Rx Modules Work & Interface with Arduino](https://lastminuteengineers.com/433mhz-rf-wireless-arduino-tutorial/) this tutorial, and my goal is to send a message to the receiver. I downloaded the latest version of Radiohead and the code is exactly the same as that. The receiver and the transmitter have all been connected to the right places, like the data and VCC and Ground pins are all at the right places. I used the same port for uploading for both of them. After uploading the code into the transmitter, I put a battery into the transmitter, and so the code should keep on running. Then I imported the code into the receiver. But for some reason, the "hello world" just doesn't pop up on my serial monitor. For the pins, I have plugged into digital pin 12 for the transmitter, and 11 for receiver, because those are the default pins. I have looked into every possible problem, and I couldn't find a solution. Spent the last few days in frustration because of this problem. Any help would be appreciated. Thanks in advance

---

<div class="post-metadata">

**Author:** ![StefanL38](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/stefanl38/32/713548_2.png) [@StefanL38](https://forum.arduino.cc/u/StefanL38)\
**Post date:** [December 23, 2023, 8:02am UTC](https://forum.arduino.cc/t/i-cant-seem-to-get-rf-transmitter-and-receiver-working/1203014/2 "2023-12-23T08:02:01Z")

</div>

Hi @daniu13,

welcome to the arduino-Forum.

You have taken the effort to write down a pretty detailed description of what you have done and a link what source you used.

You are working on an informatic project and in an informatic project is most needed guess what?  
Information.

Still much more information is needed for effectivly helping you.

It might well be that you added a single character that changed the code to be not working  
and this is the reason why you should **really** post **your** code

If I would say "remove line 547 from your code"

Will this work? Surely not because without seeing this line of code this make really no sense.

## post complete sketches

Post your complete sketches. From the very first to the very last line.  
There is a shortcut with which this can be done with a few mouse-clicks and keypresses  
It is described here

> [@Make experienced users help: two ways to quickly post code as a code-section](https://forum.arduino.cc/t/make-experienced-users-help-two-ways-to-quickly-post-code-as-a-code-section/937298/1):
>
> Hi newcomer, This thread wants to show you how you can speed-up getting helpful answers with small effort. If you manage at least to post this way. You have the sympathy of the experienced users. If you are willing to invest another 20 minutes these 20 minutes extra-time will save you a minimum of 200 minutes to finish your project. always post your full sketch. As a code-section from the very first to the very last line A code-section has a small height =\> keeps your posting "short" but e…

best regards Stefan

---

<div class="post-metadata">

**Author:** ![StefanL38](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/stefanl38/32/713548_2.png) [@StefanL38](https://forum.arduino.cc/u/StefanL38)\
**Post date:** [December 23, 2023, 8:11am UTC](https://forum.arduino.cc/t/i-cant-seem-to-get-rf-transmitter-and-receiver-working/1203014/3 "2023-12-23T08:11:28Z")

</div>

Additionally you should post a **schematic** of your wiring  
do **NOT** post a fritzing picture!

A fritzing picture is **NOT** a schematic! fritzing pictures are annoying through:

- too much details that are not relevant
- do not follow rules how to draw schematics
- take too much time to create them

Read this tutorial how to quickly create a schematic.

> [@How to provide an easy to read schematic and how not](https://forum.arduino.cc/t/how-to-provide-an-easy-to-read-schematic-and-how-not/989506):
>
> This tutorial shall show how to provide an easy to read schematic of your wiring and how you should not post fritzing pictures don't post frizzy-pictures like that! if you look at this pictures please tell me the IO-pin-numbers! What ?? You can't read the IO-pin-numbers? You have to download the picture and than zoom in. Don't you have time? You have to download the datasheet of the chip and then look up which pin is connected to what. take additional time to count through the chip-pins an…

For posting pictures you have to do a few things that are easy to do  
You have to reach trustlevel 1 through these activities:

Get to trust level 1 by…

- clicking on 5 different threads
- reading 30 postings (they must have been visible on the screen
- beeing a minimum time of 10 minutes in the forum

best regards Stefan

---

<div class="post-metadata">

**Author:** ![StefanL38](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/stefanl38/32/713548_2.png) [@StefanL38](https://forum.arduino.cc/u/StefanL38)\
**Post date:** [December 23, 2023, 8:34am UTC](https://forum.arduino.cc/t/i-cant-seem-to-get-rf-transmitter-and-receiver-working/1203014/4 "2023-12-23T08:34:32Z")

</div>

> [@daniu13](#):
>
> After uploading the code into the transmitter, I put a battery into the transmitter, and so the code should keep on running.

You make an assumption. The code **should** be running.  
There are mutliple reasons why your microcontroller might be **not** running:

- broken Arduino
- too weak battery
- invisible broken wire
- broken transmitter module (for what reason ever)
- no antenna at all / no length matched antenna

And all these possible reasons must be checked to replace assumptions with **real** checking

does arduino still work?  
load the basic blink-sketch that blinks the onboard led  
After uploading the blink-sketch does the led really blink?

what voltage does the battery have?  
To which input is the battery connected?  
Post a picture of your real setup

Did you check if you have voltage between the 5V and the GND-pin?

Post a picture of your real wiring

---

<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:** [December 23, 2023, 9:53am UTC](https://forum.arduino.cc/t/i-cant-seem-to-get-rf-transmitter-and-receiver-working/1203014/5 "2023-12-23T09:53:32Z")

</div>

> [@daniu13](#):
>
> I put a battery into the transmitter,

What battery and where did you put it?

---

<div class="post-metadata">

**Author:** ![daniu13](https://avatars.discourse-cdn.com/v4/letter/d/3ec8ea/32.png) [@daniu13](https://forum.arduino.cc/u/daniu13)\
**Post date:** [December 30, 2023, 8:43am UTC](https://forum.arduino.cc/t/i-cant-seem-to-get-rf-transmitter-and-receiver-working/1203014/6 "2023-12-30T08:43:24Z")

</div>

this is my code

#include \<RH\_ASK.h\>  
#include \<SPI.h\>  
RH\_ASK rf\_driver;

void setup() {  
// put your setup code here, to run once:

rf\_driver.init();

}

void loop() {  
// put your main code here, to run repeatedly:  
const char _msg="Hello World!";  
rf\_driver.send((uint8\_t_)msg,strlen(msg));  
rf\_driver.waitPacketSent();

delay(1000);  
}  
#include \<RH\_ASK.h\>  
#include \<SPI.h\>  
RH\_ASK rf\_driver;

void setup() {  
// put your setup code here, to run once:

Serial.begin(9600);  
rf\_driver.init();  
}

void loop() {  
// put your main code here, to run repeatedly:  
uint8\_t buf[12];  
uint8\_t buflen=sizeof(buf);  
if(rf\_driver.recv(buf,&buflen))  
{

```
Serial.print("Recieved");
Serial.println((char*)buf);

```

}  
else {  
Serial.println("No data received");  
}  
delay(1000);  
}  
Thanks for the reply, and sorry for the late reply. Anyways, my arduino works, battery is 9V and seems to work fine. However, I don’t have an antenna for my transmitter and receiver, would that by the issue? I have the transmitter and receiver right next to each other though. Also, how can I check if my transmitter and receiver is working? There doesn’t seem to be any tutorial on this. Thanks so much for the help by the way, I appreciate it a lot.

 ![2023-12-30 (1)](https://europe1.discourse-cdn.com/arduino/original/4X/1/8/c/18c632e753a1110df48ac2fe6f3bfc1ba518494d.png)  
 ![2023-12-30 (2)](https://europe1.discourse-cdn.com/arduino/original/4X/e/0/a/e0ad035fb1d2d75f524c185cdf364144bcc7d272.png)

---

<div class="post-metadata">

**Author:** ![StefanL38](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/stefanl38/32/713548_2.png) [@StefanL38](https://forum.arduino.cc/u/StefanL38)\
**Post date:** [December 30, 2023, 9:45am UTC](https://forum.arduino.cc/t/i-cant-seem-to-get-rf-transmitter-and-receiver-working/1203014/7 "2023-12-30T09:45:38Z")

</div>

> [@daniu13](#):
>
> Anyways, my arduino works, battery is 9V and seems to work fine.

This seems to be contradictory to this

> [@daniu13](#):
>
> I don’t have an antenna for my transmitter and receiver, would that by the issue?

What dos this mean? Do you still have an issue that it is not working or does it work now?  
Does it work reliably?

How close / how far do you have to place transmitter / receiver to each other to make it work reliably?

Without a **length-matched** antenna the RF-power that is sended out by the transmittor will be only 1% of the power that would be send out with a length-matched antenna.

And the receiver will only receive only 1% of the RF-power without a length-matched antenna.  
This means transmitting the data will only work over a very short distance reliably.

You posted fritzing pictures as a "schematic".  
I have a question: can you read the letters that indicate which pin has what function on the transmitter and the receiver?

 ![image](https://europe1.discourse-cdn.com/arduino/original/4X/6/0/c/60cf6912802b0e19b23a42d59c923718b40b5c29.png)  
 ![image](https://europe1.discourse-cdn.com/arduino/original/4X/4/0/b/40b13343ee3f3e6f69b6bfa8046cbe3e45524cd1.png)

If somebody would like to check your wiring she/he would be forced to lookup  
datasheets of the transmitter / receiver  
Without knowing which **exact type** of transmitter/receiver this is.

Making assumptions which one it **might** be which could be wrong.

If you look at the picture below  
This receiver-boards

 ![image](https://europe1.discourse-cdn.com/arduino/original/4X/b/8/a/b8a30d0794c5844f5fd284de7bb8da689ebd9b30.jpeg)

show the pin-order. Is your pin-order the same?

This is the reason why you should provide datasheets and pictures of your **real** hardware.

> [@daniu13](#):
>
> Also, how can I check if my transmitter and receiver is working?

The real check of the transmitter working or not working  
would be to use an expensive receiver

To check if the receiver is working could be done with a much simpler testcode that just prints the state of the IO-pin to the serial monitor

I haven't analysed deeply enough if this transmitter makes the receivers output-pin just "blink" HIGH/LOW if the transmitter has a HIGH/LOW on his input-pin.

This would be a basic test if they work at all.

If you can afford to buy two HC-12 modules in a set that includes a length-matched antenna I recommend them  
[https://howtomechatronics.com/tutorials/arduino/arduino-and-hc-12-long-range-wireless-communication-module/](https://howtomechatronics.com/tutorials/arduino/arduino-and-hc-12-long-range-wireless-communication-module/)

This tranceivers enable send and receive in both directions hence the name tran-ceiver  
and you simply use them with a serial connection.  
They represented wireless wires

---

<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:** [June 27, 2024, 9:45am UTC](https://forum.arduino.cc/t/i-cant-seem-to-get-rf-transmitter-and-receiver-working/1203014/8 "2024-06-27T09:45:51Z")

</div>

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