1 /* btp_has.h - Bluetooth tester headers */ 2 3 /* 4 * Copyright (c) 2023 Oticon 5 * 6 * SPDX-License-Identifier: Apache-2.0 7 */ 8 #include <zephyr/bluetooth/addr.h> 9 10 /* HAS commands */ 11 #define BTP_HAS_READ_SUPPORTED_COMMANDS 0x01 12 struct btp_has_read_supported_commands_rp { 13 uint8_t data[0]; 14 } __packed; 15 16 #define BTP_HAS_SET_ACTIVE_INDEX 0x02 17 struct btp_has_set_active_index_cmd { 18 bt_addr_le_t address; 19 uint8_t index; 20 } __packed; 21 22 #define BTP_HAS_SET_PRESET_NAME 0x03 23 struct btp_has_set_preset_name_cmd { 24 bt_addr_le_t address; 25 uint8_t index; 26 uint8_t length; 27 char name[0]; 28 } __packed; 29 30 #define BTP_HAS_REMOVE_PRESET 0x04 31 struct btp_has_remove_preset_cmd { 32 bt_addr_le_t address; 33 uint8_t index; 34 } __packed; 35 36 #define BTP_HAS_ADD_PRESET 0x05 37 struct btp_has_add_preset_cmd { 38 bt_addr_le_t address; 39 uint8_t index; 40 uint8_t props; 41 uint8_t length; 42 char name[0]; 43 } __packed; 44 45 #define BTP_HAS_SET_PROPERTIES 0x06 46 struct btp_has_set_properties_cmd { 47 bt_addr_le_t address; 48 uint8_t index; 49 uint8_t props; 50 } __packed; 51 52 /* HAS events */ 53 #define BTP_HAS_EV_OPERATION_COMPLETED 0x80 54 struct btp_has_operation_completed_ev { 55 bt_addr_le_t address; 56 uint8_t index; 57 uint8_t opcode; 58 uint8_t status; 59 60 /* RFU */ 61 uint8_t flags; 62 } __packed; 63