How to WAKEUP BLE module from sleep/deepsleep if no HW connection.

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
Anonymous
Not applicable

Hi All,

   

I am using CYBLE 012011-00 module in my system.

   

basic function of the module is whatever received from PC based application to put it to UART.

   

I am facing issue in implementation of low power modes idea for my system is when PC will want to connect/send data to it, module should wakeup from sleep/deepsleep.

   

problem is i don't have any HW pins to wakeup the module and don't know can connection request from PC can wakeup the module.

   

i am using low power mode code from UART-BLE Peripheral example

   

but the problem is before connection to PC it is going to sleep i even tried putting delay but after connection module is getting disconnected and put into deepsleep and never wakesup.

   

attaching settings please suggest any changes need to do?

0 Likes
1 Solution
AnjanaM_61
Moderator
Moderator
Moderator
5 comments on KBA First comment on KBA 5 questions asked

Hi Sagard,

   

If you don't have an option of hardware interrupt, you can use WDT interrupt.

   

2.check for central device if not go to sleep/deepsleep - once advertisement timed out, you can put device in deepsleep. Then start WDT timer which set for the next wake up time.

   

3, 4 will do automatically in the low power code.

   

Please refer our low power appnote for better understanding: http://www.cypress.com/documentation/application-notes/an92584-designing-low-power-and-estimating-ba...

   

Thanks & Regards,
Anjana

View solution in original post

0 Likes
6 Replies
lock attach
Attachments are accessible only for community members.
Anonymous
Not applicable

Here are the low power settings attachments,

0 Likes
Anonymous
Not applicable

If the BLESS is advertising or connected to another bluetooth device, then it will "wakeup" at intervals to check connection/data, and thus will allow you to be in low power most of the time. If you are NOT advertising or connected to a bluetooth device, then going to sleep will not be wake-able without hardware pin interrupts.

0 Likes
lock attach
Attachments are accessible only for community members.
Anonymous
Not applicable

Hi Pratt,

   

Thanks For Reply,

   

But now i am confused cause the design requirement in my project doesn't have scope for HW connection so no HW pin interrupts.

   

what are my option for still implementing low power mode because requirement is as below:-

   

1.BLE module should wakeup periodically after like 30-60 mins advertised

   

2.check for central device if not go to sleep/deepsleep

   

3.if connection established wait for command from central if no command sleep/deepsleep

   

4.if command received respond to it wait for next if no command then sleep/deepsleep

   

Please suggest if any solution is available.

   

attaching the code snippet.PFA

0 Likes
Anonymous
Not applicable

1. You can try setting the advertisement interval to the "maximum" value, and then just restart the advertisement if the number of timeouts*timeout-time is less than 30-60 minutes. (The unit will wakeup when the BLESS fires interrupts; iirc, this includes advertisement intervals, connection intervals, and BLE communications requests (from a connected device))

   

2. If the device is set as a peripheral, then it "advertises" at timing intervals, with the central device requesting a connection when it wants to connect to the peripheral device. If the peripheral is currently advertising, then the central will "see" it, and only needs to request a connection to connect. This "advertising" can be implemented while the unit is deep sleeping/sleeping.

   

3. You can have the unit go to deep sleep/sleep while waiting for commands from the connected central device, or you can have it stay awake for a fixed time then go to sleep after a timeout, or do a mixture of both.

   

4. This would be more or less the same as number 3.

   

My suggestion would be to try the example low-power mode BLE project to fully test/understand how the BLE operation works, and how it interweaves with low-power modes. That way, you can understand fully how the hardware works before fully committing to something longer-term. The UART to BLE Peripheral Example should be very close to what you are looking for, but you will probably need to change a couple things. The "UART to BLE Central" Example would be implemented on your PC.

   

Tl;dr; Everything you listed can/is possible to implement on the BLE modules, but it does take some architecting to make sure it works properly.

0 Likes
AnjanaM_61
Moderator
Moderator
Moderator
5 comments on KBA First comment on KBA 5 questions asked

Hi Sagard,

   

If you don't have an option of hardware interrupt, you can use WDT interrupt.

   

2.check for central device if not go to sleep/deepsleep - once advertisement timed out, you can put device in deepsleep. Then start WDT timer which set for the next wake up time.

   

3, 4 will do automatically in the low power code.

   

Please refer our low power appnote for better understanding: http://www.cypress.com/documentation/application-notes/an92584-designing-low-power-and-estimating-ba...

   

Thanks & Regards,
Anjana

0 Likes
Anonymous
Not applicable

Good catch on the WDT Anjana; I forgot to mention that

0 Likes