nRF24L01 + Arduino Uno + 3 servos + Joystickshield

i try to use nRF24L01 to control 3 servos , but i cannot work.

JOYSTICK_SHD_V2.0.pdf (40.5 KB)

jixieshoubiRX.ino (5.78 KB)

jixieshoubiRX.ino (5.78 KB)

but i cannot work.

Conveys absolutely no useful information that we don't already know. You would not be here if it worked.

Did you develop that code a little at a time, testing each piece before adding more?

groundfungus: Conveys absolutely no useful information that we don't already know. You would not be here if it worked.

Did you develop that code a little at a time, testing each piece before adding more?

yes, i test each part with test code, it work perfectly. But than i use the code for robotarm, it cannot work. I try to fix it, but it didn't work. I guess there are some problems in nRF24L01.

groundfungus: Conveys absolutely no useful information that we don't already know. You would not be here if it worked.

Did you develop that code a little at a time, testing each piece before adding more?

i test nRF24L01 again, not working!!! I think it is one of the reason for that.QAQ

Maybe this Simple nRF24L01+ Tutorial will help.

Debugging wireless is always difficult so get that part working first and then add the other parts piece by piece testing at each step.

...R

Robin2: Maybe this Simple nRF24L01+ Tutorial will help.

Debugging wireless is always difficult so get that part working first and then add the other parts piece by piece testing at each step.

...R

you know what happened? I tested the one of the nRF24L01 with RX code:

include

include

include

include

int value;

void setup() { Serial.begin(9600); Mirf.spi = &MirfHardwareSpi; Mirf.init();

Mirf.setRADDR((byte *)"FGHIJ"); Mirf.payload = sizeof(value); Mirf.channel = 90; Mirf.config(); Serial.println("Listening..."); }

void loop() { if(Mirf.dataReady()) { Mirf.getData((byte *) &value); Serial.print("Got data: "); Serial.println(value); } }

It printed "Got data:0 or -1 or 3969" , even the transimitter didn't exist! QAQ

TX code:

include

include

include

include

int value;

void setup() { Mirf.spi = &MirfHardwareSpi; Mirf.init(); Mirf.setRADDR((byte *)"ABCDE"); Mirf.payload = sizeof(value); Mirf.channel = 90; Mirf.config(); }

void loop() { Mirf.setTADDR((byte *)"FGHIJ"); value = random(255); Mirf.send((byte *)&value); while(Mirf.isSending()) delay(1); delay(1000); }

So i guess this nRF24L01 went wrong, i need a brand-new one to test again.