NRF24L01 and AVR - Does not transmit / Receive

Discussion about wireless devices

Re: NRF24L01 and AVR - Does not transmit / Receive

Postby rrupad » Tue Sep 30, 2014 2:16 pm

As regards to the power supply to the nRF, I have two Eneloops (AA) supplying power - reads 2.69 volts as of now - within the voltage bandwidth of 1.9V to 3.6V.

Regards,

Ravi Upadhyaya
rrupad
 
Posts: 20
Joined: Thu Sep 25, 2014 9:24 am

Re: NRF24L01 and AVR - Does not transmit / Receive

Postby brennen » Tue Sep 30, 2014 3:24 pm

That voltage should be sufficient to get the chip to work. You can email me those images by clicking the little envelope icon by any one of my posts.
brennen
Site Admin
 
Posts: 395
Joined: Sun Aug 17, 2008 2:15 pm

Re: NRF24L01 and AVR - Does not transmit / Receive

Postby rrupad » Tue Sep 30, 2014 5:43 pm

Scoured your posts carefully to find the little envelope... Found a PM icon, and an envelope at the top right corner - adjacent to ^Av. The PM icon gives me a message page, however I do not see any file attachment options. There is a small icon ahead your name in each of the posts, but clicking on it seems to show the post again..

I am not sure why it does not show up!!!!

Please share your e-mail id - I shall send in the screen shots.

Thanks

Ravi Upadhyaya
rrupad
 
Posts: 20
Joined: Thu Sep 25, 2014 9:24 am

Re: NRF24L01 and AVR - Does not transmit / Receive

Postby rrupad » Wed Oct 01, 2014 2:23 am

Hi Brennen:

Please send a test mail to ravi_upadhyaya@hotmail.com and I shall send the screen shots.

Thanks,
Ravi Upadhyaya
rrupad
 
Posts: 20
Joined: Thu Sep 25, 2014 9:24 am

Re: NRF24L01 and AVR - Does not transmit / Receive

Postby rrupad » Wed Oct 01, 2014 1:26 pm

Hi Brennen:

I have sent a mail to your diyembedded e-mail ID with the screen shots. This is FYI.

Regards,
Ravi Upadhyaya
rrupad
 
Posts: 20
Joined: Thu Sep 25, 2014 9:24 am

Re: NRF24L01 and AVR - Does not transmit / Receive

Postby brennen » Thu Oct 02, 2014 5:59 pm

