mirror of
https://github.com/bluekitchen/btstack.git
synced 2025-03-26 02:37:41 +00:00
btstack_event: enable getters for HCI_EVENT_REMOTE_NAME_REQUEST_COMPLETE
This commit is contained in:
parent
d79faacd66
commit
47430bed98
@ -350,27 +350,27 @@ static inline uint16_t hci_event_authentication_complete_event_get_connection_ha
|
|||||||
* @return status
|
* @return status
|
||||||
* @note: btstack_type 1
|
* @note: btstack_type 1
|
||||||
*/
|
*/
|
||||||
// static inline uint8_t hci_event_remote_name_request_complete_get_status(const uint8_t * event){
|
static inline uint8_t hci_event_remote_name_request_complete_get_status(const uint8_t * event){
|
||||||
// not implemented yet
|
return event[2];
|
||||||
// }
|
}
|
||||||
/**
|
/**
|
||||||
* @brief Get field bd_addr from event HCI_EVENT_REMOTE_NAME_REQUEST_COMPLETE
|
* @brief Get field bd_addr from event HCI_EVENT_REMOTE_NAME_REQUEST_COMPLETE
|
||||||
* @param event packet
|
* @param event packet
|
||||||
* @return bd_addr
|
* @param Pointer to storage for bd_addr
|
||||||
* @note: btstack_type B
|
* @note: btstack_type B
|
||||||
*/
|
*/
|
||||||
// static inline bd_addr_t hci_event_remote_name_request_complete_get_bd_addr(const uint8_t * event){
|
static inline void hci_event_remote_name_request_complete_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){
|
||||||
// not implemented yet
|
reverse_bd_addr(&event[3], bd_addr);
|
||||||
// }
|
}
|
||||||
/**
|
/**
|
||||||
* @brief Get field remote_name from event HCI_EVENT_REMOTE_NAME_REQUEST_COMPLETE
|
* @brief Get field remote_name from event HCI_EVENT_REMOTE_NAME_REQUEST_COMPLETE
|
||||||
* @param event packet
|
* @param event packet
|
||||||
* @return remote_name
|
* @return remote_name
|
||||||
* @note: btstack_type N
|
* @note: btstack_type N
|
||||||
*/
|
*/
|
||||||
// static inline String hci_event_remote_name_request_complete_get_remote_name(const uint8_t * event){
|
static inline const char * hci_event_remote_name_request_complete_get_remote_name(const uint8_t * event){
|
||||||
// not implemented yet
|
return (const char *) &event[9];
|
||||||
// }
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Get field status from event HCI_EVENT_ENCRYPTION_CHANGE
|
* @brief Get field status from event HCI_EVENT_ENCRYPTION_CHANGE
|
||||||
|
@ -185,17 +185,19 @@ param_read = {
|
|||||||
'H' : 'return little_endian_read_16(event, {offset});',
|
'H' : 'return little_endian_read_16(event, {offset});',
|
||||||
'B' : 'reverse_bd_addr(&event[{offset}], {result_name});',
|
'B' : 'reverse_bd_addr(&event[{offset}], {result_name});',
|
||||||
'R' : 'return &event[{offset}];',
|
'R' : 'return &event[{offset}];',
|
||||||
|
'N' : 'return (const char *) &event[{offset}];',
|
||||||
'T' : 'return (const char *) &event[{offset}];',
|
'T' : 'return (const char *) &event[{offset}];',
|
||||||
'Q' : 'reverse_bytes(&event[{offset}], {result_name}, 32);',
|
'Q' : 'reverse_bytes(&event[{offset}], {result_name}, 32);',
|
||||||
'V' : 'return &event[{offset}];',
|
'V' : 'return &event[{offset}];',
|
||||||
'X' : 'gatt_client_deserialize_service(event, {offset}, {result_name});',
|
'X' : 'gatt_client_deserialize_service(event, {offset}, {result_name});',
|
||||||
'Y' : 'gatt_client_deserialize_characteristic(event, {offset}, {result_name});',
|
'Y' : 'gatt_client_deserialize_characteristic(event, {offset}, {result_name});',
|
||||||
'Z' : 'gatt_client_deserialize_characteristic_descriptor(event, {offset}, {result_name});',
|
'Z' : 'gatt_client_deserialize_characteristic_descriptor(event, {offset}, {result_name});',
|
||||||
|
'V' : 'return &event[{offset}];',
|
||||||
}
|
}
|
||||||
|
|
||||||
def c_type_for_btstack_type(type):
|
def c_type_for_btstack_type(type):
|
||||||
param_types = { '1' : 'uint8_t', '2' : 'uint16_t', '3' : 'uint32_t', '4' : 'uint32_t', 'H' : 'hci_con_handle_t', 'B' : 'bd_addr_t',
|
param_types = { '1' : 'uint8_t', '2' : 'uint16_t', '3' : 'uint32_t', '4' : 'uint32_t', 'H' : 'hci_con_handle_t', 'B' : 'bd_addr_t',
|
||||||
'D' : 'const uint8_t *', 'E' : 'const uint8_t * ', 'N' : 'String' , 'P' : 'const uint8_t *', 'A' : 'const uint8_t *',
|
'D' : 'const uint8_t *', 'E' : 'const uint8_t * ', 'N' : 'const char *' , 'P' : 'const uint8_t *', 'A' : 'const uint8_t *',
|
||||||
'R' : 'const uint8_t *', 'S' : 'const uint8_t *',
|
'R' : 'const uint8_t *', 'S' : 'const uint8_t *',
|
||||||
'J' : 'int', 'L' : 'int', 'V' : 'const uint8_t *', 'U' : 'BT_UUID',
|
'J' : 'int', 'L' : 'int', 'V' : 'const uint8_t *', 'U' : 'BT_UUID',
|
||||||
'Q' : 'uint8_t *',
|
'Q' : 'uint8_t *',
|
||||||
|
Loading…
x
Reference in New Issue
Block a user