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

Did not get "Constant carrier wave output for testing" working on nRF24L01+

Hello,

Like in the description, I dont get this to work. Im trying to get The nRF24L01+ connected to a PIC16LF18345. I did Some Pictures of the SPI logic and Here is a Part of the Code Ive written of the configuration for carrier Signal like described in the datasheet.

    while(1)
    {
    if(PORTCbits.RC4 == 0) //Startswitch
    {
    __delay_ms (2500);
        
    spi_start();
    spi_rx(0b00100000); //W + Reg CONFIG
    spi_rx(0x02); //PWR UP
    spi_stop();
    
    __delay_us(1700);
    
    spi_start();
    spi_rx(0b00100110); //W + Reg RF_SETUP
    spi_rx(0b10010110); 
    spi_stop();

    spi_start();
    spi_rx(0b00100101); //W + Reg RF_CH
    spi_rx(0x22); 
    spi_stop();

       while(1){
    PORTCbits.RC7 = 1;  //CE
                }
        }
    }

I have tried almost everything and so now im here and ask for help :) 

Parents
  • Hi,

     

    It looks like the device is responding with 0x21 in the first transaction, which is the STATUS register that is shifted out on the MISO pin. This indicates that the TX FIFO is full, and MAX_RT is set.

    In the second transaction, it looks like data is echoed at MISO/MOSI.

    The datasheet states:

    The content of the status register is always read to MISO after a high to low transition on CSN.

     

    This does not seem to be the case in your logic trace. I would recommend that you check your wired connections.

     

    Best regards,

    Håkon

     

  • The Connection Looks good i Think. Ive set the Frequency down to 32kHz for the best possible stability for the spi but...could it be the High Level of the MOSI/MISO pin between the 2 Transactions which will cause the Problem? But then it will be the nRF because the uC will take this lines low like in the Programm and, at the end of the scnd Transaction we see this too. I did a lot of testing with caps and resistors like in the datasheet, also tried something like Pull down resistors as Ive read on the Internet which worked for someone using a pic uC.

    Thank you for Your Time

    Daniel

Reply
  • The Connection Looks good i Think. Ive set the Frequency down to 32kHz for the best possible stability for the spi but...could it be the High Level of the MOSI/MISO pin between the 2 Transactions which will cause the Problem? But then it will be the nRF because the uC will take this lines low like in the Programm and, at the end of the scnd Transaction we see this too. I did a lot of testing with caps and resistors like in the datasheet, also tried something like Pull down resistors as Ive read on the Internet which worked for someone using a pic uC.

    Thank you for Your Time

    Daniel

Children
Related