Hi,
I have got a nRF24L01 device (sparkfun: SparkFun Transceiver Breakout - nRF24L01+ (RP-SMA) - WRL-00705 - SparkFun Electronics ), a Arduino Diecimila and a robot.
The robot is configurated with this parameters:
Channel: 10
Address: AISOY
Payload: 32
Speed: 1 Mbps
CRC ON with 1 byte
I'm using this library: Arduino Playground - Nrf24L01 and I connected nRF24L01 with arduino as in this url.
Datasheet of nRF24L01 : Explore our product portfolio - nordicsemi.com
On page 54 can be seen the configurable registers.
My code:
#include <SPI.h>
#include <Mirf.h>
#include <nRF24L01.h>
#include <MirfHardwareSpiDriver.h>
#include "Arduino.h"
byte data[32];
void setup(){
Serial.begin(9600);
Mirf.spi = &MirfHardwareSpi;
Mirf.csnPin = 8;
Mirf.cePin = 7;
Mirf.init();
Mirf.payload = 32;
Mirf.channel = 10;
Mirf.config();
Mirf.setRADDR((byte*)"AISAY");
Mirf.configRegister(RF_SETUP, 0x80); //Air data rate 1Mbit, 0dBm, Setup LNA
Mirf.configRegister(EN_AA, 0x00); //Disable auto-acknowledge
Mirf.configRegister(SETUP_RETR, 0x00);
Mirf.configRegister(CONFIG, 0x7B);
Mirf.configRegister(SETUP_AW, 0x03);
Serial.println("Configuration Success.");
delay(500);
}
void loop(){
if(Mirf.dataReady()){
Mirf.getData(data);
Serial.println(data[0]);
Mirf.flushRx();
}
}
I want send from robot to nRF24L01 a string, for example "333" and read 3 with serial monitor to verify that is working well.
But when I uploaded this sketch, and I see the serial monitor I read this (robot didn't send nothing, was off, I only was testing nRF24L01):

Why if i didn't send nothing? Noise? bad configuration? Mirf.dataReady() should be 0...
Thanks for the replys! ![]()