Loading system/stack/acl/acl.h +1 −0 Original line number Diff line number Diff line Loading @@ -21,6 +21,7 @@ #include <unordered_set> #include <vector> #include "stack/acl/peer_packet_types.h" #include "stack/include/acl_api_types.h" #include "stack/include/bt_types.h" #include "stack/include/btm_api_types.h" Loading system/stack/acl/peer_packet_types.h +16 −0 Original line number Diff line number Diff line Loading @@ -19,6 +19,22 @@ #include "stack/include/bt_types.h" #include "stack/include/hcidefs.h" #define BD_FEATURES_LEN 8 typedef uint8_t BD_FEATURES[BD_FEATURES_LEN]; /* LMP features supported by device */ // Bit order [0]:0-7 [1]:8-15 ... [7]:56-63 inline std::string bd_features_text(const BD_FEATURES& features) { uint8_t len = BD_FEATURES_LEN; char buf[255]; char* pbuf = buf; const uint8_t* b = features; while (len--) { pbuf += sprintf(pbuf, "0x%02x ", *b++); } return std::string(buf); } /** * Create a bitmask of packet types from the remote feature */ Loading system/stack/include/bt_types.h +0 −18 Original line number Diff line number Diff line Loading @@ -348,24 +348,6 @@ typedef uint8_t PIN_CODE[PIN_CODE_LEN]; /* Pin Code (upto 128 bits) MSB is 0 */ #define BD_NAME_LEN 248 typedef uint8_t BD_NAME[BD_NAME_LEN + 1]; /* Device name */ #define BD_FEATURES_LEN 8 typedef uint8_t BD_FEATURES[BD_FEATURES_LEN]; /* LMP features supported by device */ #ifdef __cplusplus // Bit order [0]:0-7 [1]:8-15 ... [7]:56-63 inline std::string bd_features_text(const BD_FEATURES& features) { uint8_t len = BD_FEATURES_LEN; char buf[255]; char* pbuf = buf; const uint8_t* b = features; while (len--) { pbuf += sprintf(pbuf, "0x%02x ", *b++); } return std::string(buf); } #endif // __cplusplus #define BT_EVENT_MASK_LEN 8 typedef uint8_t BT_EVENT_MASK[BT_EVENT_MASK_LEN]; /* Event Mask */ Loading Loading
system/stack/acl/acl.h +1 −0 Original line number Diff line number Diff line Loading @@ -21,6 +21,7 @@ #include <unordered_set> #include <vector> #include "stack/acl/peer_packet_types.h" #include "stack/include/acl_api_types.h" #include "stack/include/bt_types.h" #include "stack/include/btm_api_types.h" Loading
system/stack/acl/peer_packet_types.h +16 −0 Original line number Diff line number Diff line Loading @@ -19,6 +19,22 @@ #include "stack/include/bt_types.h" #include "stack/include/hcidefs.h" #define BD_FEATURES_LEN 8 typedef uint8_t BD_FEATURES[BD_FEATURES_LEN]; /* LMP features supported by device */ // Bit order [0]:0-7 [1]:8-15 ... [7]:56-63 inline std::string bd_features_text(const BD_FEATURES& features) { uint8_t len = BD_FEATURES_LEN; char buf[255]; char* pbuf = buf; const uint8_t* b = features; while (len--) { pbuf += sprintf(pbuf, "0x%02x ", *b++); } return std::string(buf); } /** * Create a bitmask of packet types from the remote feature */ Loading
system/stack/include/bt_types.h +0 −18 Original line number Diff line number Diff line Loading @@ -348,24 +348,6 @@ typedef uint8_t PIN_CODE[PIN_CODE_LEN]; /* Pin Code (upto 128 bits) MSB is 0 */ #define BD_NAME_LEN 248 typedef uint8_t BD_NAME[BD_NAME_LEN + 1]; /* Device name */ #define BD_FEATURES_LEN 8 typedef uint8_t BD_FEATURES[BD_FEATURES_LEN]; /* LMP features supported by device */ #ifdef __cplusplus // Bit order [0]:0-7 [1]:8-15 ... [7]:56-63 inline std::string bd_features_text(const BD_FEATURES& features) { uint8_t len = BD_FEATURES_LEN; char buf[255]; char* pbuf = buf; const uint8_t* b = features; while (len--) { pbuf += sprintf(pbuf, "0x%02x ", *b++); } return std::string(buf); } #endif // __cplusplus #define BT_EVENT_MASK_LEN 8 typedef uint8_t BT_EVENT_MASK[BT_EVENT_MASK_LEN]; /* Event Mask */ Loading