Sorry it took so long to respond. In your screenshots, I don't see anything obviously wrong. It's also difficult to verify in your screen shots, but you want to make sure that the data line is clocked out first, then you get a rising edge on the clock (in traditional SPI speak, CPOL and CPHA should both be zero in your AVR's respective settings bits...see http://en.wikipedia.org/wiki/Serial_Per ... _and_phase). Your CPOL value looks correct, since your clock is at '0' at rest. In v1.0 of the nRF24L01+ datasheet, you can see the expected SPI timings on p. 52 in figures 26 (reading) and 27 (writing). I know that when I was first bringing up the nRF24L01 years ago, I had the CPHA value wrong and I would sometimes read values correctly, and other times I wouldn't.

One other thing to note, is that if you have auto-acknowledge and auto-retry enabled, TX packets DO NOT get deleted from the TX FIFO if they fail (you should get a MAX_RT interrupt when this happens, though).
brennen
Site Admin
 
Posts: 395
Joined: Sun Aug 17, 2008 2:15 pm

Re: NRF24L01 and AVR - Does not transmit / Receive

Postby rrupad » Fri Oct 10, 2014 3:27 am

Hi Brennen:

It started working!!! I connected a 1uF capacitor across the GND and VCC pins of the nRF and supplied a 3.3V regulated power.

Thank you, Brennen for your time and effort in resolving this issue.
rrupad
 
Posts: 20
Joined: Thu Sep 25, 2014 9:24 am

Re: NRF24L01 and AVR - Does not transmit / Receive

Postby rrupad » Fri Oct 10, 2014 12:01 pm

Hi Brennen:

The receiver too is working. However, after receiving the first packet, it stops receiving further packets. I am transmitting "ABCD" continuously from the transmitter.

Any tips as to why?

Thanks in advance,
rrupad
 
Posts: 20
Joined: Thu Sep 25, 2014 9:24 am

Re: NRF24L01 and AVR - Does not transmit / Receive

Postby brennen » Fri Oct 10, 2014 12:46 pm

Just to verify, you know for a fact that the TX is still sending packets, as in getting TX_DS interrupts after the first one? If you're getting MAX_RT interrupts, then the RX is *not* going to be receiving packets.
brennen
Site Admin
 
Posts: 395
Joined: Sun Aug 17, 2008 2:15 pm

Re: NRF24L01 and AVR - Does not transmit / Receive

Postby rrupad » Fri Oct 10, 2014 1:22 pm

Yes Brennen. TX is sending packets - The status register is as shown below. Retries register has been set to 0. On the Logic Analyzer - I can see the IRQ pin going low after each packet transmit.

Code: Select all
--------------- Transmitter ----------------
Reg : a    Val : e7e7e7e7e7
Reg : 10    Val : e7e7e7e7e7
======== TX - MY settings =============
Reg : 0    Val : 2 -> CONFIG
Reg : 1    Val : 0 -> AUTO ACK
Reg : 2    Val : 1 -> RECEIVE PIPE
Reg : 3    Val : 3 -> ADDR WIDTH
Reg : 4    Val : 0 -> RETRIES
Reg : 5    Val : 2 -> RF-CHANNEL
Reg : 6    Val : 7 -> RF SETUP
Reg : 7    Val : 0 -> STATUS
Reg : 8    Val : 0 -> OBSERVE TRANSMIT
Reg : 9    Val : 0 ->
Reg : 10    Val : 4
Reg : a    Val : e7e7e7e7e7
Reg : 10    Val : e7e7e7e7e7
--------------------------------------------------

--- Val is in Binary ---------
Reg : 7    Val : 0
Reg : 17    Val : 10
Reg : 7    Val : 100000 -> TX_DS is set
Reg : 17    Val : 10
Reg : 7    Val : 100000 -> TX_DS is set
Reg : 17    Val : 10
Reg : 7    Val : 100000 -> TX_DS is set
Reg : 17    Val : 10
Reg : 7    Val : 100000 -> TX_DS is set
Reg : 17    Val : 10
Reg : 7    Val : 100000 -> TX_DS is set
Reg : 17    Val : 10
Reg : 7    Val : 100000 -> TX_DS is set
.
.
.



The Receiver printout

Code: Select all
======== RX - MY settings =============
Reg : 0    Val : 3 -> CONFIG
Reg : 1    Val : 0 -> EN_AA
Reg : 2    Val : 1 -> RX_ADDR
Reg : 3    Val : 3 -> ADDR WIDTH
Reg : 4    Val : 0 -> RETRIES
Reg : 5    Val : 2 -> RF-CHANNEL
Reg : 6    Val : 7 -> RF-SETUP
Reg : 7    Val : 60 -> STATUS
Reg : 8    Val : 0 -> OBSERVE TRANSMIT
Reg : 9    Val : 0
Reg : 10    Val : 4 -> PAYLOAD WIDTH
Reg : a    Val : e7e7e7e7e7 - RX-ADDR PIPE 0
Reg : 10    Val : e7e7e7e7e7 - TX-ADDR
----------------------------------------------------------------
RX - FIFO : 10010
RX - Status : 1100000 <- RX_DR is set here
Recd Buffer : ABCD <- Received data
RX - FIFO : 10001
RX - Status : 101110 <- Funnily TX_DS is set here ??!!
Recd Buffer :
RX - FIFO : 10001
RX - Status : 101110
Recd Buffer :
RX - FIFO : 10001
RX - Status : 101110
Recd Buffer :
.
.
.
rrupad
 
Posts: 20
Joined: Thu Sep 25, 2014 9:24 am

PreviousNext

Return to Wireless

Who is online

Users browsing this forum: No registered users and 1 guest

cron