This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

CC1352P7: Waking up radio after updating settings

Part Number: CC1352P7


Tool/software:

Hello,

I try to change parameters centerFreq, loDivider for the radio, when radio is opened. After running the following commands:

1) RF_postCmd

2) RF_control

3) RF_yield

What command should be used to power up RF core in order to take in affect new settings?

Thanks,

Alex

  • you should just run your next RX or TX command, and the power driver and rf driver will make sure that the proper setup command and FS commands are executed first.

    Siri

  • Hello Siri,

    Thanks for so fast response.

    Since I need to change many parameters: frequency, fractFreq, centerFreq, intFreq, loDivider, TtxPower for frequency hopping radio, using RF_open and RF_close is time consuming: ~15ms.I need to do it faster. That is why I try to update setting, turn off RF core and turn on RF core. What tuning time can I expect? Or if there's some other solution?

    Because of some reason the sequence of operation you recommended, doesn't work: radio doesn't take data and there is no RF transmission. Please verify that used sequence of functions is correct:

    1) Initialisation of radio using default frequency and power, Executiog RF_open.

    2) Set up for a hopping frequency: execution of RF_postCmd with updated structure rfc_CMD_PROP_RADIO_DIV_SETUP_PA_t.

    3) Set up a hopping frequency:execution of RF_postCmd with updated structure rfc_CMD_FS_t.

    4) Set up power: execution of RF_postCmd with updated structure rfc_CMD_SET_TX_POWER_t.

    5) Update setup command: rf_cntrl = RF_control(rfHandle, RF_CTRL_UPDATE_SETUP_CMD, NULL).

    6) Executing the RF_yield;

    5) Loading  pointers to the first portion of Tx data.

    6) Start transmission using RF_postCmd with updated structure rfc_CMD_PROP_TX_ADV_t.

    7) radio doesn't go into the Transmit mode: no RF emission, no taken data.

    Do you see anything wrong in my sequence?

    Thanks,

    Alex

  • not exacty sure how your code looks like, so I took the rfPacketTx example from the SDK and made a small demo.

    I use the default 50 kbps PHY and change between sending at packet at 868 MHz @ 10 dBm out and at 915 MHz at 0 dBm out.

    Code is below:

    void *mainThread(void *arg0)
    {
        RF_Params rfParams;
        RF_Params_init(&rfParams);
    
        GPIO_setConfig(CONFIG_GPIO_GLED, GPIO_CFG_OUT_STD | GPIO_CFG_OUT_LOW);
    
        GPIO_write(CONFIG_GPIO_GLED, CONFIG_GPIO_LED_OFF);
    
        RF_cmdPropTx.pktLen = PAYLOAD_LENGTH;
        RF_cmdPropTx.pPkt = packet;
        RF_cmdPropTx.startTrigger.triggerType = TRIG_NOW;
    
        uint8_t i;
        for (i = 0; i < PAYLOAD_LENGTH; i++)
        {
            packet[i] = rand();
        }
    
        // open the rfDriver
        rfHandle = RF_open(&rfObject, &RF_prop, (RF_RadioSetup*)&RF_cmdPropRadioDivSetup, &rfParams);
    
        while(1)
        {
            packet[0] = (uint8_t)(seqNumber >> 8);
            packet[1] = (uint8_t)(seqNumber++);
    
            // Set freq 868 MHz
            RF_postCmd(rfHandle, (RF_Op*)&RF_cmdFs, RF_PriorityNormal, NULL, 0);
    
            // Transmit packet at 868 MHz
            RF_runCmd(rfHandle, (RF_Op*)&RF_cmdPropTx, RF_PriorityNormal, NULL, 0);
    
            // Change frequency
            RF_cmdFs.frequency = 915;
            RF_cmdPropRadioDivSetup.centerFreq = 915;
    
            // Set output power to 0
            RF_setTxPower(rfHandle, RF_TxPowerTable_findValue(txPowerTable, 0));
    
            // Make sure the setup command is being updated
            status = RF_control(rfHandle, RF_CTRL_UPDATE_SETUP_CMD, NULL);
            RF_yield(rfHandle);
    
            packet[0] = (uint8_t)(seqNumber >> 8);
            packet[1] = (uint8_t)(seqNumber++);
    
            // Set freq to 915 MHz
            RF_postCmd(rfHandle, (RF_Op*)&RF_cmdFs, RF_PriorityNormal, NULL, 0);
    
            // Transmit packet at 915 MHz
            RF_runCmd(rfHandle, (RF_Op*)&RF_cmdPropTx, RF_PriorityNormal, NULL, 0);
    
            // Change frequency back to 868 MHz
            RF_cmdFs.frequency = 868;
            RF_cmdPropRadioDivSetup.centerFreq = 868;
    
            // Set output power to 10
            RF_setTxPower(rfHandle, RF_TxPowerTable_findValue(txPowerTable, 10));
    
            // Make sure the setup command is being updated
            status = RF_control(rfHandle, RF_CTRL_UPDATE_SETUP_CMD, NULL);
            RF_yield(rfHandle);
        }
    }

    I measure around 1 ms from exiting TX on one frequency and entering on the next:

    Siri

  • Siri, thank you so much.