introduce HCI states SLEEPING and FALLING_ASLEEP, introduce HCI power mode command SLEEP

This commit is contained in:
matthias.ringwald 2011-01-06 23:07:41 +00:00
parent 56a25c4cef
commit 15d7b8a815
2 changed files with 22 additions and 5 deletions

View File

@ -11,12 +11,26 @@
- Cocoa run_loop: added timeouts, include in libBTstack.dylib build - Cocoa run_loop: added timeouts, include in libBTstack.dylib build
2010-xxxx: Release 0.2 - revions xxx 2010-xxxx: Release 0.2 - revions xxx
- limit size of /tmp/hci_dump.pklg to 1000 packets (max 1 MB) - limit size of /tmp/hci_dump.pklg to 1000 packets (max 1 MB)
- power handling: receive power notifications
NEXT: NEXT:
- figure out how to receive iPhone System Power IONotifications (in BTdaemon) to detect, when phone gets locked - power handling
- have a look at External Accessory interface by Apple - it's quite similar - DONE: figure out how to receive iPhone System Power IONotifications (in BTdaemon) to detect, when phone gets locked and wakes up
- DONE: introduce HCI states SLEEPING and FALLING_ASLEEP
- DONE: introduce HCI power mode command SLEEP
- stop all baseband connections on HCI_POWER_OFF and HCI_POWER_SLEEP
- for now, treat sleep/wake the same as power off/on
- decide on configure flags
- clean up components
- decide what to do with the CocoaTouch code.
- do nothing
- add it to libBTstack.dylib
- provide a libBTstackCocoaTouch.dylib?
- move RFCOMM code into BTdaemon - move RFCOMM code into BTdaemon
- have a look at External Accessory interface by Apple - it's quite similar in function to BTstack
- HCI CMD packet is limited to 1024 bytes payload. SDP records could be larger than that. Options: - HCI CMD packet is limited to 1024 bytes payload. SDP records could be larger than that. Options:
- provide a way to transfer SDP records in segments - provide a way to transfer SDP records in segments
- ignore HCI command lenght on socket connection and directly stream data without buffer - ignore HCI command lenght on socket connection and directly stream data without buffer

View File

@ -174,7 +174,8 @@ extern "C" {
*/ */
typedef enum { typedef enum {
HCI_POWER_OFF = 0, HCI_POWER_OFF = 0,
HCI_POWER_ON HCI_POWER_ON,
HCI_POWER_SLEEP
} HCI_POWER_MODE; } HCI_POWER_MODE;
/** /**
@ -184,7 +185,9 @@ typedef enum {
HCI_STATE_OFF = 0, HCI_STATE_OFF = 0,
HCI_STATE_INITIALIZING, HCI_STATE_INITIALIZING,
HCI_STATE_WORKING, HCI_STATE_WORKING,
HCI_STATE_HALTING HCI_STATE_HALTING,
HCI_STATE_SLEEPING,
HCI_STATE_FALLING_ASLEEP
} HCI_STATE; } HCI_STATE;
/** /**