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.

How can I Reduce Advertising duration in the nonconnection mode

Hello TI Experts,

The image below is output of packet sniffer in my setup.

How can I reduce time duration of advertising? for example in the P.nbr. 33475 the advertising time duration is 138364us and I'm looking for a parameter which determine that. for your information I'm using keyfob project.

thanks.

 

  • Hello.

    Our 1.0 release had a bug causing those "0's" you see in adv and scan response.  I would recommend upgrading to 1.1 release which you can find at ti.com/blestack.  The keyFob project has also been updated in 1.1 to send items below, but if power is major concern you can also reduce this.

     // GAP - Advertisement data (max size = 31 bytes, though this is

    // best kept short to conserve power while advertisting)

    static uint8 advertData[] = 

      0x02,   // length of first data structure (2 bytes excluding length byte)

      GAP_ADTYPE_FLAGS,   // AD Type = Flags

      DEFAULT_DISCOVERABLE_MODE | GAP_ADTYPE_FLAGS_BREDR_NOT_SUPPORTED,

     

      // service UUID, to notify central devices what services are included

      // in this peripheral

      0x07,   // length of second data structure (7 bytes excluding length byte)

      GAP_ADTYPE_16BIT_MORE,   // list of 16-bit UUID's available, but not complete list

      LO_UINT16( LINK_LOSS_SERVICE_UUID ),        // Link Loss Service (Proximity Profile)

      HI_UINT16( LINK_LOSS_SERVICE_UUID ),        

      LO_UINT16( IMMEDIATE_ALERT_SERVICE_UUID ),  // Immediate Alert Service (Proximity / Find Me Profile)

      HI_UINT16( IMMEDIATE_ALERT_SERVICE_UUID ),

      LO_UINT16( TX_PWR_LEVEL_SERVICE_UUID ),     // Tx Power Level Service (Proximity Profile)

      HI_UINT16( TX_PWR_LEVEL_SERVICE_UUID )  

    };

     

    Br,

    -Greg

  • Thanks Greg. but I can't realize how I can reduce the advertising time duration in the disconnection mode. would you please tell me which parameter determine that?

     

  • The reason the advertising duration that you see is long is because you are transmitting additional zeros in your advertising data with each packet. By switching to v1.1 as Greg suggests, you will not transmit these additional zeros, which will effectively reduce the duration of the packets.

  • Hi Willis,

    Thanks for your advice. As you can see in the image bellow, I've  reduce the number 0s by changing advertising packet size, but I can't achieve to less than 100ms. it seems to be time interval between Advertising  event. Is this BLE stack limitation or I can use a parameter to reduce 100ms and for example achieve to 80ms?

    Thanks.

  • Use GAP_SetParamValue, and change the value of the parameters TGAP_CONN_ADV_INT_MIN  and TGAP_CONN_ADV_INT_MAX.

    -Greg

  • Hi Greg,

    I want to increase the advertising interval of non-connectable un-directed advertisement , i have used 

    GAP_SetParamValue(TGAP_GEN_DISC_ADV_INT_MIN , 8000);

    GAP_SetParamValue(TGAP_GEN_DISC_ADV_INT_MAX , 8000);

    to set the advertising interval to 5 seconds in case of connectable undirected advertisement,it is working but after the connection is established ,my keyfob will advertise non-connectable advertisement ( am using PeripheralBroadcaster role ) constantly around 1.28 seconds , how can i modify this interval ? 

    I have tried with 

    //Advertising Interval is set to 5 sec
    // GAP_SetParamValue(TGAP_CONN_ADV_INT_MIN , 8000);

    //GAP_SetParamValue(TGAP_CONN_ADV_INT_MIN , 8000);

    But i cannot able to find the non-connectable advertisement working ! 

    Any help on this is much appreciated.

    Regards,

    Senthil 

  • Hello Senthil,

    I am currently facing the same issue. Have you by any chance found an answer to that?

    Best regards,
    Gabriel