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.

Question about reduce transmission power

Other Parts Discussed in Thread: CC2500, SIMPLICITI

Hi all,

I am using eZ430-CC2500 chip and IAR software for my project. i want to use solar panel to power the msp, but i realised that the solar can last for a very short time.

So i am thinking to reduce the transmission power to reduce the current consumption. And i found these two actions:

IOCTL_ACT_RADIO_RXIDLE--put radio in idle state

 

IOCTL_ACT_RADIO_SETPWR --set output power level

 

 

Can anyone tell me that whether it can be used for my case? and How should i use it to control?

I hope i state my question clearly. Thank you inadvance!

Regards

  • Hi Ivy,

    If used correctly; both will reduce the power consumption for the boards.

    The first command will put the radio in idle mode. In a low power system, reducing the amount of time with the radio ON is crucial. Not sure what you are looking to do from a application perspective, but the easiest is to use a timer to create a timed protocol where the radio is only doing TX/RX when needed. When not used, the radio should be put in Idle or sleep. Same applies to the MCU.

    The second one is used to control the output power of the device. See the CC2500 datasheet table 31. for typical reduction. The IOCTL allows to set three different output powers, but this can easily be extended if needed. By default the values are 0x46, 0x97 and 0xFE (see mrfiRFPowerTable[] in mrfi_f1f2.c)

    Hope this helps.
    Kjetil

     

  • Hi kjetil,

    Thank you very much. It helps a lot.

    I've already used radio wakeup and radio sleep to make the raio on only when TX needed. So i should choose to control the output power to further reduce the power consumption right? And, how to write the comment to set the power? I am new to this program, so do you have any sample code?

    Thanks again.  

  • Hi Kjetil,

    Can i set the output power with IAR ? How should i do it?

    Thanks a lot in advance

  • Hi Ivy,

    Yes, have a look here:
    http://focus.ti.com/docs/toolsw/folders/print/cc2510dk-mini.html#Support%20Software

    The example code there contains some code for setting output power (line186 in simple_link.c).

    Regards,
    Kjetil

     

  • Hi Kjetil,

    Thank you. But when i tried to add the comment in, there shows the error that  "IOCTL_ACT_RADIO_SETPWR" is undefined. How to correct it?

    And is it possible to change the value of MRFI_SETTING_PATABLE0 in mrfi_radio.c  to control the output power and current consumption so that can save more power?

    Thanks in advance

    Regards

    Ivy

  • Ivy,

    Try including the file nwk_types.h to resolve your issue with IOCTL_ACT_RADIO_SETPWR being undefined.

    Yes it is possible to change the value of MRFI_SETTING_PATABLE0 to any value you wish that is compatible with your system.  You can also modify the values in the mrfiRFPowerTable array so that you can select several different power levels dynamically allowing you to optimize power consumption to meet changes in the deployed environment.

    Jim

     

  • Hi Jim & Kjetil

    Thanks very much. The problem has been solved.

    Ivy

  • Jim Noxon said:

    Ivy,

    Try including the file nwk_types.h to resolve your issue with IOCTL_ACT_RADIO_SETPWR being undefined.

    Yes it is possible to change the value of MRFI_SETTING_PATABLE0 to any value you wish that is compatible with your system.  You can also modify the values in the mrfiRFPowerTable array so that you can select several different power levels dynamically allowing you to optimize power consumption to meet changes in the deployed environment.

    Jim

     

    I am trying to alter the output power also but I am working with the ez430_chronos sample project. I am using the Limited CCS Core Edition v4 right now  so some of the files come excluded from the build. IOCTL_ACT_RADIO_SETPWR is set in main_ED_BM.c so I included this file in the build and edited it. However, it needed to reference bsp.h and bsp_board_defs.h so I included that as well but I am getting a different error now:

    "C:/Texas Instruments/ccsv4/msp430/include/msp430.h", line 743: fatal error: #error "Failed to match a default include file"
    1 fatal error detected in the compilation of "../simpliciti/Applications/application/End Device/main_ED_BM.c".
    Compilation terminated.

    Do you have any advice for this? Thank you.

  • My two cents worth for changing power:

    This is the power table found in mrfi_radio.c, I changed the 3rd entry to 9.4dB as per DN013 for my device.

    static const uint8_t mrfiRFPowerTable[] =
    {
    0x0D, //-20.8 dB
    0x34, //-10.9 dB
    //0x8E, //-0.6 dB
    0xC0 //9.4 dB
    };

    Then put this in your simpliciti code:

    //select the maximum power level
    int PwrIdx = IOCTL_LEVEL_2;
    SMPL_Ioctl( IOCTL_OBJ_RADIO, IOCTL_ACT_RADIO_SETPWR, &PwrIdx);

    This is the actual code in nwk_ioctl.c evetually called by the SMPL_Ioctl which you can see selects the index in the table.

    smplStatus_t nwk_radioControl(ioctlAction_t action, void *val)

    else if (IOCTL_ACT_RADIO_SETPWR == action)
    {
    uint8_t idx;

    switch (*(ioctlLevel_t *)val)
    {
    case IOCTL_LEVEL_2:
    idx = 2;
    break;

    case IOCTL_LEVEL_1:
    idx = 1;
    break;

    case IOCTL_LEVEL_0:
    idx = 0;
    break;

    default:
    return SMPL_BAD_PARAM;
    }
    MRFI_SetRFPwr(idx);
    return SMPL_SUCCESS;
    }

    ..