Problems with NRF24L01 and Arduino

This is the 3rd time I have typed this up because it keeps failing UGH! But hello, I am currently having problems with my first "wireless" Arduino project using an Arduino Uno (Receiver) and an Arduino Pro Mini (transmitter) both using NRF24L01 modules. The two arduinos cannot interact with simple code of setting a message from one side to the other. However, I know that it works because I have tested it with two Unos!

Transmitter Code:

#include <SPI.h>
#include <nRF24L01.h>
#include <RF24.h>
RF24 radio(7, 8); // CE, CSN
const byte address[6] = "00001";
void setup() {
  radio.begin();
  radio.openWritingPipe(address);
  radio.setPALevel(RF24_PA_MIN);
  radio.setDataRate(RF24_250KBPS);
  radio.stopListening();
}
void loop() {
  const char text[] = "Hello World";
  radio.write(&text, sizeof(text));
  delay(1000);
}

Receiver Code:

#include <SPI.h>
#include <nRF24L01.h>
#include <RF24.h>
RF24 radio(7, 8); // CE, CSN
const byte address[6] = "00001";
void setup() {
  Serial.begin(9600);
  radio.begin();
  radio.openReadingPipe(0, address);
  radio.setPALevel(RF24_PA_MIN);
  radio.setDataRate(RF24_250KBPS);
  radio.startListening();
}
void loop() {
  if (radio.available()) {
    char text[32] = "";
    radio.read(&text, sizeof(text));
    Serial.println(text);
  }
}

Here is a picture of my Arduino Pro Mini Transmitter that I have made alongside a schematic.
IMG_8083 (1).jpg

IMG_8082 (1).jpg

IMG_8084 (1).jpg

These are the solutions that I have tried so far:

  • Checked that both NRF24L01 modules are working
  • Check the voltages of both NRF24L01 (3.3v) and Arduino (5V) is correct by using a multimeter
  • Tested that both the pro mini and NRF24L01 worked before soldering by using basic jumper cables and the power pins off of an Arduino Uno
  • Checked all cables and made sure they are in the correct spot

IMG_8083 (1).jpg

IMG_8082 (1).jpg

IMG_8084 (1).jpg

Have a look at this Simple nRF24L01+ Tutorial.

Wireless problems can be very difficult to debug so get the wireless part working on its own before you start adding any other features.

The examples are as simple as I could make them and they have worked for other Forum members. If you get stuck it will be easier to help with code that I am familiar with. Start by getting the first example to work

There is also a connection test program to check that the Arduino can talk to the nRF24 it is connected to. If the first example does not work be sure to try the connection test for both of your Arduinos. Nothing will work if the connection test fails.

A common problem with nRF24 modules is insufficient 3.3v current from the Arduino 3.3v pin. This seems to be a particular problem with the nano. The high-power nRF24s (with the external antenna) will definitely need an external power supply. At least for testing try powering the nRF24 with a pair of AA alkaline cells (3v) with the battery GND connected to the Arduino GND.

…R