cancel
Showing results for 
Search instead for 
Did you mean: 

WICED Smart Bluetooth

Anonymous
Not applicable

I can use devlpm_registerForLowPowerQueries() to disable sleep mode, , but how can I restore into sleep mode?

1 Solution
ArvindS_76
Employee

Are you using a 20732S module? If so, please search the forums for crystal warmup (or xtal warmup) issue and see how to increase the crystal warmup time to something of the order of 4000 or 5000 uS.

View solution in original post

0 Likes
9 Replies
Anonymous
Not applicable

Disable sleep mode when callback return 0, Enter sleep mode when callback return other number. In sleep mode, Can I keep the Bluetooth connection?

0 Likes
MichaelF_56
Moderator
Moderator

Unfortunately, deep sleep (hidoff) is not supported while the connection is up.

0 Likes
ArvindS_76
Employee

And when connected/scanning/advertising, the device will always sleep between RF activity if the application allows it and there is sufficient time before the next scheduled activity. Deepsleep/hid-off does not retain state, so the chip cannot enter deep sleep when connected.

0 Likes
MichaelF_56
Moderator
Moderator

Note that there are 14 GPIOs on the module and most can drive/sink up to 2mA and are capable of waking device from sleep or deep sleep.

In addition, there are multiple low power modes, and in many cases the firmware automatically handles low power states (as mentioned previously).

In addition, the application may choose to participate in sleep and deep sleep decisions.

Here's a list of the modes:

  • Pause
    • The processor is idle if sleep is not allowed or there is not enough time to sleep
    • All state information is maintained
    • Near 0 cycle latency to wake up
  • Sleep
    • When lower power consumption is required
    • All state information is maintained
    • Can be woken up by timer or GPIO/ Keyscan /Quadrature sensors
    • About 2 mS latency to wake up
  • Deep Sleep
    • No state information is maintained
    • Can be woken up by GPIO/ Keyscan /Quadrature sensors
    • Includes ability to wake after configured time
      • With internal clock, can wake anywhere from 64mS to ~36 Hrs.
      • With external 32 KHz xtal, 128mS to ~144 Hrs
Anonymous
Not applicable

I set the fine_timer_interval to 12.5. I need use PWM to driver the LED light, so I callback return 0 in devlpm_registerForLowPowerQueries() function. When I don't need PWM output, I callback return 80000 to enter low power mode. In low power mode, Can I keep the Bluetooth connection? In reality, some Bluetooth devices can remain connected, some not。 Why?

0 Likes
ArvindS_76
Employee

Yes, a connection can be kept when sleep is enabled (but not when deep sleep engages). When you say some devices do not remain connected, what do you see? Does the connection drop? Could you please give us some more information?

0 Likes
Anonymous
Not applicable

Sometimes, I need output PWM. So I return 0 in devlpm_registerForLowPowerQueries() callback. When I need enter sleep mode, I return 80000 in devlpm_registerForLowPowerQueries() callback. I rely devlpm_registerForLowPowerQueries () callback to enter sleep or wake up. In sleep mode, some Bluetooth devices can remain connected, some not. And normal timer(bleprofile_regTimerCb) of some devices is stop.

0 Likes
ArvindS_76
Employee

Are you using a 20732S module? If so, please search the forums for crystal warmup (or xtal warmup) issue and see how to increase the crystal warmup time to something of the order of 4000 or 5000 uS.

View solution in original post

0 Likes
Anonymous
Not applicable

Thank you for your help. It's OK.

0 Likes