NRF24L01+ SimpleRX not working with integers

Using the tutorials provided by Robin2 here: (Robin2's Simple Tutorials), I have built two devices with NRF24L01 transceivers.
One device uses a BME to read the temp and humidity at a distant point, and send it back to the main Mega chip for display.

I have managed to get the devices working with the sample sketches, and the "CheckConn" sketch returns non-zero values, so I am reasonably confident the radios themselves are not the issue.

The remote version is a simple device and it seems to be working as expected. Temp and humidity read correctly, and the NRF Serial monitor returns "Data Sent 50 Acknowledge Received" once per second as expected.

The receiver is a basic mega with nothing else atached. The code is designed to return the value sent from the remote to the Serial Monitor, and is almost unchanged from the "SimpleRX Sketch" provided by Robin2 in the much referenced forum post.

I suspect the issue lies in the use of "int" instead of "char" for the data sent between the units, but I am not sure how to best resolve this. I am experienced with electrical work but very new to programming. This issue has me tearing my hair out because I am certain there is only a tiny yet elusive problem here.

Thanks in advance for your patience. I am happy to provide more info or photos if needed.

Transmitter Code: Seems to work properly!

#include <LiquidCrystal.h>
LiquidCrystal lcd(8, 9, 4, 5, 6, 7);
#include <SPI.h>
#include <nRF24L01.h>
#include <RF24.h>
#include <Wire.h>
#include <Adafruit_Sensor.h>
#include <Adafruit_BME280.h>

Adafruit_BME280 bme;

#define CE_PIN   3
#define CSN_PIN 2

const byte slaveAddress[5] = {'R','x','A','A','A'};

RF24 radio(CE_PIN, CSN_PIN); // Create a Radio

char RArrow = (char)B01111110;
char LArrow = (char)B01111111;
char Degree = (char)223;

int Z2Hum;
int Z2Temp;

unsigned long currentMillis;
unsigned long prevMillis;
unsigned long txIntervalMillis = 1000; // send once per second

void setup() {

    Serial.println("SimpleTx Starting");
bool status;
    status = bme.begin(0x76);
    if (!status) {
        Serial.println("Could not find a valid BME280 sensor, check wiring!");
        while (1);
      radio.setDataRate( RF24_250KBPS );
      radio.setRetries(3,5); // delay, count



void loop() {
    currentMillis = millis();
    if (currentMillis - prevMillis >= txIntervalMillis) {
        prevMillis = millis();

void Display(){
  lcd.setCursor(0, 0);
    lcd.setCursor(8, 0);

void TXOKDisplay(){
  lcd.setCursor(0, 1);
   lcd.print("Transmitting... ");
  void TXERRDisplay(){
  lcd.setCursor(0, 1);
   lcd.print("ERROR SENDING...");
void send() {

    bool rslt;
    rslt = radio.write( &Z2Hum, sizeof(Z2Hum) );
    Serial.print("Data Sent ");
    if (rslt) {
       Serial.println("  Acknowledge received");
    else {
        Serial.println("  Tx failed");


void MonitorTempHum(){
  int TempMeas = bme.readTemperature();
  int HumMeas = bme.readHumidity();
  Z2Hum = HumMeas;
  Z2Temp = Celcius2Fahrenheit(TempMeas);
  float Celcius2Fahrenheit(float celsius)
  return celsius * 9 / 5 + 32;

Receiver Code - Stops at "Simple RX Started" and does not appear to do anything else

// SimpleRx - the slave or the receiver

#include <SPI.h>
#include <nRF24L01.h>
#include <RF24.h>

#define CE_PIN   48
#define CSN_PIN 47
#define SS_PIN 53

const byte thisSlaveAddress[5] = {'R','x','A','A','A'};

RF24 radio(CE_PIN, CSN_PIN);

int dataReceived; // this must match dataToSend in the TX
bool newData = false;
char Z2Hum;


void setup() {

    pinMode(SS_PIN, OUTPUT);
    Serial.println("SimpleRx Starting");
    radio.setDataRate( RF24_250KBPS );
    radio.openReadingPipe(1, thisSlaveAddress);
    Serial.println("SimpleRx Started...");


void loop() {


void getData() {
    if (radio.available()) { &dataReceived, sizeof(dataReceived));
        newData = true;

void showData() {
    if (newData == true) {
        Serial.print("Data received ");
        Z2Hum = dataReceived;
        newData = false;

I don't immediately see anything wrong with the wireless stuff in your program - but I am not good at spotting the obvious.

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

Have you managed to send an int with a minimally modified version of one of my examples? If not then please post the program for your attempt.

When using SPI with a Mega you should set pin 53 as OUTPUT (it is the equivalent of Pin 10 on an Uno).