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.

CC2640R2F: CC2640R2F

Part Number: CC2640R2F

Hi Support, my application was based on the Simple_Peripheral example. I am advertising two sets:

SDK in use: simplelink_cc2640r2_sdk_5_30_00_03

1. One set when a button is pushed, I advertise for 4 seconds, payload of 27bytes in total using legacy mode(GapAdv_params_t advParamLegacy = GAPADV_PARAMS_LEGACY_SCANN_CONN).

2. Second set every 40 seconds, I advertise every for 300ms, payload of 21bytes in total using legacy mode (GapAdv_params_t advParamLegacy = GAPADV_PARAMS_LEGACY_SCANN_CONN).

I want to advertise in longrange mode when the button is pushed and legacy mode every 40seconds.

When I change the GapAdv_params_t advParamLegacy = GAPADV_PARAMS_LEGACY_SCANN_CONN; to GapAdv_params_t advParamLongrange = GAPADV_PARAMS_AE_LONG_RANGE_CONN;

The above happens in the GAP_DEVICE_INIT_DONE_EVENT state.

However when I change the advertise type from legacy to longrange the code gest stuck in simple_peripheral_spin();

When I change back to legacy mode and recompile and run, then everything works fine.

What am I doing wrongly, and how do I get to advertise one set in long range and another set in legacy mode.

Thanks

  • Hi,

    Thank you for reaching out to us. I have a few questions that may help us resolve this as efficiently as possible. Is advertising disabled when the advertising parameter change is attempted? Are you using a BLE4 or BLE5 example? I would also suggest referencing the Scanning and Advertising SLA lab. This lab cover show to modify advertising parameters during runtime.

    Best Regards,

    Jan