• Resolved

CC2540 consumption in advertising

Hello,

looking at SimpleBLEPeripheral I was not able to find where default values of minimum and maximum advertising interval default values are defined and assessed.

In time between adversting events, does CC2540 go in low power mode , when in advertising ? How can be estimated the power consumption vs. advertising interval?

  • Hi 

       You can start and stop advertising using the gap events. See peripheral.c file

    GAPROLE_ADVERT_ENABLED and DEFAULT_ADVERT_OFF_TIME is for how long the device will advertise before going into sleep mode.There are four special physical channels in bluetooth for advertisement. GAP_EndDiscoverable()  is used to end advertisment and sal_set_event( gapRole_TaskID, START_ADVERTISING_EVT ) can be used to start

    You should check the status of your device before advertisement as you can connect to only one central device at once so no point in advertising always

    The simpleBLE example goto simplebleperiheral c file take a look at these two initializations

        GAPRole_SetParameter( GAPROLE_ADVERT_ENABLED, sizeof( uint8 ), &initial_advertising_enable );

        GAPRole_SetParameter( GAPROLE_ADVERT_OFF_TIME, sizeof( uint16 ), &gapRole_AdvertOffTime );

    Im not sure about power consumption , but ive seen it in the forums somewhere.let me know if you find any specifics

     

     

     

  • Hi Vasco,

    i think you can find power consumption vs. advertising interval by method in the following link:

    http://focus.ti.com/lit/an/swra347/swra347.pdf

    Cheers

  • In reply to Younes Rashidi:

    I went through  

    http://focus.ti.com/lit/an/swra347/swra347.pdf

    On page 22 to measure the standby current in PM2 state we enter MIN AND MAX connection interval to be 3200 which is 4 seconds.

    "With these settings, the effective connection interval is 8 seconds, meaning that the CC2540 

    will be in PM2 for 8 seconds between each connection event. Click the “Establish” button to 

    form the connection between the devices. "

    Then how do you get 8 seconds effective interval?

    What is MIN and MAX connection interval and how are these actually used to get the connection interval for communication

    Thankyou

  • The default advertising interval is 100ms. This can be changed by directly calling the GAP API function GAP_SetParamValue and changing the value of the parameters TGAP_LIM_DISC_ADV_INT_MIN and TGAP_LIM_DISC_ADV_INT_MAX.

    Yes, the CC2540 does go into low power mode between advertising events.

  • In reply to Hansen Dsouza:

    The effective connection interval is 8 seconds because slave latency is set to 1, and the connection interval is set to 4s. For more details on the terms "connection interval", "effective connection interval", and "slave latency", please see the software developer's guide.

    The CC2540 BLE controller actually always uses the MAX connection interval, though for clarity the app note just recommends setting the two values equal so that you can just specify the exact interval desired. The reason for having a MIN and MAX value is that the BT 4.0 spec requires this, primarily for systems in which the controller and host are implemented as separate devices.

  • In reply to Willis1:

    Willis

        Thanks i will try that out

         Being a peripheral device do I have to be in discoverable mode ie. advertising in order for a central device to be able to connect to me.

         If so then in a scenario where communication has to be re established once broken should the peripheral device have to be continously advertising?

  • In reply to Hansen Dsouza:

    Hi

        I put the device in general discovery mode so the device will keep advertising when connection is lost.I noticed on the oscilloscope that the advertising rate was quite high about 10ms so I used 

        GAP_SetParamValue(TGAP_GEN_DISC_ADV_INT_MIN , 15000);

        GAP_SetParamValue(TGAP_GEN_DISC_ADV_INT_MAX , 15000);

    to set it to 15 secs and I can still detect the device now using Btool.

    Im gonna have to disable the automatic battery reading feature because the device keeps waking up out of PM3

     

    Anyway i can scan for advertisement being a peripheral instead of broadcasting to reduce power? 

  • In reply to Hansen Dsouza:

    Hi Dsouza ,

    The advertising interval is from the 20 ms to 10.24 s ( I have got it from Ti's Deep dive BLE training ppt ) but how can you set to 15 secs ???

    Thanks in advance ,

    Senthil kumar  

  • In reply to Willis1:

    Willis,

    I have read these posts and I am still somewhat confused on how to determine the power consumption for a BLE device during advertising only.  I know that Advertising Interval can be in the range of 20 ms to 10.24 s.  So for example, if my advertising interval is set to 100 ms, how do I determine what the power consumption is for an advertising interval time of 100 ms?

  • In reply to James Coleman:

    James,

    Have you read this applicatiopn note:

    http://www.ti.com/general/docs/litabsmultiplefilelist.tsp?literatureNumber=swra347a

    That might give some more insights.

    Let me know if it helps.