This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

NRF24L01+ doesn't receive on pipes 2-5

Hello all,

after a long period of trial and error I come for advice. I use the NRF24L01+ module with a slightly modified NRF24-library based on the work of MikeM (www.airspayce.com/.../). I am aware of the upgrade to the RadioHead library, I just wanted to go through the code myself. And: I want to use multiple pipes.

Now: I do have a working setup.

Module 1 sends to address "recv1"

Module 2 receives as address "recv1" on pipe1, with auto ACK enabled

As soon as I change the pipe on Module 2 - the receiving end - to pipe 2 all communication stops :( It just doesn't want to receive anything on pipe 2 - 5.

A registry dump where everything is working from the receiving end:

00: 0C: 0000 1100<br>
01: 3F: 0011 1111            <--- Auto ACK enabled on pipe 0-5<br>
02: 3F: 0011 1111            <--- Pipe 0-5 enabled<br>
03: 03: 0000 0011<br>
04: 73: 0111 0011<br>
05: 02: 0000 0010<br>
06: 26: 0010 0110<br>
07: 0E: 0000 1110<br>
08: 00: 0000 0000<br>
09: 00: 0000 0000<br>
0A: E7 E7 E7 E7 E7 ççççç     <--- pipe 0 address (not used)<br>
0B: 72 65 63 76 31 recv1     <--- receiving address on pipe 1<br>
0C: 32 32 32 32 32 22222     <--- pipe 2-5 only have LSB different from pipe 1<br>
0D: 33 33 33 33 33 33333<br>
0E: 34 34 34 34 34 44444<br>
0F: 35 35 35 35 35 55555<br>
10: E7 E7 E7 E7 E7 ççççç     <--- no transmit address necessary<br>
11: 00: 0000 0000<br>
12: 00: 0000 0000<br>
13: 00: 0000 0000<br>
14: 00: 0000 0000<br>
15: 00: 0000 0000<br>
16: 00: 0000 0000<br>
17: 11: 0001 0001<br>
1C: 2F: 0010 1111<br>
1D: 05: 0000 0101<br>

A registry dump where it doesnt work anymore from the receiving end:

00: 0C: 0000 1100<br>
01: 3F: 0011 1111<br>
02: 3F: 0011 1111<br>
03: 03: 0000 0011<br>
04: 73: 0111 0011<br>
05: 02: 0000 0010<br>
06: 26: 0010 0110<br>
07: 0E: 0000 1110<br>
08: 00: 0000 0000<br>
09: 00: 0000 0000<br>
0A: E7 E7 E7 E7 E7 ççççç<br>
0B: 72 65 63 76 32 recv2    <--- changed this so pipe 1 hasnt the same address anymore<br>
0C: 31 31 31 31 31 11111    <--- now this is "1", combined with "recv" makes "recv1"<br>
0D: 33 33 33 33 33 33333<br>
0E: 34 34 34 34 34 44444<br>
0F: 35 35 35 35 35 55555<br>
10: E7 E7 E7 E7 E7 ççççç    <--- no transmit address necessary<br>
11: 00: 0000 0000<br>
12: 00: 0000 0000<br>
13: 00: 0000 0000<br>
14: 00: 0000 0000<br>
15: 00: 0000 0000<br>
16: 00: 0000 0000<br>
17: 11: 0001 0001<br>
1C: 2F: 0010 1111<br>
1D: 05: 0000 0101<br>

I have no clue why I don't receive anything on pipe 2-5, and have no idea what to test for next. Has anyone got pipes 2-5 working?

Kind regards,

Jack

Parents
  • The address for the pipes is shifted in LSB first. Pipe 2-5 share the 4 MSB's with pipe 1. In my code something happens like:

    [code] address = "recv1"

    shift this into the address for pipe 1. [/code]

    And this is where things go wrong: "recv1" sort of implies the "1" is the LSB, but the code shifts this out to the NRF24 as the last byte, so the NRF treats it like the MSB. To the NRF the LSB is "r" !

    Now in order to set pipe 2 to "recv2" I did:

    [code] address = "recv2"

    and shift this into pipe 2. [/code]

    The code does pick the "2" as the LSB to shift out to the NRF (thinking address[4] is the LSB), but instead of setting the address to "recv2" we get "2ecv1".

    My solution was to adapt the code so address runs from LSB to MSB, and for pipe 2-5 it uses address[0] to write for the LSB for one of the pipes 2-5.

    Cheers,

    Jack

  • Thank you for the reply, yes I figured it out :D Just wanted to share for in case someone else bumps into this problem, either with or without the specific library I mentioned.

Reply Children
No Data
Related