cancel
Showing results for 
Search instead for 
Did you mean: 

BLE sleep advertising at fast rate of 1 or 2 ms

DS.4
Senior II

Got this issue on entering sleep.

 

I set my advertising to 1 second, and do not touch it after.

 

Before sleep, all was good,  I was advertising every ~1 second

 

but when I enter sleep I notice it jumps to 1 or 2 ms.. very fast, and not so power consuming.

 

I didn't test with power testing tool, to validate the peaks, but only via the phone app.

 

Wonder what might be causing this?? Do I accidently shutdown some peripheral important for BLE?

 

 

4 REPLIES 4
FilipKremen
ST Employee

Hello,

can you please describe the issue more in detail? Can you show any waveform?

Also, if you could share the steps when you're testing it, so I could reproduce it on my side.

Thank you.

 

Best regards,

ST support

We are currently trying to get our hands on a better sniffing tool, but this might take some time..

 

Meanwhile,  did manage to improve it slightly by following the free rtos example with ble.

 

BTW, I am on stack 21 .

 

Now, I see a drop from 1 sec ( initial pre sleep setting ) to around 200-250 ms during sleep.

 

Any idea to why do I get this drop? Any debug I can add to BLE stack? Anything you know of that might be causing this ? 

 

I did follow the example as much as possible. HAL, RTC, CLOCKS.. ( FreeRTOS BleHeartRate)

 

We use a slightly different operating system, a CMSIS one.

 

Do you guys have a CMSIS RTOS sleep example?

 

 

 

 

FilipKremen
ST Employee

Hello,

which board do you use? Is it a custom board? You can enable debug traces in the app_conf.h file.

Can you please share the measurement? Thank you.

Unfortunately, there is no CMSIS RTOS sleep example in the WB package.

 

Best regards,

ST support

 

@FilipKremen

 

As soon as we hit EnterLowPower() , out advertising goes crazy ( 1- 2 ms ) 

 

This pretty sure is caused because we use PLL's in SystemClock_Config .

 

They are used also for our :ADC , RTC. 

 

(Although that's not the config you guys use in your example)

 

After turning PLL off , no issue !

 

BUT WHY? 

and is there any way we don't have to make grand changes in our clocks to fix this?

 



.