各位大大, 請問如何在BLE已連接的情況下下令kernel叫QN9021進入deep sleep?
// Check whether the chip can enters sleep mode
//
// Chip enter sleep condition:
// ±-------±-------±-------±-------±-------+
// | USR | | | | |
// | BLE | ACTIVE | IDLE | SLEEP | DEEP |
// ±-------±-------±-------±-------±-------+
// | ACTIVE | active | active | active | active |
// | IDLE | active | idle | idle | idle |
// | SLEEP | active | idle | sleep | deep |
// ±-------±-------±-------±-------±-------+
在main program中看到這個表,需要USR進入DEEP SLEEP和BLE進入SLEEP 才可以令QN9021進入DEEP SLEEP。
在usr_sleep() 的function中看見若果BLE還有event的時候就不能進入deep sleep,那麼我們是否應該叫kernel 清除event還是應該其他方法做才能令它進入deep sleep?