TinyCircuits Forum
TinyCircuits Products => TinyDuino Processors & TinyShields => Topic started by: Bullwinkle on January 27, 2017, 07:03:02 PM
-
I've been searching for example of how to implement sleep/wake operation for the Tiny's Nordic BLE module.
If an API function(s) exists at the same level as "BLEsetup()", I can't find it. (for that matter, I'm not sure where
the BLEsetup() signature is defined). In my application, I've gotten my processor sleep/wake operations working
as desired, but the BLE connection remains active when the cpu sleeps -- I need to disconnect it, and have the client
code reconnect after cpu wakes up.
Any ideas are appreciated!
-
BLEsetup() is just in the UART.h/UART.ino file- it's just an adaption of the Nordic example code. There should be a lib_aci_sleep() function that's used if advertising times out, but I'm not sure of exactly how to implement it and wake up again- there's a lib_aci_wakeup() function, or you may just need to call lib_aci_connect to begin advertising again.
-
Thanks for the pointer... lib_aci_sleep() does exactly what I was looking for. Since I post a "shutdown" message to my client prior to sleeping, I don't need to use wakeup()... I just go thru my normal startup/connect sequence for reconnect.
Appreciate the help!
Jim