The Thunderboard Forum is no longer active. If you would like to post a question regarding Thunderboard Kits, please use the Bluetooth Forum.

This discussion and its replies are closed

Does anyone know where in the code is the setting for setting the advertising period?

I find that it goes into standby to fast for my requirements.

 

Yours Simon M.

  • Bluetooth Low Energy
  • Discussion Forums
  • Answered
  • Thunderboard Kits
Answered
  • You can fine tune the advertising time in file radio_ble.c. The timeout is implemented in function advertisingIteration()

     

    This define (in radio_ble.c) specifies the number of loop iterations until the device is put to sleep:


    /* Each iteration is 100 ms */
    #define APP_ADV_SLEEP_TIMEOUT_ITERATIONS 300

    Correct Answer
    0
  • Perfect!

    many thanks, and I notice it a remove 

    if( (loopCount - advStartedLC) > sleepTimeout ){

    block, it broadcasts continually.

     

    Thanks 

    Simon M.

    0
  • Screen Shot 2017-06-03 at 7.55.14 PM.png

    @samarkh

     

    Do you guys know what is happening here when I'm trying to edit the radio_ble.c? I try to Debug / Flash the update (changing code so that the TBSense stays advertising for longer) and it says the following ...

     

    Screen Shot 2017-06-03 at 9.26.52 PM.png

     

    Is it because I don't have the IAR ARM Toolchain installed? If so then please let me know which version I should be downloading (I see there are a number of versions... I assume it is the ARM, latest variety).

     

    Neal. 

    0
  • Hi Neal,

    No you don't need IAR any more, I haven't.

    follow this link

    http://community.silabs.com/t5/Bluetooth-Wi-Fi/Thunderboard-Sense-Do-I-need-IAR-to-compile-cpde/m-p/195435#M19330

     

    Yours Simon M.

    0
  • Also did you have the latest Bluetooth installed?

    0
  • @samarkh - I do however I don't think I had it selected. So have just updated that. Thanks. Will give it a try now. 

    0