aboutsummaryrefslogtreecommitdiffstats
path: root/epan
diff options
context:
space:
mode:
authorBill Meier <wmeier@newsguy.com>2012-03-12 14:40:09 +0000
committerBill Meier <wmeier@newsguy.com>2012-03-12 14:40:09 +0000
commit3dd8ed0279efb51adcaf46bd14e59164f51bfc21 (patch)
tree59c2230313b4945b6d3e0266728f136231fdaa5d /epan
parentba2cda4ef0e5a13e3d1d22cc21fb0220d2de2056 (diff)
Use consistent indentation;
Do minor reformatting. svn path=/trunk/; revision=41503
Diffstat (limited to 'epan')
-rw-r--r--epan/dissectors/packet-bthci_acl.c410
-rw-r--r--epan/dissectors/packet-bthci_acl.h2
-rw-r--r--epan/dissectors/packet-bthci_cmd.c4910
-rw-r--r--epan/dissectors/packet-bthci_evt.c5198
-rw-r--r--epan/dissectors/packet-bthci_sco.c88
5 files changed, 5306 insertions, 5302 deletions
diff --git a/epan/dissectors/packet-bthci_acl.c b/epan/dissectors/packet-bthci_acl.c
index 0e03baa1c9..100abd6a37 100644
--- a/epan/dissectors/packet-bthci_acl.c
+++ b/epan/dissectors/packet-bthci_acl.c
@@ -54,36 +54,36 @@ static int hf_btacl_reassembled_in = -1;
/* Initialize the subtree pointers */
static gint ett_btacl = -1;
-static dissector_handle_t btl2cap_handle=NULL;
+static dissector_handle_t btl2cap_handle = NULL;
static gboolean acl_reassembly = TRUE;
typedef struct _multi_fragment_pdu_t {
- guint32 first_frame;
- guint32 last_frame;
- guint16 tot_len;
- char *reassembled;
- int cur_off; /* counter used by reassembly */
+ guint32 first_frame;
+ guint32 last_frame;
+ guint16 tot_len;
+ char *reassembled;
+ int cur_off; /* counter used by reassembly */
} multi_fragment_pdu_t;
typedef struct _chandle_data_t {
- emem_tree_t *start_fragments; /* indexed by pinfo->fd->num */
+ emem_tree_t *start_fragments; /* indexed by pinfo->fd->num */
} chandle_data_t;
-static emem_tree_t *chandle_tree=NULL;
+static emem_tree_t *chandle_tree = NULL;
static const value_string pb_flag_vals[] = {
{0, "First Non-automatically Flushable Packet"},
{1, "Continuing Fragment"},
{2, "First Automatically Flushable Packet"},
- {0, NULL }
+ {0, NULL }
};
static const value_string bc_flag_vals[] = {
- {0, "Point-To-Point"},
- {1, "Active Broadcast"},
- {2, "Piconet Broadcast"},
- {0, NULL }
+ {0, "Point-To-Point"},
+ {1, "Active Broadcast"},
+ {2, "Piconet Broadcast"},
+ {0, NULL }
};
@@ -92,134 +92,134 @@ static const value_string bc_flag_vals[] = {
static void
dissect_btacl(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
{
- proto_item *ti=NULL;
- proto_tree *btacl_tree=NULL;
- guint16 flags, length;
- gboolean fragmented;
- int offset=0;
- guint16 pb_flag, l2cap_length=0;
- tvbuff_t *next_tvb;
- bthci_acl_data_t *acl_data;
- chandle_data_t *chandle_data;
- void* pd_save;
-
- col_set_str(pinfo->cinfo, COL_PROTOCOL, "HCI_ACL");
-
- if(tree){
- ti=proto_tree_add_item(tree, proto_btacl, tvb, offset, -1, ENC_NA);
- btacl_tree = proto_item_add_subtree(ti, ett_btacl);
- }
-
- flags=tvb_get_letohs(tvb, offset);
- pb_flag = (flags & 0x3000) >> 12;
- proto_tree_add_item(btacl_tree, hf_btacl_chandle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(btacl_tree, hf_btacl_pb_flag, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(btacl_tree, hf_btacl_bc_flag, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
-
- acl_data=ep_alloc(sizeof(bthci_acl_data_t));
- acl_data->chandle=flags&0x0fff;
- pd_save = pinfo->private_data;
- pinfo->private_data=acl_data;
-
- /* find the chandle_data structure associated with this chandle */
- chandle_data=se_tree_lookup32(chandle_tree, acl_data->chandle);
- if(!chandle_data){
- chandle_data=se_alloc(sizeof(chandle_data_t));
- chandle_data->start_fragments=se_tree_create_non_persistent(EMEM_TREE_TYPE_RED_BLACK, "bthci_acl fragment starts");
- se_tree_insert32(chandle_tree, acl_data->chandle, chandle_data);
- }
-
- length = tvb_get_letohs(tvb, offset);
- proto_tree_add_item(btacl_tree, hf_btacl_length, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
-
- /* determine if packet is fragmented */
- switch(pb_flag){
- case 0x01: /* Continuation fragment */
- fragmented = TRUE;
- break;
- case 0x00: /* First fragment/packet, non-auto flushable */
- case 0x02: /* First fragment/packet, auto flushable */
- l2cap_length=tvb_get_letohs(tvb, offset);
- fragmented=((l2cap_length+4)!=length);
- break;
- default:
- /* unknown pb_flag */
- fragmented = FALSE;
- }
-
-
- if((!fragmented)
- || ((!acl_reassembly)&& !(pb_flag&0x01)) ){
- /* call L2CAP dissector for PDUs that are not fragmented
- * also for the first fragment if reassembly is disabled
- */
- next_tvb=tvb_new_subset(tvb, offset, tvb_length_remaining(tvb, offset), length);
- if(btl2cap_handle){
- call_dissector(btl2cap_handle, next_tvb, pinfo, tree);
- }
- pinfo->private_data = pd_save;
- return;
- }
-
- if(fragmented && acl_reassembly){
- multi_fragment_pdu_t *mfp=NULL;
- gint len;
-
- if(!(pb_flag&0x01)){ /* first fragment */
- if(!pinfo->fd->flags.visited){
- mfp=se_alloc(sizeof(multi_fragment_pdu_t));
- mfp->first_frame=pinfo->fd->num;
- mfp->last_frame=0;
- mfp->tot_len=l2cap_length+4;
- mfp->reassembled=se_alloc(mfp->tot_len);
- len = tvb_length_remaining(tvb, offset);
- if (len <= mfp->tot_len) {
- tvb_memcpy(tvb, (guint8*)mfp->reassembled, offset, len);
- mfp->cur_off=len;
- se_tree_insert32(chandle_data->start_fragments, pinfo->fd->num, mfp);
- }
- } else {
- mfp=se_tree_lookup32(chandle_data->start_fragments, pinfo->fd->num);
- }
- if(mfp != NULL && mfp->last_frame){
- proto_item *item;
- item=proto_tree_add_uint(btacl_tree, hf_btacl_reassembled_in, tvb, 0, 0, mfp->last_frame);
- PROTO_ITEM_SET_GENERATED(item);
- col_append_fstr(pinfo->cinfo, COL_INFO, " [Reassembled in #%u]", mfp->last_frame);
- }
- }
- if(pb_flag==0x01){ /* continuation fragment */
- mfp=se_tree_lookup32_le(chandle_data->start_fragments, pinfo->fd->num);
- if(!pinfo->fd->flags.visited){
- len = tvb_length_remaining(tvb, offset);
- if(mfp != NULL && !mfp->last_frame && (mfp->tot_len>=mfp->cur_off+len)){
- tvb_memcpy(tvb, (guint8*)mfp->reassembled+mfp->cur_off, offset, len);
- mfp->cur_off+=len;
- if(mfp->cur_off==mfp->tot_len){
- mfp->last_frame=pinfo->fd->num;
- }
- }
- }
- if(mfp){
- proto_item *item;
- item=proto_tree_add_uint(btacl_tree, hf_btacl_continuation_to, tvb, 0, 0, mfp->first_frame);
- PROTO_ITEM_SET_GENERATED(item);
- col_append_fstr(pinfo->cinfo, COL_INFO, " [Continuation to #%u]", mfp->first_frame);
- }
- if(mfp != NULL && mfp->last_frame==pinfo->fd->num){
- next_tvb = tvb_new_child_real_data(tvb, (guint8*)mfp->reassembled, mfp->tot_len, mfp->tot_len);
- add_new_data_source(pinfo, next_tvb, "Reassembled BTHCI ACL");
-
- /* call L2CAP dissector */
- if(btl2cap_handle){
- call_dissector(btl2cap_handle, next_tvb, pinfo, tree);
- }
- }
- }
- }
- pinfo->private_data = pd_save;
+ proto_item *ti = NULL;
+ proto_tree *btacl_tree = NULL;
+ guint16 flags, length;
+ gboolean fragmented;
+ int offset = 0;
+ guint16 pb_flag, l2cap_length = 0;
+ tvbuff_t *next_tvb;
+ bthci_acl_data_t *acl_data;
+ chandle_data_t *chandle_data;
+ void* pd_save;
+
+ col_set_str(pinfo->cinfo, COL_PROTOCOL, "HCI_ACL");
+
+ if (tree) {
+ ti = proto_tree_add_item(tree, proto_btacl, tvb, offset, -1, ENC_NA);
+ btacl_tree = proto_item_add_subtree(ti, ett_btacl);
+ }
+
+ flags = tvb_get_letohs(tvb, offset);
+ pb_flag = (flags & 0x3000) >> 12;
+ proto_tree_add_item(btacl_tree, hf_btacl_chandle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(btacl_tree, hf_btacl_pb_flag, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(btacl_tree, hf_btacl_bc_flag, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset += 2;
+
+ acl_data = ep_alloc(sizeof(bthci_acl_data_t));
+ acl_data->chandle = flags&0x0fff;
+ pd_save = pinfo->private_data;
+ pinfo->private_data = acl_data;
+
+ /* find the chandle_data structure associated with this chandle */
+ chandle_data = se_tree_lookup32(chandle_tree, acl_data->chandle);
+ if (!chandle_data) {
+ chandle_data = se_alloc(sizeof(chandle_data_t));
+ chandle_data->start_fragments = se_tree_create_non_persistent(EMEM_TREE_TYPE_RED_BLACK, "bthci_acl fragment starts");
+ se_tree_insert32(chandle_tree, acl_data->chandle, chandle_data);
+ }
+
+ length = tvb_get_letohs(tvb, offset);
+ proto_tree_add_item(btacl_tree, hf_btacl_length, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+
+ /* determine if packet is fragmented */
+ switch(pb_flag) {
+ case 0x01: /* Continuation fragment */
+ fragmented = TRUE;
+ break;
+ case 0x00: /* First fragment/packet, non-auto flushable */
+ case 0x02: /* First fragment/packet, auto flushable */
+ l2cap_length = tvb_get_letohs(tvb, offset);
+ fragmented = ((l2cap_length+4)!=length);
+ break;
+ default:
+ /* unknown pb_flag */
+ fragmented = FALSE;
+ }
+
+
+ if ((!fragmented)
+ || ((!acl_reassembly)&& !(pb_flag&0x01))) {
+ /* call L2CAP dissector for PDUs that are not fragmented
+ * also for the first fragment if reassembly is disabled
+ */
+ next_tvb = tvb_new_subset(tvb, offset, tvb_length_remaining(tvb, offset), length);
+ if (btl2cap_handle) {
+ call_dissector(btl2cap_handle, next_tvb, pinfo, tree);
+ }
+ pinfo->private_data = pd_save;
+ return;
+ }
+
+ if (fragmented && acl_reassembly) {
+ multi_fragment_pdu_t *mfp = NULL;
+ gint len;
+
+ if (!(pb_flag&0x01)) { /* first fragment */
+ if (!pinfo->fd->flags.visited) {
+ mfp = se_alloc(sizeof(multi_fragment_pdu_t));
+ mfp->first_frame = pinfo->fd->num;
+ mfp->last_frame = 0;
+ mfp->tot_len = l2cap_length+4;
+ mfp->reassembled = se_alloc(mfp->tot_len);
+ len = tvb_length_remaining(tvb, offset);
+ if (len <= mfp->tot_len) {
+ tvb_memcpy(tvb, (guint8*)mfp->reassembled, offset, len);
+ mfp->cur_off = len;
+ se_tree_insert32(chandle_data->start_fragments, pinfo->fd->num, mfp);
+ }
+ } else {
+ mfp = se_tree_lookup32(chandle_data->start_fragments, pinfo->fd->num);
+ }
+ if (mfp != NULL && mfp->last_frame) {
+ proto_item *item;
+ item = proto_tree_add_uint(btacl_tree, hf_btacl_reassembled_in, tvb, 0, 0, mfp->last_frame);
+ PROTO_ITEM_SET_GENERATED(item);
+ col_append_fstr(pinfo->cinfo, COL_INFO, " [Reassembled in #%u]", mfp->last_frame);
+ }
+ }
+ if (pb_flag == 0x01) { /* continuation fragment */
+ mfp = se_tree_lookup32_le(chandle_data->start_fragments, pinfo->fd->num);
+ if (!pinfo->fd->flags.visited) {
+ len = tvb_length_remaining(tvb, offset);
+ if (mfp != NULL && !mfp->last_frame && (mfp->tot_len>=mfp->cur_off+len)) {
+ tvb_memcpy(tvb, (guint8*)mfp->reassembled+mfp->cur_off, offset, len);
+ mfp->cur_off+=len;
+ if (mfp->cur_off == mfp->tot_len) {
+ mfp->last_frame = pinfo->fd->num;
+ }
+ }
+ }
+ if (mfp) {
+ proto_item *item;
+ item = proto_tree_add_uint(btacl_tree, hf_btacl_continuation_to, tvb, 0, 0, mfp->first_frame);
+ PROTO_ITEM_SET_GENERATED(item);
+ col_append_fstr(pinfo->cinfo, COL_INFO, " [Continuation to #%u]", mfp->first_frame);
+ }
+ if (mfp != NULL && mfp->last_frame == pinfo->fd->num) {
+ next_tvb = tvb_new_child_real_data(tvb, (guint8*)mfp->reassembled, mfp->tot_len, mfp->tot_len);
+ add_new_data_source(pinfo, next_tvb, "Reassembled BTHCI ACL");
+
+ /* call L2CAP dissector */
+ if (btl2cap_handle) {
+ call_dissector(btl2cap_handle, next_tvb, pinfo, tree);
+ }
+ }
+ }
+ }
+ pinfo->private_data = pd_save;
}
@@ -227,77 +227,81 @@ void
proto_register_btacl(void)
{
- /* Setup list of header fields See Section 1.6.1 for details*/
- static hf_register_info hf[] = {
- { &hf_btacl_chandle,
- { "Connection Handle", "bthci_acl.chandle",
- FT_UINT16, BASE_HEX, NULL, 0x0FFF,
- NULL, HFILL }
- },
- { &hf_btacl_pb_flag,
- { "PB Flag", "bthci_acl.pb_flag",
- FT_UINT16, BASE_DEC, VALS(pb_flag_vals), 0x3000,
- "Packet Boundary Flag", HFILL }
- },
- { &hf_btacl_bc_flag,
- { "BC Flag", "bthci_acl.bc_flag",
- FT_UINT16, BASE_DEC, VALS(bc_flag_vals), 0xC000,
- "Broadcast Flag", HFILL }
- },
- { &hf_btacl_length,
- { "Data Total Length", "bthci_acl.length",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- NULL, HFILL }
- },
- { &hf_btacl_data,
- { "Data", "bthci_acl.data",
- FT_NONE, BASE_NONE, NULL, 0x0,
- NULL, HFILL }
- },
- { &hf_btacl_continuation_to,
- { "This is a continuation to the PDU in frame", "bthci_acl.continuation_to", FT_FRAMENUM, BASE_NONE, NULL, 0x0,
- "This is a continuation to the PDU in frame #", HFILL }},
- { &hf_btacl_reassembled_in,
- { "This PDU is reassembled in frame", "bthci_acl.reassembled_in", FT_FRAMENUM, BASE_NONE, NULL, 0x0,
- "This PDU is reassembled in frame #", HFILL }},
- };
-
- /* Setup protocol subtree array */
- static gint *ett[] = {
- &ett_btacl,
- };
- module_t *btacl_module;
-
- /* Register the protocol name and description */
- proto_btacl = proto_register_protocol("Bluetooth HCI ACL Packet", "HCI_ACL", "bthci_acl");
- register_dissector("bthci_acl", dissect_btacl, proto_btacl);
-
- /* Required function calls to register the header fields and subtrees used */
- proto_register_field_array(proto_btacl, hf, array_length(hf));
- proto_register_subtree_array(ett, array_length(ett));
-
- /* Register configuration preferences */
- btacl_module = prefs_register_protocol(proto_btacl, NULL);
- prefs_register_bool_preference(btacl_module, "btacl_reassembly",
- "Reassemble ACL Fragments",
- "Whether the ACL dissector should reassemble fragmented PDUs",
- &acl_reassembly);
-
- chandle_tree=se_tree_create(EMEM_TREE_TYPE_RED_BLACK, "bthci_acl chandles");
+ /* Setup list of header fields See Section 1.6.1 for details*/
+ static hf_register_info hf[] = {
+ { &hf_btacl_chandle,
+ { "Connection Handle", "bthci_acl.chandle",
+ FT_UINT16, BASE_HEX, NULL, 0x0FFF,
+ NULL, HFILL }
+ },
+ { &hf_btacl_pb_flag,
+ { "PB Flag", "bthci_acl.pb_flag",
+ FT_UINT16, BASE_DEC, VALS(pb_flag_vals), 0x3000,
+ "Packet Boundary Flag", HFILL }
+ },
+ { &hf_btacl_bc_flag,
+ { "BC Flag", "bthci_acl.bc_flag",
+ FT_UINT16, BASE_DEC, VALS(bc_flag_vals), 0xC000,
+ "Broadcast Flag", HFILL }
+ },
+ { &hf_btacl_length,
+ { "Data Total Length", "bthci_acl.length",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ NULL, HFILL }
+ },
+ { &hf_btacl_data,
+ { "Data", "bthci_acl.data",
+ FT_NONE, BASE_NONE, NULL, 0x0,
+ NULL, HFILL }
+ },
+ { &hf_btacl_continuation_to,
+ { "This is a continuation to the PDU in frame", "bthci_acl.continuation_to",
+ FT_FRAMENUM, BASE_NONE, NULL, 0x0,
+ "This is a continuation to the PDU in frame #", HFILL }
+ },
+ { &hf_btacl_reassembled_in,
+ { "This PDU is reassembled in frame", "bthci_acl.reassembled_in",
+ FT_FRAMENUM, BASE_NONE, NULL, 0x0,
+ "This PDU is reassembled in frame #", HFILL }
+ },
+ };
+
+ /* Setup protocol subtree array */
+ static gint *ett[] = {
+ &ett_btacl,
+ };
+ module_t *btacl_module;
+
+ /* Register the protocol name and description */
+ proto_btacl = proto_register_protocol("Bluetooth HCI ACL Packet", "HCI_ACL", "bthci_acl");
+ register_dissector("bthci_acl", dissect_btacl, proto_btacl);
+
+ /* Required function calls to register the header fields and subtrees used */
+ proto_register_field_array(proto_btacl, hf, array_length(hf));
+ proto_register_subtree_array(ett, array_length(ett));
+
+ /* Register configuration preferences */
+ btacl_module = prefs_register_protocol(proto_btacl, NULL);
+ prefs_register_bool_preference(btacl_module, "btacl_reassembly",
+ "Reassemble ACL Fragments",
+ "Whether the ACL dissector should reassemble fragmented PDUs",
+ &acl_reassembly);
+
+ chandle_tree = se_tree_create(EMEM_TREE_TYPE_RED_BLACK, "bthci_acl chandles");
}
void
proto_reg_handoff_btacl(void)
{
- dissector_handle_t bthci_acl_handle;
+ dissector_handle_t bthci_acl_handle;
- bthci_acl_handle = find_dissector("bthci_acl");
- dissector_add_uint("hci_h4.type", HCI_H4_TYPE_ACL, bthci_acl_handle);
- dissector_add_uint("hci_h1.type", BTHCI_CHANNEL_ACL, bthci_acl_handle);
+ bthci_acl_handle = find_dissector("bthci_acl");
+ dissector_add_uint("hci_h4.type", HCI_H4_TYPE_ACL, bthci_acl_handle);
+ dissector_add_uint("hci_h1.type", BTHCI_CHANNEL_ACL, bthci_acl_handle);
- btl2cap_handle = find_dissector("btl2cap");
+ btl2cap_handle = find_dissector("btl2cap");
}
diff --git a/epan/dissectors/packet-bthci_acl.h b/epan/dissectors/packet-bthci_acl.h
index c2f4a3ee94..c116078523 100644
--- a/epan/dissectors/packet-bthci_acl.h
+++ b/epan/dissectors/packet-bthci_acl.h
@@ -25,7 +25,7 @@
#define __PACKET_BTHCI_ACL_H__
typedef struct _bthci_acl_data_t {
- guint16 chandle; /* only low 12 bits used */
+ guint16 chandle; /* only low 12 bits used */
} bthci_acl_data_t;
#endif
diff --git a/epan/dissectors/packet-bthci_cmd.c b/epan/dissectors/packet-bthci_cmd.c
index 769220dc4d..18215af650 100644
--- a/epan/dissectors/packet-bthci_cmd.c
+++ b/epan/dissectors/packet-bthci_cmd.c
@@ -239,1646 +239,1646 @@ static gint ett_eir_subtree = -1;
static gint ett_eir_struct_subtree = -1;
static const value_string bthci_cmd_opcode_vals[] = {
- {0x0000, "No Operation"},
- {0x0401, "Inquiry"},
- {0x0402, "Inquiry Cancel"},
- {0x0403, "Periodic Inquiry Mode"},
- {0x0404, "Exit Periodic Inquiry Mode"},
- {0x0405, "Create Connection"},
- {0x0406, "Disconnect"},
- {0x0407, "Add SCO Connection"},
- {0x0408, "Create Connection Cancel"},
- {0x0409, "Accept Connection Request"},
- {0x040a, "Reject Connection Request"},
- {0x040b, "Link Key Request Reply"},
- {0x040c, "Link Key Request Negative Reply"},
- {0x040d, "PIN Code Request Reply"},
- {0x040e, "PIN Code Request Negative Reply"},
- {0x040f, "Change Connection Packet Type"},
- {0x0411, "Authentication Requested"},
- {0x0413, "Set Connection Encryption"},
- {0x0415, "Change Connection Link Key"},
- {0x0417, "Master Link Key"},
- {0x0419, "Remote Name Request"},
- {0x041a, "Remote Name Request Cancel"},
- {0x041b, "Read Remote Supported Features"},
- {0x041c, "Read Remote Extended Features"},
- {0x041d, "Read Remote Version Information"},
- {0x041f, "Read Clock offset"},
- {0x0420, "Read LMP Handle"},
- {0x0428, "Setup Synchronous Connection"},
- {0x0429, "Accept Synchronous Connection Request"},
- {0x042a, "Reject Synchronous Connection Request"},
- {0x042b, "IO Capability Request Reply"},
- {0x042c, "User Confirmation Request Reply"},
- {0x042d, "User Confirmation Request Negative Reply"},
- {0x042e, "User Passkey Request Reply"},
- {0x042f, "User Passkey Request Negative Reply"},
- {0x0430, "Remote OOB Data Request Reply"},
- {0x0433, "Remote OOB Data Request Negative Reply"},
- {0x0801, "Hold Mode"},
- {0x0803, "Sniff Mode"},
- {0x0804, "Exit Sniff Mode"},
- {0x0805, "Park Mode"},
- {0x0806, "Exit Park Mode"},
- {0x0807, "QoS Setup"},
- {0x0809, "Role Discovery"},
- {0x080b, "Switch Role"},
- {0x080c, "Read Link Policy Settings"},
- {0x080d, "Write Link Policy Settings"},
- {0x080e, "Read Default Link Policy Settings"},
- {0x080f, "Write Default Link Policy Settings"},
- {0x0810, "Flow Specification"},
- {0x0811, "Sniff Subrating"},
- {0x0c01, "Set Event Mask"},
- {0x0c03, "Reset"},
- {0x0c05, "Set Event Filter"},
- {0x0c08, "Flush"},
- {0x0c09, "Read PIN Type "},
- {0x0c0a, "Write PIN Type"},
- {0x0c0b, "Create New Unit Key"},
- {0x0c0d, "Read Stored Link Key"},
- {0x0c11, "Write Stored Link Key"},
- {0x0c12, "Delete Stored Link Key"},
- {0x0c13, "Change Local Name"},
- {0x0c14, "Read Local Name"},
- {0x0c15, "Read Connection Accept Timeout"},
- {0x0c16, "Write Connection Accept Timeout"},
- {0x0c17, "Read Page Timeout"},
- {0x0c18, "Write Page Timeout"},
- {0x0c19, "Read Scan Enable"},
- {0x0c1a, "Write Scan Enable"},
- {0x0c1b, "Read Page Scan Activity"},
- {0x0c1c, "Write Page Scan Activity"},
- {0x0c1d, "Read Inquiry Scan Activity"},
- {0x0c1e, "Write Inquiry Scan Activity"},
- {0x0c1f, "Read Authentication Enable"},
- {0x0c20, "Write Authentication Enable"},
- {0x0c21, "Read Encryption Mode"},
- {0x0c22, "Write Encryption Mode"},
- {0x0c23, "Read Class of Device"},
- {0x0c24, "Write Class of Device"},
- {0x0c25, "Read Voice Setting"},
- {0x0c26, "Write Voice Setting"},
- {0x0c27, "Read Automatic Flush Timeout"},
- {0x0c28, "Write Automatic Flush Timeout"},
- {0x0c29, "Read Num Broadcast Retransmissions"},
- {0x0c2a, "Write Num Broadcast Retransmissions"},
- {0x0c2b, "Read Hold Mode Activity "},
- {0x0c2c, "Write Hold Mode Activity"},
- {0x0c2d, "Read Tx Power Level"},
- {0x0c2e, "Read SCO Flow Control Enable"},
- {0x0c2f, "Write SCO Flow Control Enable"},
- {0x0c31, "Set Host Controller To Host Flow Control"},
- {0x0c33, "Host Buffer Size"},
- {0x0c35, "Host Number of Completed Packets"},
- {0x0c36, "Read Link Supervision Timeout"},
- {0x0c37, "Write Link Supervision Timeout"},
- {0x0c38, "Read Number of Supported IAC"},
- {0x0c39, "Read Current IAC LAP"},
- {0x0c3a, "Write Current IAC LAP"},
- {0x0c3b, "Read Page Scan Period Mode"},
- {0x0c3c, "Write Page Scan Period Mode"},
- {0x0c3d, "Read Page Scan Mode"},
- {0x0c3e, "Write Page Scan Mode"},
- {0x0c3f, "Set AFH Host Channel Classification"},
- {0x0c42, "Read Inquiry Scan Type"},
- {0x0c43, "Write Inquiry Scan Type"},
- {0x0c44, "Read Inquiry Mode"},
- {0x0c45, "Write Inquiry Mode"},
- {0x0c46, "Read Page Scan Type"},
- {0x0c47, "Write Page Scan Type"},
- {0x0c48, "Read AFH Channel Assessment Mode"},
- {0x0c49, "Write AFH Channel Assessment Mode"},
- {0x0c51, "Read Extended Inquiry Response"},
- {0x0c52, "Write Extended Inquiry Response"},
- {0x0c53, "Refresh Encryption Key"},
- {0x0c55, "Read Simple Pairing Mode"},
- {0x0c56, "Write Simple Pairing Mode"},
- {0x0c57, "Read Local OOB Data"},
- {0x0c58, "Read Inquiry Response Tx Power Level"},
- {0x0c59, "Write Inquiry Tx Power Level"},
- {0x0c5a, "Read Default Erroneous Data Reporting"},
- {0x0c5b, "Write Default Erroneous Data Reporting"},
- {0x0c5f, "Enhanced Flush"},
- {0x0c60, "Send Keypress Notification"},
- {0x1001, "Read Local Version Information"},
- {0x1002, "Read Local Supported Commands"},
- {0x1003, "Read Local Supported Features"},
- {0x1004, "Read Local Extended Features"},
- {0x1005, "Read Buffer Size"},
- {0x1007, "Read Country Code"},
- {0x1009, "Read BD ADDR"},
- {0x1401, "Read Failed Contact Counter"},
- {0x1402, "Reset Failed Contact Counter"},
- {0x1403, "Read Link Quality"},
- {0x1405, "Read RSSI"},
- {0x1406, "Read AFH Channel Map"},
- {0x1407, "Read Clock"},
- {0x1801, "Read Loopback Mode"},
- {0x1802, "Write Loopback Mode"},
- {0x1803, "Enable Device Under Test Mode"},
- {0x1804, "Write Simple Pairing Debug Mode"},
- {0xfc00, "Vendor-Specific"},
- {0, NULL}
+ {0x0000, "No Operation"},
+ {0x0401, "Inquiry"},
+ {0x0402, "Inquiry Cancel"},
+ {0x0403, "Periodic Inquiry Mode"},
+ {0x0404, "Exit Periodic Inquiry Mode"},
+ {0x0405, "Create Connection"},
+ {0x0406, "Disconnect"},
+ {0x0407, "Add SCO Connection"},
+ {0x0408, "Create Connection Cancel"},
+ {0x0409, "Accept Connection Request"},
+ {0x040a, "Reject Connection Request"},
+ {0x040b, "Link Key Request Reply"},
+ {0x040c, "Link Key Request Negative Reply"},
+ {0x040d, "PIN Code Request Reply"},
+ {0x040e, "PIN Code Request Negative Reply"},
+ {0x040f, "Change Connection Packet Type"},
+ {0x0411, "Authentication Requested"},
+ {0x0413, "Set Connection Encryption"},
+ {0x0415, "Change Connection Link Key"},
+ {0x0417, "Master Link Key"},
+ {0x0419, "Remote Name Request"},
+ {0x041a, "Remote Name Request Cancel"},
+ {0x041b, "Read Remote Supported Features"},
+ {0x041c, "Read Remote Extended Features"},
+ {0x041d, "Read Remote Version Information"},
+ {0x041f, "Read Clock offset"},
+ {0x0420, "Read LMP Handle"},
+ {0x0428, "Setup Synchronous Connection"},
+ {0x0429, "Accept Synchronous Connection Request"},
+ {0x042a, "Reject Synchronous Connection Request"},
+ {0x042b, "IO Capability Request Reply"},
+ {0x042c, "User Confirmation Request Reply"},
+ {0x042d, "User Confirmation Request Negative Reply"},
+ {0x042e, "User Passkey Request Reply"},
+ {0x042f, "User Passkey Request Negative Reply"},
+ {0x0430, "Remote OOB Data Request Reply"},
+ {0x0433, "Remote OOB Data Request Negative Reply"},
+ {0x0801, "Hold Mode"},
+ {0x0803, "Sniff Mode"},
+ {0x0804, "Exit Sniff Mode"},
+ {0x0805, "Park Mode"},
+ {0x0806, "Exit Park Mode"},
+ {0x0807, "QoS Setup"},
+ {0x0809, "Role Discovery"},
+ {0x080b, "Switch Role"},
+ {0x080c, "Read Link Policy Settings"},
+ {0x080d, "Write Link Policy Settings"},
+ {0x080e, "Read Default Link Policy Settings"},
+ {0x080f, "Write Default Link Policy Settings"},
+ {0x0810, "Flow Specification"},
+ {0x0811, "Sniff Subrating"},
+ {0x0c01, "Set Event Mask"},
+ {0x0c03, "Reset"},
+ {0x0c05, "Set Event Filter"},
+ {0x0c08, "Flush"},
+ {0x0c09, "Read PIN Type "},
+ {0x0c0a, "Write PIN Type"},
+ {0x0c0b, "Create New Unit Key"},
+ {0x0c0d, "Read Stored Link Key"},
+ {0x0c11, "Write Stored Link Key"},
+ {0x0c12, "Delete Stored Link Key"},
+ {0x0c13, "Change Local Name"},
+ {0x0c14, "Read Local Name"},
+ {0x0c15, "Read Connection Accept Timeout"},
+ {0x0c16, "Write Connection Accept Timeout"},
+ {0x0c17, "Read Page Timeout"},
+ {0x0c18, "Write Page Timeout"},
+ {0x0c19, "Read Scan Enable"},
+ {0x0c1a, "Write Scan Enable"},
+ {0x0c1b, "Read Page Scan Activity"},
+ {0x0c1c, "Write Page Scan Activity"},
+ {0x0c1d, "Read Inquiry Scan Activity"},
+ {0x0c1e, "Write Inquiry Scan Activity"},
+ {0x0c1f, "Read Authentication Enable"},
+ {0x0c20, "Write Authentication Enable"},
+ {0x0c21, "Read Encryption Mode"},
+ {0x0c22, "Write Encryption Mode"},
+ {0x0c23, "Read Class of Device"},
+ {0x0c24, "Write Class of Device"},
+ {0x0c25, "Read Voice Setting"},
+ {0x0c26, "Write Voice Setting"},
+ {0x0c27, "Read Automatic Flush Timeout"},
+ {0x0c28, "Write Automatic Flush Timeout"},
+ {0x0c29, "Read Num Broadcast Retransmissions"},
+ {0x0c2a, "Write Num Broadcast Retransmissions"},
+ {0x0c2b, "Read Hold Mode Activity "},
+ {0x0c2c, "Write Hold Mode Activity"},
+ {0x0c2d, "Read Tx Power Level"},
+ {0x0c2e, "Read SCO Flow Control Enable"},
+ {0x0c2f, "Write SCO Flow Control Enable"},
+ {0x0c31, "Set Host Controller To Host Flow Control"},
+ {0x0c33, "Host Buffer Size"},
+ {0x0c35, "Host Number of Completed Packets"},
+ {0x0c36, "Read Link Supervision Timeout"},
+ {0x0c37, "Write Link Supervision Timeout"},
+ {0x0c38, "Read Number of Supported IAC"},
+ {0x0c39, "Read Current IAC LAP"},
+ {0x0c3a, "Write Current IAC LAP"},
+ {0x0c3b, "Read Page Scan Period Mode"},
+ {0x0c3c, "Write Page Scan Period Mode"},
+ {0x0c3d, "Read Page Scan Mode"},
+ {0x0c3e, "Write Page Scan Mode"},
+ {0x0c3f, "Set AFH Host Channel Classification"},
+ {0x0c42, "Read Inquiry Scan Type"},
+ {0x0c43, "Write Inquiry Scan Type"},
+ {0x0c44, "Read Inquiry Mode"},
+ {0x0c45, "Write Inquiry Mode"},
+ {0x0c46, "Read Page Scan Type"},
+ {0x0c47, "Write Page Scan Type"},
+ {0x0c48, "Read AFH Channel Assessment Mode"},
+ {0x0c49, "Write AFH Channel Assessment Mode"},
+ {0x0c51, "Read Extended Inquiry Response"},
+ {0x0c52, "Write Extended Inquiry Response"},
+ {0x0c53, "Refresh Encryption Key"},
+ {0x0c55, "Read Simple Pairing Mode"},
+ {0x0c56, "Write Simple Pairing Mode"},
+ {0x0c57, "Read Local OOB Data"},
+ {0x0c58, "Read Inquiry Response Tx Power Level"},
+ {0x0c59, "Write Inquiry Tx Power Level"},
+ {0x0c5a, "Read Default Erroneous Data Reporting"},
+ {0x0c5b, "Write Default Erroneous Data Reporting"},
+ {0x0c5f, "Enhanced Flush"},
+ {0x0c60, "Send Keypress Notification"},
+ {0x1001, "Read Local Version Information"},
+ {0x1002, "Read Local Supported Commands"},
+ {0x1003, "Read Local Supported Features"},
+ {0x1004, "Read Local Extended Features"},
+ {0x1005, "Read Buffer Size"},
+ {0x1007, "Read Country Code"},
+ {0x1009, "Read BD ADDR"},
+ {0x1401, "Read Failed Contact Counter"},
+ {0x1402, "Reset Failed Contact Counter"},
+ {0x1403, "Read Link Quality"},
+ {0x1405, "Read RSSI"},
+ {0x1406, "Read AFH Channel Map"},
+ {0x1407, "Read Clock"},
+ {0x1801, "Read Loopback Mode"},
+ {0x1802, "Write Loopback Mode"},
+ {0x1803, "Enable Device Under Test Mode"},
+ {0x1804, "Write Simple Pairing Debug Mode"},
+ {0xfc00, "Vendor-Specific"},
+ {0, NULL}
};
value_string_ext bthci_cmd_opcode_vals_ext = VALUE_STRING_EXT_INIT(bthci_cmd_opcode_vals);
static const value_string bthci_ogf_vals[] = {
- { HCI_OGF_LINK_CONTROL, "Link Control Commands" },
- { HCI_OGF_LINK_POLICY, "Link Policy Commands" },
- { HCI_OGF_HOST_CONTROLLER,"Host Controller & Baseband Commands" },
- { HCI_OGF_INFORMATIONAL,"Informational Parameters" },
- { HCI_OGF_STATUS, "Status Parameters" },
- { HCI_OGF_TESTING, "Testing Commands" },
- { HCI_OGF_LOGO_TESTING, "Bluetooth Logo Testing Commands" },
- { HCI_OGF_VENDOR_SPECIFIC, "Vendor-Specific Commands" },
- { 0, NULL }
+ { HCI_OGF_LINK_CONTROL, "Link Control Commands" },
+ { HCI_OGF_LINK_POLICY, "Link Policy Commands" },
+ { HCI_OGF_HOST_CONTROLLER,"Host Controller & Baseband Commands" },
+ { HCI_OGF_INFORMATIONAL,"Informational Parameters" },
+ { HCI_OGF_STATUS, "Status Parameters" },
+ { HCI_OGF_TESTING, "Testing Commands" },
+ { HCI_OGF_LOGO_TESTING, "Bluetooth Logo Testing Commands" },
+ { HCI_OGF_VENDOR_SPECIFIC, "Vendor-Specific Commands" },
+ { 0, NULL }
};
value_string_ext bthci_ogf_vals_ext = VALUE_STRING_EXT_INIT(bthci_ogf_vals);
static const value_string bthci_cmd_status_vals[] = {
- {0x00, "Success"},
- {0x01, "Unknown HCI Command"},
- {0x02, "No Connection"},
- {0x03, "Hardware Failure"},
- {0x04, "Page Timeout"},
- {0x05, "Authentication Failure"},
- {0x06, "Key Missing"},
- {0x07, "Memory Full"},
- {0x08, "Connection Timeout"},
- {0x09, "Max Number Of Connections"},
- {0x0A, "Max Number Of SCO Connections To A Device"},
- {0x0B, "ACL connection already exists"},
- {0x0C, "Command Disallowed"},
- {0x0D, "Host Rejected due to limited resources"},
- {0x0E, "Host Rejected due to security reasons"},
- {0x0F, "Host Rejected due to remote device is only a personal device"},
- {0x10, "Host Timeout"},
- {0x11, "Unsupported Feature or Parameter Value"},
- {0x12, "Invalid HCI Command Parameters"},
- {0x13, "Other End Terminated Connection: User Ended Connection"},
- {0x14, "Other End Terminated Connection: Low Resources"},
- {0x15, "Other End Terminated Connection: About to Power Off"},
- {0x16, "Connection Terminated by Local Host"},
- {0x17, "Repeated Attempts"},
- {0x18, "Pairing Not Allowed"},
- {0x19, "Unknown LMP PDU"},
- {0x1A, "Unsupported Remote Feature"},
- {0x1B, "SCO Offset Rejected"},
- {0x1C, "SCO Interval Rejected"},
- {0x1D, "SCO Air Mode Rejected"},
- {0x1E, "Invalid LMP Parameters"},
- {0x1F, "Unspecified Error"},
- {0x20, "Unsupported LMP Parameter Value"},
- {0x21, "Role Change Not Allowed"},
- {0x22, "LMP Response Timeout"},
- {0x23, "LMP Error Transaction Collision"},
- {0x24, "LMP PDU Not Allowed"},
- {0x25, "Encryption Mode Not Acceptable"},
- {0x26, "Unit Key Used"},
- {0x27, "QoS is Not Supported"},
- {0x28, "Instant Passed"},
- {0x29, "Pairing with Unit Key Not Supported"},
- {0x2A, "Different Transaction Collision"},
- {0x2C, "QoS Unacceptable Parameter"},
- {0x2D, "QoS Rejected"},
- {0x2E, "Channel Classification Not Supported"},
- {0x2F, "Insufficient Security"},
- {0x30, "Parameter Out Of Mandatory Range"},
- {0x31, "Unknown"},
- {0x32, "Role Switch Pending"},
- {0x33, "Unknown"},
- {0x34, "Reserved Slot Violation"},
- {0x35, "Role Switch Failed"},
- {0x36, "Extended Inquiry Response Too Large"},
- {0x37, "Secure Simple Pairing Not Supported By Host"},
- {0x38, "Host Busy - Pairing"},
- {0, NULL }
+ {0x00, "Success"},
+ {0x01, "Unknown HCI Command"},
+ {0x02, "No Connection"},
+ {0x03, "Hardware Failure"},
+ {0x04, "Page Timeout"},
+ {0x05, "Authentication Failure"},
+ {0x06, "Key Missing"},
+ {0x07, "Memory Full"},
+ {0x08, "Connection Timeout"},
+ {0x09, "Max Number Of Connections"},
+ {0x0A, "Max Number Of SCO Connections To A Device"},
+ {0x0B, "ACL connection already exists"},
+ {0x0C, "Command Disallowed"},
+ {0x0D, "Host Rejected due to limited resources"},
+ {0x0E, "Host Rejected due to security reasons"},
+ {0x0F, "Host Rejected due to remote device is only a personal device"},
+ {0x10, "Host Timeout"},
+ {0x11, "Unsupported Feature or Parameter Value"},
+ {0x12, "Invalid HCI Command Parameters"},
+ {0x13, "Other End Terminated Connection: User Ended Connection"},
+ {0x14, "Other End Terminated Connection: Low Resources"},
+ {0x15, "Other End Terminated Connection: About to Power Off"},
+ {0x16, "Connection Terminated by Local Host"},
+ {0x17, "Repeated Attempts"},
+ {0x18, "Pairing Not Allowed"},
+ {0x19, "Unknown LMP PDU"},
+ {0x1A, "Unsupported Remote Feature"},
+ {0x1B, "SCO Offset Rejected"},
+ {0x1C, "SCO Interval Rejected"},
+ {0x1D, "SCO Air Mode Rejected"},
+ {0x1E, "Invalid LMP Parameters"},
+ {0x1F, "Unspecified Error"},
+ {0x20, "Unsupported LMP Parameter Value"},
+ {0x21, "Role Change Not Allowed"},
+ {0x22, "LMP Response Timeout"},
+ {0x23, "LMP Error Transaction Collision"},
+ {0x24, "LMP PDU Not Allowed"},
+ {0x25, "Encryption Mode Not Acceptable"},
+ {0x26, "Unit Key Used"},
+ {0x27, "QoS is Not Supported"},
+ {0x28, "Instant Passed"},
+ {0x29, "Pairing with Unit Key Not Supported"},
+ {0x2A, "Different Transaction Collision"},
+ {0x2C, "QoS Unacceptable Parameter"},
+ {0x2D, "QoS Rejected"},
+ {0x2E, "Channel Classification Not Supported"},
+ {0x2F, "Insufficient Security"},
+ {0x30, "Parameter Out Of Mandatory Range"},
+ {0x31, "Unknown"},
+ {0x32, "Role Switch Pending"},
+ {0x33, "Unknown"},
+ {0x34, "Reserved Slot Violation"},
+ {0x35, "Role Switch Failed"},
+ {0x36, "Extended Inquiry Response Too Large"},
+ {0x37, "Secure Simple Pairing Not Supported By Host"},
+ {0x38, "Host Busy - Pairing"},
+ {0, NULL }
};
value_string_ext bthci_cmd_status_vals_ext = VALUE_STRING_EXT_INIT(bthci_cmd_status_vals);
static const value_string bthci_cmd_major_dev_class_vals[] = {
- {0x00, "Miscellaneous"},
- {0x01, "Computer"},
- {0x02, "Phone"},
- {0x03, "LAN/Network Access Point"},
- {0x04, "Audio/Video"},
- {0x05, "Peripheral (HID)"},
- {0x06, "Imaging"},
- {0x07, "Wearable"},
- {0x08, "Toy"},
- {0, NULL }
+ {0x00, "Miscellaneous"},
+ {0x01, "Computer"},
+ {0x02, "Phone"},
+ {0x03, "LAN/Network Access Point"},
+ {0x04, "Audio/Video"},
+ {0x05, "Peripheral (HID)"},
+ {0x06, "Imaging"},
+ {0x07, "Wearable"},
+ {0x08, "Toy"},
+ {0, NULL }
};
value_string_ext bthci_cmd_major_dev_class_vals_ext = VALUE_STRING_EXT_INIT(bthci_cmd_major_dev_class_vals);
static const value_string bthci_cmd_service_class_type_vals[] = {
- {0x1000, "Service Discovery Server Service"},
- {0x1001, "Browse Group Descriptor Service"},
- {0x1002, "Public Browse Group"},
- {0x1101, "Serial Port"},
- {0x1102, "LAN Access Using PPP"},
- {0x1103, "Dialup Networking"},
- {0x1104, "IrMC Sync"},
- {0x1105, "OBEX Object Push"},
- {0x1106, "OBEX File Transfer"},
- {0x1107, "IrMC Sync Command"},
- {0x1108, "Headset"},
- {0x1109, "Cordless Telephony"},
- {0x110A, "Audio Source"},
- {0x110B, "Audio Sink"},
- {0x110C, "A/V Remote Control Target"},
- {0x110D, "Advanced Audio Distribution"},
- {0x110E, "A/V Remote Control"},
- {0x110F, "Video Conferencing"},
- {0x1110, "Intercom"},
- {0x1111, "Fax"},
- {0x1112, "Headset Audio Gateway"},
- {0x1113, "WAP"},
- {0x1114, "WAP Client"},
- {0x1115, "PANU"},
- {0x1116, "NAP"},
- {0x1117, "GN"},
- {0x1118, "Direct Printing"},
- {0x1119, "Reference Printing"},
- {0x111A, "Imaging"},
- {0x111B, "Imaging Responder"},
- {0x111C, "Imaging Automatic Archive"},
- {0x111D, "Imaging Referenced Objects"},
- {0x111E, "Handsfree"},
- {0x111F, "Handsfree Audio Gateway"},
- {0x1120, "Direct Printing Reference Objects Service"},
- {0x1121, "Reflected UI"},
- {0x1122, "Basic Printing"},
- {0x1123, "Printing Status"},
- {0x1124, "Human Interface Device Service"},
- {0x1125, "Hardcopy Cable Replacement"},
- {0x1126, "HCR Print"},
- {0x1127, "HCR Scan"},
- {0x1128, "Common ISDN Access"},
- {0x1129, "Video Conferencing GW"},
- {0x112A, "UDI_MT"},
- {0x112B, "UDI_TA"},
- {0x112C, "Audio/Video"},
- {0x112D, "SIM Access"},
- {0x112E, "Phonebook Access - PCE"},
- {0x112F, "Phonebook Access - PSE"},
- {0x1130, "Phonebook Access"},
- {0x1200, "PnP Information"},
- {0x1201, "Generic Networking"},
- {0x1202, "Generic File Transfer"},
- {0x1203, "Generic Audio"},
- {0x1204, "Generic Telephony"},
- {0x1205, "UPNP Service"},
- {0x1206, "UPNP IP Service"},
- {0x1300, "ESDP_UPNP_IP_PAN"},
- {0x1301, "ESDP_UPNP_IP_LAP"},
- {0x1302, "ESDP_UPNP_L2CAP"},
- {0x1303, "Video Source"},
- {0x1304, "Video Sink"},
- {0x1305, "Video Distribution"},
- {0, NULL}
+ {0x1000, "Service Discovery Server Service"},
+ {0x1001, "Browse Group Descriptor Service"},
+ {0x1002, "Public Browse Group"},
+ {0x1101, "Serial Port"},
+ {0x1102, "LAN Access Using PPP"},
+ {0x1103, "Dialup Networking"},
+ {0x1104, "IrMC Sync"},
+ {0x1105, "OBEX Object Push"},
+ {0x1106, "OBEX File Transfer"},
+ {0x1107, "IrMC Sync Command"},
+ {0x1108, "Headset"},
+ {0x1109, "Cordless Telephony"},
+ {0x110A, "Audio Source"},
+ {0x110B, "Audio Sink"},
+ {0x110C, "A/V Remote Control Target"},
+ {0x110D, "Advanced Audio Distribution"},
+ {0x110E, "A/V Remote Control"},
+ {0x110F, "Video Conferencing"},
+ {0x1110, "Intercom"},
+ {0x1111, "Fax"},
+ {0x1112, "Headset Audio Gateway"},
+ {0x1113, "WAP"},
+ {0x1114, "WAP Client"},
+ {0x1115, "PANU"},
+ {0x1116, "NAP"},
+ {0x1117, "GN"},
+ {0x1118, "Direct Printing"},
+ {0x1119, "Reference Printing"},
+ {0x111A, "Imaging"},
+ {0x111B, "Imaging Responder"},
+ {0x111C, "Imaging Automatic Archive"},
+ {0x111D, "Imaging Referenced Objects"},
+ {0x111E, "Handsfree"},
+ {0x111F, "Handsfree Audio Gateway"},
+ {0x1120, "Direct Printing Reference Objects Service"},
+ {0x1121, "Reflected UI"},
+ {0x1122, "Basic Printing"},
+ {0x1123, "Printing Status"},
+ {0x1124, "Human Interface Device Service"},
+ {0x1125, "Hardcopy Cable Replacement"},
+ {0x1126, "HCR Print"},
+ {0x1127, "HCR Scan"},
+ {0x1128, "Common ISDN Access"},
+ {0x1129, "Video Conferencing GW"},
+ {0x112A, "UDI_MT"},
+ {0x112B, "UDI_TA"},
+ {0x112C, "Audio/Video"},
+ {0x112D, "SIM Access"},
+ {0x112E, "Phonebook Access - PCE"},
+ {0x112F, "Phonebook Access - PSE"},
+ {0x1130, "Phonebook Access"},
+ {0x1200, "PnP Information"},
+ {0x1201, "Generic Networking"},
+ {0x1202, "Generic File Transfer"},
+ {0x1203, "Generic Audio"},
+ {0x1204, "Generic Telephony"},
+ {0x1205, "UPNP Service"},
+ {0x1206, "UPNP IP Service"},
+ {0x1300, "ESDP_UPNP_IP_PAN"},
+ {0x1301, "ESDP_UPNP_IP_LAP"},
+ {0x1302, "ESDP_UPNP_L2CAP"},
+ {0x1303, "Video Source"},
+ {0x1304, "Video Sink"},
+ {0x1305, "Video Distribution"},
+ {0, NULL}
};
value_string_ext bthci_cmd_service_class_type_vals_ext = VALUE_STRING_EXT_INIT(bthci_cmd_service_class_type_vals);
static const value_string bthci_cmd_eir_data_type_vals[] = {
- {0x01, "Flags" },
- {0x02, "16-bit Service Class UUIDs (incomplete)" },
- {0x03, "16-bit Service Class UUIDs" },
- {0x04, "32-bit Service Class UUIDs (incomplete)" },
- {0x05, "32-bit Service Class UUIDs" },
- {0x06, "128-bit Service Class UUIDs (incomplete)" },
- {0x07, "128-bit Service Class UUIDs" },
- {0x08, "Device Name (shortened)" },
- {0x09, "Device Name" },
- {0x0A, "Tx Power Level" },
- {0x0B, "OOB Optional Data Length" },
- {0x0C, "BD_ADDR" },
- {0x0D, "Class Of Device" },
- {0x0E, "Simple Pairing Hash C" },
- {0x0F, "Simple Pairing Randomizer R" },
- {0xFF, "Manufacturer Specific" },
- { 0, NULL }
+ {0x01, "Flags" },
+ {0x02, "16-bit Service Class UUIDs (incomplete)" },
+ {0x03, "16-bit Service Class UUIDs" },
+ {0x04, "32-bit Service Class UUIDs (incomplete)" },
+ {0x05, "32-bit Service Class UUIDs" },
+ {0x06, "128-bit Service Class UUIDs (incomplete)" },
+ {0x07, "128-bit Service Class UUIDs" },
+ {0x08, "Device Name (shortened)" },
+ {0x09, "Device Name" },
+ {0x0A, "Tx Power Level" },
+ {0x0B, "OOB Optional Data Length" },
+ {0x0C, "BD_ADDR" },
+ {0x0D, "Class Of Device" },
+ {0x0E, "Simple Pairing Hash C" },
+ {0x0F, "Simple Pairing Randomizer R" },
+ {0xFF, "Manufacturer Specific" },
+ { 0, NULL }
};
value_string_ext bthci_cmd_eir_data_type_vals_ext = VALUE_STRING_EXT_INIT(bthci_cmd_eir_data_type_vals);
const value_string bthci_cmd_io_capability_vals[] = {
- {0x00, "Display Only" },
- {0x01, "Display Yes/No" },
- {0x02, "Keyboard Only" },
- {0x03, "No Input, No Output" },
- { 0, NULL }
+ {0x00, "Display Only" },
+ {0x01, "Display Yes/No" },
+ {0x02, "Keyboard Only" },
+ {0x03, "No Input, No Output" },
+ { 0, NULL }
};
const value_string bthci_cmd_oob_data_present_vals[] = {
- {0x00, "OOB Authentication Data Not Present" },
- {0x01, "OOB Authentication Data From Remote Device Present" },
- { 0, NULL }
+ {0x00, "OOB Authentication Data Not Present" },
+ {0x01, "OOB Authentication Data From Remote Device Present" },
+ { 0, NULL }
};
static const value_string bthci_cmd_auth_req_vals[] = {
- {0x00, "MITM Protection Not Required - No Bonding. Numeric Comparison, Automatic Accept Allowed" },
- {0x01, "MITM Protection Required - No Bonding. Use IO Capabilty To Determine Procedure" },
- {0x02, "MITM Protection Not Required - Dedicated Bonding. Numeric Comparison, Automatic Accept Allowed" },
- {0x03, "MITM Protection Required - Dedicated Bonding. Use IO Capabilty To Determine Procedure" },
- {0x04, "MITM Protection Not Required - General Bonding. Numeric Comparison, Automatic Accept Allowed" },
- {0x05, "MITM Protection Required - General Bonding. Use IO Capabilty To Determine Procedure" },
- { 0, NULL }
+ {0x00, "MITM Protection Not Required - No Bonding. Numeric Comparison, Automatic Accept Allowed" },
+ {0x01, "MITM Protection Required - No Bonding. Use IO Capabilty To Determine Procedure" },
+ {0x02, "MITM Protection Not Required - Dedicated Bonding. Numeric Comparison, Automatic Accept Allowed" },
+ {0x03, "MITM Protection Required - Dedicated Bonding. Use IO Capabilty To Determine Procedure" },
+ {0x04, "MITM Protection Not Required - General Bonding. Numeric Comparison, Automatic Accept Allowed" },
+ {0x05, "MITM Protection Required - General Bonding. Use IO Capabilty To Determine Procedure" },
+ { 0, NULL }
};
value_string_ext bthci_cmd_auth_req_vals_ext = VALUE_STRING_EXT_INIT(bthci_cmd_auth_req_vals);
static const value_string cmd_role_vals[] = {
- {0x00, "Become Master"},
- {0x01, "Remain Slave"},
- {0, NULL }
+ {0x00, "Become Master"},
+ {0x01, "Remain Slave"},
+ {0, NULL }
};
static const value_string cmd_pin_types[] = {
- {0x00, "Variable PIN" },
- {0x01, "Fixed PIN" },
- {0, NULL }
+ {0x00, "Variable PIN" },
+ {0x01, "Fixed PIN" },
+ {0, NULL }
};
static const value_string cmd_encryption_enable[] = {
- {0x00, "Link Level Encryption is OFF"},
- {0x01, "Link Level Encryption is ON"},
- {0, NULL }
+ {0x00, "Link Level Encryption is OFF"},
+ {0x01, "Link Level Encryption is ON"},
+ {0, NULL }
};
static const value_string cmd_key_flag[] = {
- {0x00, "Using Semi-permanent Link Key"},
- {0x01, "Using Temporary Link Key"},
- {0, NULL }
+ {0x00, "Using Semi-permanent Link Key"},
+ {0x01, "Using Temporary Link Key"},
+ {0, NULL }
};
static const value_string cmd_filter_types[] = {
- {0x00, "Clear all Filters" },
- {0x01, "Inquiry Result" },
- {0x02, "Connection Setup" },
- {0, NULL }
+ {0x00, "Clear all Filters" },
+ {0x01, "Inquiry Result" },
+ {0x02, "Connection Setup" },
+ {0, NULL }
};
static const value_string cmd_inquiry_result_filter_condition_types[] = {
- {0x00, "A new device responded" },
- {0x01, "A device with the specified Class of Device responded" },
- {0x02, "A device with the specified BD_ADDR responded" },
- {0, NULL }
+ {0x00, "A new device responded" },
+ {0x01, "A device with the specified Class of Device responded" },
+ {0x02, "A device with the specified BD_ADDR responded" },
+ {0, NULL }
};
static const value_string cmd_service_types[] = {
- {0x00, "No Traffic"},
- {0x01, "Best Effort"},
- {0x02, "Guaranteed"},
- {0, NULL }
+ {0x00, "No Traffic"},
+ {0x01, "Best Effort"},
+ {0x02, "Guaranteed"},
+ {0, NULL }
};
static const value_string cmd_connection_setup_filter_condition_types[] = {
- {0x00, "Allow Connections from all devices" },
- {0x01, "Allow Connections from a device with a specific Class of Device" },
- {0x02, "Allow Connections from a device with a specific BD_ADDR" },
- {0, NULL }
+ {0x00, "Allow Connections from all devices" },
+ {0x01, "Allow Connections from a device with a specific Class of Device" },
+ {0x02, "Allow Connections from a device with a specific BD_ADDR" },
+ {0, NULL }
};
static const value_string cmd_auto_acc_flag_values[] = {
- {0x01, "Do NOT Auto accept" },
- {0x02, "Do Auto accept, role switch disabled" },
- {0x03, "Do Auto accept, role switch enabled" },
- {0, NULL }
+ {0x01, "Do NOT Auto accept" },
+ {0x02, "Do Auto accept, role switch disabled" },
+ {0x03, "Do Auto accept, role switch enabled" },
+ {0, NULL }
};
static const value_string cmd_read_all_flag_values[] = {
- {0x00, "Return Link Key for specified BD_ADDR" },
- {0x01, "Return all stored Link Keys" },
- {0, NULL }
+ {0x00, "Return Link Key for specified BD_ADDR" },
+ {0x01, "Return all stored Link Keys" },
+ {0, NULL }
};
static const value_string cmd_delete_all_flag_values[] = {
- {0x00, "Delete only Link Key for specified BD_ADDR" },
- {0x01, "Delete all stored Link Keys" },
- {0, NULL }
+ {0x00, "Delete only Link Key for specified BD_ADDR" },
+ {0x01, "Delete all stored Link Keys" },
+ {0, NULL }
};
static const value_string cmd_scan_enable_values[] = {
- {0x00, "No Scans enabled" },
- {0x01, "Inquiry Scan enabled/Page Scan disable" },
- {0x02, "Inquiry Scan disabled/Page Scan enabled" },
- {0x03, "Inquiry Scan enabled/Page Scan enabled" },
- {0, NULL }
+ {0x00, "No Scans enabled" },
+ {0x01, "Inquiry Scan enabled/Page Scan disable" },
+ {0x02, "Inquiry Scan disabled/Page Scan enabled" },
+ {0x03, "Inquiry Scan enabled/Page Scan enabled" },
+ {0, NULL }
};
static const value_string cmd_authentication_enable_values[] = {
- {0x00, "Authentication disabled" },
- {0x01, "Authentication enabled for all connection" },
- {0, NULL }
+ {0x00, "Authentication disabled" },
+ {0x01, "Authentication enabled for all connection" },
+ {0, NULL }
};
static const value_string cmd_input_coding_values[] = {
- {0x0, "Linear" },
- {0x1, "\xb5-law" },
- {0x2, "A-law" },
- {0, NULL }
+ {0x0, "Linear" },
+ {0x1, "\xb5-law" },
+ {0x2, "A-law" },
+ {0, NULL }
};
static const value_string cmd_input_data_format_values[] = {
- {0x0, "1's complement" },
- {0x1, "2's complement" },
- {0x2, "Sign-Magnitude" },
- {0, NULL }
+ {0x0, "1's complement" },
+ {0x1, "2's complement" },
+ {0x2, "Sign-Magnitude" },
+ {0, NULL }
};
static const value_string cmd_input_sample_size_values[] = {
- {0x0, "8 bit (only for Linear PCM)" },
- {0x1, "16 bit (only for Linear PCM)" },
- {0, NULL }
+ {0x0, "8 bit (only for Linear PCM)" },
+ {0x1, "16 bit (only for Linear PCM)" },
+ {0, NULL }
};
static const value_string cmd_air_coding_format_values[] = {
- {0x0, "CVSD" },
- {0x1, "\xb5-law" },
- {0x2, "A-law" },
- {0, NULL }
+ {0x0, "CVSD" },
+ {0x1, "\xb5-law" },
+ {0x2, "A-law" },
+ {0, NULL }
};
static const value_string cmd_en_disabled[] = {
- {0x00, "disabled" },
- {0x01, "enabled" },
- {0, NULL }
+ {0x00, "disabled" },
+ {0x01, "enabled" },
+ {0, NULL }
};
static const value_string cmd_flow_contr_enable[] = {
- {0x00, "Flow control off in direction from Host Controller to Host." },
- {0x01, "ON - HCI ACL Data Packets / OFF - HCI SCO Data Packets" },
- {0x02, "OFF - HCI ACL Data Packets / ON - HCI SCO Data Packets" },
- {0x03, "ON - HCI ACL Data Packets / ON - HCI SCO Data Packets" },
- {0, NULL }
+ {0x00, "Flow control off in direction from Host Controller to Host." },
+ {0x01, "ON - HCI ACL Data Packets / OFF - HCI SCO Data Packets" },
+ {0x02, "OFF - HCI ACL Data Packets / ON - HCI SCO Data Packets" },
+ {0x03, "ON - HCI ACL Data Packets / ON - HCI SCO Data Packets" },
+ {0, NULL }
};
static const value_string cmd_power_level_types[] = {
- {0x00, "Read Current Transmission Power Level" },
- {0x01, "Read Maximum Transmission Power Level" },
- {0, NULL }
+ {0x00, "Read Current Transmission Power Level" },
+ {0x01, "Read Maximum Transmission Power Level" },
+ {0, NULL }
};
static const value_string cmd_loopback_modes[] = {
- {0x00, "No Loopback mode enabled" },
- {0x01, "Enable Local Loopback" },
- {0x02, "Enable Remote Loopback" },
- {0, NULL }
+ {0x00, "No Loopback mode enabled" },
+ {0x01, "Enable Local Loopback" },
+ {0x02, "Enable Remote Loopback" },
+ {0, NULL }
};
static const value_string encrypt_mode_vals[] = {
- { 0x00, "Encryption Disabled" },
- { 0x01, "Encryption only for Point-To-Point Packets" },
- { 0x02, "Encryption for Point-To-Point and Broadcast Packets" },
- { 0, NULL }
+ { 0x00, "Encryption Disabled" },
+ { 0x01, "Encryption only for Point-To-Point Packets" },
+ { 0x02, "Encryption for Point-To-Point and Broadcast Packets" },
+ { 0, NULL }
};
static const value_string cmd_boolean[] = {
- {0, "false" },
- {1, "true" },
- {0, NULL }
+ {0, "false" },
+ {1, "true" },
+ {0, NULL }
};
static const value_string cmd_page_scan_modes[] = {
- {0, "Mandatory Page Scan Mode"},
- {1, "Optional Page Scan Mode I"},
- {2, "Optional Page Scan Mode II"},
- {3, "Optional Page Scan Mode III"},
- {0, NULL }
+ {0, "Mandatory Page Scan Mode"},
+ {1, "Optional Page Scan Mode I"},
+ {2, "Optional Page Scan Mode II"},
+ {3, "Optional Page Scan Mode III"},
+ {0, NULL }
};
static const value_string cmd_page_scan_repetition_modes[] = {
- {0, "R0"},
- {1, "R1"},
- {2, "R2"},
- {0, NULL }
+ {0, "R0"},
+ {1, "R1"},
+ {2, "R2"},
+ {0, NULL }
};
static const value_string cmd_page_scan_period_modes[] = {
- {0, "P0"},
- {1, "P1"},
- {2, "P2"},
- {0, NULL }
+ {0, "P0"},
+ {1, "P1"},
+ {2, "P2"},
+ {0, NULL }
};
static const value_string cmd_role_switch_modes[] = {
- {0, "Local device will be master, and will not accept a master-slave switch request." },
- {1, "Local device may be master, or may become slave after accepting a master slave switch." },
- {0, NULL }
+ {0, "Local device will be master, and will not accept a master-slave switch request." },
+ {1, "Local device may be master, or may become slave after accepting a master slave switch." },
+ {0, NULL }
};
static const value_string cmd_rtx_effort[] = {
- {0x00, "No Retransmission" },
- {0x01, "At least 1 retransmission, optimize for consumption" },
- {0x02, "At least 1 retransmission, optimize for link quality" },
- {0xFF, "Don't Care" },
- { 0, NULL }
+ {0x00, "No Retransmission" },
+ {0x01, "At least 1 retransmission, optimize for consumption" },
+ {0x02, "At least 1 retransmission, optimize for link quality" },
+ {0xFF, "Don't Care" },
+ { 0, NULL }
};
static const value_string cmd_scan_types[] = {
- {0x00, "Standard Scan" },
- {0x01, "Interlaced Scan" },
- { 0, NULL }
+ {0x00, "Standard Scan" },
+ {0x01, "Interlaced Scan" },
+ { 0, NULL }
};
static const value_string cmd_inq_modes[] = {
- {0x00, "Standard Results" },
- {0x01, "Results With RSSI" },
- {0x02, "Results With RSSI or Extended Results" },
- { 0, NULL }
+ {0x00, "Standard Results" },
+ {0x01, "Results With RSSI" },
+ {0x02, "Results With RSSI or Extended Results" },
+ { 0, NULL }
};
static const value_string cmd_flush_pkt_type[] = {
- {0x00, "Automatically Flushable Only" },
- { 0, NULL }
+ {0x00, "Automatically Flushable Only" },
+ { 0, NULL }
};
static const value_string cmd_which_clock[] = {
- {0x00, "Local" },
- {0x01, "Piconet" },
- { 0, NULL }
+ {0x00, "Local" },
+ {0x01, "Piconet" },
+ { 0, NULL }
};
static const value_string cmd_notification_types[] = {
- {0x00, "Passkey Entry Started" },
- {0x01, "Passkey Digit Entered" },
- {0x02, "Passkey Digit Erased" },
- {0x03, "Passkey Cleared" },
- {0x04, "Passkey Entry Completed" },
- { 0, NULL }
+ {0x00, "Passkey Entry Started" },
+ {0x01, "Passkey Digit Entered" },
+ {0x02, "Passkey Digit Erased" },
+ {0x03, "Passkey Cleared" },
+ {0x04, "Passkey Entry Completed" },
+ { 0, NULL }
};
static int
dissect_bthci_cmd_bd_addr(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- guint8 i, bd_addr[6];
- proto_item *item;
+ guint8 i, bd_addr[6];
+ proto_item *item;
- for(i=6; i; i--)
- bd_addr[6-i] = tvb_get_guint8(tvb, offset+i-1);
+ for(i=6; i; i--)
+ bd_addr[6-i] = tvb_get_guint8(tvb, offset+i-1);
- item = proto_tree_add_item(tree, hf_bthci_cmd_bd_addr, tvb, offset, 6, ENC_NA);
- proto_item_append_text(item, "%02x%02x:%02x:%02x%02x%02x (%s)",
- bd_addr[0], bd_addr[1], bd_addr[2], bd_addr[3], bd_addr[4], bd_addr[5],
- get_ether_name(bd_addr));
+ item = proto_tree_add_item(tree, hf_bthci_cmd_bd_addr, tvb, offset, 6, ENC_NA);
+ proto_item_append_text(item, "%02x%02x:%02x:%02x%02x%02x (%s)",
+ bd_addr[0], bd_addr[1], bd_addr[2], bd_addr[3], bd_addr[4], bd_addr[5],
+ get_ether_name(bd_addr));
- offset+=6;
+ offset+=6;
- return offset;
+ return offset;
}
static int
dissect_bthci_cmd_cod(int type, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- guint8 cod1, cod2;
- proto_item *item;
-
- item = proto_tree_add_item(tree, type, tvb, offset, 3, ENC_LITTLE_ENDIAN);
-
- cod1 = tvb_get_guint8(tvb, offset+1);
- cod2 = tvb_get_guint8(tvb, offset+2);
-
- if( (cod2 != 0) || (cod1 & 0x20) )
- {
- char buf[128];
-
- buf[0] = '\0';
-
- proto_item_append_text(item, " (%s - services:", val_to_str_ext_const(cod1 & 0x1f, &bthci_cmd_major_dev_class_vals_ext, "???"));
- if (cod2 & 0x80) g_strlcat(buf, " Information,", sizeof(buf));
- if (cod2 & 0x40) g_strlcat(buf, " Telephony,", sizeof(buf));
- if (cod2 & 0x20) g_strlcat(buf, " Audio,", sizeof(buf));
- if (cod2 & 0x10) g_strlcat(buf, " Object transfer,", sizeof(buf));
- if (cod2 & 0x08) g_strlcat(buf, " Capturing,", sizeof(buf));
- if (cod2 & 0x04) g_strlcat(buf, " Rendering,", sizeof(buf));
- if (cod2 & 0x02) g_strlcat(buf, " Networking,", sizeof(buf));
- if (cod2 & 0x01) g_strlcat(buf, " Positioning,", sizeof(buf));
- if (cod1 & 0x20) g_strlcat(buf, " Limited discoverable mode,", sizeof(buf));
-
- buf[strlen(buf)-1] = '\0'; /* skip last comma */
-
- g_strlcat(buf, ")", sizeof(buf));
- proto_item_append_text(item, "%s", buf);
- }
- else
- {
- proto_item_append_text(item, " (%s - no major services)", val_to_str_ext_const(cod1 & 0x1f, &bthci_cmd_major_dev_class_vals_ext, "???"));
- }
-
- return offset+3;
+ guint8 cod1, cod2;
+ proto_item *item;
+
+ item = proto_tree_add_item(tree, type, tvb, offset, 3, ENC_LITTLE_ENDIAN);
+
+ cod1 = tvb_get_guint8(tvb, offset+1);
+ cod2 = tvb_get_guint8(tvb, offset+2);
+
+ if ((cod2 != 0) || (cod1 & 0x20))
+ {
+ char buf[128];
+
+ buf[0] = '\0';
+
+ proto_item_append_text(item, " (%s - services:", val_to_str_ext_const(cod1 & 0x1f, &bthci_cmd_major_dev_class_vals_ext, "???"));
+ if (cod2 & 0x80) g_strlcat(buf, " Information,", sizeof(buf));
+ if (cod2 & 0x40) g_strlcat(buf, " Telephony,", sizeof(buf));
+ if (cod2 & 0x20) g_strlcat(buf, " Audio,", sizeof(buf));
+ if (cod2 & 0x10) g_strlcat(buf, " Object transfer,", sizeof(buf));
+ if (cod2 & 0x08) g_strlcat(buf, " Capturing,", sizeof(buf));
+ if (cod2 & 0x04) g_strlcat(buf, " Rendering,", sizeof(buf));
+ if (cod2 & 0x02) g_strlcat(buf, " Networking,", sizeof(buf));
+ if (cod2 & 0x01) g_strlcat(buf, " Positioning,", sizeof(buf));
+ if (cod1 & 0x20) g_strlcat(buf, " Limited discoverable mode,", sizeof(buf));
+
+ buf[strlen(buf)-1] = '\0'; /* skip last comma */
+
+ g_strlcat(buf, ")", sizeof(buf));
+ proto_item_append_text(item, "%s", buf);
+ }
+ else
+ {
+ proto_item_append_text(item, " (%s - no major services)", val_to_str_ext_const(cod1 & 0x1f, &bthci_cmd_major_dev_class_vals_ext, "???"));
+ }
+
+ return offset+3;
}
static int
dissect_bthci_ext_inquiry_response(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- guint8 i, j, length, type;
- proto_item *ti_eir=NULL;
- proto_tree *ti_eir_subtree=NULL;
-
- if(tree){
- ti_eir=proto_tree_add_text(tree, tvb, offset, 240, "Extended Inquiry Response Data");
- ti_eir_subtree=proto_item_add_subtree(ti_eir, ett_eir_subtree);
- }
-
- i=0;
- while(i<240){
- length = tvb_get_guint8(tvb, offset+i);
- if( length != 0 ){
-
- proto_item *ti_eir_struct=NULL;
- proto_tree *ti_eir_struct_subtree=NULL;
-
- ti_eir_struct = proto_tree_add_text(ti_eir_subtree, tvb, offset+i, length+1, "%s", "");
- ti_eir_struct_subtree = proto_item_add_subtree(ti_eir_struct, ett_eir_struct_subtree);
-
- type = tvb_get_guint8(tvb, offset+i+1);
-
- proto_item_append_text(ti_eir_struct,"%s", val_to_str_ext_const(type, &bthci_cmd_eir_data_type_vals_ext, "Unknown"));
-
- proto_tree_add_item(ti_eir_struct_subtree,hf_bthci_cmd_eir_struct_length, tvb, offset+i, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_eir_struct_subtree,hf_bthci_cmd_eir_struct_type, tvb, offset+i+1, 1, ENC_LITTLE_ENDIAN);
-
- switch(type) {
- case 0x02: /* 16-bit Service Class UUIDs, incomplete list */
- case 0x03: /* 16-bit Service Class UUIDs, complete list */
- j=0;
- while(j<(length-1))
- {
- proto_tree_add_item(ti_eir_struct_subtree, hf_bthci_cmd_sc_uuid16, tvb, offset+i+j+2, 2, ENC_LITTLE_ENDIAN);
- j+=2;
- }
- break;
- case 0x04: /* 32-bit Service Class UUIDs, incomplete list */
- case 0x05: /* 32-bit Service Class UUIDs, complete list */
- j=0;
- while(j<(length-1))
- {
- proto_tree_add_item(ti_eir_struct_subtree, hf_bthci_cmd_sc_uuid32, tvb, offset+i+j+2, 4, ENC_LITTLE_ENDIAN);
- j+=4;
- }
- break;
- case 0x06: /* 128-bit Service Class UUIDs, incomplete list */
- case 0x07: /* 128-bit Service Class UUIDs, complete list */
- j=0;
- while(j<(length-1))
- {
- proto_tree_add_item(ti_eir_struct_subtree, hf_bthci_cmd_sc_uuid128, tvb, offset+i+j+2, 16, ENC_NA);
- j+=16;
- }
- break;
- case 0x08: /* Device Name, shortened */
- case 0x09: /* Device Name, full */
- proto_tree_add_item(ti_eir_struct_subtree, hf_bthci_cmd_device_name, tvb, offset+i+2, length-1, ENC_ASCII|ENC_NA);
- proto_item_append_text(ti_eir_struct,": %s", tvb_format_text(tvb,offset+i+2,length-1));
- break;
- case 0x0A: /* Tx Power Level */
- proto_tree_add_item(ti_eir_struct_subtree, hf_bthci_cmd_tx_power, tvb, offset+i+2, 1, ENC_LITTLE_ENDIAN);
-
- default:
- proto_tree_add_item(ti_eir_struct_subtree, hf_bthci_cmd_eir_data, tvb, offset+i+2, length-1, ENC_NA);
- break;
- }
- i += length+1;
- }
- else {
- break;
- }
- }
-
- return offset+240;
+ guint8 i, j, length, type;
+ proto_item *ti_eir = NULL;
+ proto_tree *ti_eir_subtree = NULL;
+
+ if (tree) {
+ ti_eir=proto_tree_add_text(tree, tvb, offset, 240, "Extended Inquiry Response Data");
+ ti_eir_subtree=proto_item_add_subtree(ti_eir, ett_eir_subtree);
+ }
+
+ i=0;
+ while(i<240) {
+ length = tvb_get_guint8(tvb, offset+i);
+ if (length != 0) {
+
+ proto_item *ti_eir_struct=NULL;
+ proto_tree *ti_eir_struct_subtree=NULL;
+
+ ti_eir_struct = proto_tree_add_text(ti_eir_subtree, tvb, offset+i, length+1, "%s", "");
+ ti_eir_struct_subtree = proto_item_add_subtree(ti_eir_struct, ett_eir_struct_subtree);
+
+ type = tvb_get_guint8(tvb, offset+i+1);
+
+ proto_item_append_text(ti_eir_struct,"%s", val_to_str_ext_const(type, &bthci_cmd_eir_data_type_vals_ext, "Unknown"));
+
+ proto_tree_add_item(ti_eir_struct_subtree,hf_bthci_cmd_eir_struct_length, tvb, offset+i, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_eir_struct_subtree,hf_bthci_cmd_eir_struct_type, tvb, offset+i+1, 1, ENC_LITTLE_ENDIAN);
+
+ switch (type) {
+ case 0x02: /* 16-bit Service Class UUIDs, incomplete list */
+ case 0x03: /* 16-bit Service Class UUIDs, complete list */
+ j=0;
+ while(j<(length-1))
+ {
+ proto_tree_add_item(ti_eir_struct_subtree, hf_bthci_cmd_sc_uuid16, tvb, offset+i+j+2, 2, ENC_LITTLE_ENDIAN);
+ j+=2;
+ }
+ break;
+ case 0x04: /* 32-bit Service Class UUIDs, incomplete list */
+ case 0x05: /* 32-bit Service Class UUIDs, complete list */
+ j=0;
+ while(j<(length-1))
+ {
+ proto_tree_add_item(ti_eir_struct_subtree, hf_bthci_cmd_sc_uuid32, tvb, offset+i+j+2, 4, ENC_LITTLE_ENDIAN);
+ j+=4;
+ }
+ break;
+ case 0x06: /* 128-bit Service Class UUIDs, incomplete list */
+ case 0x07: /* 128-bit Service Class UUIDs, complete list */
+ j=0;
+ while(j<(length-1))
+ {
+ proto_tree_add_item(ti_eir_struct_subtree, hf_bthci_cmd_sc_uuid128, tvb, offset+i+j+2, 16, ENC_NA);
+ j+=16;
+ }
+ break;
+ case 0x08: /* Device Name, shortened */
+ case 0x09: /* Device Name, full */
+ proto_tree_add_item(ti_eir_struct_subtree, hf_bthci_cmd_device_name, tvb, offset+i+2, length-1, ENC_ASCII|ENC_NA);
+ proto_item_append_text(ti_eir_struct,": %s", tvb_format_text(tvb,offset+i+2,length-1));
+ break;
+ case 0x0A: /* Tx Power Level */
+ proto_tree_add_item(ti_eir_struct_subtree, hf_bthci_cmd_tx_power, tvb, offset+i+2, 1, ENC_LITTLE_ENDIAN);
+
+ default:
+ proto_tree_add_item(ti_eir_struct_subtree, hf_bthci_cmd_eir_data, tvb, offset+i+2, length-1, ENC_NA);
+ break;
+ }
+ i += length+1;
+ }
+ else {
+ break;
+ }
+ }
+
+ return offset+240;
}
static int
dissect_link_control_cmd(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, guint16 cmd_ocf)
{
- proto_item *item;
- guint32 clock_value;
-
- switch(cmd_ocf) {
- case 0x0001: /* Inquiry */
- proto_tree_add_item(tree, hf_bthci_cmd_lap, tvb, offset, 3, ENC_LITTLE_ENDIAN);
- offset+=3;
- proto_tree_add_item(tree, hf_bthci_cmd_inq_length, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- proto_tree_add_item(tree, hf_bthci_cmd_num_responses, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- case 0x0002: /* Inquiry Cancel */
- /* no parameters */
- break;
-
- case 0x0003: /* Periodic Inquiry Mode */
- proto_tree_add_item(tree, hf_bthci_cmd_max_period_length, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- proto_tree_add_item(tree, hf_bthci_cmd_min_period_length, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- proto_tree_add_item(tree, hf_bthci_cmd_lap, tvb, offset, 3, ENC_LITTLE_ENDIAN);
- offset+=3;
- proto_tree_add_item(tree, hf_bthci_cmd_inq_length, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- proto_tree_add_item(tree, hf_bthci_cmd_num_responses, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- case 0x0004: /* Exit Periodic Inquiry Mode */
- /* no parameters */
- break;
-
- case 0x0005: /* Create Connection */
- offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
-
- proto_tree_add_item(tree, hf_bthci_cmd_packet_type_2dh1, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_packet_type_3dh1, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_packet_type_dm1, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_packet_type_dh1, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_packet_type_2dh3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_packet_type_3dh3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_packet_type_dm3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_packet_type_dh3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_packet_type_2dh5, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_packet_type_3dh5, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_packet_type_dm5, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_packet_type_dh5, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
-
- proto_tree_add_item(tree, hf_bthci_cmd_page_scan_repetition_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
-
- proto_tree_add_item(tree, hf_bthci_cmd_page_scan_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
-
- item = proto_tree_add_item(tree, hf_bthci_cmd_clock_offset, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- clock_value = tvb_get_letohs(tvb, 13) & 32767; /* only bit0-14 are valid */
- proto_item_append_text(item, " (%g ms)", 1.25*clock_value);
- proto_tree_add_item(tree, hf_bthci_cmd_clock_offset_valid , tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
-
- proto_tree_add_item(tree, hf_bthci_cmd_allow_role_switch, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- case 0x0006: /* Disconnect */
- proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- proto_tree_add_item(tree, hf_bthci_cmd_reason, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- case 0x0007: /* Add SCO Connection */
- proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- proto_tree_add_item(tree, hf_bthci_cmd_packet_type_hv1, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_packet_type_hv2, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_packet_type_hv3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- break;
-
- case 0x0008: /* Create Connection Cancel Request */
- offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
- break;
-
- case 0x0009: /* Accept Connection Request */
- offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
-
- proto_tree_add_item(tree, hf_bthci_cmd_role, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- case 0x000a: /* Reject Connection Request */
- offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
-
- proto_tree_add_item(tree, hf_bthci_cmd_reason, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- case 0x000b: /* Link Key Request Reply */
- offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
-
- proto_tree_add_item(tree, hf_bthci_cmd_link_key, tvb, offset, 16, ENC_NA);
- offset+=16;
- break;
-
- case 0x000c: /* Link Key Request Negative Reply */
- offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
- break;
-
- case 0x000d: /* PIN Code Request Reply */
- offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
-
- proto_tree_add_item(tree, hf_bthci_cmd_pin_code_length ,tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- proto_tree_add_item(tree, hf_bthci_cmd_pin_code ,tvb, offset, 16, ENC_ASCII|ENC_NA);
- offset+=16;
- break;
-
- case 0x000e: /* PIN Code Request Negative Reply */
- offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
- break;
-
- case 0x000f: /* Change Connection Packet Type */
- proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- proto_tree_add_item(tree, hf_bthci_cmd_packet_type_2dh1, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_packet_type_3dh1, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_packet_type_dm1, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_packet_type_dh1, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_packet_type_2dh3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_packet_type_3dh3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_packet_type_dm3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_packet_type_dh3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_packet_type_2dh5, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_packet_type_3dh5, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_packet_type_dm5, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_packet_type_dh5, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- break;
-
- case 0x0011: /* Authentication Request */
- proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- break;
-
- case 0x0013: /* Set Connection Encryption */
- proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- proto_tree_add_item(tree, hf_bthci_cmd_encryption_enable, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- case 0x0017: /* Master Link Key */
- proto_tree_add_item(tree, hf_bthci_cmd_key_flag, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- case 0x0019: /* Remote Name Request */
- offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
-
- proto_tree_add_item(tree, hf_bthci_cmd_page_scan_repetition_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
-
- proto_tree_add_item(tree, hf_bthci_cmd_page_scan_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
-
- item = proto_tree_add_item(tree, hf_bthci_cmd_clock_offset, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- clock_value = tvb_get_letohs(tvb, offset) & 32767; /* only bit0-14 are valid */
- proto_item_append_text(item, " (%g ms)", 1.25*clock_value);
- proto_tree_add_item(tree, hf_bthci_cmd_clock_offset_valid , tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- break;
-
- case 0x001a: /* Remote Name Request Cancel */
- offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
- break;
-
- case 0x001c: /* Read Remote Extended Features */
- proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- proto_tree_add_item(tree, hf_bthci_cmd_page_number, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- case 0x0028: /* Setup Synchronous Connection */
- case 0x0029: /* Accept Synchronous Connection Request */
- proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- proto_tree_add_item(tree, hf_bthci_cmd_transmit_bandwidth, tvb, offset, 4, ENC_LITTLE_ENDIAN);
- offset+=4;
- proto_tree_add_item(tree, hf_bthci_cmd_receive_bandwidth, tvb, offset, 4, ENC_LITTLE_ENDIAN);
- offset+=4;
- proto_tree_add_item(tree, hf_bthci_cmd_max_latency_ms, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
-
- proto_tree_add_item(tree, hf_bthci_cmd_input_coding, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_input_data_format, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_input_sample_size, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_linear_pcm_bit_pos, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_air_coding_format, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
-
- proto_tree_add_item(tree, hf_bthci_cmd_retransmission_effort, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
-
- proto_tree_add_item(tree, hf_bthci_cmd_sco_packet_type_hv1, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_sco_packet_type_hv2, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_sco_packet_type_hv3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_sco_packet_type_ev3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_sco_packet_type_ev4, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_sco_packet_type_ev5, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_sco_packet_type_2ev3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_sco_packet_type_3ev3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_sco_packet_type_2ev5, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_sco_packet_type_3ev5, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- break;
-
- case 0x002a: /* Reject Synchronous Connection Request */
- offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
-
- proto_tree_add_item(tree, hf_bthci_cmd_reason, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- case 0x0015: /* Change Connection Link Key */
- case 0x001b: /* Read Remote Supported Features */
- case 0x001d: /* Read Remote Version Information */
- case 0x001f: /* Read Clock Offset*/
- case 0x0020: /* Read LMP Handle */
- proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- break;
-
- case 0x002b: /* IO Capability Response */
- offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
-
- proto_tree_add_item(tree, hf_bthci_cmd_io_capability, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- proto_tree_add_item(tree, hf_bthci_cmd_oob_data_present, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- proto_tree_add_item(tree, hf_bthci_cmd_auth_requirements, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- case 0x002c: /* User Confirmation Request Reply */
- case 0x002d: /* User Confirmation Request Negative Reply */
- case 0x002f: /* User Passkey Request Negative Reply */
- case 0x0033: /* Remote OOB Data Request Negative Reply */
- offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
- break;
-
- case 0x002e: /* User Passkey Request Reply */
- offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
-
- proto_tree_add_item(tree, hf_bthci_cmd_passkey, tvb, offset, 4, ENC_LITTLE_ENDIAN);
- offset+=4;
- break;
-
- case 0x0030: /* Remote OOB Data Request Reply */
- offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
-
- proto_tree_add_item(tree, hf_bthci_cmd_hash_c, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- proto_tree_add_item(tree, hf_bthci_cmd_randomizer_r, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- break;
-
- default:
- proto_tree_add_item(tree, hf_bthci_cmd_params, tvb, offset, -1, ENC_NA);
- offset+=tvb_length_remaining(tvb, offset);
- break;
- }
+ proto_item *item;
+ guint32 clock_value;
+
+ switch (cmd_ocf) {
+ case 0x0001: /* Inquiry */
+ proto_tree_add_item(tree, hf_bthci_cmd_lap, tvb, offset, 3, ENC_LITTLE_ENDIAN);
+ offset+=3;
+ proto_tree_add_item(tree, hf_bthci_cmd_inq_length, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ proto_tree_add_item(tree, hf_bthci_cmd_num_responses, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ case 0x0002: /* Inquiry Cancel */
+ /* no parameters */
+ break;
+
+ case 0x0003: /* Periodic Inquiry Mode */
+ proto_tree_add_item(tree, hf_bthci_cmd_max_period_length, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ proto_tree_add_item(tree, hf_bthci_cmd_min_period_length, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ proto_tree_add_item(tree, hf_bthci_cmd_lap, tvb, offset, 3, ENC_LITTLE_ENDIAN);
+ offset+=3;
+ proto_tree_add_item(tree, hf_bthci_cmd_inq_length, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ proto_tree_add_item(tree, hf_bthci_cmd_num_responses, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ case 0x0004: /* Exit Periodic Inquiry Mode */
+ /* no parameters */
+ break;
+
+ case 0x0005: /* Create Connection */
+ offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
+
+ proto_tree_add_item(tree, hf_bthci_cmd_packet_type_2dh1, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_packet_type_3dh1, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_packet_type_dm1, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_packet_type_dh1, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_packet_type_2dh3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_packet_type_3dh3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_packet_type_dm3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_packet_type_dh3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_packet_type_2dh5, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_packet_type_3dh5, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_packet_type_dm5, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_packet_type_dh5, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+
+ proto_tree_add_item(tree, hf_bthci_cmd_page_scan_repetition_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+
+ proto_tree_add_item(tree, hf_bthci_cmd_page_scan_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+
+ item = proto_tree_add_item(tree, hf_bthci_cmd_clock_offset, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ clock_value = tvb_get_letohs(tvb, 13) & 32767; /* only bit0-14 are valid */
+ proto_item_append_text(item, " (%g ms)", 1.25*clock_value);
+ proto_tree_add_item(tree, hf_bthci_cmd_clock_offset_valid , tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+
+ proto_tree_add_item(tree, hf_bthci_cmd_allow_role_switch, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ case 0x0006: /* Disconnect */
+ proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ proto_tree_add_item(tree, hf_bthci_cmd_reason, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ case 0x0007: /* Add SCO Connection */
+ proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ proto_tree_add_item(tree, hf_bthci_cmd_packet_type_hv1, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_packet_type_hv2, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_packet_type_hv3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ break;
+
+ case 0x0008: /* Create Connection Cancel Request */
+ offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
+ break;
+
+ case 0x0009: /* Accept Connection Request */
+ offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
+
+ proto_tree_add_item(tree, hf_bthci_cmd_role, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ case 0x000a: /* Reject Connection Request */
+ offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
+
+ proto_tree_add_item(tree, hf_bthci_cmd_reason, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ case 0x000b: /* Link Key Request Reply */
+ offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
+
+ proto_tree_add_item(tree, hf_bthci_cmd_link_key, tvb, offset, 16, ENC_NA);
+ offset+=16;
+ break;
+
+ case 0x000c: /* Link Key Request Negative Reply */
+ offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
+ break;
+
+ case 0x000d: /* PIN Code Request Reply */
+ offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
+
+ proto_tree_add_item(tree, hf_bthci_cmd_pin_code_length ,tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ proto_tree_add_item(tree, hf_bthci_cmd_pin_code ,tvb, offset, 16, ENC_ASCII|ENC_NA);
+ offset+=16;
+ break;
+
+ case 0x000e: /* PIN Code Request Negative Reply */
+ offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
+ break;
+
+ case 0x000f: /* Change Connection Packet Type */
+ proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ proto_tree_add_item(tree, hf_bthci_cmd_packet_type_2dh1, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_packet_type_3dh1, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_packet_type_dm1, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_packet_type_dh1, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_packet_type_2dh3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_packet_type_3dh3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_packet_type_dm3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_packet_type_dh3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_packet_type_2dh5, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_packet_type_3dh5, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_packet_type_dm5, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_packet_type_dh5, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ break;
+
+ case 0x0011: /* Authentication Request */
+ proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ break;
+
+ case 0x0013: /* Set Connection Encryption */
+ proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ proto_tree_add_item(tree, hf_bthci_cmd_encryption_enable, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ case 0x0017: /* Master Link Key */
+ proto_tree_add_item(tree, hf_bthci_cmd_key_flag, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ case 0x0019: /* Remote Name Request */
+ offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
+
+ proto_tree_add_item(tree, hf_bthci_cmd_page_scan_repetition_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+
+ proto_tree_add_item(tree, hf_bthci_cmd_page_scan_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+
+ item = proto_tree_add_item(tree, hf_bthci_cmd_clock_offset, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ clock_value = tvb_get_letohs(tvb, offset) & 32767; /* only bit0-14 are valid */
+ proto_item_append_text(item, " (%g ms)", 1.25*clock_value);
+ proto_tree_add_item(tree, hf_bthci_cmd_clock_offset_valid , tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ break;
+
+ case 0x001a: /* Remote Name Request Cancel */
+ offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
+ break;
+
+ case 0x001c: /* Read Remote Extended Features */
+ proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ proto_tree_add_item(tree, hf_bthci_cmd_page_number, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ case 0x0028: /* Setup Synchronous Connection */
+ case 0x0029: /* Accept Synchronous Connection Request */
+ proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ proto_tree_add_item(tree, hf_bthci_cmd_transmit_bandwidth, tvb, offset, 4, ENC_LITTLE_ENDIAN);
+ offset+=4;
+ proto_tree_add_item(tree, hf_bthci_cmd_receive_bandwidth, tvb, offset, 4, ENC_LITTLE_ENDIAN);
+ offset+=4;
+ proto_tree_add_item(tree, hf_bthci_cmd_max_latency_ms, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+
+ proto_tree_add_item(tree, hf_bthci_cmd_input_coding, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_input_data_format, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_input_sample_size, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_linear_pcm_bit_pos, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_air_coding_format, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+
+ proto_tree_add_item(tree, hf_bthci_cmd_retransmission_effort, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+
+ proto_tree_add_item(tree, hf_bthci_cmd_sco_packet_type_hv1, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_sco_packet_type_hv2, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_sco_packet_type_hv3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_sco_packet_type_ev3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_sco_packet_type_ev4, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_sco_packet_type_ev5, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_sco_packet_type_2ev3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_sco_packet_type_3ev3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_sco_packet_type_2ev5, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_sco_packet_type_3ev5, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ break;
+
+ case 0x002a: /* Reject Synchronous Connection Request */
+ offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
+
+ proto_tree_add_item(tree, hf_bthci_cmd_reason, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ case 0x0015: /* Change Connection Link Key */
+ case 0x001b: /* Read Remote Supported Features */
+ case 0x001d: /* Read Remote Version Information */
+ case 0x001f: /* Read Clock Offset*/
+ case 0x0020: /* Read LMP Handle */
+ proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ break;
+
+ case 0x002b: /* IO Capability Response */
+ offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
+
+ proto_tree_add_item(tree, hf_bthci_cmd_io_capability, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ proto_tree_add_item(tree, hf_bthci_cmd_oob_data_present, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ proto_tree_add_item(tree, hf_bthci_cmd_auth_requirements, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ case 0x002c: /* User Confirmation Request Reply */
+ case 0x002d: /* User Confirmation Request Negative Reply */
+ case 0x002f: /* User Passkey Request Negative Reply */
+ case 0x0033: /* Remote OOB Data Request Negative Reply */
+ offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
+ break;
+
+ case 0x002e: /* User Passkey Request Reply */
+ offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
+
+ proto_tree_add_item(tree, hf_bthci_cmd_passkey, tvb, offset, 4, ENC_LITTLE_ENDIAN);
+ offset+=4;
+ break;
+
+ case 0x0030: /* Remote OOB Data Request Reply */
+ offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
+
+ proto_tree_add_item(tree, hf_bthci_cmd_hash_c, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ proto_tree_add_item(tree, hf_bthci_cmd_randomizer_r, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ break;
+
+ default:
+ proto_tree_add_item(tree, hf_bthci_cmd_params, tvb, offset, -1, ENC_NA);
+ offset+=tvb_length_remaining(tvb, offset);
+ break;
+ }
return offset;
}
static int
dissect_link_policy_cmd(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, guint16 cmd_ocf)
{
- proto_item *item;
- guint16 timeout;
-
- switch(cmd_ocf) {
-
- case 0x0001: /* Hold Mode */
- proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- item = proto_tree_add_item(tree, hf_bthci_cmd_max_interval_hold, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- timeout = tvb_get_letohs(tvb, offset);
- proto_item_append_text(item, " slots (%g msec)", timeout*0.625);
- offset+=2;
- item = proto_tree_add_item(tree, hf_bthci_cmd_min_interval_hold, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- timeout = tvb_get_letohs(tvb, offset);
- proto_item_append_text(item, " slots (%g msec)", timeout*0.625);
- offset+=2;
- break;
-
- case 0x0003: /* sniff mode */
- proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- item = proto_tree_add_item(tree, hf_bthci_cmd_max_interval_sniff, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_item_append_text(item, " slots (%g msec)", tvb_get_letohs(tvb, offset)*0.625);
- offset+=2;
- item = proto_tree_add_item(tree, hf_bthci_cmd_min_interval_sniff, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_item_append_text(item, " slots (%g msec)", tvb_get_letohs(tvb, offset)*0.625);
- offset+=2;
- item = proto_tree_add_item(tree, hf_bthci_cmd_sniff_attempt, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- timeout = tvb_get_letohs(tvb, offset);
- if(timeout>0){
- proto_item_append_text(item, " (%g msec)", (2*timeout-1)*0.625);
- } else {
- proto_item_append_text(item, " (0 msec)");
- }
- offset+=2;
- item = proto_tree_add_item(tree, hf_bthci_cmd_timeout, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_item_append_text(item, " slots (%g msec)", tvb_get_letohs(tvb, offset)*1.25);
- offset+=2;
- break;
-
- case 0x0005: /* Park Mode */
- proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- item = proto_tree_add_item(tree, hf_bthci_cmd_max_interval_beacon, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- timeout = tvb_get_letohs(tvb, offset);
- proto_item_append_text(item, " slots (%g msec)", timeout*0.625);
- offset+=2;
- item = proto_tree_add_item(tree, hf_bthci_cmd_min_interval_beacon, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- timeout = tvb_get_letohs(tvb, offset);
- proto_item_append_text(item, " slots (%g msec)", timeout*0.625);
- offset+=2;
- break;
-
- case 0x0007: /* QoS Setup */
- proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- proto_tree_add_item(tree, hf_bthci_cmd_flags, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- proto_tree_add_item(tree, hf_bthci_cmd_service_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- proto_tree_add_item(tree, hf_bthci_cmd_token_rate, tvb, offset, 4, ENC_LITTLE_ENDIAN);
- offset+=4;
- proto_tree_add_item(tree, hf_bthci_cmd_peak_bandwidth, tvb, offset, 4, ENC_LITTLE_ENDIAN);
- offset+=4;
- proto_tree_add_item(tree, hf_bthci_cmd_latency, tvb, offset, 4, ENC_LITTLE_ENDIAN);
- offset+=4;
- proto_tree_add_item(tree, hf_bthci_cmd_delay_variation, tvb, offset, 4, ENC_LITTLE_ENDIAN);
- offset+=4;
- break;
-
- case 0x000b: /* Switch Role */
- offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
-
- proto_tree_add_item(tree, hf_bthci_cmd_role, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- case 0x0004: /* Exit Sniff Mode */
- case 0x0006: /* Exit Park Mode */
- case 0x0009: /* Role Discovery */
- case 0x000c: /* Read Link Policy Settings */
- proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- break;
-
- case 0x000d: /* Write Link Policy Settings */
- case 0x000f: /* Write Default Link Policy Settings */
- proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- proto_tree_add_item(tree, hf_bthci_cmd_link_policy_setting_switch, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_link_policy_setting_hold , tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_link_policy_setting_sniff , tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_link_policy_setting_park , tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- break;
-
- case 0x0010: /* Flow Specification */
- proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- proto_tree_add_item(tree, hf_bthci_cmd_flags, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- proto_tree_add_item(tree, hf_bthci_cmd_service_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- proto_tree_add_item(tree, hf_bthci_cmd_token_rate, tvb, offset, 4, ENC_LITTLE_ENDIAN);
- offset+=4;
- proto_tree_add_item(tree, hf_bthci_cmd_token_bucket_size, tvb, offset, 4, ENC_LITTLE_ENDIAN);
- offset+=4;
- proto_tree_add_item(tree, hf_bthci_cmd_peak_bandwidth, tvb, offset, 4, ENC_LITTLE_ENDIAN);
- offset+=4;
- proto_tree_add_item(tree, hf_bthci_cmd_latency, tvb, offset, 4, ENC_LITTLE_ENDIAN);
- offset+=4;
- break;
-
- case 0x0011: /* Sniff Subrating */
- proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
-
- item = proto_tree_add_item(tree, hf_bthci_cmd_max_latency, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_item_append_text(item, " slots (%g msec)", tvb_get_letohs(tvb, offset)*0.625);
- offset+=2;
-
- item = proto_tree_add_item(tree, hf_bthci_cmd_min_remote_timeout, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_item_append_text(item, " slots (%g msec)", tvb_get_letohs(tvb, offset)*0.625);
- offset+=2;
-
- item = proto_tree_add_item(tree, hf_bthci_cmd_min_local_timeout, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_item_append_text(item, " slots (%g msec)", tvb_get_letohs(tvb, offset)*0.625);
- offset+=2;
- break;
-
- default:
- proto_tree_add_item(tree, hf_bthci_cmd_params, tvb, offset, -1, ENC_NA);
- offset+=tvb_length_remaining(tvb, offset);
- break;
-
- }
+ proto_item *item;
+ guint16 timeout;
+
+ switch (cmd_ocf) {
+
+ case 0x0001: /* Hold Mode */
+ proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ item = proto_tree_add_item(tree, hf_bthci_cmd_max_interval_hold, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ timeout = tvb_get_letohs(tvb, offset);
+ proto_item_append_text(item, " slots (%g msec)", timeout*0.625);
+ offset+=2;
+ item = proto_tree_add_item(tree, hf_bthci_cmd_min_interval_hold, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ timeout = tvb_get_letohs(tvb, offset);
+ proto_item_append_text(item, " slots (%g msec)", timeout*0.625);
+ offset+=2;
+ break;
+
+ case 0x0003: /* sniff mode */
+ proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ item = proto_tree_add_item(tree, hf_bthci_cmd_max_interval_sniff, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_item_append_text(item, " slots (%g msec)", tvb_get_letohs(tvb, offset)*0.625);
+ offset+=2;
+ item = proto_tree_add_item(tree, hf_bthci_cmd_min_interval_sniff, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_item_append_text(item, " slots (%g msec)", tvb_get_letohs(tvb, offset)*0.625);
+ offset+=2;
+ item = proto_tree_add_item(tree, hf_bthci_cmd_sniff_attempt, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ timeout = tvb_get_letohs(tvb, offset);
+ if (timeout>0) {
+ proto_item_append_text(item, " (%g msec)", (2*timeout-1)*0.625);
+ } else {
+ proto_item_append_text(item, " (0 msec)");
+ }
+ offset+=2;
+ item = proto_tree_add_item(tree, hf_bthci_cmd_timeout, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_item_append_text(item, " slots (%g msec)", tvb_get_letohs(tvb, offset)*1.25);
+ offset+=2;
+ break;
+
+ case 0x0005: /* Park Mode */
+ proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ item = proto_tree_add_item(tree, hf_bthci_cmd_max_interval_beacon, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ timeout = tvb_get_letohs(tvb, offset);
+ proto_item_append_text(item, " slots (%g msec)", timeout*0.625);
+ offset+=2;
+ item = proto_tree_add_item(tree, hf_bthci_cmd_min_interval_beacon, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ timeout = tvb_get_letohs(tvb, offset);
+ proto_item_append_text(item, " slots (%g msec)", timeout*0.625);
+ offset+=2;
+ break;
+
+ case 0x0007: /* QoS Setup */
+ proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ proto_tree_add_item(tree, hf_bthci_cmd_flags, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ proto_tree_add_item(tree, hf_bthci_cmd_service_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ proto_tree_add_item(tree, hf_bthci_cmd_token_rate, tvb, offset, 4, ENC_LITTLE_ENDIAN);
+ offset+=4;
+ proto_tree_add_item(tree, hf_bthci_cmd_peak_bandwidth, tvb, offset, 4, ENC_LITTLE_ENDIAN);
+ offset+=4;
+ proto_tree_add_item(tree, hf_bthci_cmd_latency, tvb, offset, 4, ENC_LITTLE_ENDIAN);
+ offset+=4;
+ proto_tree_add_item(tree, hf_bthci_cmd_delay_variation, tvb, offset, 4, ENC_LITTLE_ENDIAN);
+ offset+=4;
+ break;
+
+ case 0x000b: /* Switch Role */
+ offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
+
+ proto_tree_add_item(tree, hf_bthci_cmd_role, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ case 0x0004: /* Exit Sniff Mode */
+ case 0x0006: /* Exit Park Mode */
+ case 0x0009: /* Role Discovery */
+ case 0x000c: /* Read Link Policy Settings */
+ proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ break;
+
+ case 0x000d: /* Write Link Policy Settings */
+ case 0x000f: /* Write Default Link Policy Settings */
+ proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ proto_tree_add_item(tree, hf_bthci_cmd_link_policy_setting_switch, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_link_policy_setting_hold , tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_link_policy_setting_sniff , tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_link_policy_setting_park , tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ break;
+
+ case 0x0010: /* Flow Specification */
+ proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ proto_tree_add_item(tree, hf_bthci_cmd_flags, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ proto_tree_add_item(tree, hf_bthci_cmd_service_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ proto_tree_add_item(tree, hf_bthci_cmd_token_rate, tvb, offset, 4, ENC_LITTLE_ENDIAN);
+ offset+=4;
+ proto_tree_add_item(tree, hf_bthci_cmd_token_bucket_size, tvb, offset, 4, ENC_LITTLE_ENDIAN);
+ offset+=4;
+ proto_tree_add_item(tree, hf_bthci_cmd_peak_bandwidth, tvb, offset, 4, ENC_LITTLE_ENDIAN);
+ offset+=4;
+ proto_tree_add_item(tree, hf_bthci_cmd_latency, tvb, offset, 4, ENC_LITTLE_ENDIAN);
+ offset+=4;
+ break;
+
+ case 0x0011: /* Sniff Subrating */
+ proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+
+ item = proto_tree_add_item(tree, hf_bthci_cmd_max_latency, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_item_append_text(item, " slots (%g msec)", tvb_get_letohs(tvb, offset)*0.625);
+ offset+=2;
+
+ item = proto_tree_add_item(tree, hf_bthci_cmd_min_remote_timeout, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_item_append_text(item, " slots (%g msec)", tvb_get_letohs(tvb, offset)*0.625);
+ offset+=2;
+
+ item = proto_tree_add_item(tree, hf_bthci_cmd_min_local_timeout, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_item_append_text(item, " slots (%g msec)", tvb_get_letohs(tvb, offset)*0.625);
+ offset+=2;
+ break;
+
+ default:
+ proto_tree_add_item(tree, hf_bthci_cmd_params, tvb, offset, -1, ENC_NA);
+ offset+=tvb_length_remaining(tvb, offset);
+ break;
+
+ }
return offset;
}
static int
dissect_host_controller_baseband_cmd(tvbuff_t *tvb, int offset, packet_info *pinfo _U_,
- proto_tree *tree, guint16 cmd_ocf)
+ proto_tree *tree, guint16 cmd_ocf)
{
- proto_item *item;
- guint16 timeout;
- guint8 filter_type, filter_condition_type, num8;
- int i;
-
- switch(cmd_ocf) {
-
- case 0x0001: /* Set Event Mask */
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_00, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_01, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_02, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_03, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_04, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_05, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_06, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_07, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
-
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_10, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_11, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_12, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_13, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_14, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_17, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
-
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_20, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_21, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_23, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_24, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_25, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_26, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_27, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
-
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_30, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_31, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_32, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_33, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_34, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_35, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_36, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_37, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
-
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_40, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_41, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_42, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
-
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_53, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_54, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_55, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_56, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_57, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
-
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_60, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_61, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_62, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_63, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_64, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_65, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_67, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
-
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_70, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_72, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_73, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- case 0x0005: /* Set Event Filter */
- proto_tree_add_item(tree, hf_bthci_cmd_filter_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- filter_type = tvb_get_guint8(tvb, 3);
- offset++;
- switch (filter_type) {
-
- case 0x01: /* Inquiry Result Filter */
- proto_tree_add_item(tree, hf_bthci_cmd_inquiry_result_filter_condition_type,
- tvb, offset, 1, ENC_LITTLE_ENDIAN);
- filter_condition_type = tvb_get_guint8(tvb, offset);
- offset++;
- switch (filter_condition_type) {
- case 0x01:
- offset=dissect_bthci_cmd_cod(hf_bthci_cmd_class_of_device, tvb, offset, pinfo, tree);
- offset=dissect_bthci_cmd_cod(hf_bthci_cmd_class_of_device_mask, tvb, offset, pinfo, tree);
- break;
-
- case 0x02:
- offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
- break;
-
- default:
- break;
-
- }
- break;
-
- case 0x02: /* Connection Setup Filter */
- proto_tree_add_item(tree, hf_bthci_cmd_connection_setup_filter_condition_type,
- tvb, offset, 1, ENC_LITTLE_ENDIAN);
- filter_condition_type = tvb_get_guint8(tvb, offset);
- offset++;
- switch (filter_condition_type) {
- case 0x00:
- proto_tree_add_item(tree, hf_bthci_cmd_auto_acc_flag, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- case 0x01:
- offset=dissect_bthci_cmd_cod(hf_bthci_cmd_class_of_device, tvb, offset, pinfo, tree);
- offset=dissect_bthci_cmd_cod(hf_bthci_cmd_class_of_device_mask, tvb, offset, pinfo, tree);
-
- proto_tree_add_item(tree, hf_bthci_cmd_auto_acc_flag, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- case 0x02:
- offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
-
- proto_tree_add_item(tree, hf_bthci_cmd_auto_acc_flag, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- default:
- break;
-
- }
- break;
-
- default:
- break;
-
- }
-
- break;
- case 0x000a: /* Write PIN Type */
- proto_tree_add_item(tree, hf_bthci_cmd_pin_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- case 0x000d: /* Read Stored Link Key */
- offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
-
- proto_tree_add_item(tree, hf_bthci_cmd_read_all_flag, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- case 0x0011: /* Write Stored Link Key */
- proto_tree_add_item(tree, hf_bthci_cmd_num_link_keys, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- num8 = tvb_get_guint8(tvb, offset);
- offset++;
- for (i=0; i<num8; i++) {
- dissect_bthci_cmd_bd_addr(tvb, offset+(i*22), pinfo, tree);
- proto_tree_add_item(tree, hf_bthci_cmd_link_key, tvb, offset+6+(i*22), 16, ENC_NA);
- }
- break;
-
- case 0x0012: /* Delete Stored Link Key */
- offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
-
- proto_tree_add_item(tree, hf_bthci_cmd_delete_all_flag, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- case 0x0013: /* Change Local Name */
- proto_tree_add_item(tree, hf_bthci_cmd_device_name,
- tvb, offset, 248, ENC_ASCII|ENC_NA);
- offset+=248;
- break;
-
- case 0x0016: /* Write Connection Accept Timeout */
- item = proto_tree_add_item(tree, hf_bthci_cmd_timeout, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- timeout = tvb_get_letohs(tvb, offset);
- proto_item_append_text(item, " slots (%g msec)", timeout*0.625);
- offset+=2;
- break;
-
- case 0x0018: /* Write Page Timeout */
- item = proto_tree_add_item(tree, hf_bthci_cmd_timeout, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- timeout = tvb_get_letohs(tvb, offset);
- if(timeout > 0){
- proto_item_append_text(item, " slots (%g msec)", timeout*0.625);
- } else {
- proto_item_append_text(item, " Illegal Page Timeout");
- }
- offset+=2;
- break;
-
- case 0x001a: /* Write Scan Enable */
- proto_tree_add_item(tree, hf_bthci_cmd_scan_enable,
- tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- case 0x0020: /* Write Authentication Enable */
- proto_tree_add_item(tree, hf_bthci_cmd_authentication_enable,
- tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- case 0x0022: /* Write Encryption Mode */
- proto_tree_add_item(tree, hf_bthci_cmd_encrypt_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- case 0x0024: /* Write Class of Device */
- offset=dissect_bthci_cmd_cod(hf_bthci_cmd_class_of_device, tvb, offset, pinfo, tree);
- break;
-
- case 0x0026: /* Write Voice Setting */
- proto_tree_add_item(tree, hf_bthci_cmd_input_coding,
- tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_input_data_format,
- tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_input_sample_size,
- tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_linear_pcm_bit_pos,
- tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_air_coding_format,
- tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- break;
-
- case 0x0028: /* Write Automatic Flush Timeout */
- proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- item = proto_tree_add_item(tree, hf_bthci_cmd_timeout, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- timeout = tvb_get_letohs(tvb, offset);
- if(timeout>0){
- proto_item_append_text(item, " slots (%g msec)", timeout*0.625);
- } else {
- proto_item_append_text(item, " (= No Automatic Flush )");
- }
- offset+=2;
- break;
-
- case 0x002a: /* Write Num of Broadcast Retransmissions */
- proto_tree_add_item(tree, hf_bthci_cmd_num_broadcast_retransmissions,
- tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- case 0x002c: /* Write Hold Mode Activity */
- proto_tree_add_item(tree, hf_bthci_cmd_hold_mode_act_page,
- tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_hold_mode_act_inquiry,
- tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_hold_mode_act_periodic,
- tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- case 0x002d: /* Read Transmit Power Level */
- proto_tree_add_item(tree, hf_bthci_cmd_connection_handle,
- tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- proto_tree_add_item(tree, hf_bthci_cmd_power_level_type,
- tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- case 0x002f: /* Write SCO Flow Control Enable */
- proto_tree_add_item(tree, hf_bthci_cmd_sco_flow_control,
- tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- case 0x0031: /* Set Host Controller To Host Flow Control */
- proto_tree_add_item(tree, hf_bthci_cmd_flow_contr_enable,
- tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- case 0x0033: /* Host Buffer Size */
- proto_tree_add_item(tree, hf_bthci_cmd_host_data_packet_length_acl,
- tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- proto_tree_add_item(tree, hf_bthci_cmd_host_data_packet_length_sco,
- tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- proto_tree_add_item(tree, hf_bthci_cmd_host_total_num_acl_data_packets,
- tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- proto_tree_add_item(tree, hf_bthci_cmd_host_total_num_sco_data_packets,
- tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- break;
-
- case 0x0035: /* Host Number Of Completed Packets */
- proto_tree_add_item(tree, hf_bthci_cmd_num_handles,
- tvb, offset, 1, ENC_LITTLE_ENDIAN);
- num8 = tvb_get_guint8(tvb, offset);
- offset++;
- for (i=0; i<num8; i++) {
- proto_tree_add_item(tree, hf_bthci_cmd_connection_handle,
- tvb, offset+(i*4), 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_cmd_num_compl_packets,
- tvb, offset+2+(i*4), 2, ENC_LITTLE_ENDIAN);
- }
- break;
-
- case 0x0037: /* Write Link Supervision Timeout */
- proto_tree_add_item(tree, hf_bthci_cmd_connection_handle,
- tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- item = proto_tree_add_item(tree, hf_bthci_cmd_timeout,
- tvb, offset, 2, ENC_LITTLE_ENDIAN);
- timeout = tvb_get_letohs(tvb, offset);
- if(timeout>0){
- proto_item_append_text(item, " slots (%g msec)", timeout*0.625);
- } else {
- proto_item_append_text(item, " (= No Link Supervision Timeout)");
- }
- offset+=2;
- break;
-
- case 0x003a: /* Write Current IAC LAP */
- proto_tree_add_item(tree, hf_bthci_cmd_num_curr_iac, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- num8 = tvb_get_guint8(tvb, offset);
- offset++;
- for (i=0; i<num8; i++) {
- proto_tree_add_item(tree, hf_bthci_cmd_iac_lap, tvb, offset+(i*3), 3, ENC_LITTLE_ENDIAN);
- }
- break;
-
- case 0x003c: /* Write Page Scan Period Mode */
- proto_tree_add_item(tree, hf_bthci_cmd_page_scan_period_mode,
- tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- case 0x003e: /* Write Page Scan Mode */
- proto_tree_add_item(tree, hf_bthci_cmd_page_scan_mode,
- tvb, 3, 1, ENC_LITTLE_ENDIAN);
- break;
-
- case 0x003f: /* Set AFH Host Channel Classification */
- proto_tree_add_item(tree, hf_bthci_cmd_afh_ch_classification, tvb, offset, 10, ENC_NA);
- offset+=10;
- break;
-
- case 0x0008: /* Flush */
- case 0x0027: /* Read Automatic Flush Timeout */
- case 0x0036: /* Read Link Supervision Timeout */
- proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- break;
-
- case 0x001c: /* Write Page Scan Activity */
- case 0x001e: /* Write Inquiry Scan Activity */
- item = proto_tree_add_item(tree, hf_bthci_cmd_interval, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_item_append_text(item, " slots (%g msec)", tvb_get_letohs(tvb, offset)*0.625);
- offset+=2;
- item = proto_tree_add_item(tree, hf_bthci_cmd_window, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_item_append_text(item, " slots (%g msec)", tvb_get_letohs(tvb, offset)*0.625);
- offset+=2;
- break;
-
-
- case 0x0043: /* Write Inquiry Scan Type */
- proto_tree_add_item(tree, hf_bthci_cmd_scan_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- case 0x0045: /* Write Inquiry Mode */
- proto_tree_add_item(tree, hf_bthci_cmd_inq_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- case 0x0047: /* Write Page Scan Type */
- proto_tree_add_item(tree, hf_bthci_cmd_scan_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- case 0x0049: /* Write AFH Channel Assessment Mode */
- proto_tree_add_item(tree, hf_bthci_cmd_afh_ch_assessment_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- case 0x0052: /* Write Extended Inquiry Response */
- proto_tree_add_item(tree, hf_bthci_cmd_fec_required, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- offset=dissect_bthci_ext_inquiry_response(tvb, offset, pinfo, tree);
- break;
-
- case 0x0053: /* Refresh Encryption Key */
- proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- break;
-
- case 0x0056: /* Write Simple Pairing Mode */
- proto_tree_add_item(tree, hf_bthci_cmd_simple_pairing_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- case 0x0059: /* Write Inquiry Tx Response Power Level */
- proto_tree_add_item(tree, hf_bthci_cmd_tx_power, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- case 0x005b: /* Write Default Erroneous Data Reporting */
- proto_tree_add_item(tree, hf_bthci_cmd_err_data_reporting, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- case 0x005f: /* Enhanced Flush */
- proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- proto_tree_add_item(tree, hf_bthci_cmd_flush_packet_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- case 0x0060: /* Send Keypress Notification */
- offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
-
- proto_tree_add_item(tree, hf_bthci_cmd_notification_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- default:
- proto_tree_add_item(tree, hf_bthci_cmd_params, tvb, offset, -1, ENC_NA);
- offset+=tvb_length_remaining(tvb, offset);
- break;
-
- }
+ proto_item *item;
+ guint16 timeout;
+ guint8 filter_type, filter_condition_type, num8;
+ int i;
+
+ switch (cmd_ocf) {
+
+ case 0x0001: /* Set Event Mask */
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_00, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_01, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_02, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_03, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_04, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_05, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_06, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_07, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_10, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_11, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_12, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_13, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_14, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_17, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_20, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_21, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_23, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_24, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_25, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_26, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_27, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_30, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_31, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_32, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_33, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_34, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_35, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_36, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_37, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_40, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_41, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_42, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_53, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_54, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_55, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_56, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_57, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_60, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_61, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_62, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_63, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_64, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_65, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_67, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_70, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_72, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_evt_mask_73, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ case 0x0005: /* Set Event Filter */
+ proto_tree_add_item(tree, hf_bthci_cmd_filter_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ filter_type = tvb_get_guint8(tvb, 3);
+ offset++;
+ switch (filter_type) {
+
+ case 0x01: /* Inquiry Result Filter */
+ proto_tree_add_item(tree, hf_bthci_cmd_inquiry_result_filter_condition_type,
+ tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ filter_condition_type = tvb_get_guint8(tvb, offset);
+ offset++;
+ switch (filter_condition_type) {
+ case 0x01:
+ offset=dissect_bthci_cmd_cod(hf_bthci_cmd_class_of_device, tvb, offset, pinfo, tree);
+ offset=dissect_bthci_cmd_cod(hf_bthci_cmd_class_of_device_mask, tvb, offset, pinfo, tree);
+ break;
+
+ case 0x02:
+ offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
+ break;
+
+ default:
+ break;
+
+ }
+ break;
+
+ case 0x02: /* Connection Setup Filter */
+ proto_tree_add_item(tree, hf_bthci_cmd_connection_setup_filter_condition_type,
+ tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ filter_condition_type = tvb_get_guint8(tvb, offset);
+ offset++;
+ switch (filter_condition_type) {
+ case 0x00:
+ proto_tree_add_item(tree, hf_bthci_cmd_auto_acc_flag, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ case 0x01:
+ offset=dissect_bthci_cmd_cod(hf_bthci_cmd_class_of_device, tvb, offset, pinfo, tree);
+ offset=dissect_bthci_cmd_cod(hf_bthci_cmd_class_of_device_mask, tvb, offset, pinfo, tree);
+
+ proto_tree_add_item(tree, hf_bthci_cmd_auto_acc_flag, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ case 0x02:
+ offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
+
+ proto_tree_add_item(tree, hf_bthci_cmd_auto_acc_flag, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ default:
+ break;
+
+ }
+ break;
+
+ default:
+ break;
+
+ }
+
+ break;
+ case 0x000a: /* Write PIN Type */
+ proto_tree_add_item(tree, hf_bthci_cmd_pin_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ case 0x000d: /* Read Stored Link Key */
+ offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
+
+ proto_tree_add_item(tree, hf_bthci_cmd_read_all_flag, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ case 0x0011: /* Write Stored Link Key */
+ proto_tree_add_item(tree, hf_bthci_cmd_num_link_keys, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ num8 = tvb_get_guint8(tvb, offset);
+ offset++;
+ for (i=0; i<num8; i++) {
+ dissect_bthci_cmd_bd_addr(tvb, offset+(i*22), pinfo, tree);
+ proto_tree_add_item(tree, hf_bthci_cmd_link_key, tvb, offset+6+(i*22), 16, ENC_NA);
+ }
+ break;
+
+ case 0x0012: /* Delete Stored Link Key */
+ offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
+
+ proto_tree_add_item(tree, hf_bthci_cmd_delete_all_flag, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ case 0x0013: /* Change Local Name */
+ proto_tree_add_item(tree, hf_bthci_cmd_device_name,
+ tvb, offset, 248, ENC_ASCII|ENC_NA);
+ offset+=248;
+ break;
+
+ case 0x0016: /* Write Connection Accept Timeout */
+ item = proto_tree_add_item(tree, hf_bthci_cmd_timeout, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ timeout = tvb_get_letohs(tvb, offset);
+ proto_item_append_text(item, " slots (%g msec)", timeout*0.625);
+ offset+=2;
+ break;
+
+ case 0x0018: /* Write Page Timeout */
+ item = proto_tree_add_item(tree, hf_bthci_cmd_timeout, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ timeout = tvb_get_letohs(tvb, offset);
+ if (timeout > 0) {
+ proto_item_append_text(item, " slots (%g msec)", timeout*0.625);
+ } else {
+ proto_item_append_text(item, " Illegal Page Timeout");
+ }
+ offset+=2;
+ break;
+
+ case 0x001a: /* Write Scan Enable */
+ proto_tree_add_item(tree, hf_bthci_cmd_scan_enable,
+ tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ case 0x0020: /* Write Authentication Enable */
+ proto_tree_add_item(tree, hf_bthci_cmd_authentication_enable,
+ tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ case 0x0022: /* Write Encryption Mode */
+ proto_tree_add_item(tree, hf_bthci_cmd_encrypt_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ case 0x0024: /* Write Class of Device */
+ offset=dissect_bthci_cmd_cod(hf_bthci_cmd_class_of_device, tvb, offset, pinfo, tree);
+ break;
+
+ case 0x0026: /* Write Voice Setting */
+ proto_tree_add_item(tree, hf_bthci_cmd_input_coding,
+ tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_input_data_format,
+ tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_input_sample_size,
+ tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_linear_pcm_bit_pos,
+ tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_air_coding_format,
+ tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ break;
+
+ case 0x0028: /* Write Automatic Flush Timeout */
+ proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ item = proto_tree_add_item(tree, hf_bthci_cmd_timeout, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ timeout = tvb_get_letohs(tvb, offset);
+ if (timeout>0) {
+ proto_item_append_text(item, " slots (%g msec)", timeout*0.625);
+ } else {
+ proto_item_append_text(item, " (= No Automatic Flush )");
+ }
+ offset+=2;
+ break;
+
+ case 0x002a: /* Write Num of Broadcast Retransmissions */
+ proto_tree_add_item(tree, hf_bthci_cmd_num_broadcast_retransmissions,
+ tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ case 0x002c: /* Write Hold Mode Activity */
+ proto_tree_add_item(tree, hf_bthci_cmd_hold_mode_act_page,
+ tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_hold_mode_act_inquiry,
+ tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_hold_mode_act_periodic,
+ tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ case 0x002d: /* Read Transmit Power Level */
+ proto_tree_add_item(tree, hf_bthci_cmd_connection_handle,
+ tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ proto_tree_add_item(tree, hf_bthci_cmd_power_level_type,
+ tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ case 0x002f: /* Write SCO Flow Control Enable */
+ proto_tree_add_item(tree, hf_bthci_cmd_sco_flow_control,
+ tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ case 0x0031: /* Set Host Controller To Host Flow Control */
+ proto_tree_add_item(tree, hf_bthci_cmd_flow_contr_enable,
+ tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ case 0x0033: /* Host Buffer Size */
+ proto_tree_add_item(tree, hf_bthci_cmd_host_data_packet_length_acl,
+ tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ proto_tree_add_item(tree, hf_bthci_cmd_host_data_packet_length_sco,
+ tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ proto_tree_add_item(tree, hf_bthci_cmd_host_total_num_acl_data_packets,
+ tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ proto_tree_add_item(tree, hf_bthci_cmd_host_total_num_sco_data_packets,
+ tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ break;
+
+ case 0x0035: /* Host Number Of Completed Packets */
+ proto_tree_add_item(tree, hf_bthci_cmd_num_handles,
+ tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ num8 = tvb_get_guint8(tvb, offset);
+ offset++;
+ for (i=0; i<num8; i++) {
+ proto_tree_add_item(tree, hf_bthci_cmd_connection_handle,
+ tvb, offset+(i*4), 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_cmd_num_compl_packets,
+ tvb, offset+2+(i*4), 2, ENC_LITTLE_ENDIAN);
+ }
+ break;
+
+ case 0x0037: /* Write Link Supervision Timeout */
+ proto_tree_add_item(tree, hf_bthci_cmd_connection_handle,
+ tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ item = proto_tree_add_item(tree, hf_bthci_cmd_timeout,
+ tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ timeout = tvb_get_letohs(tvb, offset);
+ if (timeout>0) {
+ proto_item_append_text(item, " slots (%g msec)", timeout*0.625);
+ } else {
+ proto_item_append_text(item, " (= No Link Supervision Timeout)");
+ }
+ offset+=2;
+ break;
+
+ case 0x003a: /* Write Current IAC LAP */
+ proto_tree_add_item(tree, hf_bthci_cmd_num_curr_iac, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ num8 = tvb_get_guint8(tvb, offset);
+ offset++;
+ for (i=0; i<num8; i++) {
+ proto_tree_add_item(tree, hf_bthci_cmd_iac_lap, tvb, offset+(i*3), 3, ENC_LITTLE_ENDIAN);
+ }
+ break;
+
+ case 0x003c: /* Write Page Scan Period Mode */
+ proto_tree_add_item(tree, hf_bthci_cmd_page_scan_period_mode,
+ tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ case 0x003e: /* Write Page Scan Mode */
+ proto_tree_add_item(tree, hf_bthci_cmd_page_scan_mode,
+ tvb, 3, 1, ENC_LITTLE_ENDIAN);
+ break;
+
+ case 0x003f: /* Set AFH Host Channel Classification */
+ proto_tree_add_item(tree, hf_bthci_cmd_afh_ch_classification, tvb, offset, 10, ENC_NA);
+ offset+=10;
+ break;
+
+ case 0x0008: /* Flush */
+ case 0x0027: /* Read Automatic Flush Timeout */
+ case 0x0036: /* Read Link Supervision Timeout */
+ proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ break;
+
+ case 0x001c: /* Write Page Scan Activity */
+ case 0x001e: /* Write Inquiry Scan Activity */
+ item = proto_tree_add_item(tree, hf_bthci_cmd_interval, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_item_append_text(item, " slots (%g msec)", tvb_get_letohs(tvb, offset)*0.625);
+ offset+=2;
+ item = proto_tree_add_item(tree, hf_bthci_cmd_window, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_item_append_text(item, " slots (%g msec)", tvb_get_letohs(tvb, offset)*0.625);
+ offset+=2;
+ break;
+
+
+ case 0x0043: /* Write Inquiry Scan Type */
+ proto_tree_add_item(tree, hf_bthci_cmd_scan_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ case 0x0045: /* Write Inquiry Mode */
+ proto_tree_add_item(tree, hf_bthci_cmd_inq_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ case 0x0047: /* Write Page Scan Type */
+ proto_tree_add_item(tree, hf_bthci_cmd_scan_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ case 0x0049: /* Write AFH Channel Assessment Mode */
+ proto_tree_add_item(tree, hf_bthci_cmd_afh_ch_assessment_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ case 0x0052: /* Write Extended Inquiry Response */
+ proto_tree_add_item(tree, hf_bthci_cmd_fec_required, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ offset=dissect_bthci_ext_inquiry_response(tvb, offset, pinfo, tree);
+ break;
+
+ case 0x0053: /* Refresh Encryption Key */
+ proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ break;
+
+ case 0x0056: /* Write Simple Pairing Mode */
+ proto_tree_add_item(tree, hf_bthci_cmd_simple_pairing_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ case 0x0059: /* Write Inquiry Tx Response Power Level */
+ proto_tree_add_item(tree, hf_bthci_cmd_tx_power, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ case 0x005b: /* Write Default Erroneous Data Reporting */
+ proto_tree_add_item(tree, hf_bthci_cmd_err_data_reporting, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ case 0x005f: /* Enhanced Flush */
+ proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ proto_tree_add_item(tree, hf_bthci_cmd_flush_packet_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ case 0x0060: /* Send Keypress Notification */
+ offset = dissect_bthci_cmd_bd_addr(tvb, offset, pinfo, tree);
+
+ proto_tree_add_item(tree, hf_bthci_cmd_notification_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ default:
+ proto_tree_add_item(tree, hf_bthci_cmd_params, tvb, offset, -1, ENC_NA);
+ offset+=tvb_length_remaining(tvb, offset);
+ break;
+
+ }
return offset;
}
static int
dissect_informational_parameters_cmd(tvbuff_t *tvb, int offset, packet_info *pinfo _U_,
- proto_tree *tree, guint16 cmd_ocf)
+ proto_tree *tree, guint16 cmd_ocf)
{
- switch(cmd_ocf) {
+ switch (cmd_ocf) {
- case 0x0004: /* Read Local Extended Features */
- proto_tree_add_item(tree, hf_bthci_cmd_page_number, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
+ case 0x0004: /* Read Local Extended Features */
+ proto_tree_add_item(tree, hf_bthci_cmd_page_number, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
- default:
- proto_tree_add_item(tree, hf_bthci_cmd_params, tvb, offset, -1, ENC_NA);
- offset+=tvb_length_remaining(tvb, offset);
- break;
+ default:
+ proto_tree_add_item(tree, hf_bthci_cmd_params, tvb, offset, -1, ENC_NA);
+ offset+=tvb_length_remaining(tvb, offset);
+ break;
- }
+ }
return offset;
}
static int
dissect_status_parameters_cmd(tvbuff_t *tvb, int offset, packet_info *pinfo _U_,
- proto_tree *tree, guint16 cmd_ocf)
+ proto_tree *tree, guint16 cmd_ocf)
{
- switch(cmd_ocf) {
-
- case 0x0001: /* Read Failed Contact Counter */
- case 0x0002: /* Reset Failed Contact Counter */
- case 0x0003: /* Get Link Quality */
- case 0x0005: /* Read RSSI */
- case 0x0006: /* Read AFH Channel Map */
- proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- break;
-
- case 0x0007: /* Read Clock */
- proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- proto_tree_add_item(tree, hf_bthci_cmd_which_clock, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- default:
- proto_tree_add_item(tree, hf_bthci_cmd_params, tvb, offset, -1, ENC_NA);
- offset+=tvb_length_remaining(tvb, offset);
- break;
-
- }
+ switch (cmd_ocf) {
+
+ case 0x0001: /* Read Failed Contact Counter */
+ case 0x0002: /* Reset Failed Contact Counter */
+ case 0x0003: /* Get Link Quality */
+ case 0x0005: /* Read RSSI */
+ case 0x0006: /* Read AFH Channel Map */
+ proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ break;
+
+ case 0x0007: /* Read Clock */
+ proto_tree_add_item(tree, hf_bthci_cmd_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ proto_tree_add_item(tree, hf_bthci_cmd_which_clock, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ default:
+ proto_tree_add_item(tree, hf_bthci_cmd_params, tvb, offset, -1, ENC_NA);
+ offset+=tvb_length_remaining(tvb, offset);
+ break;
+
+ }
return offset;
}
static int
dissect_testing_cmd(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, guint16 cmd_ocf)
{
- switch(cmd_ocf) {
+ switch (cmd_ocf) {
- case 0x0002: /* Write Loopback Mode */
- proto_tree_add_item(tree, hf_bthci_cmd_loopback_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
+ case 0x0002: /* Write Loopback Mode */
+ proto_tree_add_item(tree, hf_bthci_cmd_loopback_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
- case 0x0004: /* Write Simple Pairing Debug Mode */
- proto_tree_add_item(tree, hf_bthci_cmd_simple_pairing_debug_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
+ case 0x0004: /* Write Simple Pairing Debug Mode */
+ proto_tree_add_item(tree, hf_bthci_cmd_simple_pairing_debug_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
- default:
- proto_tree_add_item(tree, hf_bthci_cmd_params, tvb, offset, -1, ENC_NA);
- offset+=tvb_length_remaining(tvb, offset);
- break;
+ default:
+ proto_tree_add_item(tree, hf_bthci_cmd_params, tvb, offset, -1, ENC_NA);
+ offset+=tvb_length_remaining(tvb, offset);
+ break;
- }
+ }
return offset;
}
@@ -1886,72 +1886,72 @@ return offset;
static void
dissect_bthci_cmd(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
{
- proto_item *ti_cmd=NULL;
- proto_tree *bthci_cmd_tree=NULL;
- guint16 opcode, ocf;
- guint8 param_length, ogf;
- int offset=0;
-
- proto_item *ti_opcode;
- proto_tree *opcode_tree;
-
- if(tree){
- ti_cmd = proto_tree_add_item(tree, proto_bthci_cmd, tvb, offset, -1, ENC_NA);
- bthci_cmd_tree = proto_item_add_subtree(ti_cmd, ett_bthci_cmd);
- }
-
- opcode = tvb_get_letohs(tvb, offset);
- ocf = opcode & 0x03ff;
+ proto_item *ti_cmd = NULL;
+ proto_tree *bthci_cmd_tree = NULL;
+ guint16 opcode, ocf;
+ guint8 param_length, ogf;
+ int offset = 0;
+
+ proto_item *ti_opcode;
+ proto_tree *opcode_tree;
+
+ if (tree) {
+ ti_cmd = proto_tree_add_item(tree, proto_bthci_cmd, tvb, offset, -1, ENC_NA);
+ bthci_cmd_tree = proto_item_add_subtree(ti_cmd, ett_bthci_cmd);
+ }
+
+ opcode = tvb_get_letohs(tvb, offset);
+ ocf = opcode & 0x03ff;
ogf = (guint8) (opcode >> 10);
- proto_item_append_text(ti_cmd," - %s", val_to_str_ext(opcode, &bthci_cmd_opcode_vals_ext, "Unknown 0x%04x"));
+ proto_item_append_text(ti_cmd," - %s", val_to_str_ext(opcode, &bthci_cmd_opcode_vals_ext, "Unknown 0x%04x"));
- col_set_str(pinfo->cinfo, COL_PROTOCOL, "HCI_CMD");
+ col_set_str(pinfo->cinfo, COL_PROTOCOL, "HCI_CMD");
- col_append_fstr(pinfo->cinfo, COL_INFO, " %s", val_to_str_ext(opcode, &bthci_cmd_opcode_vals_ext, "Unknown 0x%04x"));
+ col_append_fstr(pinfo->cinfo, COL_INFO, " %s", val_to_str_ext(opcode, &bthci_cmd_opcode_vals_ext, "Unknown 0x%04x"));
- ti_opcode = proto_tree_add_item(bthci_cmd_tree, hf_bthci_cmd_opcode, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- opcode_tree = proto_item_add_subtree(ti_opcode, ett_opcode);
- proto_tree_add_item(opcode_tree, hf_bthci_cmd_ogf, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(opcode_tree, hf_bthci_cmd_ocf, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ ti_opcode = proto_tree_add_item(bthci_cmd_tree, hf_bthci_cmd_opcode, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ opcode_tree = proto_item_add_subtree(ti_opcode, ett_opcode);
+ proto_tree_add_item(opcode_tree, hf_bthci_cmd_ogf, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(opcode_tree, hf_bthci_cmd_ocf, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- proto_tree_add_item(bthci_cmd_tree, hf_bthci_cmd_param_length, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- param_length = tvb_get_guint8(tvb, offset);
- offset++;
+ proto_tree_add_item(bthci_cmd_tree, hf_bthci_cmd_param_length, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ param_length = tvb_get_guint8(tvb, offset);
+ offset++;
- if(param_length>0){
- switch(ogf){
- case 0x01: /* Link Control Command */
- dissect_link_control_cmd(tvb, offset, pinfo, bthci_cmd_tree, ocf);
- break;
+ if (param_length > 0) {
+ switch (ogf) {
+ case 0x01: /* Link Control Command */
+ dissect_link_control_cmd(tvb, offset, pinfo, bthci_cmd_tree, ocf);
+ break;
- case 0x02: /* Link Policy Command */
- dissect_link_policy_cmd(tvb, offset, pinfo, bthci_cmd_tree, ocf);
- break;
+ case 0x02: /* Link Policy Command */
+ dissect_link_policy_cmd(tvb, offset, pinfo, bthci_cmd_tree, ocf);
+ break;
- case 0x03: /* Host Controller & Baseband Command */
- dissect_host_controller_baseband_cmd(tvb, offset, pinfo, bthci_cmd_tree, ocf);
- break;
+ case 0x03: /* Host Controller & Baseband Command */
+ dissect_host_controller_baseband_cmd(tvb, offset, pinfo, bthci_cmd_tree, ocf);
+ break;
- case 0x04: /* Informational Parameter Command */
- dissect_informational_parameters_cmd(tvb, offset, pinfo, bthci_cmd_tree, ocf);
- break;
+ case 0x04: /* Informational Parameter Command */
+ dissect_informational_parameters_cmd(tvb, offset, pinfo, bthci_cmd_tree, ocf);
+ break;
- case 0x05: /* Status Parameter Command */
- dissect_status_parameters_cmd(tvb, offset, pinfo, bthci_cmd_tree, ocf);
- break;
+ case 0x05: /* Status Parameter Command */
+ dissect_status_parameters_cmd(tvb, offset, pinfo, bthci_cmd_tree, ocf);
+ break;
- case 0x06: /* Testing Command */
- dissect_testing_cmd(tvb, offset, pinfo, bthci_cmd_tree, ocf);
- break;
+ case 0x06: /* Testing Command */
+ dissect_testing_cmd(tvb, offset, pinfo, bthci_cmd_tree, ocf);
+ break;
- default:
- proto_tree_add_item(bthci_cmd_tree, hf_bthci_cmd_params, tvb, 3, -1, ENC_NA);
- break;
- }
- }
+ default:
+ proto_tree_add_item(bthci_cmd_tree, hf_bthci_cmd_params, tvb, 3, -1, ENC_NA);
+ break;
+ }
+ }
}
@@ -1964,957 +1964,957 @@ void
proto_register_bthci_cmd(void)
{
- /* Setup list of header fields See Section 1.6.1 for details*/
- static hf_register_info hf[] = {
- { &hf_bthci_cmd_opcode,
- { "Command Opcode","bthci_cmd.opcode", FT_UINT16, BASE_HEX|BASE_EXT_STRING,
- &bthci_cmd_opcode_vals_ext, 0x0, "HCI Command Opcode", HFILL }
- },
- { &hf_bthci_cmd_ogf,
- { "ogf", "bthci_cmd.ogf",
- FT_UINT16, BASE_HEX|BASE_EXT_STRING, &bthci_ogf_vals_ext, 0xfc00,
- "Opcode Group Field", HFILL }
- },
- { &hf_bthci_cmd_ocf,
- { "ocf", "bthci_cmd.ocf",
- FT_UINT16, BASE_HEX, NULL, 0x03ff,
- "Opcode Command Field", HFILL }
- },
- { &hf_bthci_cmd_param_length,
- { "Parameter Total Length", "bthci_cmd.param_length",
- FT_UINT8, BASE_DEC, NULL, 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_params,
- { "Command Parameters", "bthci_cmd.params",
- FT_BYTES, BASE_NONE, NULL, 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_lap,
- { "LAP", "bthci_cmd.lap",
- FT_UINT24, BASE_HEX, NULL, 0x0,
- "LAP for the inquiry access code", HFILL }
- },
- { &hf_bthci_cmd_inq_length,
- { "Inquiry Length", "bthci_cmd.inq_length",
- FT_UINT8, BASE_DEC, NULL, 0x0,
- "Inquiry Length (*1.28s)", HFILL }
- },
- { &hf_bthci_cmd_num_responses,
- { "Num Responses", "bthci_cmd.num_responses",
- FT_UINT8, BASE_DEC, NULL, 0x0,
- "Number of Responses", HFILL }
- },
- { &hf_bthci_cmd_encrypt_mode,
- { "Encryption Mode", "bthci_cmd.encrypt_mode",
- FT_UINT8, BASE_HEX, VALS(encrypt_mode_vals), 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_bd_addr,
- { "BD_ADDR:", "bthci_cmd.bd_addr",
- FT_NONE, BASE_NONE, NULL, 0x0,
- "Bluetooth Device Address", HFILL}
- },
- { &hf_bthci_cmd_packet_type_2dh1,
- { "Packet Type 2-DH1", "bthci_cmd.packet_type_2dh1",
- FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0002,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_packet_type_3dh1,
- { "Packet Type 3-DH1", "bthci_cmd.packet_type_3dh1",
- FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0004,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_packet_type_dm1,
- { "Packet Type DM1", "bthci_cmd.packet_type_dm1",
- FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0008,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_packet_type_dh1,
- { "Packet Type DH1", "bthci_cmd.packet_type_dh1",
- FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0010,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_packet_type_2dh3,
- { "Packet Type 2-DH3", "bthci_cmd.packet_type_2dh3",
- FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0100,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_packet_type_3dh3,
- { "Packet Type 3-DH3", "bthci_cmd.packet_type_3dh3",
- FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0200,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_packet_type_dm3,
- { "Packet Type DM3", "bthci_cmd.packet_type_dm3",
- FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0400,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_packet_type_dh3,
- { "Packet Type DH3", "bthci_cmd.packet_type_dh3",
- FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0800,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_packet_type_2dh5,
- { "Packet Type 2-DH5", "bthci_cmd.packet_type_2dh5",
- FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x1000,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_packet_type_3dh5,
- { "Packet Type 3-DH5", "bthci_cmd.packet_type_3dh5",
- FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x2000,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_packet_type_dm5,
- { "Packet Type DM5", "bthci_cmd.packet_type_dm5",
- FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x4000,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_packet_type_dh5,
- { "Packet Type DH5", "bthci_cmd.packet_type_dh5",
- FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x8000,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_page_scan_mode,
- { "Page Scan Mode", "bthci_cmd.page_scan_mode",
- FT_UINT8, BASE_HEX, VALS(cmd_page_scan_modes), 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_page_scan_repetition_mode,
- { "Page Scan Repetition Mode", "bthci_cmd.page_scan_repetition_mode",
- FT_UINT8, BASE_HEX, VALS(cmd_page_scan_repetition_modes), 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_page_scan_period_mode,
- { "Page Scan Period Mode", "bthci_cmd.page_scan_period_mode",
- FT_UINT8, BASE_HEX, VALS(cmd_page_scan_period_modes), 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_clock_offset,
- { "Clock Offset", "bthci_cmd.clock_offset",
- FT_UINT16, BASE_HEX, NULL, 0x7FFF,
- "Bit 2-16 of the Clock Offset between CLKmaster-CLKslave", HFILL }
- },
- { &hf_bthci_cmd_clock_offset_valid,
- { "Clock_Offset_Valid_Flag", "bthci_cmd.clock_offset_valid",
- FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x8000,
- "Indicates if clock offset is valid", HFILL }
- },
- { &hf_bthci_cmd_allow_role_switch,
- { "Allow Role Switch", "bthci_cmd.allow_role_switch",
- FT_UINT8, BASE_HEX, VALS(cmd_role_switch_modes), 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_status,
- { "Status", "bthci_cmd.status",
- FT_UINT8, BASE_HEX|BASE_EXT_STRING, &bthci_cmd_status_vals_ext, 0x0,
- NULL, HFILL }
- },
-
- { &hf_bthci_cmd_max_period_length,
- { "Max Period Length", "bthci_cmd.max_period_length",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- "Maximum amount of time specified between consecutive inquiries.", HFILL }
- },
- { &hf_bthci_cmd_min_period_length,
- { "Min Period Length", "bthci_cmd.min_period_length",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- "Minimum amount of time specified between consecutive inquiries.", HFILL }
- },
- { &hf_bthci_cmd_connection_handle,
- { "Connection Handle", "bthci_cmd.connection_handle",
- FT_UINT16, BASE_HEX, NULL, 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_reason,
- { "Reason", "bthci_cmd.reason",
- FT_UINT8, BASE_HEX|BASE_EXT_STRING, &bthci_cmd_status_vals_ext, 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_num_link_keys,
- { "Number of Link Keys", "bthci_cmd.num_link_keys",
- FT_UINT8, BASE_DEC, NULL, 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_link_key,
- { "Link Key", "bthci_cmd.link_key",
- FT_BYTES, BASE_NONE, NULL, 0x0,
- "Link Key for the associated BD_ADDR", HFILL }
- },
- { &hf_bthci_cmd_packet_type_hv1,
- { "Packet Type HV1", "bthci_cmd.packet_type_hv1",
- FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0020,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_packet_type_hv2,
- { "Packet Type HV2", "bthci_cmd.packet_type_hv2",
- FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0040,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_packet_type_hv3,
- { "Packet Type HV3", "bthci_cmd.packet_type_hv3",
- FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0080,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_role,
- { "Role", "bthci_cmd.role",
- FT_UINT8, BASE_HEX, VALS(cmd_role_vals), 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_pin_code_length,
- { "PIN Code Length", "bthci_cmd.pin_code_length",
- FT_UINT8, BASE_DEC, NULL, 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_pin_code,
- { "PIN Code", "bthci_cmd.pin_code",
- FT_STRING, BASE_NONE, NULL, 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_pin_type,
- { "PIN Type", "bthci_cmd.pin_type",
- FT_UINT8, BASE_HEX, VALS(cmd_pin_types), 0x0,
- "PIN Types", HFILL }
- },
- { &hf_bthci_cmd_encryption_enable,
- { "Encryption Enable", "bthci_cmd.encryption_enable",
- FT_UINT8, BASE_HEX, VALS(cmd_encryption_enable), 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_key_flag,
- { "Key Flag", "bthci_cmd.key_flag",
- FT_UINT8, BASE_HEX, VALS(cmd_key_flag), 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_max_interval_hold,
- { "Hold Mode Max Interval", "bthci_cmd.hold_mode_max_int",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- "Maximal acceptable number of Baseband slots to wait in Hold Mode.", HFILL }
- },
- { &hf_bthci_cmd_min_interval_hold,
- { "Hold Mode Min Interval", "bthci_cmd.hold_mode_min_int",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- "Minimum acceptable number of Baseband slots to wait in Hold Mode.", HFILL }
- },
- { &hf_bthci_cmd_max_interval_sniff,
- { "Sniff Max Interval", "bthci_cmd.sniff_max_int",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- "Maximal acceptable number of Baseband slots between each sniff period.", HFILL }
- },
- { &hf_bthci_cmd_min_interval_sniff,
- { "Sniff Min Interval", "bthci_cmd.sniff_min_int",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- "Minimum acceptable number of Baseband slots between each sniff period.", HFILL }
- },
- { &hf_bthci_cmd_sniff_attempt,
- { "Sniff Attempt", "bthci_cmd.sniff_attempt",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- "Number of Baseband receive slots for sniff attempt.", HFILL }
- },
- { &hf_bthci_cmd_timeout,
- { "Timeout", "bthci_cmd.timeout",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- "Number of Baseband slots for timeout.", HFILL }
- },
- { &hf_bthci_cmd_max_interval_beacon,
- { "Beacon Max Interval", "bthci_cmd.beacon_max_int",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- "Maximal acceptable number of Baseband slots between consecutive beacons.", HFILL }
- },
- { &hf_bthci_cmd_min_interval_beacon,
- { "Beacon Min Interval", "bthci_cmd.beacon_min_int",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- "Minimum acceptable number of Baseband slots between consecutive beacons.", HFILL }
- },
- { &hf_bthci_cmd_flags,
- { "Flags", "bthci_cmd.flags",
- FT_UINT8, BASE_HEX, NULL, 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_service_type,
- { "Service Type", "bthci_cmd.service_type",
- FT_UINT8, BASE_HEX, VALS(cmd_service_types), 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_token_rate,
- { "Available Token Rate", "bthci_cmd.token_rate",
- FT_UINT32, BASE_DEC, NULL, 0x0,
- "Token Rate, in bytes per second", HFILL }
- },
- { &hf_bthci_cmd_token_bucket_size,
- { "Available Token Bucket Size", "bthci_cmd.token_bucket_size",
- FT_UINT32, BASE_DEC, NULL, 0x0,
- "Token Bucket Size in bytes", HFILL }
- },
- { &hf_bthci_cmd_peak_bandwidth,
- { "Peak Bandwidth", "bthci_cmd.peak_bandwidth",
- FT_UINT32, BASE_DEC, NULL, 0x0,
- "Peak Bandwidth, in bytes per second", HFILL }
- },
- { &hf_bthci_cmd_latency,
- { "Latency", "bthci_cmd.latency",
- FT_UINT32, BASE_DEC, NULL, 0x0,
- "Latency, in microseconds", HFILL }
- },
- { &hf_bthci_cmd_delay_variation,
- { "Delay Variation", "bthci_cmd.delay_variation",
- FT_UINT32, BASE_DEC, NULL, 0x0,
- "Delay Variation, in microseconds", HFILL }
- },
- { &hf_bthci_cmd_link_policy_setting_switch,
- { "Enable Master Slave Switch", "bthci_cmd.link_policy_switch",
- FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0001,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_link_policy_setting_hold,
- { "Enable Hold Mode", "bthci_cmd.link_policy_hold",
- FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0002,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_link_policy_setting_sniff,
- { "Enable Sniff Mode", "bthci_cmd.link_policy_sniff",
- FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0004,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_link_policy_setting_park,
- { "Enable Park Mode", "bthci_cmd.link_policy_park",
- FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0008,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_filter_type,
- { "Filter Type", "bthci_cmd.filter_type",
- FT_UINT8, BASE_HEX, VALS(cmd_filter_types), 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_inquiry_result_filter_condition_type,
- { "Filter Condition Type", "bthci_cmd.filter_condition_type",
- FT_UINT8, BASE_HEX, VALS(cmd_inquiry_result_filter_condition_types), 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_connection_setup_filter_condition_type,
- { "Filter Condition Type", "bthci_cmd.filter_condition_type",
- FT_UINT8, BASE_HEX, VALS(cmd_connection_setup_filter_condition_types), 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_class_of_device,
- { "Class of Device", "bthci_cmd.class_of_device",
- FT_UINT24, BASE_HEX, NULL, 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_class_of_device_mask,
- { "Class of Device Mask", "bthci_cmd.class_of_device_mask",
- FT_UINT24, BASE_HEX, NULL, 0x0,
- "Bit Mask used to determine which bits of the Class of Device parameter are of interest.", HFILL }
- },
- { &hf_bthci_cmd_auto_acc_flag,
- { "Auto Accept Flag", "bthci_cmd.auto_accept_flag",
- FT_UINT8, BASE_HEX, VALS(cmd_auto_acc_flag_values), 0x0,
- "Class of Device of Interest", HFILL }
- },
- { &hf_bthci_cmd_read_all_flag,
- { "Read All Flag", "bthci_cmd.read_all_flag",
- FT_UINT8, BASE_HEX, VALS(cmd_read_all_flag_values), 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_delete_all_flag,
- { "Delete All Flag", "bthci_cmd.delete_all_flag",
- FT_UINT8, BASE_HEX, VALS(cmd_delete_all_flag_values), 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_authentication_enable,
- { "Authentication Enable", "bthci_cmd.auth_enable",
- FT_UINT8, BASE_HEX, VALS(cmd_authentication_enable_values), 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_input_coding,
- { "Input Coding", "bthci_cmd.input_coding",
- FT_UINT16, BASE_DEC, VALS(cmd_input_coding_values), 0x0300,
- "Authentication Enable", HFILL }
- },
- { &hf_bthci_cmd_input_data_format,
- { "Input Data Format", "bthci_cmd.input_data_format",
- FT_UINT16, BASE_DEC, VALS(cmd_input_data_format_values), 0x00c0,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_input_sample_size,
- { "Input Sample Size", "bthci_cmd.input_sample_size",
- FT_UINT16, BASE_DEC, VALS(cmd_input_sample_size_values), 0x0020,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_linear_pcm_bit_pos,
- { "Linear PCM Bit Pos", "bthci_cmd.lin_pcm_bit_pos",
- FT_UINT16, BASE_DEC, NULL, 0x001c,
- "# bit pos. that MSB of sample is away from starting at MSB", HFILL }
- },
- { &hf_bthci_cmd_air_coding_format,
- { "Air Coding Format", "bthci_cmd.air_coding_format",
- FT_UINT16, BASE_DEC, VALS(cmd_air_coding_format_values), 0x0003,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_num_broadcast_retransmissions,
- { "Num Broadcast Retran", "bthci_cmd.num_broad_retran",
- FT_UINT8, BASE_DEC, NULL, 0x0,
- "Number of Broadcast Retransmissions", HFILL }
- },
- { &hf_bthci_cmd_hold_mode_act_page,
- { "Suspend Page Scan", "bthci_cmd.hold_mode_page",
- FT_UINT8, BASE_DEC, VALS(cmd_boolean), 0x1,
- "Device can enter low power state", HFILL }
- },
- { &hf_bthci_cmd_hold_mode_act_inquiry,
- { "Suspend Inquiry Scan", "bthci_cmd.hold_mode_inquiry",
- FT_UINT8, BASE_DEC, VALS(cmd_boolean), 0x2,
- "Device can enter low power state", HFILL }
- },
- { &hf_bthci_cmd_hold_mode_act_periodic,
- { "Suspend Periodic Inquiries", "bthci_cmd.hold_mode_periodic",
- FT_UINT8, BASE_DEC, VALS(cmd_boolean), 0x4,
- "Device can enter low power state", HFILL }
- },
- { &hf_bthci_cmd_scan_enable,
- { "Scan Enable", "bthci_cmd.scan_enable",
- FT_UINT8, BASE_HEX, VALS(cmd_scan_enable_values), 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_interval,
- { "Interval", "bthci_cmd.interval",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_window,
- { "Interval", "bthci_cmd.window",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- "Window", HFILL }
- },
- { &hf_bthci_cmd_device_name,
- { "Device Name", "bthci_cmd.device_name",
- FT_STRINGZ, BASE_NONE, NULL, 0x0,
- "Userfriendly descriptive name for the device", HFILL }
- },
- { &hf_bthci_cmd_num_curr_iac,
- { "Number of Current IAC", "bthci_cmd.num_curr_iac",
- FT_UINT8, BASE_DEC, NULL, 0x0,
- "Number of IACs which are currently in use", HFILL }
- },
- { &hf_bthci_cmd_iac_lap,
- { "IAC LAP", "bthci_cmd.num_curr_iac",
- FT_UINT24, BASE_HEX, NULL, 0x0,
- "LAP(s)used to create IAC", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_00,
- { "Inquiry Complete", "bthci_cmd.evt_mask_00",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x01,
- "Inquiry Complete Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_01,
- { "Inquiry Result", "bthci_cmd.evt_mask_01",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x02,
- "Inquiry Result Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_02,
- { "Connect Complete", "bthci_cmd.evt_mask_02",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x04,
- "Connection Complete Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_03,
- { "Connect Request", "bthci_cmd.evt_mask_03",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x08,
- "Connect Request Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_04,
- { "Disconnect Complete", "bthci_cmd.evt_mask_04",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x10,
- "Disconnect Complete Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_05,
- { "Auth Complete", "bthci_cmd.evt_mask_05",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x20,
- "Auth Complete Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_06,
- { "Remote Name Req Complete", "bthci_cmd.evt_mask_06",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x40,
- "Remote Name Req Complete Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_07,
- { "Encrypt Change", "bthci_cmd.evt_mask_07",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x80,
- "Encrypt Change Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_10,
- { "Change Connection Link Key Complete", "bthci_cmd.evt_mask_10",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x01,
- "Change Connection Link Key Complete Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_11,
- { "Master Link Key Complete", "bthci_cmd.evt_mask_11",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x02,
- "Master Link Key Complete Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_12,
- { "Read Remote Supported Features", "bthci_cmd.evt_mask_12",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x04,
- "Read Remote Supported Features Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_13,
- { "Read Remote Ver Info Complete", "bthci_cmd.evt_mask_13",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x08,
- "Read Remote Ver Info Complete Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_14,
- { "QoS Setup Complete", "bthci_cmd.evt_mask_14",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x10,
- "QoS Setup Complete Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_17,
- { "Hardware Error", "bthci_cmd.evt_mask_17",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x80,
- "Hardware Error Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_20,
- { "Flush Occurred", "bthci_cmd.evt_mask_20",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x01,
- "Flush Occurred Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_21,
- { "Role Change", "bthci_cmd.evt_mask_21",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x02,
- "Role Change Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_23,
- { "Mode Change", "bthci_cmd.evt_mask_23",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x08,
- "Mode Change Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_24,
- { "Return Link Keys", "bthci_cmd.evt_mask_24",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x10,
- "Return Link Keys Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_25,
- { "PIN Code Request", "bthci_cmd.evt_mask_25",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x20,
- "PIN Code Request Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_26,
- { "Link Key Request", "bthci_cmd.evt_mask_26",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x40,
- "Link Key Request Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_27,
- { "Link Key Notification", "bthci_cmd.evt_mask_27",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x80,
- "Link Key Notification Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_30,
- { "Loopback Command", "bthci_cmd.evt_mask_30",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x01,
- "Loopback Command Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_31,
- { "Data Buffer Overflow" , "bthci_cmd.evt_mask_31",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x02,
- "Data Buffer Overflow Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_32,
- { "Max Slots Change", "bthci_cmd.evt_mask_32",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x04,
- "Max Slots Change Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_33,
- { "Read Clock Offset Complete", "bthci_cmd.evt_mask_33",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x08,
- "Read Clock Offset Complete Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_34,
- { "Connection Packet Type Changed", "bthci_cmd.evt_mask_34",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x10,
- "Connection Packet Type Changed Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_35,
- { "QoS Violation", "bthci_cmd.evt_mask_35",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x20,
- "QoS Violation Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_36,
- { "Page Scan Mode Change", "bthci_cmd.evt_mask_36",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x40,
- "Page Scan Mode Change Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_37,
- { "Page Scan Repetition Mode Change", "bthci_cmd.evt_mask_37",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x80,
- "Page Scan Repetition Mode Change Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_40,
- { "Flow Specification Complete", "bthci_cmd.evt_mask_40",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x01,
- "Flow Specification Complete Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_41,
- { "Inquiry Result With RSSI", "bthci_cmd.evt_mask_41",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x02,
- "Inquiry Result With RSSI Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_42,
- { "Read Remote Ext. Features Complete", "bthci_cmd.evt_mask_42",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x04,
- "Read Remote Ext. Features Complete Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_53,
- { "Synchronous Connection Complete", "bthci_cmd.evt_mask_53",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x08,
- "Synchronous Connection Complete Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_54,
- { "Synchronous Connection Changed", "bthci_cmd.evt_mask_54",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x10,
- "Synchronous Connection Changed Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_55,
- { "Sniff Subrate", "bthci_cmd.evt_mask_55",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x20,
- "Sniff Subrate Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_56,
- { "Extended Inquiry Result", "bthci_cmd.evt_mask_56",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x40,
- "Extended Inquiry Result Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_57,
- { "Encryption Key Refresh Complete", "bthci_cmd.evt_mask_57",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x80,
- "Encryption Key Refresh Complete Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_60,
- { "IO Capability Request", "bthci_cmd.evt_mask_60",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x01,
- "IO Capability Request Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_61,
- { "IO Capability Response", "bthci_cmd.evt_mask_61",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x02,
- "IO Capability Response Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_62,
- { "User Confirmation Request", "bthci_cmd.evt_mask_62",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x04,
- "User Confirmation Request Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_63,
- { "User Passkey Request", "bthci_cmd.evt_mask_63",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x08,
- "User Passkey Request Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_64,
- { "Remote OOB Data Request", "bthci_cmd.evt_mask_64",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x10,
- "Remote OOB Data Request Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_65,
- { "Simple Pairing Complete", "bthci_cmd.evt_mask_65",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x20,
- "Simple Pairing Complete Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_67,
- { "Link Supervision Timeout Changed", "bthci_cmd.evt_mask_67",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x80,
- "Link Supervision Timeout Changed Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_70,
- { "Enhanced Flush Complete", "bthci_cmd.evt_mask_70",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x01,
- "Enhanced Flush Complete Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_72,
- { "User Passkey Notification", "bthci_cmd.evt_mask_72",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x04,
- "User Passkey Notification Bit", HFILL }
- },
- { &hf_bthci_cmd_evt_mask_73,
- { "Keypress Notification", "bthci_cmd.evt_mask_73",
- FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x08,
- "Keypress Notification Bit", HFILL }
- },
- { &hf_bthci_cmd_sco_flow_control,
- { "SCO Flow Control","bthci_cmd.flow_control",
- FT_UINT8, BASE_HEX, VALS(cmd_en_disabled), 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_num_handles,
- { "Number of Handles", "bthci_cmd.num_handles",
- FT_UINT8, BASE_DEC, NULL, 0x0,
- NULL, HFILL }
- },
-
- { &hf_bthci_cmd_num_compl_packets,
- { "Number of Completed Packets", "bthci_cmd.num_compl_packets",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- "Number of Completed HCI Data Packets", HFILL }
- },
- { &hf_bthci_cmd_flow_contr_enable,
- { "Flow Control Enable", "bthci_cmd.flow_contr_enable",
- FT_UINT8, BASE_HEX, VALS(cmd_flow_contr_enable), 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_host_data_packet_length_acl,
- {"Host ACL Data Packet Length (bytes)", "bthci_cmd.max_data_length_acl",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- "Max Host ACL Data Packet length of data portion host is able to accept", HFILL }
- },
- { &hf_bthci_cmd_host_data_packet_length_sco,
- {"Host SCO Data Packet Length (bytes)", "bthci_cmd.max_data_length_sco",
- FT_UINT8, BASE_DEC, NULL, 0x0,
- "Max Host SCO Data Packet length of data portion host is able to accept", HFILL }
- },
- { &hf_bthci_cmd_host_total_num_acl_data_packets,
- {"Host Total Num ACL Data Packets", "bthci_cmd.max_data_num_acl",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- "Total Number of HCI ACL Data Packets that can be stored in the data buffers of the Host", HFILL }
- },
- { &hf_bthci_cmd_host_total_num_sco_data_packets,
- {"Host Total Num SCO Data Packets", "bthci_cmd.max_data_num_sco",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- "Total Number of HCI SCO Data Packets that can be stored in the data buffers of the Host", HFILL }
- },
- { &hf_bthci_cmd_power_level_type,
- {"Type", "bthci_cmd.power_level_type",
- FT_UINT8, BASE_HEX, VALS(cmd_power_level_types), 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_cmd_loopback_mode,
- {"Loopback Mode", "bthci_cmd.loopback_mode",
- FT_UINT8, BASE_HEX, VALS(cmd_loopback_modes), 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_cmd_page_number,
- {"Page Number", "bthci_cmd.page_number",
- FT_UINT8, BASE_DEC, NULL, 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_cmd_transmit_bandwidth,
- {"Tx Bandwidth (bytes/s)", "bthci_cmd.tx_bandwidth",
- FT_UINT32, BASE_DEC, NULL, 0x0,
- "Tx Bandwidth", HFILL}
- },
- { &hf_bthci_cmd_receive_bandwidth,
- {"Rx Bandwidth (bytes/s)", "bthci_cmd.rx_bandwidth",
- FT_UINT32, BASE_DEC, NULL, 0x0,
- "Rx Bandwidth", HFILL}
- },
- { &hf_bthci_cmd_max_latency_ms,
- {"Max. Latency (ms)", "bthci_cmd.max_latency_ms",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_cmd_max_latency,
- {"Max. Latency", "bthci_cmd.max_latency",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- "Max. Latency in baseband slots", HFILL}
- },
- { &hf_bthci_cmd_retransmission_effort,
- {"Retransmission Effort", "bthci_cmd.retransmission_effort",
- FT_UINT8, BASE_DEC, VALS(cmd_rtx_effort), 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_cmd_scan_type,
- {"Scan Type", "bthci_cmd.inq_scan_type",
- FT_UINT8, BASE_DEC, VALS(cmd_scan_types), 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_cmd_inq_mode,
- {"Inquiry Mode", "bthci_cmd.inq_scan_type",
- FT_UINT8, BASE_DEC, VALS(cmd_inq_modes), 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_cmd_fec_required,
- {"FEC Required", "bthci_cmd.fec_required",
- FT_UINT8, BASE_DEC, VALS(cmd_boolean), 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_cmd_err_data_reporting,
- {"Erroneous Data Reporting", "bthci_cmd.err_data_reporting",
- FT_UINT8, BASE_DEC, VALS(cmd_en_disabled), 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_cmd_tx_power,
- {"Power Level (dBm)", "bthci_cmd.power_level",
- FT_INT8, BASE_DEC, NULL, 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_cmd_sco_packet_type_hv1,
- { "Packet Type HV1", "bthci_cmd.sco_packet_type_hv1",
- FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0001,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_sco_packet_type_hv2,
- { "Packet Type HV2", "bthci_cmd.sco_packet_type_hv2",
- FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0002,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_sco_packet_type_hv3,
- { "Packet Type HV3", "bthci_cmd.sco_packet_type_hv3",
- FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0004,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_sco_packet_type_ev3,
- { "Packet Type EV3", "bthci_cmd.sco_packet_type_ev3",
- FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0008,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_sco_packet_type_ev4,
- { "Packet Type EV4", "bthci_cmd.sco_packet_type_ev4",
- FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0010,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_sco_packet_type_ev5,
- { "Packet Type EV5", "bthci_cmd.sco_packet_type_ev5",
- FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0020,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_sco_packet_type_2ev3,
- { "Packet Type 2-EV3", "bthci_cmd.sco_packet_type_2ev3",
- FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0040,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_sco_packet_type_3ev3,
- { "Packet Type 3-EV3", "bthci_cmd.sco_packet_type_3ev3",
- FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0080,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_sco_packet_type_2ev5,
- { "Packet Type 2-EV5", "bthci_cmd.sco_packet_type_2ev5",
- FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0100,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_sco_packet_type_3ev5,
- { "Packet Type 3-EV5", "bthci_cmd.sco_packet_type_3ev5",
- FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0200,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_min_remote_timeout,
- {"Min. Remote Timeout", "bthci_cmd.min_remote_timeout",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- "Min. Remote Timeout in baseband slots", HFILL}
- },
- { &hf_bthci_cmd_min_local_timeout,
- {"Min. Local Timeout", "bthci_cmd.min_local_timeout",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- "Min. Local Timeout in baseband slots", HFILL}
- },
- { &hf_bthci_cmd_flush_packet_type,
- {"Packet Type", "bthci_cmd.flush_packet_type",
- FT_UINT8, BASE_DEC, VALS(cmd_flush_pkt_type), 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_cmd_afh_ch_assessment_mode,
- {"AFH Channel Assessment Mode", "bthci_cmd.afh_ch_assessment_mode",
- FT_UINT8, BASE_DEC, VALS(cmd_en_disabled), 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_cmd_afh_ch_classification,
- { "Channel Classification", "bthci_cmd.afh_ch_classification",
- FT_NONE, BASE_NONE, NULL, 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_cmd_which_clock,
- {"Which Clock", "bthci_cmd.which_clock",
- FT_UINT8, BASE_DEC, VALS(cmd_which_clock), 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_cmd_io_capability,
- {"IO Capability", "bthci_cmd.io_capability",
- FT_UINT8, BASE_DEC, VALS(bthci_cmd_io_capability_vals), 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_cmd_oob_data_present,
- {"OOB Data Present", "bthci_cmd.oob_data_present",
- FT_UINT8, BASE_DEC, VALS(bthci_cmd_oob_data_present_vals), 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_cmd_auth_requirements,
- {"Authentication Requirements", "bthci_cmd.auth_requirements",
- FT_UINT8, BASE_DEC|BASE_EXT_STRING, &bthci_cmd_auth_req_vals_ext, 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_cmd_passkey,
- {"Passkey", "bthci_cmd.passkey",
- FT_UINT32, BASE_DEC, NULL, 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_cmd_hash_c,
- {"Hash C", "bthci_cmd.hash_c",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_cmd_randomizer_r,
- {"Randomizer R", "bthci_cmd.randomizer_r",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_cmd_simple_pairing_mode,
- {"Simple Pairing Mode", "bthci_cmd.simple_pairing_mode",
- FT_UINT8, BASE_DEC, VALS(cmd_en_disabled), 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_cmd_simple_pairing_debug_mode,
- {"Simple Pairing Debug Mode", "bthci_cmd.simple_pairing_debug_mode",
- FT_UINT8, BASE_DEC, VALS(cmd_en_disabled), 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_cmd_notification_type,
- {"Notification Type", "bthci_cmd.notification_type",
- FT_UINT8, BASE_DEC, VALS(cmd_notification_types), 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_cmd_eir_data,
- {"Data", "bthci_cmd.eir_data",
- FT_BYTES, BASE_NONE, NULL, 0x0,
- "EIR Data", HFILL}
- },
- { &hf_bthci_cmd_eir_struct_length,
- { "Length", "bthci_cmd.eir_struct_length",
- FT_UINT8, BASE_DEC, NULL, 0x0,
- "Structure Length", HFILL }
- },
- { &hf_bthci_cmd_eir_struct_type,
- { "Type", "bthci_cmd.eir_data_type",
- FT_UINT8, BASE_HEX|BASE_EXT_STRING, &bthci_cmd_eir_data_type_vals_ext, 0x0,
- "Data Type", HFILL }
- },
- { &hf_bthci_cmd_sc_uuid16,
- { "UUID", "bthci_cmd.service_class_uuid16",
- FT_UINT16, BASE_HEX|BASE_EXT_STRING, &bthci_cmd_service_class_type_vals_ext, 0x0,
- "16-bit Service Class UUID", HFILL }
- },
- { &hf_bthci_cmd_sc_uuid32,
- { "UUID", "bthci_cmd.service_class_uuid32",
- FT_UINT32, BASE_HEX, NULL, 0x0,
- "32-bit Service Class UUID", HFILL }
- },
- { &hf_bthci_cmd_sc_uuid128,
- { "UUID", "bthci_cmd.service_class_uuid128",
- FT_BYTES, BASE_NONE, NULL, 0x0,
- "128-bit Service Class UUID", HFILL }
- }
- };
-
- /* Setup protocol subtree array */
- static gint *ett[] = {
- &ett_bthci_cmd,
- &ett_opcode,
- &ett_eir_subtree,
- &ett_eir_struct_subtree
- };
-
- /* Register the protocol name and description */
- proto_bthci_cmd = proto_register_protocol("Bluetooth HCI Command", "HCI_CMD", "bthci_cmd");
-
- register_dissector("bthci_cmd", dissect_bthci_cmd, proto_bthci_cmd);
-
- /* Required function calls to register the header fields and subtrees used */
- proto_register_field_array(proto_bthci_cmd, hf, array_length(hf));
- proto_register_subtree_array(ett, array_length(ett));
+ /* Setup list of header fields See Section 1.6.1 for details*/
+ static hf_register_info hf[] = {
+ { &hf_bthci_cmd_opcode,
+ { "Command Opcode","bthci_cmd.opcode", FT_UINT16, BASE_HEX|BASE_EXT_STRING,
+ &bthci_cmd_opcode_vals_ext, 0x0, "HCI Command Opcode", HFILL }
+ },
+ { &hf_bthci_cmd_ogf,
+ { "ogf", "bthci_cmd.ogf",
+ FT_UINT16, BASE_HEX|BASE_EXT_STRING, &bthci_ogf_vals_ext, 0xfc00,
+ "Opcode Group Field", HFILL }
+ },
+ { &hf_bthci_cmd_ocf,
+ { "ocf", "bthci_cmd.ocf",
+ FT_UINT16, BASE_HEX, NULL, 0x03ff,
+ "Opcode Command Field", HFILL }
+ },
+ { &hf_bthci_cmd_param_length,
+ { "Parameter Total Length", "bthci_cmd.param_length",
+ FT_UINT8, BASE_DEC, NULL, 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_params,
+ { "Command Parameters", "bthci_cmd.params",
+ FT_BYTES, BASE_NONE, NULL, 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_lap,
+ { "LAP", "bthci_cmd.lap",
+ FT_UINT24, BASE_HEX, NULL, 0x0,
+ "LAP for the inquiry access code", HFILL }
+ },
+ { &hf_bthci_cmd_inq_length,
+ { "Inquiry Length", "bthci_cmd.inq_length",
+ FT_UINT8, BASE_DEC, NULL, 0x0,
+ "Inquiry Length (*1.28s)", HFILL }
+ },
+ { &hf_bthci_cmd_num_responses,
+ { "Num Responses", "bthci_cmd.num_responses",
+ FT_UINT8, BASE_DEC, NULL, 0x0,
+ "Number of Responses", HFILL }
+ },
+ { &hf_bthci_cmd_encrypt_mode,
+ { "Encryption Mode", "bthci_cmd.encrypt_mode",
+ FT_UINT8, BASE_HEX, VALS(encrypt_mode_vals), 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_bd_addr,
+ { "BD_ADDR:", "bthci_cmd.bd_addr",
+ FT_NONE, BASE_NONE, NULL, 0x0,
+ "Bluetooth Device Address", HFILL}
+ },
+ { &hf_bthci_cmd_packet_type_2dh1,
+ { "Packet Type 2-DH1", "bthci_cmd.packet_type_2dh1",
+ FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0002,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_packet_type_3dh1,
+ { "Packet Type 3-DH1", "bthci_cmd.packet_type_3dh1",
+ FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0004,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_packet_type_dm1,
+ { "Packet Type DM1", "bthci_cmd.packet_type_dm1",
+ FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0008,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_packet_type_dh1,
+ { "Packet Type DH1", "bthci_cmd.packet_type_dh1",
+ FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0010,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_packet_type_2dh3,
+ { "Packet Type 2-DH3", "bthci_cmd.packet_type_2dh3",
+ FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0100,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_packet_type_3dh3,
+ { "Packet Type 3-DH3", "bthci_cmd.packet_type_3dh3",
+ FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0200,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_packet_type_dm3,
+ { "Packet Type DM3", "bthci_cmd.packet_type_dm3",
+ FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0400,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_packet_type_dh3,
+ { "Packet Type DH3", "bthci_cmd.packet_type_dh3",
+ FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0800,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_packet_type_2dh5,
+ { "Packet Type 2-DH5", "bthci_cmd.packet_type_2dh5",
+ FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x1000,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_packet_type_3dh5,
+ { "Packet Type 3-DH5", "bthci_cmd.packet_type_3dh5",
+ FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x2000,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_packet_type_dm5,
+ { "Packet Type DM5", "bthci_cmd.packet_type_dm5",
+ FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x4000,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_packet_type_dh5,
+ { "Packet Type DH5", "bthci_cmd.packet_type_dh5",
+ FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x8000,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_page_scan_mode,
+ { "Page Scan Mode", "bthci_cmd.page_scan_mode",
+ FT_UINT8, BASE_HEX, VALS(cmd_page_scan_modes), 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_page_scan_repetition_mode,
+ { "Page Scan Repetition Mode", "bthci_cmd.page_scan_repetition_mode",
+ FT_UINT8, BASE_HEX, VALS(cmd_page_scan_repetition_modes), 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_page_scan_period_mode,
+ { "Page Scan Period Mode", "bthci_cmd.page_scan_period_mode",
+ FT_UINT8, BASE_HEX, VALS(cmd_page_scan_period_modes), 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_clock_offset,
+ { "Clock Offset", "bthci_cmd.clock_offset",
+ FT_UINT16, BASE_HEX, NULL, 0x7FFF,
+ "Bit 2-16 of the Clock Offset between CLKmaster-CLKslave", HFILL }
+ },
+ { &hf_bthci_cmd_clock_offset_valid,
+ { "Clock_Offset_Valid_Flag", "bthci_cmd.clock_offset_valid",
+ FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x8000,
+ "Indicates if clock offset is valid", HFILL }
+ },
+ { &hf_bthci_cmd_allow_role_switch,
+ { "Allow Role Switch", "bthci_cmd.allow_role_switch",
+ FT_UINT8, BASE_HEX, VALS(cmd_role_switch_modes), 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_status,
+ { "Status", "bthci_cmd.status",
+ FT_UINT8, BASE_HEX|BASE_EXT_STRING, &bthci_cmd_status_vals_ext, 0x0,
+ NULL, HFILL }
+ },
+
+ { &hf_bthci_cmd_max_period_length,
+ { "Max Period Length", "bthci_cmd.max_period_length",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ "Maximum amount of time specified between consecutive inquiries.", HFILL }
+ },
+ { &hf_bthci_cmd_min_period_length,
+ { "Min Period Length", "bthci_cmd.min_period_length",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ "Minimum amount of time specified between consecutive inquiries.", HFILL }
+ },
+ { &hf_bthci_cmd_connection_handle,
+ { "Connection Handle", "bthci_cmd.connection_handle",
+ FT_UINT16, BASE_HEX, NULL, 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_reason,
+ { "Reason", "bthci_cmd.reason",
+ FT_UINT8, BASE_HEX|BASE_EXT_STRING, &bthci_cmd_status_vals_ext, 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_num_link_keys,
+ { "Number of Link Keys", "bthci_cmd.num_link_keys",
+ FT_UINT8, BASE_DEC, NULL, 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_link_key,
+ { "Link Key", "bthci_cmd.link_key",
+ FT_BYTES, BASE_NONE, NULL, 0x0,
+ "Link Key for the associated BD_ADDR", HFILL }
+ },
+ { &hf_bthci_cmd_packet_type_hv1,
+ { "Packet Type HV1", "bthci_cmd.packet_type_hv1",
+ FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0020,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_packet_type_hv2,
+ { "Packet Type HV2", "bthci_cmd.packet_type_hv2",
+ FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0040,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_packet_type_hv3,
+ { "Packet Type HV3", "bthci_cmd.packet_type_hv3",
+ FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0080,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_role,
+ { "Role", "bthci_cmd.role",
+ FT_UINT8, BASE_HEX, VALS(cmd_role_vals), 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_pin_code_length,
+ { "PIN Code Length", "bthci_cmd.pin_code_length",
+ FT_UINT8, BASE_DEC, NULL, 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_pin_code,
+ { "PIN Code", "bthci_cmd.pin_code",
+ FT_STRING, BASE_NONE, NULL, 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_pin_type,
+ { "PIN Type", "bthci_cmd.pin_type",
+ FT_UINT8, BASE_HEX, VALS(cmd_pin_types), 0x0,
+ "PIN Types", HFILL }
+ },
+ { &hf_bthci_cmd_encryption_enable,
+ { "Encryption Enable", "bthci_cmd.encryption_enable",
+ FT_UINT8, BASE_HEX, VALS(cmd_encryption_enable), 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_key_flag,
+ { "Key Flag", "bthci_cmd.key_flag",
+ FT_UINT8, BASE_HEX, VALS(cmd_key_flag), 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_max_interval_hold,
+ { "Hold Mode Max Interval", "bthci_cmd.hold_mode_max_int",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ "Maximal acceptable number of Baseband slots to wait in Hold Mode.", HFILL }
+ },
+ { &hf_bthci_cmd_min_interval_hold,
+ { "Hold Mode Min Interval", "bthci_cmd.hold_mode_min_int",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ "Minimum acceptable number of Baseband slots to wait in Hold Mode.", HFILL }
+ },
+ { &hf_bthci_cmd_max_interval_sniff,
+ { "Sniff Max Interval", "bthci_cmd.sniff_max_int",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ "Maximal acceptable number of Baseband slots between each sniff period.", HFILL }
+ },
+ { &hf_bthci_cmd_min_interval_sniff,
+ { "Sniff Min Interval", "bthci_cmd.sniff_min_int",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ "Minimum acceptable number of Baseband slots between each sniff period.", HFILL }
+ },
+ { &hf_bthci_cmd_sniff_attempt,
+ { "Sniff Attempt", "bthci_cmd.sniff_attempt",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ "Number of Baseband receive slots for sniff attempt.", HFILL }
+ },
+ { &hf_bthci_cmd_timeout,
+ { "Timeout", "bthci_cmd.timeout",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ "Number of Baseband slots for timeout.", HFILL }
+ },
+ { &hf_bthci_cmd_max_interval_beacon,
+ { "Beacon Max Interval", "bthci_cmd.beacon_max_int",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ "Maximal acceptable number of Baseband slots between consecutive beacons.", HFILL }
+ },
+ { &hf_bthci_cmd_min_interval_beacon,
+ { "Beacon Min Interval", "bthci_cmd.beacon_min_int",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ "Minimum acceptable number of Baseband slots between consecutive beacons.", HFILL }
+ },
+ { &hf_bthci_cmd_flags,
+ { "Flags", "bthci_cmd.flags",
+ FT_UINT8, BASE_HEX, NULL, 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_service_type,
+ { "Service Type", "bthci_cmd.service_type",
+ FT_UINT8, BASE_HEX, VALS(cmd_service_types), 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_token_rate,
+ { "Available Token Rate", "bthci_cmd.token_rate",
+ FT_UINT32, BASE_DEC, NULL, 0x0,
+ "Token Rate, in bytes per second", HFILL }
+ },
+ { &hf_bthci_cmd_token_bucket_size,
+ { "Available Token Bucket Size", "bthci_cmd.token_bucket_size",
+ FT_UINT32, BASE_DEC, NULL, 0x0,
+ "Token Bucket Size in bytes", HFILL }
+ },
+ { &hf_bthci_cmd_peak_bandwidth,
+ { "Peak Bandwidth", "bthci_cmd.peak_bandwidth",
+ FT_UINT32, BASE_DEC, NULL, 0x0,
+ "Peak Bandwidth, in bytes per second", HFILL }
+ },
+ { &hf_bthci_cmd_latency,
+ { "Latency", "bthci_cmd.latency",
+ FT_UINT32, BASE_DEC, NULL, 0x0,
+ "Latency, in microseconds", HFILL }
+ },
+ { &hf_bthci_cmd_delay_variation,
+ { "Delay Variation", "bthci_cmd.delay_variation",
+ FT_UINT32, BASE_DEC, NULL, 0x0,
+ "Delay Variation, in microseconds", HFILL }
+ },
+ { &hf_bthci_cmd_link_policy_setting_switch,
+ { "Enable Master Slave Switch", "bthci_cmd.link_policy_switch",
+ FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0001,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_link_policy_setting_hold,
+ { "Enable Hold Mode", "bthci_cmd.link_policy_hold",
+ FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0002,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_link_policy_setting_sniff,
+ { "Enable Sniff Mode", "bthci_cmd.link_policy_sniff",
+ FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0004,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_link_policy_setting_park,
+ { "Enable Park Mode", "bthci_cmd.link_policy_park",
+ FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0008,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_filter_type,
+ { "Filter Type", "bthci_cmd.filter_type",
+ FT_UINT8, BASE_HEX, VALS(cmd_filter_types), 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_inquiry_result_filter_condition_type,
+ { "Filter Condition Type", "bthci_cmd.filter_condition_type",
+ FT_UINT8, BASE_HEX, VALS(cmd_inquiry_result_filter_condition_types), 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_connection_setup_filter_condition_type,
+ { "Filter Condition Type", "bthci_cmd.filter_condition_type",
+ FT_UINT8, BASE_HEX, VALS(cmd_connection_setup_filter_condition_types), 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_class_of_device,
+ { "Class of Device", "bthci_cmd.class_of_device",
+ FT_UINT24, BASE_HEX, NULL, 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_class_of_device_mask,
+ { "Class of Device Mask", "bthci_cmd.class_of_device_mask",
+ FT_UINT24, BASE_HEX, NULL, 0x0,
+ "Bit Mask used to determine which bits of the Class of Device parameter are of interest.", HFILL }
+ },
+ { &hf_bthci_cmd_auto_acc_flag,
+ { "Auto Accept Flag", "bthci_cmd.auto_accept_flag",
+ FT_UINT8, BASE_HEX, VALS(cmd_auto_acc_flag_values), 0x0,
+ "Class of Device of Interest", HFILL }
+ },
+ { &hf_bthci_cmd_read_all_flag,
+ { "Read All Flag", "bthci_cmd.read_all_flag",
+ FT_UINT8, BASE_HEX, VALS(cmd_read_all_flag_values), 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_delete_all_flag,
+ { "Delete All Flag", "bthci_cmd.delete_all_flag",
+ FT_UINT8, BASE_HEX, VALS(cmd_delete_all_flag_values), 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_authentication_enable,
+ { "Authentication Enable", "bthci_cmd.auth_enable",
+ FT_UINT8, BASE_HEX, VALS(cmd_authentication_enable_values), 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_input_coding,
+ { "Input Coding", "bthci_cmd.input_coding",
+ FT_UINT16, BASE_DEC, VALS(cmd_input_coding_values), 0x0300,
+ "Authentication Enable", HFILL }
+ },
+ { &hf_bthci_cmd_input_data_format,
+ { "Input Data Format", "bthci_cmd.input_data_format",
+ FT_UINT16, BASE_DEC, VALS(cmd_input_data_format_values), 0x00c0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_input_sample_size,
+ { "Input Sample Size", "bthci_cmd.input_sample_size",
+ FT_UINT16, BASE_DEC, VALS(cmd_input_sample_size_values), 0x0020,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_linear_pcm_bit_pos,
+ { "Linear PCM Bit Pos", "bthci_cmd.lin_pcm_bit_pos",
+ FT_UINT16, BASE_DEC, NULL, 0x001c,
+ "# bit pos. that MSB of sample is away from starting at MSB", HFILL }
+ },
+ { &hf_bthci_cmd_air_coding_format,
+ { "Air Coding Format", "bthci_cmd.air_coding_format",
+ FT_UINT16, BASE_DEC, VALS(cmd_air_coding_format_values), 0x0003,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_num_broadcast_retransmissions,
+ { "Num Broadcast Retran", "bthci_cmd.num_broad_retran",
+ FT_UINT8, BASE_DEC, NULL, 0x0,
+ "Number of Broadcast Retransmissions", HFILL }
+ },
+ { &hf_bthci_cmd_hold_mode_act_page,
+ { "Suspend Page Scan", "bthci_cmd.hold_mode_page",
+ FT_UINT8, BASE_DEC, VALS(cmd_boolean), 0x1,
+ "Device can enter low power state", HFILL }
+ },
+ { &hf_bthci_cmd_hold_mode_act_inquiry,
+ { "Suspend Inquiry Scan", "bthci_cmd.hold_mode_inquiry",
+ FT_UINT8, BASE_DEC, VALS(cmd_boolean), 0x2,
+ "Device can enter low power state", HFILL }
+ },
+ { &hf_bthci_cmd_hold_mode_act_periodic,
+ { "Suspend Periodic Inquiries", "bthci_cmd.hold_mode_periodic",
+ FT_UINT8, BASE_DEC, VALS(cmd_boolean), 0x4,
+ "Device can enter low power state", HFILL }
+ },
+ { &hf_bthci_cmd_scan_enable,
+ { "Scan Enable", "bthci_cmd.scan_enable",
+ FT_UINT8, BASE_HEX, VALS(cmd_scan_enable_values), 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_interval,
+ { "Interval", "bthci_cmd.interval",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_window,
+ { "Interval", "bthci_cmd.window",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ "Window", HFILL }
+ },
+ { &hf_bthci_cmd_device_name,
+ { "Device Name", "bthci_cmd.device_name",
+ FT_STRINGZ, BASE_NONE, NULL, 0x0,
+ "Userfriendly descriptive name for the device", HFILL }
+ },
+ { &hf_bthci_cmd_num_curr_iac,
+ { "Number of Current IAC", "bthci_cmd.num_curr_iac",
+ FT_UINT8, BASE_DEC, NULL, 0x0,
+ "Number of IACs which are currently in use", HFILL }
+ },
+ { &hf_bthci_cmd_iac_lap,
+ { "IAC LAP", "bthci_cmd.num_curr_iac",
+ FT_UINT24, BASE_HEX, NULL, 0x0,
+ "LAP(s)used to create IAC", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_00,
+ { "Inquiry Complete", "bthci_cmd.evt_mask_00",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x01,
+ "Inquiry Complete Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_01,
+ { "Inquiry Result", "bthci_cmd.evt_mask_01",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x02,
+ "Inquiry Result Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_02,
+ { "Connect Complete", "bthci_cmd.evt_mask_02",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x04,
+ "Connection Complete Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_03,
+ { "Connect Request", "bthci_cmd.evt_mask_03",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x08,
+ "Connect Request Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_04,
+ { "Disconnect Complete", "bthci_cmd.evt_mask_04",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x10,
+ "Disconnect Complete Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_05,
+ { "Auth Complete", "bthci_cmd.evt_mask_05",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x20,
+ "Auth Complete Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_06,
+ { "Remote Name Req Complete", "bthci_cmd.evt_mask_06",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x40,
+ "Remote Name Req Complete Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_07,
+ { "Encrypt Change", "bthci_cmd.evt_mask_07",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x80,
+ "Encrypt Change Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_10,
+ { "Change Connection Link Key Complete", "bthci_cmd.evt_mask_10",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x01,
+ "Change Connection Link Key Complete Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_11,
+ { "Master Link Key Complete", "bthci_cmd.evt_mask_11",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x02,
+ "Master Link Key Complete Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_12,
+ { "Read Remote Supported Features", "bthci_cmd.evt_mask_12",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x04,
+ "Read Remote Supported Features Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_13,
+ { "Read Remote Ver Info Complete", "bthci_cmd.evt_mask_13",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x08,
+ "Read Remote Ver Info Complete Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_14,
+ { "QoS Setup Complete", "bthci_cmd.evt_mask_14",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x10,
+ "QoS Setup Complete Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_17,
+ { "Hardware Error", "bthci_cmd.evt_mask_17",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x80,
+ "Hardware Error Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_20,
+ { "Flush Occurred", "bthci_cmd.evt_mask_20",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x01,
+ "Flush Occurred Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_21,
+ { "Role Change", "bthci_cmd.evt_mask_21",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x02,
+ "Role Change Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_23,
+ { "Mode Change", "bthci_cmd.evt_mask_23",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x08,
+ "Mode Change Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_24,
+ { "Return Link Keys", "bthci_cmd.evt_mask_24",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x10,
+ "Return Link Keys Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_25,
+ { "PIN Code Request", "bthci_cmd.evt_mask_25",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x20,
+ "PIN Code Request Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_26,
+ { "Link Key Request", "bthci_cmd.evt_mask_26",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x40,
+ "Link Key Request Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_27,
+ { "Link Key Notification", "bthci_cmd.evt_mask_27",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x80,
+ "Link Key Notification Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_30,
+ { "Loopback Command", "bthci_cmd.evt_mask_30",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x01,
+ "Loopback Command Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_31,
+ { "Data Buffer Overflow" , "bthci_cmd.evt_mask_31",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x02,
+ "Data Buffer Overflow Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_32,
+ { "Max Slots Change", "bthci_cmd.evt_mask_32",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x04,
+ "Max Slots Change Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_33,
+ { "Read Clock Offset Complete", "bthci_cmd.evt_mask_33",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x08,
+ "Read Clock Offset Complete Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_34,
+ { "Connection Packet Type Changed", "bthci_cmd.evt_mask_34",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x10,
+ "Connection Packet Type Changed Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_35,
+ { "QoS Violation", "bthci_cmd.evt_mask_35",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x20,
+ "QoS Violation Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_36,
+ { "Page Scan Mode Change", "bthci_cmd.evt_mask_36",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x40,
+ "Page Scan Mode Change Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_37,
+ { "Page Scan Repetition Mode Change", "bthci_cmd.evt_mask_37",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x80,
+ "Page Scan Repetition Mode Change Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_40,
+ { "Flow Specification Complete", "bthci_cmd.evt_mask_40",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x01,
+ "Flow Specification Complete Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_41,
+ { "Inquiry Result With RSSI", "bthci_cmd.evt_mask_41",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x02,
+ "Inquiry Result With RSSI Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_42,
+ { "Read Remote Ext. Features Complete", "bthci_cmd.evt_mask_42",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x04,
+ "Read Remote Ext. Features Complete Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_53,
+ { "Synchronous Connection Complete", "bthci_cmd.evt_mask_53",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x08,
+ "Synchronous Connection Complete Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_54,
+ { "Synchronous Connection Changed", "bthci_cmd.evt_mask_54",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x10,
+ "Synchronous Connection Changed Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_55,
+ { "Sniff Subrate", "bthci_cmd.evt_mask_55",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x20,
+ "Sniff Subrate Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_56,
+ { "Extended Inquiry Result", "bthci_cmd.evt_mask_56",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x40,
+ "Extended Inquiry Result Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_57,
+ { "Encryption Key Refresh Complete", "bthci_cmd.evt_mask_57",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x80,
+ "Encryption Key Refresh Complete Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_60,
+ { "IO Capability Request", "bthci_cmd.evt_mask_60",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x01,
+ "IO Capability Request Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_61,
+ { "IO Capability Response", "bthci_cmd.evt_mask_61",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x02,
+ "IO Capability Response Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_62,
+ { "User Confirmation Request", "bthci_cmd.evt_mask_62",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x04,
+ "User Confirmation Request Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_63,
+ { "User Passkey Request", "bthci_cmd.evt_mask_63",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x08,
+ "User Passkey Request Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_64,
+ { "Remote OOB Data Request", "bthci_cmd.evt_mask_64",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x10,
+ "Remote OOB Data Request Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_65,
+ { "Simple Pairing Complete", "bthci_cmd.evt_mask_65",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x20,
+ "Simple Pairing Complete Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_67,
+ { "Link Supervision Timeout Changed", "bthci_cmd.evt_mask_67",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x80,
+ "Link Supervision Timeout Changed Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_70,
+ { "Enhanced Flush Complete", "bthci_cmd.evt_mask_70",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x01,
+ "Enhanced Flush Complete Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_72,
+ { "User Passkey Notification", "bthci_cmd.evt_mask_72",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x04,
+ "User Passkey Notification Bit", HFILL }
+ },
+ { &hf_bthci_cmd_evt_mask_73,
+ { "Keypress Notification", "bthci_cmd.evt_mask_73",
+ FT_UINT8, BASE_HEX, VALS(cmd_boolean), 0x08,
+ "Keypress Notification Bit", HFILL }
+ },
+ { &hf_bthci_cmd_sco_flow_control,
+ { "SCO Flow Control","bthci_cmd.flow_control",
+ FT_UINT8, BASE_HEX, VALS(cmd_en_disabled), 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_num_handles,
+ { "Number of Handles", "bthci_cmd.num_handles",
+ FT_UINT8, BASE_DEC, NULL, 0x0,
+ NULL, HFILL }
+ },
+
+ { &hf_bthci_cmd_num_compl_packets,
+ { "Number of Completed Packets", "bthci_cmd.num_compl_packets",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ "Number of Completed HCI Data Packets", HFILL }
+ },
+ { &hf_bthci_cmd_flow_contr_enable,
+ { "Flow Control Enable", "bthci_cmd.flow_contr_enable",
+ FT_UINT8, BASE_HEX, VALS(cmd_flow_contr_enable), 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_host_data_packet_length_acl,
+ {"Host ACL Data Packet Length (bytes)", "bthci_cmd.max_data_length_acl",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ "Max Host ACL Data Packet length of data portion host is able to accept", HFILL }
+ },
+ { &hf_bthci_cmd_host_data_packet_length_sco,
+ {"Host SCO Data Packet Length (bytes)", "bthci_cmd.max_data_length_sco",
+ FT_UINT8, BASE_DEC, NULL, 0x0,
+ "Max Host SCO Data Packet length of data portion host is able to accept", HFILL }
+ },
+ { &hf_bthci_cmd_host_total_num_acl_data_packets,
+ {"Host Total Num ACL Data Packets", "bthci_cmd.max_data_num_acl",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ "Total Number of HCI ACL Data Packets that can be stored in the data buffers of the Host", HFILL }
+ },
+ { &hf_bthci_cmd_host_total_num_sco_data_packets,
+ {"Host Total Num SCO Data Packets", "bthci_cmd.max_data_num_sco",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ "Total Number of HCI SCO Data Packets that can be stored in the data buffers of the Host", HFILL }
+ },
+ { &hf_bthci_cmd_power_level_type,
+ {"Type", "bthci_cmd.power_level_type",
+ FT_UINT8, BASE_HEX, VALS(cmd_power_level_types), 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_cmd_loopback_mode,
+ {"Loopback Mode", "bthci_cmd.loopback_mode",
+ FT_UINT8, BASE_HEX, VALS(cmd_loopback_modes), 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_cmd_page_number,
+ {"Page Number", "bthci_cmd.page_number",
+ FT_UINT8, BASE_DEC, NULL, 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_cmd_transmit_bandwidth,
+ {"Tx Bandwidth (bytes/s)", "bthci_cmd.tx_bandwidth",
+ FT_UINT32, BASE_DEC, NULL, 0x0,
+ "Tx Bandwidth", HFILL}
+ },
+ { &hf_bthci_cmd_receive_bandwidth,
+ {"Rx Bandwidth (bytes/s)", "bthci_cmd.rx_bandwidth",
+ FT_UINT32, BASE_DEC, NULL, 0x0,
+ "Rx Bandwidth", HFILL}
+ },
+ { &hf_bthci_cmd_max_latency_ms,
+ {"Max. Latency (ms)", "bthci_cmd.max_latency_ms",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_cmd_max_latency,
+ {"Max. Latency", "bthci_cmd.max_latency",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ "Max. Latency in baseband slots", HFILL}
+ },
+ { &hf_bthci_cmd_retransmission_effort,
+ {"Retransmission Effort", "bthci_cmd.retransmission_effort",
+ FT_UINT8, BASE_DEC, VALS(cmd_rtx_effort), 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_cmd_scan_type,
+ {"Scan Type", "bthci_cmd.inq_scan_type",
+ FT_UINT8, BASE_DEC, VALS(cmd_scan_types), 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_cmd_inq_mode,
+ {"Inquiry Mode", "bthci_cmd.inq_scan_type",
+ FT_UINT8, BASE_DEC, VALS(cmd_inq_modes), 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_cmd_fec_required,
+ {"FEC Required", "bthci_cmd.fec_required",
+ FT_UINT8, BASE_DEC, VALS(cmd_boolean), 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_cmd_err_data_reporting,
+ {"Erroneous Data Reporting", "bthci_cmd.err_data_reporting",
+ FT_UINT8, BASE_DEC, VALS(cmd_en_disabled), 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_cmd_tx_power,
+ {"Power Level (dBm)", "bthci_cmd.power_level",
+ FT_INT8, BASE_DEC, NULL, 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_cmd_sco_packet_type_hv1,
+ { "Packet Type HV1", "bthci_cmd.sco_packet_type_hv1",
+ FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0001,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_sco_packet_type_hv2,
+ { "Packet Type HV2", "bthci_cmd.sco_packet_type_hv2",
+ FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0002,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_sco_packet_type_hv3,
+ { "Packet Type HV3", "bthci_cmd.sco_packet_type_hv3",
+ FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0004,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_sco_packet_type_ev3,
+ { "Packet Type EV3", "bthci_cmd.sco_packet_type_ev3",
+ FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0008,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_sco_packet_type_ev4,
+ { "Packet Type EV4", "bthci_cmd.sco_packet_type_ev4",
+ FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0010,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_sco_packet_type_ev5,
+ { "Packet Type EV5", "bthci_cmd.sco_packet_type_ev5",
+ FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0020,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_sco_packet_type_2ev3,
+ { "Packet Type 2-EV3", "bthci_cmd.sco_packet_type_2ev3",
+ FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0040,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_sco_packet_type_3ev3,
+ { "Packet Type 3-EV3", "bthci_cmd.sco_packet_type_3ev3",
+ FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0080,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_sco_packet_type_2ev5,
+ { "Packet Type 2-EV5", "bthci_cmd.sco_packet_type_2ev5",
+ FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0100,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_sco_packet_type_3ev5,
+ { "Packet Type 3-EV5", "bthci_cmd.sco_packet_type_3ev5",
+ FT_UINT16, BASE_DEC, VALS(cmd_boolean), 0x0200,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_min_remote_timeout,
+ {"Min. Remote Timeout", "bthci_cmd.min_remote_timeout",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ "Min. Remote Timeout in baseband slots", HFILL}
+ },
+ { &hf_bthci_cmd_min_local_timeout,
+ {"Min. Local Timeout", "bthci_cmd.min_local_timeout",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ "Min. Local Timeout in baseband slots", HFILL}
+ },
+ { &hf_bthci_cmd_flush_packet_type,
+ {"Packet Type", "bthci_cmd.flush_packet_type",
+ FT_UINT8, BASE_DEC, VALS(cmd_flush_pkt_type), 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_cmd_afh_ch_assessment_mode,
+ {"AFH Channel Assessment Mode", "bthci_cmd.afh_ch_assessment_mode",
+ FT_UINT8, BASE_DEC, VALS(cmd_en_disabled), 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_cmd_afh_ch_classification,
+ { "Channel Classification", "bthci_cmd.afh_ch_classification",
+ FT_NONE, BASE_NONE, NULL, 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_cmd_which_clock,
+ {"Which Clock", "bthci_cmd.which_clock",
+ FT_UINT8, BASE_DEC, VALS(cmd_which_clock), 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_cmd_io_capability,
+ {"IO Capability", "bthci_cmd.io_capability",
+ FT_UINT8, BASE_DEC, VALS(bthci_cmd_io_capability_vals), 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_cmd_oob_data_present,
+ {"OOB Data Present", "bthci_cmd.oob_data_present",
+ FT_UINT8, BASE_DEC, VALS(bthci_cmd_oob_data_present_vals), 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_cmd_auth_requirements,
+ {"Authentication Requirements", "bthci_cmd.auth_requirements",
+ FT_UINT8, BASE_DEC|BASE_EXT_STRING, &bthci_cmd_auth_req_vals_ext, 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_cmd_passkey,
+ {"Passkey", "bthci_cmd.passkey",
+ FT_UINT32, BASE_DEC, NULL, 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_cmd_hash_c,
+ {"Hash C", "bthci_cmd.hash_c",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_cmd_randomizer_r,
+ {"Randomizer R", "bthci_cmd.randomizer_r",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_cmd_simple_pairing_mode,
+ {"Simple Pairing Mode", "bthci_cmd.simple_pairing_mode",
+ FT_UINT8, BASE_DEC, VALS(cmd_en_disabled), 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_cmd_simple_pairing_debug_mode,
+ {"Simple Pairing Debug Mode", "bthci_cmd.simple_pairing_debug_mode",
+ FT_UINT8, BASE_DEC, VALS(cmd_en_disabled), 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_cmd_notification_type,
+ {"Notification Type", "bthci_cmd.notification_type",
+ FT_UINT8, BASE_DEC, VALS(cmd_notification_types), 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_cmd_eir_data,
+ {"Data", "bthci_cmd.eir_data",
+ FT_BYTES, BASE_NONE, NULL, 0x0,
+ "EIR Data", HFILL}
+ },
+ { &hf_bthci_cmd_eir_struct_length,
+ { "Length", "bthci_cmd.eir_struct_length",
+ FT_UINT8, BASE_DEC, NULL, 0x0,
+ "Structure Length", HFILL }
+ },
+ { &hf_bthci_cmd_eir_struct_type,
+ { "Type", "bthci_cmd.eir_data_type",
+ FT_UINT8, BASE_HEX|BASE_EXT_STRING, &bthci_cmd_eir_data_type_vals_ext, 0x0,
+ "Data Type", HFILL }
+ },
+ { &hf_bthci_cmd_sc_uuid16,
+ { "UUID", "bthci_cmd.service_class_uuid16",
+ FT_UINT16, BASE_HEX|BASE_EXT_STRING, &bthci_cmd_service_class_type_vals_ext, 0x0,
+ "16-bit Service Class UUID", HFILL }
+ },
+ { &hf_bthci_cmd_sc_uuid32,
+ { "UUID", "bthci_cmd.service_class_uuid32",
+ FT_UINT32, BASE_HEX, NULL, 0x0,
+ "32-bit Service Class UUID", HFILL }
+ },
+ { &hf_bthci_cmd_sc_uuid128,
+ { "UUID", "bthci_cmd.service_class_uuid128",
+ FT_BYTES, BASE_NONE, NULL, 0x0,
+ "128-bit Service Class UUID", HFILL }
+ }
+ };
+
+ /* Setup protocol subtree array */
+ static gint *ett[] = {
+ &ett_bthci_cmd,
+ &ett_opcode,
+ &ett_eir_subtree,
+ &ett_eir_struct_subtree
+ };
+
+ /* Register the protocol name and description */
+ proto_bthci_cmd = proto_register_protocol("Bluetooth HCI Command", "HCI_CMD", "bthci_cmd");
+
+ register_dissector("bthci_cmd", dissect_bthci_cmd, proto_bthci_cmd);
+
+ /* Required function calls to register the header fields and subtrees used */
+ proto_register_field_array(proto_bthci_cmd, hf, array_length(hf));
+ proto_register_subtree_array(ett, array_length(ett));
}
@@ -2925,9 +2925,9 @@ proto_register_bthci_cmd(void)
void
proto_reg_handoff_bthci_cmd(void)
{
- dissector_handle_t bthci_cmd_handle;
- bthci_cmd_handle = find_dissector("bthci_cmd");
- dissector_add_uint("hci_h4.type", HCI_H4_TYPE_CMD, bthci_cmd_handle);
- dissector_add_uint("hci_h1.type", BTHCI_CHANNEL_COMMAND, bthci_cmd_handle);
+ dissector_handle_t bthci_cmd_handle;
+ bthci_cmd_handle = find_dissector("bthci_cmd");
+ dissector_add_uint("hci_h4.type", HCI_H4_TYPE_CMD, bthci_cmd_handle);
+ dissector_add_uint("hci_h1.type", BTHCI_CHANNEL_COMMAND, bthci_cmd_handle);
}
diff --git a/epan/dissectors/packet-bthci_evt.c b/epan/dissectors/packet-bthci_evt.c
index 0a96bd2b96..a6f31349de 100644
--- a/epan/dissectors/packet-bthci_evt.c
+++ b/epan/dissectors/packet-bthci_evt.c
@@ -247,2117 +247,2117 @@ static gint ett_eir_subtree = -1;
static gint ett_eir_struct_subtree = -1;
static const value_string evt_code_vals[] = {
- {0x01, "Inquiry Complete"},
- {0x02, "Inquiry Result"},
- {0x03, "Connect Complete"},
- {0x04, "Connect Request"},
- {0x05, "Disconnect Complete"},
- {0x06, "Auth Complete"},
- {0x07, "Remote Name Req Complete"},
- {0x08, "Encrypt Change"},
- {0x09, "Change Connection Link Key Complete"},
- {0x0a, "Master Link Key Complete"},
- {0x0b, "Read Remote Supported Features"},
- {0x0c, "Read Remote Ver Info Complete"},
- {0x0d, "QoS Setup Complete"},
- {0x0e, "Command Complete"},
- {0x0f, "Command Status"},
- {0x10, "Hardware Error"},
- {0x11, "Flush Occurred"},
- {0x12, "Role Change"},
- {0x13, "Number of Completed Packets"},
- {0x14, "Mode Change"},
- {0x15, "Return Link Keys"},
- {0x16, "PIN Code Request"},
- {0x17, "Link Key Request"},
- {0x18, "Link Key Notification"},
- {0x19, "Loopback Command"},
- {0x1a, "Data Buffer Overflow"},
- {0x1b, "Max Slots Change"},
- {0x1c, "Read Clock Offset Complete"},
- {0x1d, "Connection Packet Type Changed"},
- {0x1e, "QoS Violation"},
- {0x1f, "Page Scan Mode Change"},
- {0x20, "Page Scan Repetition Mode Change"},
- {0x21, "Flow Specification Complete"},
- {0x22, "Inquiry Result With RSSI"},
- {0x23, "Read Remote Extended Features Complete"},
- {0x2c, "Synchronous Connection Complete"},
- {0x2d, "Synchronous Connection Changed"},
- {0x2e, "Sniff Subrating"},
- {0x2f, "Extended Inquiry Result"},
- {0x30, "Encryption Key Refresh Complete"},
- {0x31, "IO Capability Request"},
- {0x32, "IO Capability Response"},
- {0x33, "User Confirmation Request"},
- {0x34, "User Passkey Request"},
- {0x35, "Remote OOB Data Request"},
- {0x36, "Simple Pairing Complete"},
- {0x38, "Link Supervision Timeout Changed"},
- {0x39, "Enhanced Flush Complete"},
- {0x3b, "User Passkey Notification"},
- {0x3c, "Keypress Notification"},
- {0x3d, "Remote Host Supported Features Notification"},
- {0xfe, "Bluetooth Logo Testing"},
- {0xff, "Vendor-Specific"},
- {0, NULL}
+ {0x01, "Inquiry Complete"},
+ {0x02, "Inquiry Result"},
+ {0x03, "Connect Complete"},
+ {0x04, "Connect Request"},
+ {0x05, "Disconnect Complete"},
+ {0x06, "Auth Complete"},
+ {0x07, "Remote Name Req Complete"},
+ {0x08, "Encrypt Change"},
+ {0x09, "Change Connection Link Key Complete"},
+ {0x0a, "Master Link Key Complete"},
+ {0x0b, "Read Remote Supported Features"},
+ {0x0c, "Read Remote Ver Info Complete"},
+ {0x0d, "QoS Setup Complete"},
+ {0x0e, "Command Complete"},
+ {0x0f, "Command Status"},
+ {0x10, "Hardware Error"},
+ {0x11, "Flush Occurred"},
+ {0x12, "Role Change"},
+ {0x13, "Number of Completed Packets"},
+ {0x14, "Mode Change"},
+ {0x15, "Return Link Keys"},
+ {0x16, "PIN Code Request"},
+ {0x17, "Link Key Request"},
+ {0x18, "Link Key Notification"},
+ {0x19, "Loopback Command"},
+ {0x1a, "Data Buffer Overflow"},
+ {0x1b, "Max Slots Change"},
+ {0x1c, "Read Clock Offset Complete"},
+ {0x1d, "Connection Packet Type Changed"},
+ {0x1e, "QoS Violation"},
+ {0x1f, "Page Scan Mode Change"},
+ {0x20, "Page Scan Repetition Mode Change"},
+ {0x21, "Flow Specification Complete"},
+ {0x22, "Inquiry Result With RSSI"},
+ {0x23, "Read Remote Extended Features Complete"},
+ {0x2c, "Synchronous Connection Complete"},
+ {0x2d, "Synchronous Connection Changed"},
+ {0x2e, "Sniff Subrating"},
+ {0x2f, "Extended Inquiry Result"},
+ {0x30, "Encryption Key Refresh Complete"},
+ {0x31, "IO Capability Request"},
+ {0x32, "IO Capability Response"},
+ {0x33, "User Confirmation Request"},
+ {0x34, "User Passkey Request"},
+ {0x35, "Remote OOB Data Request"},
+ {0x36, "Simple Pairing Complete"},
+ {0x38, "Link Supervision Timeout Changed"},
+ {0x39, "Enhanced Flush Complete"},
+ {0x3b, "User Passkey Notification"},
+ {0x3c, "Keypress Notification"},
+ {0x3d, "Remote Host Supported Features Notification"},
+ {0xfe, "Bluetooth Logo Testing"},
+ {0xff, "Vendor-Specific"},
+ {0, NULL}
};
static const value_string bthci_cmd_status_pending_vals[] = {
- {0x00, "Pending"},
- {0, NULL }
+ {0x00, "Pending"},
+ {0, NULL }
};
static const value_string evt_link_types[] = {
- {0x00, "SCO connection (Voice Channels)"},
- {0x01, "ACL connection (Data Channels)"},
- {0x02, "eSCO connection (Voice Channels)"},
- {0, NULL }
+ {0x00, "SCO connection (Voice Channels)"},
+ {0x01, "ACL connection (Data Channels)"},
+ {0x02, "eSCO connection (Voice Channels)"},
+ {0, NULL }
};
static const value_string evt_sync_link_types[] = {
- {0x00, "SCO connection"},
- {0x02, "eSCO connection"},
- {0, NULL }
+ {0x00, "SCO connection"},
+ {0x02, "eSCO connection"},
+ {0, NULL }
};
static const value_string evt_encryption_modes[] = {
- {0x00, "Encryption Disabled"},
- {0x01, "Encryption only for point-to-point packets"},
- {0x02, "Encryption for both point-to-point and broadcast packets"},
- {0, NULL }
+ {0x00, "Encryption Disabled"},
+ {0x01, "Encryption only for point-to-point packets"},
+ {0x02, "Encryption for both point-to-point and broadcast packets"},
+ {0, NULL }
};
static const value_string evt_encryption_enable[] = {
- {0x00, "Link Level Encryption is OFF"},
- {0x01, "Link Level Encryption is ON"},
- {0, NULL }
+ {0x00, "Link Level Encryption is OFF"},
+ {0x01, "Link Level Encryption is ON"},
+ {0, NULL }
};
static const value_string evt_key_flag[] = {
- {0x00, "Using Semi-permanent Link Key"},
- {0x01, "Using Temporary Link Key"},
- {0, NULL }
+ {0x00, "Using Semi-permanent Link Key"},
+ {0x01, "Using Temporary Link Key"},
+ {0, NULL }
};
/* Taken from https://www.bluetooth.org/Technical/AssignedNumbers/link_manager.htm */
static const value_string evt_lmp_vers_nr[] = {
- {0x00, "1.0b"},
- {0x01, "1.1"},
- {0x02, "1.2"},
- {0x03, "2.0 + EDR"},
- {0x04, "2.1 + EDR"},
- {0x05, "3.0 + HS"},
- {0x06, "4.0"},
- {0, NULL }
+ {0x00, "1.0b"},
+ {0x01, "1.1"},
+ {0x02, "1.2"},
+ {0x03, "2.0 + EDR"},
+ {0x04, "2.1 + EDR"},
+ {0x05, "3.0 + HS"},
+ {0x06, "4.0"},
+ {0, NULL }
};
/* Taken from https://www.bluetooth.org/Technical/AssignedNumbers/hci.htm
* (requires a login/password)
*/
static const value_string evt_hci_vers_nr[] = {
- {0x00, "1.0b"},
- {0x01, "1.1"},
- {0x02, "1.2"},
- {0x03, "2.0 + EDR"},
- {0x04, "2.1 + EDR"},
- {0x05, "3.0 + HS"},
- {0x06, "4.0"},
- {0, NULL }
+ {0x00, "1.0b"},
+ {0x01, "1.1"},
+ {0x02, "1.2"},
+ {0x03, "2.0 + EDR"},
+ {0x04, "2.1 + EDR"},
+ {0x05, "3.0 + HS"},
+ {0x06, "4.0"},
+ {0, NULL }
};
/* Taken from https://www.bluetooth.org/technical/assignednumbers/identifiers.htm */
static const value_string evt_comp_id[] = {
- {0x0000, "Ericsson Technology Licensing"},
- {0x0001, "Nokia Mobile Phones"},
- {0x0002, "Intel Corp."},
- {0x0003, "IBM Corp."},
- {0x0004, "Toshiba Corp."},
- {0x0005, "3Com"},
- {0x0006, "Microsoft"},
- {0x0007, "Lucent"},
- {0x0008, "Motorola"},
- {0x0009, "Infineon Technologies AG"},
- {0x000A, "Cambridge Silicon Radio"},
- {0x000B, "Silicon Wave"},
- {0x000C, "Digianswer A/S"},
- {0x000D, "Texas Instruments Inc."},
- {0x000E, "Ceva, Inc. (formerly Parthus Technologies, Inc.)"},
- {0x000F, "Broadcom Corporation"},
- {0x0010, "Mitel Semiconductor"},
- {0x0011, "Widcomm, Inc."},
- {0x0012, "Zeevo, Inc."},
- {0x0013, "Atmel Corporation"},
- {0x0014, "Mitsubishi Electric Corporation"},
- {0x0015, "RTX Telecom A/S"},
- {0x0016, "KC Technology Inc."},
- {0x0017, "Newlogic"},
- {0x0018, "Transilica, Inc."},
- {0x0019, "Rohde & Schwarz GmbH & Co. KG"},
- {0x001A, "TTPCom Limited"},
- {0x001B, "Signia Technologies, Inc."},
- {0x001C, "Conexant Systems Inc."},
- {0x001D, "Qualcomm"},
- {0x001E, "Inventel"},
- {0x001F, "AVM Berlin"},
- {0x0020, "BandSpeed, Inc."},
- {0x0021, "Mansella Ltd"},
- {0x0022, "NEC Corporation"},
- {0x0023, "WavePlus Technology Co., Ltd."},
- {0x0024, "Alcatel"},
- {0x0025, "Philips Semiconductors"},
- {0x0026, "C Technologies"},
- {0x0027, "Open Interface"},
- {0x0028, "R F Micro Devices"},
- {0x0029, "Hitachi Ltd"},
- {0x002A, "Symbol Technologies, Inc."},
- {0x002B, "Tenovis"},
- {0x002C, "Macronix International Co. Ltd."},
- {0x002D, "GCT Semiconductor"},
- {0x002E, "Norwood Systems"},
- {0x002F, "MewTel Technology Inc."},
- {0x0030, "ST Microelectronics"},
- {0x0031, "Synopsys"},
- {0x0032, "Red-M (Communications) Ltd"},
- {0x0033, "Commil Ltd"},
- {0x0034, "Computer Access Technology Corporation (CATC)"},
- {0x0035, "Eclipse (HQ Espana) S.L."},
- {0x0036, "Renesas Technology Corp."},
- {0x0037, "Mobilian Corporation"},
- {0x0038, "Terax"},
- {0x0039, "Integrated System Solution Corp."},
- {0x003A, "Matsushita Electric Industrial Co., Ltd."},
- {0x003B, "Gennum Corporation"},
- {0x003C, "Research In Motion"},
- {0x003D, "IPextreme, Inc."},
- {0x003E, "Systems and Chips, Inc"},
- {0x003F, "Bluetooth SIG, Inc"},
- {0x0040, "Seiko Epson Corporation"},
- {0x0041, "Integrated Silicon Solution Taiwan, Inc."},
- {0x0042, "CONWISE Technology Corporation Ltd"},
- {0x0043, "PARROT SA"},
- {0x0044, "Socket Mobile"},
- {0x0045, "Atheros Communications, Inc."},
- {0x0046, "MediaTek, Inc."},
- {0x0047, "Bluegiga"},
- {0x0048, "Marvell Technology Group Ltd."},
- {0x0049, "3DSP Corporation"},
- {0x004A, "Accel Semiconductor Ltd."},
- {0x004B, "Continental Automotive Systems"},
- {0x004C, "Apple, Inc."},
- {0x004D, "Staccato Communications, Inc."},
- {0x004E, "Avago Technologies"},
- {0x004F, "APT Licensing Ltd."},
- {0x0050, "SiRF Technology, Inc."},
- {0x0051, "Tzero Technologies, Inc."},
- {0x0052, "J&M Corporation"},
- {0x0053, "Free2move AB"},
- {0x0054, "3DiJoy Corporation"},
- {0x0055, "Plantronics, Inc."},
- {0x0056, "Sony Ericsson Mobile Communications"},
- {0x0057, "Harman International Industries, Inc."},
- {0x0058, "Vizio, Inc."},
- {0x0059, "Nordic Semiconductor ASA"},
- {0x005A, "EM Microelectronic-Marin SA"},
- {0x005B, "Ralink Technology Corporation"},
- {0x005C, "Belkin International, Inc."},
- {0x005D, "Realtek Semiconductor Corporation"},
- {0x005E, "Stonestreet One, LLC"},
- {0x005F, "Wicentric, Inc."},
- {0x0060, "RivieraWaves S.A.S"},
- {0x0061, "RDA Microelectronics"},
- {0x0062, "Gibson Guitars"},
- {0x0063, "MiCommand Inc."},
- {0x0064, "Band XI International, LLC"},
- {0x0065, "Hewlett-Packard Company"},
- {0x0066, "9Solutions Oy"},
- {0x0067, "GN Netcom A/S"},
- {0x0068, "General Motors"},
- {0x0069, "A&D Engineering, Inc."},
- {0x006A, "MindTree Ltd."},
- {0x006B, "Polar Electro OY"},
- {0x006C, "Beautiful Enterprise Co., Ltd."},
- {0x006D, "BriarTek, Inc."},
- {0x006E, "Summit Data Communications, Inc."},
- {0x006F, "Sound ID"},
- {0x0070, "Monster, LLC"},
- {0x0071, "connectBlue AB"},
- {0x0072, "ShangHai Super Smart Electronics Co. Ltd."},
- {0x0073, "Group Sense Ltd."},
- {0x0074, "Zomm, LLC"},
- {0x0075, "Samsung Electronics Co. Ltd."},
- {0x0076, "Creative Technology Ltd."},
- {0x0077, "Laird Technologies"},
- {0x0078, "Nike, Inc."},
- {0x0079, "lesswire AG"},
- {0x007A, "MStar Semiconductor, Inc."},
- {0x007B, "Hanlynn Technologies"},
- {0x007C, "A & R Cambridge"},
- {0x007D, "Seers Technology Co. Ltd."},
- {0xFFFF, "For use in internal and interoperability tests."},
- {0, NULL }
+ {0x0000, "Ericsson Technology Licensing"},
+ {0x0001, "Nokia Mobile Phones"},
+ {0x0002, "Intel Corp."},
+ {0x0003, "IBM Corp."},
+ {0x0004, "Toshiba Corp."},
+ {0x0005, "3Com"},
+ {0x0006, "Microsoft"},
+ {0x0007, "Lucent"},
+ {0x0008, "Motorola"},
+ {0x0009, "Infineon Technologies AG"},
+ {0x000A, "Cambridge Silicon Radio"},
+ {0x000B, "Silicon Wave"},
+ {0x000C, "Digianswer A/S"},
+ {0x000D, "Texas Instruments Inc."},
+ {0x000E, "Ceva, Inc. (formerly Parthus Technologies, Inc.)"},
+ {0x000F, "Broadcom Corporation"},
+ {0x0010, "Mitel Semiconductor"},
+ {0x0011, "Widcomm, Inc."},
+ {0x0012, "Zeevo, Inc."},
+ {0x0013, "Atmel Corporation"},
+ {0x0014, "Mitsubishi Electric Corporation"},
+ {0x0015, "RTX Telecom A/S"},
+ {0x0016, "KC Technology Inc."},
+ {0x0017, "Newlogic"},
+ {0x0018, "Transilica, Inc."},
+ {0x0019, "Rohde & Schwarz GmbH & Co. KG"},
+ {0x001A, "TTPCom Limited"},
+ {0x001B, "Signia Technologies, Inc."},
+ {0x001C, "Conexant Systems Inc."},
+ {0x001D, "Qualcomm"},
+ {0x001E, "Inventel"},
+ {0x001F, "AVM Berlin"},
+ {0x0020, "BandSpeed, Inc."},
+ {0x0021, "Mansella Ltd"},
+ {0x0022, "NEC Corporation"},
+ {0x0023, "WavePlus Technology Co., Ltd."},
+ {0x0024, "Alcatel"},
+ {0x0025, "Philips Semiconductors"},
+ {0x0026, "C Technologies"},
+ {0x0027, "Open Interface"},
+ {0x0028, "R F Micro Devices"},
+ {0x0029, "Hitachi Ltd"},
+ {0x002A, "Symbol Technologies, Inc."},
+ {0x002B, "Tenovis"},
+ {0x002C, "Macronix International Co. Ltd."},
+ {0x002D, "GCT Semiconductor"},
+ {0x002E, "Norwood Systems"},
+ {0x002F, "MewTel Technology Inc."},
+ {0x0030, "ST Microelectronics"},
+ {0x0031, "Synopsys"},
+ {0x0032, "Red-M (Communications) Ltd"},
+ {0x0033, "Commil Ltd"},
+ {0x0034, "Computer Access Technology Corporation (CATC)"},
+ {0x0035, "Eclipse (HQ Espana) S.L."},
+ {0x0036, "Renesas Technology Corp."},
+ {0x0037, "Mobilian Corporation"},
+ {0x0038, "Terax"},
+ {0x0039, "Integrated System Solution Corp."},
+ {0x003A, "Matsushita Electric Industrial Co., Ltd."},
+ {0x003B, "Gennum Corporation"},
+ {0x003C, "Research In Motion"},
+ {0x003D, "IPextreme, Inc."},
+ {0x003E, "Systems and Chips, Inc"},
+ {0x003F, "Bluetooth SIG, Inc"},
+ {0x0040, "Seiko Epson Corporation"},
+ {0x0041, "Integrated Silicon Solution Taiwan, Inc."},
+ {0x0042, "CONWISE Technology Corporation Ltd"},
+ {0x0043, "PARROT SA"},
+ {0x0044, "Socket Mobile"},
+ {0x0045, "Atheros Communications, Inc."},
+ {0x0046, "MediaTek, Inc."},
+ {0x0047, "Bluegiga"},
+ {0x0048, "Marvell Technology Group Ltd."},
+ {0x0049, "3DSP Corporation"},
+ {0x004A, "Accel Semiconductor Ltd."},
+ {0x004B, "Continental Automotive Systems"},
+ {0x004C, "Apple, Inc."},
+ {0x004D, "Staccato Communications, Inc."},
+ {0x004E, "Avago Technologies"},
+ {0x004F, "APT Licensing Ltd."},
+ {0x0050, "SiRF Technology, Inc."},
+ {0x0051, "Tzero Technologies, Inc."},
+ {0x0052, "J&M Corporation"},
+ {0x0053, "Free2move AB"},
+ {0x0054, "3DiJoy Corporation"},
+ {0x0055, "Plantronics, Inc."},
+ {0x0056, "Sony Ericsson Mobile Communications"},
+ {0x0057, "Harman International Industries, Inc."},
+ {0x0058, "Vizio, Inc."},
+ {0x0059, "Nordic Semiconductor ASA"},
+ {0x005A, "EM Microelectronic-Marin SA"},
+ {0x005B, "Ralink Technology Corporation"},
+ {0x005C, "Belkin International, Inc."},
+ {0x005D, "Realtek Semiconductor Corporation"},
+ {0x005E, "Stonestreet One, LLC"},
+ {0x005F, "Wicentric, Inc."},
+ {0x0060, "RivieraWaves S.A.S"},
+ {0x0061, "RDA Microelectronics"},
+ {0x0062, "Gibson Guitars"},
+ {0x0063, "MiCommand Inc."},
+ {0x0064, "Band XI International, LLC"},
+ {0x0065, "Hewlett-Packard Company"},
+ {0x0066, "9Solutions Oy"},
+ {0x0067, "GN Netcom A/S"},
+ {0x0068, "General Motors"},
+ {0x0069, "A&D Engineering, Inc."},
+ {0x006A, "MindTree Ltd."},
+ {0x006B, "Polar Electro OY"},
+ {0x006C, "Beautiful Enterprise Co., Ltd."},
+ {0x006D, "BriarTek, Inc."},
+ {0x006E, "Summit Data Communications, Inc."},
+ {0x006F, "Sound ID"},
+ {0x0070, "Monster, LLC"},
+ {0x0071, "connectBlue AB"},
+ {0x0072, "ShangHai Super Smart Electronics Co. Ltd."},
+ {0x0073, "Group Sense Ltd."},
+ {0x0074, "Zomm, LLC"},
+ {0x0075, "Samsung Electronics Co. Ltd."},
+ {0x0076, "Creative Technology Ltd."},
+ {0x0077, "Laird Technologies"},
+ {0x0078, "Nike, Inc."},
+ {0x0079, "lesswire AG"},
+ {0x007A, "MStar Semiconductor, Inc."},
+ {0x007B, "Hanlynn Technologies"},
+ {0x007C, "A & R Cambridge"},
+ {0x007D, "Seers Technology Co. Ltd."},
+ {0xFFFF, "For use in internal and interoperability tests."},
+ {0, NULL }
};
static const value_string evt_service_types[] = {
- {0x00, "No Traffic Available"},
- {0x01, "Best Effort Available"},
- {0x02, "Guaranteed Available"},
- {0, NULL }
+ {0x00, "No Traffic Available"},
+ {0x01, "Best Effort Available"},
+ {0x02, "Guaranteed Available"},
+ {0, NULL }
};
static const value_string evt_role_vals[] = {
- {0x00, "Currently the Master for specified BD_ADDR"},
- {0x01, "Currently the Slave for specified BD_ADDR"},
- {0, NULL }
+ {0x00, "Currently the Master for specified BD_ADDR"},
+ {0x01, "Currently the Slave for specified BD_ADDR"},
+ {0, NULL }
};
static const value_string evt_role_vals_handle[] = {
- {0x00, "Currently the Master for this connection handle"},
- {0x01, "Currently the Slave for this connection handle"},
- {0, NULL }
+ {0x00, "Currently the Master for this connection handle"},
+ {0x01, "Currently the Slave for this connection handle"},
+ {0, NULL }
};
static const value_string evt_modes[] = {
- {0x00, "Active Mode"},
- {0x01, "Hold Mode"},
- {0x02, "Sniff Mode"},
- {0x03, "Park Mode"},
- {0, NULL }
+ {0x00, "Active Mode"},
+ {0x01, "Hold Mode"},
+ {0x02, "Sniff Mode"},
+ {0x03, "Park Mode"},
+ {0, NULL }
};
static const value_string evt_key_types[] = {
- {0x00, "Combination Key"},
- {0x01, "Local Unit Key"},
- {0x02, "Remote Unit Key"},
- {0x03, "Debug Combination Key"},
- {0x04, "Unauthenticated Combination Key"},
- {0x05, "Authenticated Combination Key"},
- {0x06, "Changed Combination Key"},
- {0, NULL }
+ {0x00, "Combination Key"},
+ {0x01, "Local Unit Key"},
+ {0x02, "Remote Unit Key"},
+ {0x03, "Debug Combination Key"},
+ {0x04, "Unauthenticated Combination Key"},
+ {0x05, "Authenticated Combination Key"},
+ {0x06, "Changed Combination Key"},
+ {0, NULL }
};
static const value_string evt_page_scan_modes[] = {
- {0x00, "Mandatory Page Scan Mode"},
- {0x01, "Optional Page Scan Mode I"},
- {0x02, "Optional Page Scan Mode II"},
- {0x03, "Optional Page Scan Mode III"},
- {0, NULL }
+ {0x00, "Mandatory Page Scan Mode"},
+ {0x01, "Optional Page Scan Mode I"},
+ {0x02, "Optional Page Scan Mode II"},
+ {0x03, "Optional Page Scan Mode III"},
+ {0, NULL }
};
static const value_string evt_page_scan_repetition_modes[] = {
- {0x00, "R0"},
- {0x01, "R1"},
- {0x02, "R2"},
- {0, NULL }
+ {0x00, "R0"},
+ {0x01, "R1"},
+ {0x02, "R2"},
+ {0, NULL }
};
static const value_string evt_page_scan_period_modes[] = {
- {0x00, "P0"},
- {0x01, "P1"},
- {0x02, "P2"},
- {0, NULL }
+ {0x00, "P0"},
+ {0x01, "P1"},
+ {0x02, "P2"},
+ {0, NULL }
};
static const value_string evt_scan_types[] = {
- {0x00, "Standard Scan" },
- {0x01, "Interlaced Scan" },
- {0, NULL }
+ {0x00, "Standard Scan" },
+ {0x01, "Interlaced Scan" },
+ {0, NULL }
};
static const value_string evt_inq_modes[] = {
- {0x00, "Standard Results" },
- {0x01, "Results With RSSI" },
- {0x02, "Results With RSSI or Extended Results" },
- {0, NULL }
+ {0x00, "Standard Results" },
+ {0x01, "Results With RSSI" },
+ {0x02, "Results With RSSI or Extended Results" },
+ {0, NULL }
};
static const value_string evt_power_level_types[] = {
- {0x00, "Read Current Transmission Power Level" },
- {0x01, "Read Maximum Transmission Power Level" },
- {0, NULL }
+ {0x00, "Read Current Transmission Power Level" },
+ {0x01, "Read Maximum Transmission Power Level" },
+ {0, NULL }
};
static const value_string evt_boolean[] = {
- {0x0 , "False" },
- {0x1 , "True" },
- {0, NULL }
+ {0x0 , "False" },
+ {0x1 , "True" },
+ {0, NULL }
};
static const value_string evt_pin_types[] = {
- {0x00, "Variable PIN" },
- {0x01, "Fixed PIN" },
- {0, NULL }
+ {0x00, "Variable PIN" },
+ {0x01, "Fixed PIN" },
+ {0, NULL }
};
static const value_string evt_scan_enable_values[] = {
- {0x00, "No Scans enabled" },
- {0x01, "Inquiry Scan enabled/Page Scan disable" },
- {0x02, "Inquiry Scan disabled/Page Scan enabled" },
- {0x03, "Inquiry Scan enabled/Page Scan enabled" },
- {0, NULL }
+ {0x00, "No Scans enabled" },
+ {0x01, "Inquiry Scan enabled/Page Scan disable" },
+ {0x02, "Inquiry Scan disabled/Page Scan enabled" },
+ {0x03, "Inquiry Scan enabled/Page Scan enabled" },
+ {0, NULL }
};
static const value_string evt_auth_enable_values[] = {
- {0x00, "Disabled" },
- {0x01, "Enabled for all connections "},
- {0, NULL }
+ {0x00, "Disabled" },
+ {0x01, "Enabled for all connections "},
+ {0, NULL }
};
static const value_string evt_enable_values[] = {
- {0x00, "Disabled" },
- {0x01, "Enabled"},
- {0, NULL }
+ {0x00, "Disabled" },
+ {0x01, "Enabled"},
+ {0, NULL }
};
static const value_string evt_input_coding_values[] = {
- {0x0, "Linear" },
- {0x1, "\xb5-law" },
- {0x2, "A-law" },
- {0, NULL }
+ {0x0, "Linear" },
+ {0x1, "\xb5-law" },
+ {0x2, "A-law" },
+ {0, NULL }
};
static const value_string evt_input_data_format_values[] = {
- {0x0, "1's complement" },
- {0x1, "2's complement" },
- {0x2, "Sign-Magnitude" },
- {0, NULL }
+ {0x0, "1's complement" },
+ {0x1, "2's complement" },
+ {0x2, "Sign-Magnitude" },
+ {0, NULL }
};
static const value_string evt_input_sample_size_values[] = {
- {0x0, "8 bit (only for Linear PCM)" },
- {0x1, "16 bit (only for Linear PCM)" },
- {0, NULL }
+ {0x0, "8 bit (only for Linear PCM)" },
+ {0x1, "16 bit (only for Linear PCM)" },
+ {0, NULL }
};
static const value_string evt_loopback_modes[] = {
- {0x00, "No Loopback mode enabled" },
- {0x01, "Enable Local Loopback" },
- {0x02, "Enable Remote Loopback" },
- {0, NULL }
+ {0x00, "No Loopback mode enabled" },
+ {0x01, "Enable Local Loopback" },
+ {0x02, "Enable Remote Loopback" },
+ {0, NULL }
};
static const value_string evt_country_code_values[] = {
- {0x0, "North America & Europe (except France) and Japan" },
- {0x1, "France" },
- {0, NULL }
+ {0x0, "North America & Europe (except France) and Japan" },
+ {0x1, "France" },
+ {0, NULL }
};
static const value_string evt_air_mode_values[] = {
- {0x0, "\xb5-law" },
- {0x1, "A-law" },
- {0x2, "CVSD" },
- {0x3, "Transparent" },
- {0, NULL }
+ {0x0, "\xb5-law" },
+ {0x1, "A-law" },
+ {0x2, "CVSD" },
+ {0x3, "Transparent" },
+ {0, NULL }
};
static const value_string evt_flow_direction_values[] = {
- {0x0, "Outgoing Traffic" },
- {0x1, "Incoming Traffic" },
- {0, NULL }
+ {0x0, "Outgoing Traffic" },
+ {0x1, "Incoming Traffic" },
+ {0, NULL }
};
static const value_string evt_notification_type_vals[] = {
- {0x0, "Passkey Entry Started" },
- {0x1, "Passkey Digit Entered" },
- {0x2, "Passkey Digit Erased" },
- {0x3, "Passkey Cleared" },
- {0x4, "Passkey Entry Completed" },
- {0, NULL }
+ {0x0, "Passkey Entry Started" },
+ {0x1, "Passkey Digit Entered" },
+ {0x2, "Passkey Digit Erased" },
+ {0x3, "Passkey Cleared" },
+ {0x4, "Passkey Entry Completed" },
+ {0, NULL }
};
static int
dissect_bthci_evt_bd_addr(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- guint8 i, bd_addr[6];
- proto_item *handle_item;
+ guint8 i, bd_addr[6];
+ proto_item *handle_item;
- for(i=6; i; i--)
- bd_addr[6-i] = tvb_get_guint8(tvb, offset+i-1);
+ for(i=6; i; i--)
+ bd_addr[6-i] = tvb_get_guint8(tvb, offset+i-1);
- handle_item = proto_tree_add_item(tree, hf_bthci_evt_bd_addr, tvb, offset, 6, ENC_NA);
- proto_item_append_text(handle_item, "%02x%02x:%02x:%02x%02x%02x (%s)",
- bd_addr[0], bd_addr[1], bd_addr[2], bd_addr[3], bd_addr[4], bd_addr[5],
- get_ether_name(bd_addr));
+ handle_item = proto_tree_add_item(tree, hf_bthci_evt_bd_addr, tvb, offset, 6, ENC_NA);
+ proto_item_append_text(handle_item, "%02x%02x:%02x:%02x%02x%02x (%s)",
+ bd_addr[0], bd_addr[1], bd_addr[2], bd_addr[3], bd_addr[4], bd_addr[5],
+ get_ether_name(bd_addr));
- offset+=6;
+ offset+=6;
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_cod(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- guint8 cod1, cod2;
- proto_item *item;
-
- item = proto_tree_add_item(tree, hf_bthci_evt_class_of_device, tvb, offset, 3, ENC_LITTLE_ENDIAN);
-
- cod1 = tvb_get_guint8(tvb, offset+1);
- cod2 = tvb_get_guint8(tvb, offset+2);
-
- if( (cod2 != 0) || (cod1 & 0x20) )
- {
- char buf[128];
-
- buf[0] = 0;
-
- proto_item_append_text(item, " (%s - services:", val_to_str_ext_const(cod1 & 0x1f, &bthci_cmd_major_dev_class_vals_ext, "???"));
- if (cod2 & 0x80) g_strlcat(buf, " Information,", sizeof(buf));
- if (cod2 & 0x40) g_strlcat(buf, " Telephony,", sizeof(buf));
- if (cod2 & 0x20) g_strlcat(buf, " Audio,", sizeof(buf));
- if (cod2 & 0x10) g_strlcat(buf, " Object transfer,", sizeof(buf));
- if (cod2 & 0x08) g_strlcat(buf, " Capturing,", sizeof(buf));
- if (cod2 & 0x04) g_strlcat(buf, " Rendering,", sizeof(buf));
- if (cod2 & 0x02) g_strlcat(buf, " Networking,", sizeof(buf));
- if (cod2 & 0x01) g_strlcat(buf, " Positioning,", sizeof(buf));
- if (cod1 & 0x20) g_strlcat(buf, " Limited discoverable mode,", sizeof(buf));
-
- buf[strlen(buf)-1] = 0; /* skip last comma */
-
- g_strlcat(buf, ")", sizeof(buf));
- proto_item_append_text(item, "%s", buf);
- }
- else
- {
- proto_item_append_text(item, " (%s - no major services)", val_to_str_ext_const(cod1 & 0x1f, &bthci_cmd_major_dev_class_vals_ext, "???"));
- }
-
- return offset+3;
+ guint8 cod1, cod2;
+ proto_item *item;
+
+ item = proto_tree_add_item(tree, hf_bthci_evt_class_of_device, tvb, offset, 3, ENC_LITTLE_ENDIAN);
+
+ cod1 = tvb_get_guint8(tvb, offset+1);
+ cod2 = tvb_get_guint8(tvb, offset+2);
+
+ if ((cod2 != 0) || (cod1 & 0x20))
+ {
+ char buf[128];
+
+ buf[0] = 0;
+
+ proto_item_append_text(item, " (%s - services:", val_to_str_ext_const(cod1 & 0x1f, &bthci_cmd_major_dev_class_vals_ext, "???"));
+ if (cod2 & 0x80) g_strlcat(buf, " Information,", sizeof(buf));
+ if (cod2 & 0x40) g_strlcat(buf, " Telephony,", sizeof(buf));
+ if (cod2 & 0x20) g_strlcat(buf, " Audio,", sizeof(buf));
+ if (cod2 & 0x10) g_strlcat(buf, " Object transfer,", sizeof(buf));
+ if (cod2 & 0x08) g_strlcat(buf, " Capturing,", sizeof(buf));
+ if (cod2 & 0x04) g_strlcat(buf, " Rendering,", sizeof(buf));
+ if (cod2 & 0x02) g_strlcat(buf, " Networking,", sizeof(buf));
+ if (cod2 & 0x01) g_strlcat(buf, " Positioning,", sizeof(buf));
+ if (cod1 & 0x20) g_strlcat(buf, " Limited discoverable mode,", sizeof(buf));
+
+ buf[strlen(buf)-1] = 0; /* skip last comma */
+
+ g_strlcat(buf, ")", sizeof(buf));
+ proto_item_append_text(item, "%s", buf);
+ }
+ else
+ {
+ proto_item_append_text(item, " (%s - no major services)", val_to_str_ext_const(cod1 & 0x1f, &bthci_cmd_major_dev_class_vals_ext, "???"));
+ }
+
+ return offset+3;
}
static int
dissect_bthci_evt_inq_complete(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_conn_complete(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
+ offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
- proto_tree_add_item(tree, hf_bthci_evt_link_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_link_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_encryption_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_encryption_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_conn_request(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
+ offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
- offset = dissect_bthci_evt_cod(tvb, offset, pinfo, tree);
+ offset = dissect_bthci_evt_cod(tvb, offset, pinfo, tree);
- proto_tree_add_item(tree, hf_bthci_evt_link_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_link_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_disconn_complete(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- proto_tree_add_item(tree, hf_bthci_evt_reason, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_reason, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_auth_complete(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_lmp_features(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- guint8 fc_lag;
- proto_item *item;
- proto_item *ti_lmp_features=NULL;
- proto_item *ti_lmp_subtree=NULL;
-
- if(tree){
- ti_lmp_features=proto_tree_add_text(tree, tvb, offset, 8, "LMP_Features");
- ti_lmp_subtree=proto_item_add_subtree(ti_lmp_features, ett_lmp_subtree);
- }
-
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_00, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_01, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_02, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_03, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_04, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_05, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_06, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_07, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
-
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_10, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_11, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_12, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_13, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_14, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_15, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_16, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_17, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
-
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_20, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_21, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_22, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_23, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- item = proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_24, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- fc_lag = (tvb_get_guint8(tvb, offset) & 0x70)>>4;
- proto_item_append_text(item, " (%i bytes)", 256*fc_lag);
-
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_27, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
-
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_31, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_32, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_33, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_34, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_35, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_36, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_37, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
-
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_40, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_41, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_43, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_44, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_47, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
-
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_50, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_51, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_52, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_53, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_54, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_55, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_56, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_57, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
-
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_60, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_63, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_64, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_65, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_66, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
-
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_70, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_71, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_77, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
-
- return offset;
+ guint8 fc_lag;
+ proto_item *item;
+ proto_item *ti_lmp_features = NULL;
+ proto_item *ti_lmp_subtree = NULL;
+
+ if(tree){
+ ti_lmp_features=proto_tree_add_text(tree, tvb, offset, 8, "LMP_Features");
+ ti_lmp_subtree=proto_item_add_subtree(ti_lmp_features, ett_lmp_subtree);
+ }
+
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_00, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_01, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_02, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_03, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_04, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_05, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_06, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_07, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_10, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_11, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_12, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_13, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_14, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_15, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_16, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_17, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_20, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_21, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_22, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_23, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ item = proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_24, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ fc_lag = (tvb_get_guint8(tvb, offset) & 0x70)>>4;
+ proto_item_append_text(item, " (%i bytes)", 256*fc_lag);
+
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_27, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_31, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_32, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_33, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_34, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_35, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_36, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_37, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_40, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_41, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_43, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_44, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_47, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_50, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_51, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_52, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_53, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_54, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_55, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_56, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_57, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_60, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_63, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_64, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_65, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_66, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_70, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_71, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_lmp_subtree,hf_bthci_evt_lmp_feature_77, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+
+ return offset;
}
static int
dissect_bthci_evt_pin_code_request(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
+ offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_link_key_request(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
+ offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_link_key_notification(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
+ offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
- proto_tree_add_item(tree, hf_bthci_evt_link_key, tvb, offset, 16, ENC_NA);
- offset+=16;
+ proto_tree_add_item(tree, hf_bthci_evt_link_key, tvb, offset, 16, ENC_NA);
+ offset+=16;
- proto_tree_add_item(tree, hf_bthci_evt_key_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset+=1;
+ proto_tree_add_item(tree, hf_bthci_evt_key_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset+=1;
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_return_link_keys(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- guint8 evt_num_keys;
+ guint8 evt_num_keys;
- evt_num_keys = tvb_get_guint8(tvb, offset);
- proto_tree_add_item(tree, hf_bthci_evt_num_keys, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ evt_num_keys = tvb_get_guint8(tvb, offset);
+ proto_tree_add_item(tree, hf_bthci_evt_num_keys, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- while(evt_num_keys--){
- offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
+ while(evt_num_keys--){
+ offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
- proto_tree_add_item(tree, hf_bthci_evt_link_key, tvb, offset, 16, ENC_NA);
- offset+=16;
+ proto_tree_add_item(tree, hf_bthci_evt_link_key, tvb, offset, 16, ENC_NA);
+ offset+=16;
- }
+ }
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_read_remote_support_features_complete(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree)
{
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- offset=dissect_bthci_evt_lmp_features(tvb, offset, pinfo,tree);
+ offset=dissect_bthci_evt_lmp_features(tvb, offset, pinfo,tree);
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_remote_name_req_complete(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
+ offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
- proto_tree_add_item(tree, hf_bthci_evt_remote_name, tvb, offset, 248, ENC_ASCII|ENC_NA);
- offset+=248;
+ proto_tree_add_item(tree, hf_bthci_evt_remote_name, tvb, offset, 248, ENC_ASCII|ENC_NA);
+ offset+=248;
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_read_remote_version_information_complete(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- proto_tree_add_item(tree, hf_bthci_evt_vers_nr, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_vers_nr, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_comp_id, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_comp_id, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- proto_tree_add_item(tree, hf_bthci_evt_sub_vers_nr, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_sub_vers_nr, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_flush_occured(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_number_of_completed_packets(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- guint8 evt_num_handles;
+ guint8 evt_num_handles;
- evt_num_handles = tvb_get_guint8(tvb, offset);
- proto_tree_add_item(tree, hf_bthci_evt_num_handles, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ evt_num_handles = tvb_get_guint8(tvb, offset);
+ proto_tree_add_item(tree, hf_bthci_evt_num_handles, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- while(evt_num_handles--){
- proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ while(evt_num_handles--){
+ proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- proto_tree_add_item(tree, hf_bthci_evt_num_compl_packets, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_num_compl_packets, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- }
+ }
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_mode_change(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- proto_item *handle_item;
+ proto_item *handle_item;
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- proto_tree_add_item(tree, hf_bthci_evt_curr_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_curr_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- handle_item = proto_tree_add_item(tree, hf_bthci_evt_interval, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_item_append_text(handle_item, " Baseband slots (%f msec)", tvb_get_letohs(tvb, offset)*0.625);
- offset+=2;
+ handle_item = proto_tree_add_item(tree, hf_bthci_evt_interval, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_item_append_text(handle_item, " Baseband slots (%f msec)", tvb_get_letohs(tvb, offset)*0.625);
+ offset+=2;
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_role_change(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
+ offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
- proto_tree_add_item(tree, hf_bthci_evt_role, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_role, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_hardware_error(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- proto_tree_add_item(tree, hf_bthci_evt_hardware_code, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_hardware_code, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_loopback_command(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- tvbuff_t *next_tvb;
+ tvbuff_t *next_tvb;
- next_tvb = tvb_new_subset(tvb, offset, tvb_length_remaining(tvb, offset), -1);
- if(bthci_com_handle){
- call_dissector(bthci_com_handle, next_tvb, pinfo, tree);
- }
- offset+=tvb_length_remaining(tvb, offset);
+ next_tvb = tvb_new_subset(tvb, offset, tvb_length_remaining(tvb, offset), -1);
+ if(bthci_com_handle){
+ call_dissector(bthci_com_handle, next_tvb, pinfo, tree);
+ }
+ offset+=tvb_length_remaining(tvb, offset);
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_data_buffer_overflow(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- proto_tree_add_item(tree, hf_bthci_evt_link_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_link_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_read_clock_offset_complete(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- proto_item *handle_item;
- gint16 clk;
+ proto_item *handle_item;
+ gint16 clk;
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- handle_item = proto_tree_add_item(tree, hf_bthci_evt_clock_offset, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- clk=tvb_get_letohs(tvb, offset) & 32767; /* only bit0-14 are valid */
- proto_item_append_text(handle_item, " (%g ms)", 1.25*clk);
- offset+=2;
+ handle_item = proto_tree_add_item(tree, hf_bthci_evt_clock_offset, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ clk=tvb_get_letohs(tvb, offset) & 32767; /* only bit0-14 are valid */
+ proto_item_append_text(handle_item, " (%g ms)", 1.25*clk);
+ offset+=2;
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_max_slots_change(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- proto_tree_add_item(tree, hf_bthci_evt_max_slots, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_max_slots, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_qos_violation(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_conn_packet_type_changed(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- guint16 flags;
- proto_tree *handle_tree=NULL;
- proto_item *ti_ptype_subtree=NULL;
-
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
-
- flags=tvb_get_letohs(tvb, offset);
- proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
-
- handle_tree = proto_tree_add_text(tree, tvb, offset, 2, "Usable packet types: ");
- ti_ptype_subtree = proto_item_add_subtree(handle_tree, ett_ptype_subtree);
-
- if (flags & 0x0008)
- proto_item_append_text(handle_tree, "DM1 ");
- if (flags & 0x0010)
- proto_item_append_text(handle_tree, "DH1 ");
- if (flags & 0x0400)
- proto_item_append_text(handle_tree, "DM3 ");
- if (flags & 0x0800)
- proto_item_append_text(handle_tree, "DH3 ");
- if (flags & 0x4000)
- proto_item_append_text(handle_tree, "DM5 ");
- if (flags & 0x8000)
- proto_item_append_text(handle_tree, "DH5 ");
- if (flags & 0x0020)
- proto_item_append_text(handle_tree, "HV1 ");
- if (flags & 0x0040)
- proto_item_append_text(handle_tree, "HV2 ");
- if (flags & 0x0080)
- proto_item_append_text(handle_tree, "HV3 ");
- if (flags & 0x0002)
- proto_item_append_text(handle_tree, "2-DH1 ");
- if (flags & 0x0004)
- proto_item_append_text(handle_tree, "3-DH1 ");
- if (flags & 0x0100)
- proto_item_append_text(handle_tree, "2-DH3 ");
- if (flags & 0x0200)
- proto_item_append_text(handle_tree, "3-DH3 ");
- if (flags & 0x1000)
- proto_item_append_text(handle_tree, "2-DH5 ");
- if (flags & 0x2000)
- proto_item_append_text(handle_tree, "3-DH5 ");
-
- proto_tree_add_item(ti_ptype_subtree, hf_bthci_evt_link_type_2dh1, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_ptype_subtree, hf_bthci_evt_link_type_3dh1, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_ptype_subtree, hf_bthci_evt_link_type_dm1, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_ptype_subtree, hf_bthci_evt_link_type_dh1, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_ptype_subtree, hf_bthci_evt_link_type_2dh3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_ptype_subtree, hf_bthci_evt_link_type_3dh3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_ptype_subtree, hf_bthci_evt_link_type_dm3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_ptype_subtree, hf_bthci_evt_link_type_dh3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_ptype_subtree, hf_bthci_evt_link_type_2dh5, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_ptype_subtree, hf_bthci_evt_link_type_3dh5, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_ptype_subtree, hf_bthci_evt_link_type_dm5, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_ptype_subtree, hf_bthci_evt_link_type_dh5, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_ptype_subtree, hf_bthci_evt_link_type_hv1, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_ptype_subtree, hf_bthci_evt_link_type_hv2, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_ptype_subtree, hf_bthci_evt_link_type_hv3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
-
- return offset;
+ guint16 flags;
+ proto_tree *handle_tree=NULL;
+ proto_item *ti_ptype_subtree=NULL;
+
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+
+ flags=tvb_get_letohs(tvb, offset);
+ proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+
+ handle_tree = proto_tree_add_text(tree, tvb, offset, 2, "Usable packet types: ");
+ ti_ptype_subtree = proto_item_add_subtree(handle_tree, ett_ptype_subtree);
+
+ if (flags & 0x0008)
+ proto_item_append_text(handle_tree, "DM1 ");
+ if (flags & 0x0010)
+ proto_item_append_text(handle_tree, "DH1 ");
+ if (flags & 0x0400)
+ proto_item_append_text(handle_tree, "DM3 ");
+ if (flags & 0x0800)
+ proto_item_append_text(handle_tree, "DH3 ");
+ if (flags & 0x4000)
+ proto_item_append_text(handle_tree, "DM5 ");
+ if (flags & 0x8000)
+ proto_item_append_text(handle_tree, "DH5 ");
+ if (flags & 0x0020)
+ proto_item_append_text(handle_tree, "HV1 ");
+ if (flags & 0x0040)
+ proto_item_append_text(handle_tree, "HV2 ");
+ if (flags & 0x0080)
+ proto_item_append_text(handle_tree, "HV3 ");
+ if (flags & 0x0002)
+ proto_item_append_text(handle_tree, "2-DH1 ");
+ if (flags & 0x0004)
+ proto_item_append_text(handle_tree, "3-DH1 ");
+ if (flags & 0x0100)
+ proto_item_append_text(handle_tree, "2-DH3 ");
+ if (flags & 0x0200)
+ proto_item_append_text(handle_tree, "3-DH3 ");
+ if (flags & 0x1000)
+ proto_item_append_text(handle_tree, "2-DH5 ");
+ if (flags & 0x2000)
+ proto_item_append_text(handle_tree, "3-DH5 ");
+
+ proto_tree_add_item(ti_ptype_subtree, hf_bthci_evt_link_type_2dh1, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_ptype_subtree, hf_bthci_evt_link_type_3dh1, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_ptype_subtree, hf_bthci_evt_link_type_dm1, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_ptype_subtree, hf_bthci_evt_link_type_dh1, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_ptype_subtree, hf_bthci_evt_link_type_2dh3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_ptype_subtree, hf_bthci_evt_link_type_3dh3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_ptype_subtree, hf_bthci_evt_link_type_dm3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_ptype_subtree, hf_bthci_evt_link_type_dh3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_ptype_subtree, hf_bthci_evt_link_type_2dh5, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_ptype_subtree, hf_bthci_evt_link_type_3dh5, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_ptype_subtree, hf_bthci_evt_link_type_dm5, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_ptype_subtree, hf_bthci_evt_link_type_dh5, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_ptype_subtree, hf_bthci_evt_link_type_hv1, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_ptype_subtree, hf_bthci_evt_link_type_hv2, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_ptype_subtree, hf_bthci_evt_link_type_hv3, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+
+ return offset;
}
static int
dissect_bthci_evt_command_status(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree)
{
- guint8 status_code;
- guint16 opcode;
+ guint8 status_code;
+ guint16 opcode;
- status_code = tvb_get_guint8(tvb, offset);
+ status_code = tvb_get_guint8(tvb, offset);
- if( status_code != 0) {
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- }
- else {
- proto_tree_add_item(tree, hf_bthci_evt_status_pending, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- }
- offset++;
+ if (status_code != 0) {
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ }
+ else {
+ proto_tree_add_item(tree, hf_bthci_evt_status_pending, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ }
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_num_command_packets, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_num_command_packets, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- opcode = tvb_get_letohs(tvb, offset);
- proto_tree_add_item(tree, hf_bthci_evt_com_opcode, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ opcode = tvb_get_letohs(tvb, offset);
+ proto_tree_add_item(tree, hf_bthci_evt_com_opcode, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- col_append_fstr(pinfo->cinfo, COL_INFO, " (%s)",
- val_to_str_ext(opcode, &bthci_cmd_opcode_vals_ext, "Unknown 0x%08x"));
+ col_append_fstr(pinfo->cinfo, COL_INFO, " (%s)",
+ val_to_str_ext(opcode, &bthci_cmd_opcode_vals_ext, "Unknown 0x%08x"));
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_page_scan_mode_change(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
+ offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
- proto_tree_add_item(tree, hf_bthci_evt_page_scan_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_page_scan_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_page_scan_repetition_mode_change(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
+ offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
- proto_tree_add_item(tree, hf_bthci_evt_page_scan_repetition_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_page_scan_repetition_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_inq_result_with_rssi(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- guint8 num, evt_num_responses;
+ guint8 num, evt_num_responses;
- evt_num_responses = tvb_get_guint8(tvb, offset);
- proto_tree_add_item(tree, hf_bthci_evt_num_responses, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ evt_num_responses = tvb_get_guint8(tvb, offset);
+ proto_tree_add_item(tree, hf_bthci_evt_num_responses, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- for(num=0;num<evt_num_responses;num++){
- offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
+ for(num=0;num<evt_num_responses;num++){
+ offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
- proto_tree_add_item(tree, hf_bthci_evt_page_scan_repetition_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_page_scan_repetition_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- /* reserved byte */
- offset++;
+ /* reserved byte */
+ offset++;
- offset = dissect_bthci_evt_cod(tvb, offset, pinfo, tree);
+ offset = dissect_bthci_evt_cod(tvb, offset, pinfo, tree);
- proto_tree_add_item(tree, hf_bthci_evt_clock_offset, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_clock_offset, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- proto_tree_add_item(tree, hf_bthci_evt_rssi, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_rssi, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- }
+ }
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_ext_inquiry_response(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- guint8 i, j, length, type;
- proto_item *ti_eir=NULL;
- proto_item *ti_eir_subtree=NULL;
-
- if(tree){
- ti_eir=proto_tree_add_text(tree, tvb, offset, 240, "Extended Inquiry Response Data");
- ti_eir_subtree=proto_item_add_subtree(ti_eir, ett_eir_subtree);
- }
-
- i=0;
- while(i<240){
- length = tvb_get_guint8(tvb, offset+i);
- if( length != 0 ){
-
- proto_item *ti_eir_struct=NULL;
- proto_tree *ti_eir_struct_subtree=NULL;
-
- ti_eir_struct = proto_tree_add_text(ti_eir_subtree, tvb, offset+i, length+1, "%s", "");
- ti_eir_struct_subtree = proto_item_add_subtree(ti_eir_struct, ett_eir_struct_subtree);
-
- type = tvb_get_guint8(tvb, offset+i+1);
-
- proto_item_append_text(ti_eir_struct,"%s", val_to_str_ext_const(type, &bthci_cmd_eir_data_type_vals_ext, "Unknown"));
-
- proto_tree_add_item(ti_eir_struct_subtree,hf_bthci_evt_eir_struct_length, tvb, offset+i, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(ti_eir_struct_subtree,hf_bthci_evt_eir_struct_type, tvb, offset+i+1, 1, ENC_LITTLE_ENDIAN);
-
- switch(type) {
- case 0x02: /* 16-bit Service Class UUIDs, incomplete list */
- case 0x03: /* 16-bit Service Class UUIDs, complete list */
- j=0;
- while(j<(length-1))
- {
- proto_tree_add_item(ti_eir_struct_subtree, hf_bthci_evt_sc_uuid16, tvb, offset+i+j+2, 2, ENC_LITTLE_ENDIAN);
- j+=2;
- }
- break;
- case 0x04: /* 32-bit Service Class UUIDs, incomplete list */
- case 0x05: /* 32-bit Service Class UUIDs, complete list */
- j=0;
- while(j<(length-1))
- {
- proto_tree_add_item(ti_eir_struct_subtree, hf_bthci_evt_sc_uuid32, tvb, offset+i+j+2, 4, ENC_LITTLE_ENDIAN);
- j+=4;
- }
- break;
- case 0x06: /* 128-bit Service Class UUIDs, incomplete list */
- case 0x07: /* 128-bit Service Class UUIDs, complete list */
- j=0;
- while(j<(length-1))
- {
- proto_tree_add_item(ti_eir_struct_subtree, hf_bthci_evt_sc_uuid128, tvb, offset+i+j+2, 16, ENC_NA);
- j+=16;
- }
- break;
- case 0x08: /* Device Name, shortened */
- case 0x09: /* Device Name, full */
- proto_tree_add_item(ti_eir_struct_subtree, hf_bthci_evt_device_name, tvb, offset+i+2, length-1, ENC_ASCII|ENC_NA);
- proto_item_append_text(ti_eir_struct,": %s", tvb_format_text(tvb,offset+i+2,length-1));
- break;
- case 0x0A: /* Tx Power Level */
- proto_tree_add_item(ti_eir_struct_subtree, hf_bthci_evt_transmit_power_level, tvb, offset+i+2, 1, ENC_LITTLE_ENDIAN);
-
- default:
- proto_tree_add_item(ti_eir_struct_subtree, hf_bthci_evt_eir_data, tvb, offset+i+2, length-1, ENC_NA);
- break;
- }
- i += length+1;
- }
- else {
- break;
- }
- }
-
- return offset+240;
+ guint8 i, j, length, type;
+ proto_item *ti_eir = NULL;
+ proto_item *ti_eir_subtree = NULL;
+
+ if(tree){
+ ti_eir=proto_tree_add_text(tree, tvb, offset, 240, "Extended Inquiry Response Data");
+ ti_eir_subtree=proto_item_add_subtree(ti_eir, ett_eir_subtree);
+ }
+
+ i=0;
+ while(i<240){
+ length = tvb_get_guint8(tvb, offset+i);
+ if (length != 0) {
+
+ proto_item *ti_eir_struct=NULL;
+ proto_tree *ti_eir_struct_subtree=NULL;
+
+ ti_eir_struct = proto_tree_add_text(ti_eir_subtree, tvb, offset+i, length+1, "%s", "");
+ ti_eir_struct_subtree = proto_item_add_subtree(ti_eir_struct, ett_eir_struct_subtree);
+
+ type = tvb_get_guint8(tvb, offset+i+1);
+
+ proto_item_append_text(ti_eir_struct,"%s", val_to_str_ext_const(type, &bthci_cmd_eir_data_type_vals_ext, "Unknown"));
+
+ proto_tree_add_item(ti_eir_struct_subtree,hf_bthci_evt_eir_struct_length, tvb, offset+i, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(ti_eir_struct_subtree,hf_bthci_evt_eir_struct_type, tvb, offset+i+1, 1, ENC_LITTLE_ENDIAN);
+
+ switch(type) {
+ case 0x02: /* 16-bit Service Class UUIDs, incomplete list */
+ case 0x03: /* 16-bit Service Class UUIDs, complete list */
+ j=0;
+ while(j<(length-1))
+ {
+ proto_tree_add_item(ti_eir_struct_subtree, hf_bthci_evt_sc_uuid16, tvb, offset+i+j+2, 2, ENC_LITTLE_ENDIAN);
+ j+=2;
+ }
+ break;
+ case 0x04: /* 32-bit Service Class UUIDs, incomplete list */
+ case 0x05: /* 32-bit Service Class UUIDs, complete list */
+ j=0;
+ while(j<(length-1))
+ {
+ proto_tree_add_item(ti_eir_struct_subtree, hf_bthci_evt_sc_uuid32, tvb, offset+i+j+2, 4, ENC_LITTLE_ENDIAN);
+ j+=4;
+ }
+ break;
+ case 0x06: /* 128-bit Service Class UUIDs, incomplete list */
+ case 0x07: /* 128-bit Service Class UUIDs, complete list */
+ j=0;
+ while(j<(length-1))
+ {
+ proto_tree_add_item(ti_eir_struct_subtree, hf_bthci_evt_sc_uuid128, tvb, offset+i+j+2, 16, ENC_NA);
+ j+=16;
+ }
+ break;
+ case 0x08: /* Device Name, shortened */
+ case 0x09: /* Device Name, full */
+ proto_tree_add_item(ti_eir_struct_subtree, hf_bthci_evt_device_name, tvb, offset+i+2, length-1, ENC_ASCII|ENC_NA);
+ proto_item_append_text(ti_eir_struct,": %s", tvb_format_text(tvb,offset+i+2,length-1));
+ break;
+ case 0x0A: /* Tx Power Level */
+ proto_tree_add_item(ti_eir_struct_subtree, hf_bthci_evt_transmit_power_level, tvb, offset+i+2, 1, ENC_LITTLE_ENDIAN);
+
+ default:
+ proto_tree_add_item(ti_eir_struct_subtree, hf_bthci_evt_eir_data, tvb, offset+i+2, length-1, ENC_NA);
+ break;
+ }
+ i += length+1;
+ }
+ else {
+ break;
+ }
+ }
+
+ return offset+240;
}
static int
dissect_bthci_evt_io_capability_request(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
+ offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_io_capability_response(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
+ offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
- proto_tree_add_item(tree, hf_bthci_evt_io_capability, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_io_capability, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_oob_data_present, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_oob_data_present, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_auth_requirements, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_auth_requirements, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_user_confirmation_request(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
+ offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
- proto_tree_add_item(tree, hf_bthci_evt_numeric_value, tvb, offset, 4, ENC_LITTLE_ENDIAN);
- offset+=4;
+ proto_tree_add_item(tree, hf_bthci_evt_numeric_value, tvb, offset, 4, ENC_LITTLE_ENDIAN);
+ offset+=4;
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_user_passkey_request(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
+ offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_remote_oob_data_request(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
+ offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_simple_pairing_complete(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
+ offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_user_passkey_notification(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
+ offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
- proto_tree_add_item(tree, hf_bthci_evt_passkey, tvb, offset, 4, ENC_LITTLE_ENDIAN);
- offset+=4;
+ proto_tree_add_item(tree, hf_bthci_evt_passkey, tvb, offset, 4, ENC_LITTLE_ENDIAN);
+ offset+=4;
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_keypress_notification(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
+ offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
- proto_tree_add_item(tree, hf_bthci_evt_notification_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_notification_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_remote_host_sup_feat_notification(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
+ offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
- proto_tree_add_item(tree, hf_bthci_evt_ext_lmp_features, tvb, offset, 8, ENC_LITTLE_ENDIAN);
- offset+=8;
+ proto_tree_add_item(tree, hf_bthci_evt_ext_lmp_features, tvb, offset, 8, ENC_LITTLE_ENDIAN);
+ offset+=8;
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_command_complete(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- proto_item *ti_opcode=NULL;
- proto_tree *opcode_tree=NULL;
- proto_item *item;
- gint16 timeout;
- guint8 num8, i;
- guint16 com_opcode;
- guint32 accuracy;
-
- proto_tree_add_item(tree, hf_bthci_evt_num_command_packets, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
-
- com_opcode = tvb_get_letohs(tvb, offset);
- ti_opcode = proto_tree_add_item(tree, hf_bthci_evt_com_opcode, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- opcode_tree = proto_item_add_subtree(ti_opcode, ett_opcode);
- proto_tree_add_item(opcode_tree, hf_bthci_evt_ogf, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(opcode_tree, hf_bthci_evt_ocf, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
-
- col_append_fstr(pinfo->cinfo, COL_INFO, " (%s)",
- val_to_str_ext(com_opcode, &bthci_cmd_opcode_vals_ext, "Unknown 0x%08x"));
-
- switch(com_opcode) {
- /* This is a list of Commands that all return just the status */
- case 0x0402: /* Inquiry Cancel */
- case 0x0403: /* Periodic Inquiry Mode */
- case 0x0404: /* Exit Periodic Enquiry Mode */
- case 0x080f: /* Write Default Link Policy Settings */
- case 0x0c01: /* Set Event Mask */
- case 0x0c03: /* Reset */
- case 0x0c05: /* Set Event Filter */
- case 0x0c0a: /* Write PIN Type */
- case 0x0c0b: /* Create Unit Key */
- case 0x0c13: /* Change Local Name */
- case 0x0c16: /* Write Connection Accept Timeout */
- case 0x0c18: /* Write Page Timeout */
- case 0x0c1a: /* Write Scan Enable */
- case 0x0c1c: /* Write Page Scan Activity */
- case 0x0c1e: /* Write Inquiry Scan Activity */
- case 0x0c20: /* Write Authentication Enable */
- case 0x0c22: /* Write Encryption Mode */
- case 0x0c24: /* Write Class of Device */
- case 0x0c26: /* Write Voice Setting */
- case 0x0c2a: /* Write Num Broadcast Retransmissions */
- case 0x0c2c: /* Write Hold Mode Activity */
- case 0x0c2f: /* Write SCO Flow Control Enable */
- case 0x0c31: /* Set Host Controller To Host Flow Control */
- case 0x0c33: /* Host Buffer Size */
- case 0x0c3a: /* Write Current IAC LAP */
- case 0x0c3c: /* Write Page Scan Period Mode */
- case 0x0c3e: /* Write Page Scan Mode */
- case 0x0c3f: /* Set AFH Host Channel Classification */
- case 0x0c43: /* Write Inquiry Scan Type */
- case 0x0c45: /* Write Inquiry Mode */
- case 0x0c47: /* Write Page Scan Type */
- case 0x0c49: /* Write AFH Channel Assessment Mode */
- case 0x0c52: /* Write Extended Inquiry Response */
- case 0x0c53: /* Refresh Encryption Key */
- case 0x0c56: /* Write Simple Pairing Mode */
- case 0x0c59: /* Write Inquiry Tx Power Level */
- case 0x0c5b: /* Write Default Erroneous Data Reporting */
- case 0x0c60: /* Send Keypress Notification */
- case 0x1802: /* Write Loopback Mode */
- case 0x1803: /* Enable Device Under Test Mode */
- case 0x1804: /* Write Simple Pairing Debug Mode */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
-
- /* This is a list of Commands that all return status and BD_ADDR */
- case 0x0408: /* Create Connection Cancel */
- case 0x040b: /* Link Key Request Reply */
- case 0x040c: /* Link Key Request Negative Reply */
- case 0x040d: /* PIN Code Request Reply */
- case 0x040e: /* PIN Code Request Negative Reply */
- case 0x041a: /* Remote Name Request Cancel */
- case 0x042b: /* IO Capability Response */
- case 0x042c: /* User Confirmation Request Reply */
- case 0x042d: /* User Confirmation Request Negative Reply */
- case 0x042e: /* User Passkey Request Reply */
- case 0x042f: /* User Passkey Request Negative Reply */
- case 0x0430: /* Remote OOB Data Request Reply */
- case 0x0433: /* Remote OOB Data Request Negative Reply */
- case 0x1009: /* Read BD_ADDR */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
-
- offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
-
- break;
-
- /* This is a list of Commands that all return status and connection_handle */
- case 0x080d: /* Write Link Policy Settings */
- case 0x0811: /* Sniff Subrating */
- case 0x0c08: /* Flush */
- case 0x0c28: /* Write Automatic Flush Timeout */
- case 0x0c37: /* Write Link Supervision Timeout */
- case 0x0c5f: /* Enhanced Flush */
- case 0x1402: /* Reset Failed Contact Counter */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
-
- proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
-
- break;
-
- /* This is a list of Commands that all return status and timeout */
- case 0x0c15: /* Read Connection Accept Timeout */
- case 0x0c17: /* Read Page Timeout */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
-
- timeout = tvb_get_letohs(tvb, offset);
- item = proto_tree_add_item(tree, hf_bthci_evt_timeout, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_item_append_text(item, " slots (%g msec)", timeout*0.625);
- offset+=2;
-
- break;
-
- /* This is a list of Commands that all return status, connection handle and timeout */
- case 0x0c27: /* Read Automatic Flush Timeout */
- case 0x0c36: /* Read Link Supervision Timeout */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
-
- proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
-
- timeout = tvb_get_letohs(tvb, offset);
- item = proto_tree_add_item(tree, hf_bthci_evt_timeout, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_item_append_text(item, " slots (%g msec)", timeout*0.625);
- offset+=2;
-
- break;
-
- /* This is a list of Commands that all return status, interval and window */
- case 0x0c1b: /* Read Page Scan Activity */
- case 0x0c1d: /* Read Inquiry Scan Activity */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
-
- proto_tree_add_item(tree, hf_bthci_evt_interval, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
-
- proto_tree_add_item(tree, hf_bthci_evt_window, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
-
- break;
-
- case 0x0420: /* Read LMP Handle */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
-
- proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_item *ti_opcode=NULL;
+ proto_tree *opcode_tree=NULL;
+ proto_item *item;
+ gint16 timeout;
+ guint8 num8, i;
+ guint16 com_opcode;
+ guint32 accuracy;
+
+ proto_tree_add_item(tree, hf_bthci_evt_num_command_packets, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+
+ com_opcode = tvb_get_letohs(tvb, offset);
+ ti_opcode = proto_tree_add_item(tree, hf_bthci_evt_com_opcode, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ opcode_tree = proto_item_add_subtree(ti_opcode, ett_opcode);
+ proto_tree_add_item(opcode_tree, hf_bthci_evt_ogf, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(opcode_tree, hf_bthci_evt_ocf, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+
+ col_append_fstr(pinfo->cinfo, COL_INFO, " (%s)",
+ val_to_str_ext(com_opcode, &bthci_cmd_opcode_vals_ext, "Unknown 0x%08x"));
+
+ switch(com_opcode) {
+ /* This is a list of Commands that all return just the status */
+ case 0x0402: /* Inquiry Cancel */
+ case 0x0403: /* Periodic Inquiry Mode */
+ case 0x0404: /* Exit Periodic Enquiry Mode */
+ case 0x080f: /* Write Default Link Policy Settings */
+ case 0x0c01: /* Set Event Mask */
+ case 0x0c03: /* Reset */
+ case 0x0c05: /* Set Event Filter */
+ case 0x0c0a: /* Write PIN Type */
+ case 0x0c0b: /* Create Unit Key */
+ case 0x0c13: /* Change Local Name */
+ case 0x0c16: /* Write Connection Accept Timeout */
+ case 0x0c18: /* Write Page Timeout */
+ case 0x0c1a: /* Write Scan Enable */
+ case 0x0c1c: /* Write Page Scan Activity */
+ case 0x0c1e: /* Write Inquiry Scan Activity */
+ case 0x0c20: /* Write Authentication Enable */
+ case 0x0c22: /* Write Encryption Mode */
+ case 0x0c24: /* Write Class of Device */
+ case 0x0c26: /* Write Voice Setting */
+ case 0x0c2a: /* Write Num Broadcast Retransmissions */
+ case 0x0c2c: /* Write Hold Mode Activity */
+ case 0x0c2f: /* Write SCO Flow Control Enable */
+ case 0x0c31: /* Set Host Controller To Host Flow Control */
+ case 0x0c33: /* Host Buffer Size */
+ case 0x0c3a: /* Write Current IAC LAP */
+ case 0x0c3c: /* Write Page Scan Period Mode */
+ case 0x0c3e: /* Write Page Scan Mode */
+ case 0x0c3f: /* Set AFH Host Channel Classification */
+ case 0x0c43: /* Write Inquiry Scan Type */
+ case 0x0c45: /* Write Inquiry Mode */
+ case 0x0c47: /* Write Page Scan Type */
+ case 0x0c49: /* Write AFH Channel Assessment Mode */
+ case 0x0c52: /* Write Extended Inquiry Response */
+ case 0x0c53: /* Refresh Encryption Key */
+ case 0x0c56: /* Write Simple Pairing Mode */
+ case 0x0c59: /* Write Inquiry Tx Power Level */
+ case 0x0c5b: /* Write Default Erroneous Data Reporting */
+ case 0x0c60: /* Send Keypress Notification */
+ case 0x1802: /* Write Loopback Mode */
+ case 0x1803: /* Enable Device Under Test Mode */
+ case 0x1804: /* Write Simple Pairing Debug Mode */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
+
+ /* This is a list of Commands that all return status and BD_ADDR */
+ case 0x0408: /* Create Connection Cancel */
+ case 0x040b: /* Link Key Request Reply */
+ case 0x040c: /* Link Key Request Negative Reply */
+ case 0x040d: /* PIN Code Request Reply */
+ case 0x040e: /* PIN Code Request Negative Reply */
+ case 0x041a: /* Remote Name Request Cancel */
+ case 0x042b: /* IO Capability Response */
+ case 0x042c: /* User Confirmation Request Reply */
+ case 0x042d: /* User Confirmation Request Negative Reply */
+ case 0x042e: /* User Passkey Request Reply */
+ case 0x042f: /* User Passkey Request Negative Reply */
+ case 0x0430: /* Remote OOB Data Request Reply */
+ case 0x0433: /* Remote OOB Data Request Negative Reply */
+ case 0x1009: /* Read BD_ADDR */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+
+ offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
+
+ break;
+
+ /* This is a list of Commands that all return status and connection_handle */
+ case 0x080d: /* Write Link Policy Settings */
+ case 0x0811: /* Sniff Subrating */
+ case 0x0c08: /* Flush */
+ case 0x0c28: /* Write Automatic Flush Timeout */
+ case 0x0c37: /* Write Link Supervision Timeout */
+ case 0x0c5f: /* Enhanced Flush */
+ case 0x1402: /* Reset Failed Contact Counter */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+
+ proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+
+ break;
+
+ /* This is a list of Commands that all return status and timeout */
+ case 0x0c15: /* Read Connection Accept Timeout */
+ case 0x0c17: /* Read Page Timeout */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+
+ timeout = tvb_get_letohs(tvb, offset);
+ item = proto_tree_add_item(tree, hf_bthci_evt_timeout, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_item_append_text(item, " slots (%g msec)", timeout*0.625);
+ offset+=2;
+
+ break;
+
+ /* This is a list of Commands that all return status, connection handle and timeout */
+ case 0x0c27: /* Read Automatic Flush Timeout */
+ case 0x0c36: /* Read Link Supervision Timeout */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+
+ proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+
+ timeout = tvb_get_letohs(tvb, offset);
+ item = proto_tree_add_item(tree, hf_bthci_evt_timeout, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_item_append_text(item, " slots (%g msec)", timeout*0.625);
+ offset+=2;
+
+ break;
+
+ /* This is a list of Commands that all return status, interval and window */
+ case 0x0c1b: /* Read Page Scan Activity */
+ case 0x0c1d: /* Read Inquiry Scan Activity */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+
+ proto_tree_add_item(tree, hf_bthci_evt_interval, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+
+ proto_tree_add_item(tree, hf_bthci_evt_window, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+
+ break;
+
+ case 0x0420: /* Read LMP Handle */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+
+ proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- proto_tree_add_item(tree, hf_bthci_evt_lmp_handle, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_lmp_handle, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- /* 4 reserved bytes */
- offset+=4;
- break;
+ /* 4 reserved bytes */
+ offset+=4;
+ break;
- case 0x0809: /* Role Discovery */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ case 0x0809: /* Role Discovery */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- proto_tree_add_item(tree, hf_bthci_evt_curr_role, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_curr_role, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- break;
+ break;
- case 0x080c: /* Read Link Policy Settings */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ case 0x080c: /* Read Link Policy Settings */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- proto_tree_add_item(tree, hf_bthci_evt_link_policy_setting_switch, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_evt_link_policy_setting_hold , tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_evt_link_policy_setting_sniff , tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_evt_link_policy_setting_park , tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_link_policy_setting_switch, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_evt_link_policy_setting_hold , tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_evt_link_policy_setting_sniff , tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_evt_link_policy_setting_park , tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- break;
+ break;
- case 0x080e: /* Read Default Link Policy Settings */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ case 0x080e: /* Read Default Link Policy Settings */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_link_policy_setting_switch, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_evt_link_policy_setting_hold , tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_evt_link_policy_setting_sniff , tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_evt_link_policy_setting_park , tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_link_policy_setting_switch, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_evt_link_policy_setting_hold , tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_evt_link_policy_setting_sniff , tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_evt_link_policy_setting_park , tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- break;
+ break;
- case 0x0c09: /* Read PIN Type */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ case 0x0c09: /* Read PIN Type */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_pin_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_pin_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- break;
+ break;
- case 0x0c0d: /* Read Stored Link Key */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ case 0x0c0d: /* Read Stored Link Key */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_max_num_keys, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_max_num_keys, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- proto_tree_add_item(tree, hf_bthci_evt_num_keys_read, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_num_keys_read, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- break;
+ break;
- case 0x0c11: /* Write Stored Link Key */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ case 0x0c11: /* Write Stored Link Key */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_num_keys_written, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_num_keys_written, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- break;
+ break;
- case 0x0c12: /* Delete Stored Link Key */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ case 0x0c12: /* Delete Stored Link Key */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_num_keys_deleted, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_num_keys_deleted, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- break;
+ break;
- case 0x0c14: /* Read Local Name */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ case 0x0c14: /* Read Local Name */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_device_name, tvb, offset, 248, ENC_ASCII|ENC_NA);
- offset+=248;
+ proto_tree_add_item(tree, hf_bthci_evt_device_name, tvb, offset, 248, ENC_ASCII|ENC_NA);
+ offset+=248;
- break;
+ break;
- case 0x0c19: /* Read Scan Enable */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ case 0x0c19: /* Read Scan Enable */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_scan_enable, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_scan_enable, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- break;
+ break;
- case 0x0c1f: /* Read Authentication Enable */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ case 0x0c1f: /* Read Authentication Enable */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_authentication_enable, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_authentication_enable, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- break;
+ break;
- case 0x0c21: /* Read Encryption Mode */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ case 0x0c21: /* Read Encryption Mode */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_encryption_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_encryption_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- break;
+ break;
- case 0x0c23: /* Read Class of Device */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ case 0x0c23: /* Read Class of Device */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- offset = dissect_bthci_evt_cod(tvb, offset, pinfo, tree);
+ offset = dissect_bthci_evt_cod(tvb, offset, pinfo, tree);
- break;
+ break;
- case 0x0c25: /* Read Voice Setting */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ case 0x0c25: /* Read Voice Setting */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_input_coding, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_evt_input_data_format, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_evt_input_sample_size, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_input_coding, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_evt_input_data_format, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_evt_input_sample_size, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- break;
+ break;
- case 0x0c29: /* Read Num Broadcast Retransmissions */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ case 0x0c29: /* Read Num Broadcast Retransmissions */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_num_broadcast_retransm, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_num_broadcast_retransm, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- break;
+ break;
- case 0x0c2b: /* Read Hold Mode Activity */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ case 0x0c2b: /* Read Hold Mode Activity */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_hold_mode_act_page, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_evt_hold_mode_act_inquiry, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_tree_add_item(tree, hf_bthci_evt_hold_mode_act_periodic, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_hold_mode_act_page, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_evt_hold_mode_act_inquiry, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_tree_add_item(tree, hf_bthci_evt_hold_mode_act_periodic, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- break;
+ break;
- case 0x0c2d: /* Read Transmit Power Level */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ case 0x0c2d: /* Read Transmit Power Level */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- proto_tree_add_item(tree, hf_bthci_evt_transmit_power_level, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_transmit_power_level, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- break;
+ break;
- case 0x0c2e: /* Read SCO Flow Control Enable */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ case 0x0c2e: /* Read SCO Flow Control Enable */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_sco_flow_cont_enable, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_sco_flow_cont_enable, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- break;
+ break;
- case 0x0c38: /* Read Number of Supported IAC */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ case 0x0c38: /* Read Number of Supported IAC */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_num_supp_iac, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_num_supp_iac, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- break;
+ break;
- case 0x0c39: /* Read Current IAC LAP */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ case 0x0c39: /* Read Current IAC LAP */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- num8 = tvb_get_guint8(tvb, offset);
- proto_tree_add_item(tree, hf_bthci_evt_num_curr_iac, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ num8 = tvb_get_guint8(tvb, offset);
+ proto_tree_add_item(tree, hf_bthci_evt_num_curr_iac, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- for (i=0; i<num8; i++) {
- proto_tree_add_item(tree, hf_bthci_evt_iac_lap, tvb, offset, 3, ENC_LITTLE_ENDIAN);
- offset+=3;
- }
- break;
+ for (i=0; i<num8; i++) {
+ proto_tree_add_item(tree, hf_bthci_evt_iac_lap, tvb, offset, 3, ENC_LITTLE_ENDIAN);
+ offset+=3;
+ }
+ break;
- case 0x0c3b: /* Read Page Scan Period Mode */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ case 0x0c3b: /* Read Page Scan Period Mode */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_page_scan_period_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_page_scan_period_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- break;
+ break;
- case 0x0c3d: /* Read Page Scan Mode */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ case 0x0c3d: /* Read Page Scan Mode */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_page_scan_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_page_scan_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- break;
+ break;
- case 0x0c42: /* Read Inquiry Scan Type */
- case 0x0c46: /* Read Page Scan Type */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- proto_tree_add_item(tree, hf_bthci_evt_scan_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
+ case 0x0c42: /* Read Inquiry Scan Type */
+ case 0x0c46: /* Read Page Scan Type */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_scan_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
- case 0x0c44: /* Read Inquiry Mode */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- proto_tree_add_item(tree, hf_bthci_evt_inq_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
+ case 0x0c44: /* Read Inquiry Mode */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_inq_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
- case 0x0c48: /* Read AFH Channel Assessment Mode */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- proto_tree_add_item(tree, hf_bthci_evt_afh_ch_assessment_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
+ case 0x0c48: /* Read AFH Channel Assessment Mode */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_afh_ch_assessment_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
- case 0x0c51: /* Read Extended Inquiry Response */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ case 0x0c51: /* Read Extended Inquiry Response */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_fec_required, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_fec_required, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- offset=dissect_bthci_evt_ext_inquiry_response(tvb, offset, pinfo, tree);
- break;
+ offset=dissect_bthci_evt_ext_inquiry_response(tvb, offset, pinfo, tree);
+ break;
- case 0x0c55: /* Read Simple Pairing Mode */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ case 0x0c55: /* Read Simple Pairing Mode */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_simple_pairing_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
+ proto_tree_add_item(tree, hf_bthci_evt_simple_pairing_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
- case 0x0c57: /* Read Local OOB Data */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- proto_tree_add_item(tree, hf_bthci_evt_hash_c, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- proto_tree_add_item(tree, hf_bthci_evt_randomizer_r, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- break;
+ case 0x0c57: /* Read Local OOB Data */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_hash_c, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_randomizer_r, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ break;
- case 0x0c58: /* Read Inquiry Response Tx Power Level */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- proto_tree_add_item(tree, hf_bthci_evt_power_level_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
- break;
+ case 0x0c58: /* Read Inquiry Response Tx Power Level */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_power_level_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
+ break;
- case 0x0c5a: /* Read Default Erroneous Data Reporting */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ case 0x0c5a: /* Read Default Erroneous Data Reporting */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_err_data_reporting, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_err_data_reporting, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- break;
+ break;
- case 0x1001: /* Read Local Version Information */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ case 0x1001: /* Read Local Version Information */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_hci_vers_nr, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_hci_vers_nr, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_hci_revision, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_hci_revision, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- proto_tree_add_item(tree, hf_bthci_evt_vers_nr, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_vers_nr, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_comp_id, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_comp_id, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- proto_tree_add_item(tree, hf_bthci_evt_sub_vers_nr, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_sub_vers_nr, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- break;
+ break;
- case 0x1002: /* Read Local Supported Commands */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ case 0x1002: /* Read Local Supported Commands */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_local_supported_cmds, tvb, offset, 64, ENC_NA);
- offset+=64;
+ proto_tree_add_item(tree, hf_bthci_evt_local_supported_cmds, tvb, offset, 64, ENC_NA);
+ offset+=64;
- break;
+ break;
- case 0x1003: /* Read Local Supported Features */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ case 0x1003: /* Read Local Supported Features */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- offset=dissect_bthci_evt_lmp_features(tvb, offset, pinfo, tree);
+ offset=dissect_bthci_evt_lmp_features(tvb, offset, pinfo, tree);
- break;
+ break;
- case 0x1004: /* Read Local Extended Features */
- {
- guint8 page_number;
+ case 0x1004: /* Read Local Extended Features */
+ {
+ guint8 page_number;
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- page_number = tvb_get_guint8(tvb, offset);
- proto_tree_add_item(tree, hf_bthci_evt_page_number, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ page_number = tvb_get_guint8(tvb, offset);
+ proto_tree_add_item(tree, hf_bthci_evt_page_number, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_max_page_number, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_max_page_number, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- if( page_number == 0 ){
- offset=dissect_bthci_evt_lmp_features(tvb, offset, pinfo, tree);
- }
- else {
- proto_tree_add_item(tree, hf_bthci_evt_ext_lmp_features, tvb, offset, 8, ENC_LITTLE_ENDIAN);
- offset+=8;
- }
- }
+ if (page_number == 0) {
+ offset=dissect_bthci_evt_lmp_features(tvb, offset, pinfo, tree);
+ }
+ else {
+ proto_tree_add_item(tree, hf_bthci_evt_ext_lmp_features, tvb, offset, 8, ENC_LITTLE_ENDIAN);
+ offset+=8;
+ }
+ }
- break;
+ break;
- case 0x1005: /* Read Buffer Size */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ case 0x1005: /* Read Buffer Size */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_host_data_packet_length_acl, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_host_data_packet_length_acl, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- proto_tree_add_item(tree, hf_bthci_evt_host_data_packet_length_sco, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_host_data_packet_length_sco, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_host_total_num_acl_data_packets, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_host_total_num_acl_data_packets, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- proto_tree_add_item(tree, hf_bthci_evt_host_total_num_sco_data_packets, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_host_total_num_sco_data_packets, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- break;
+ break;
- case 0x1007: /* Read Country Code */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ case 0x1007: /* Read Country Code */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_country_code, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_country_code, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- break;
+ break;
- case 0x1401: /* Read Failed Contact Counter */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ case 0x1401: /* Read Failed Contact Counter */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- proto_tree_add_item(tree, hf_bthci_evt_failed_contact_counter, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_failed_contact_counter, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- break;
+ break;
- case 0x1403: /* Get Link Quality */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ case 0x1403: /* Get Link Quality */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- proto_tree_add_item(tree, hf_bthci_evt_link_quality, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_link_quality, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- break;
+ break;
- case 0x1405: /* Read RSSI */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ case 0x1405: /* Read RSSI */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- proto_tree_add_item(tree, hf_bthci_evt_rssi, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_rssi, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- break;
+ break;
- case 0x1406: /* Read AFH Channel Map */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ case 0x1406: /* Read AFH Channel Map */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- proto_tree_add_item(tree, hf_bthci_evt_afh_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_afh_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_afh_channel_map, tvb, offset, 10, ENC_LITTLE_ENDIAN);
- offset+=10;
+ proto_tree_add_item(tree, hf_bthci_evt_afh_channel_map, tvb, offset, 10, ENC_LITTLE_ENDIAN);
+ offset+=10;
- break;
+ break;
- case 0x1407: /* Read Clock */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ case 0x1407: /* Read Clock */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- proto_tree_add_item(tree, hf_bthci_evt_clock, tvb, offset, 4, ENC_LITTLE_ENDIAN);
- offset+=4;
+ proto_tree_add_item(tree, hf_bthci_evt_clock, tvb, offset, 4, ENC_LITTLE_ENDIAN);
+ offset+=4;
- accuracy = tvb_get_letohl(tvb, offset);
- item = proto_tree_add_item(tree, hf_bthci_evt_clock_accuracy, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_item_append_text(item, " %g msec", accuracy*0.3125);
- offset+=2;
+ accuracy = tvb_get_letohl(tvb, offset);
+ item = proto_tree_add_item(tree, hf_bthci_evt_clock_accuracy, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_item_append_text(item, " %g msec", accuracy*0.3125);
+ offset+=2;
- break;
+ break;
- case 0x1801: /* Read Loopback Mode */
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ case 0x1801: /* Read Loopback Mode */
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_loopback_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_loopback_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- break;
+ break;
- default:
- proto_tree_add_item(tree, hf_bthci_evt_ret_params, tvb, offset, -1, ENC_NA);
- offset+=tvb_length_remaining(tvb, offset);
- break;
- }
+ default:
+ proto_tree_add_item(tree, hf_bthci_evt_ret_params, tvb, offset, -1, ENC_NA);
+ offset+=tvb_length_remaining(tvb, offset);
+ break;
+ }
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_qos_setup_complete(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- proto_tree_add_item(tree, hf_bthci_evt_flags, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_flags, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_service_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_service_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_token_rate, tvb, offset, 4, ENC_LITTLE_ENDIAN);
- offset+=4;
+ proto_tree_add_item(tree, hf_bthci_evt_token_rate, tvb, offset, 4, ENC_LITTLE_ENDIAN);
+ offset+=4;
- proto_tree_add_item(tree, hf_bthci_evt_peak_bandwidth, tvb, offset, 4, ENC_LITTLE_ENDIAN);
- offset+=4;
+ proto_tree_add_item(tree, hf_bthci_evt_peak_bandwidth, tvb, offset, 4, ENC_LITTLE_ENDIAN);
+ offset+=4;
- proto_tree_add_item(tree, hf_bthci_evt_latency, tvb, offset, 4, ENC_LITTLE_ENDIAN);
- offset+=4;
+ proto_tree_add_item(tree, hf_bthci_evt_latency, tvb, offset, 4, ENC_LITTLE_ENDIAN);
+ offset+=4;
- proto_tree_add_item(tree, hf_bthci_evt_delay_variation, tvb, offset, 4, ENC_LITTLE_ENDIAN);
- offset+=4;
+ proto_tree_add_item(tree, hf_bthci_evt_delay_variation, tvb, offset, 4, ENC_LITTLE_ENDIAN);
+ offset+=4;
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_change_conn_link_key_complete(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_master_link_key_complete(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- proto_tree_add_item(tree, hf_bthci_evt_key_flag, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_key_flag, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_encryption_change(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- proto_tree_add_item(tree, hf_bthci_evt_encryption_enable, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_encryption_enable, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_read_remote_ext_features_complete(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- guint8 page_number;
+ guint8 page_number;
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- page_number = tvb_get_guint8(tvb, offset);
- proto_tree_add_item(tree, hf_bthci_evt_page_number, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ page_number = tvb_get_guint8(tvb, offset);
+ proto_tree_add_item(tree, hf_bthci_evt_page_number, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_max_page_number, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_max_page_number, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- if( page_number == 0 ){
- offset=dissect_bthci_evt_lmp_features(tvb, offset, pinfo, tree);
- }
- else {
- proto_tree_add_item(tree, hf_bthci_evt_ext_lmp_features, tvb, offset, 8, ENC_LITTLE_ENDIAN);
- offset+=8;
- }
+ if (page_number == 0) {
+ offset=dissect_bthci_evt_lmp_features(tvb, offset, pinfo, tree);
+ }
+ else {
+ proto_tree_add_item(tree, hf_bthci_evt_ext_lmp_features, tvb, offset, 8, ENC_LITTLE_ENDIAN);
+ offset+=8;
+ }
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_sync_connection_complete(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- proto_item *item;
+ proto_item *item;
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
+ offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
- proto_tree_add_item(tree, hf_bthci_evt_sync_link_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_sync_link_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- item = proto_tree_add_item(tree, hf_bthci_evt_sync_tx_interval, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_item_append_text(item, " slots (%g msec)", tvb_get_guint8(tvb, offset)*0.625);
- offset++;
+ item = proto_tree_add_item(tree, hf_bthci_evt_sync_tx_interval, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_item_append_text(item, " slots (%g msec)", tvb_get_guint8(tvb, offset)*0.625);
+ offset++;
- item = proto_tree_add_item(tree, hf_bthci_evt_sync_rtx_window, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_item_append_text(item, " slots (%g msec)", tvb_get_guint8(tvb, offset)*0.625);
- offset++;
+ item = proto_tree_add_item(tree, hf_bthci_evt_sync_rtx_window, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_item_append_text(item, " slots (%g msec)", tvb_get_guint8(tvb, offset)*0.625);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_sync_rx_packet_length, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_sync_rx_packet_length, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- proto_tree_add_item(tree, hf_bthci_evt_sync_tx_packet_length, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_sync_tx_packet_length, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- proto_tree_add_item(tree, hf_bthci_evt_air_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_air_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_sync_connection_changed(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- proto_item *item;
+ proto_item *item;
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- item = proto_tree_add_item(tree, hf_bthci_evt_sync_tx_interval, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_item_append_text(item, " slots (%g msec)", tvb_get_guint8(tvb, offset)*0.625);
- offset++;
+ item = proto_tree_add_item(tree, hf_bthci_evt_sync_tx_interval, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_item_append_text(item, " slots (%g msec)", tvb_get_guint8(tvb, offset)*0.625);
+ offset++;
- item = proto_tree_add_item(tree, hf_bthci_evt_sync_rtx_window, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_item_append_text(item, " slots (%g msec)", tvb_get_guint8(tvb, offset)*0.625);
- offset++;
+ item = proto_tree_add_item(tree, hf_bthci_evt_sync_rtx_window, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_item_append_text(item, " slots (%g msec)", tvb_get_guint8(tvb, offset)*0.625);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_sync_rx_packet_length, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_sync_rx_packet_length, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- proto_tree_add_item(tree, hf_bthci_evt_sync_tx_packet_length, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_sync_tx_packet_length, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_sniff_subrating(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- proto_item *item;
+ proto_item *item;
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- item = proto_tree_add_item(tree, hf_bthci_evt_max_tx_latency, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_item_append_text(item, " slots (%g msec)", tvb_get_letohs(tvb, offset)*0.625);
- offset+=2;
+ item = proto_tree_add_item(tree, hf_bthci_evt_max_tx_latency, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_item_append_text(item, " slots (%g msec)", tvb_get_letohs(tvb, offset)*0.625);
+ offset+=2;
- item = proto_tree_add_item(tree, hf_bthci_evt_max_rx_latency, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_item_append_text(item, " slots (%g msec)", tvb_get_letohs(tvb, offset)*0.625);
- offset+=2;
+ item = proto_tree_add_item(tree, hf_bthci_evt_max_rx_latency, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_item_append_text(item, " slots (%g msec)", tvb_get_letohs(tvb, offset)*0.625);
+ offset+=2;
- item = proto_tree_add_item(tree, hf_bthci_evt_min_remote_timeout, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_item_append_text(item, " slots (%g msec)", tvb_get_letohs(tvb, offset)*0.625);
- offset+=2;
+ item = proto_tree_add_item(tree, hf_bthci_evt_min_remote_timeout, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_item_append_text(item, " slots (%g msec)", tvb_get_letohs(tvb, offset)*0.625);
+ offset+=2;
- item = proto_tree_add_item(tree, hf_bthci_evt_min_local_timeout, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_item_append_text(item, " slots (%g msec)", tvb_get_letohs(tvb, offset)*0.625);
- offset+=2;
+ item = proto_tree_add_item(tree, hf_bthci_evt_min_local_timeout, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_item_append_text(item, " slots (%g msec)", tvb_get_letohs(tvb, offset)*0.625);
+ offset+=2;
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_flow_specification_complete(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- proto_tree_add_item(tree, hf_bthci_evt_flags, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_flags, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_flow_direction, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_flow_direction, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_service_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_service_type, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_token_rate, tvb, offset, 4, ENC_LITTLE_ENDIAN);
- offset+=4;
+ proto_tree_add_item(tree, hf_bthci_evt_token_rate, tvb, offset, 4, ENC_LITTLE_ENDIAN);
+ offset+=4;
- proto_tree_add_item(tree, hf_bthci_evt_token_bucket_size, tvb, offset, 4, ENC_LITTLE_ENDIAN);
- offset+=4;
+ proto_tree_add_item(tree, hf_bthci_evt_token_bucket_size, tvb, offset, 4, ENC_LITTLE_ENDIAN);
+ offset+=4;
- proto_tree_add_item(tree, hf_bthci_evt_peak_bandwidth, tvb, offset, 4, ENC_LITTLE_ENDIAN);
- offset+=4;
+ proto_tree_add_item(tree, hf_bthci_evt_peak_bandwidth, tvb, offset, 4, ENC_LITTLE_ENDIAN);
+ offset+=4;
- proto_tree_add_item(tree, hf_bthci_evt_latency, tvb, offset, 4, ENC_LITTLE_ENDIAN);
- offset+=4;
+ proto_tree_add_item(tree, hf_bthci_evt_latency, tvb, offset, 4, ENC_LITTLE_ENDIAN);
+ offset+=4;
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_enhanced_flush_complete(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_encryption_key_refresh_complete(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_status, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_link_supervision_timeout_changed(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- proto_item *item;
+ proto_item *item;
- proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(tree, hf_bthci_evt_connection_handle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- item = proto_tree_add_item(tree, hf_bthci_evt_link_supervision_timeout, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- proto_item_append_text(item, " slots (%g msec)", tvb_get_letohs(tvb, offset)*0.625);
- offset+=2;
+ item = proto_tree_add_item(tree, hf_bthci_evt_link_supervision_timeout, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ proto_item_append_text(item, " slots (%g msec)", tvb_get_letohs(tvb, offset)*0.625);
+ offset+=2;
- return offset;
+ return offset;
}
static int
dissect_bthci_evt_inq_result(tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree)
{
- guint8 num, evt_num_responses;
+ guint8 num, evt_num_responses;
- evt_num_responses = tvb_get_guint8(tvb, offset);
- proto_tree_add_item(tree, hf_bthci_evt_num_responses, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ evt_num_responses = tvb_get_guint8(tvb, offset);
+ proto_tree_add_item(tree, hf_bthci_evt_num_responses, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- for(num=0;num<evt_num_responses;num++){
- offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
+ for(num=0;num<evt_num_responses;num++){
+ offset = dissect_bthci_evt_bd_addr(tvb, offset, pinfo, tree);
- proto_tree_add_item(tree, hf_bthci_evt_page_scan_repetition_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_page_scan_repetition_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_page_scan_period_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_page_scan_period_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(tree, hf_bthci_evt_page_scan_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(tree, hf_bthci_evt_page_scan_mode, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- offset = dissect_bthci_evt_cod(tvb, offset, pinfo, tree);
+ offset = dissect_bthci_evt_cod(tvb, offset, pinfo, tree);
- proto_tree_add_item(tree, hf_bthci_evt_clock_offset, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
- }
+ proto_tree_add_item(tree, hf_bthci_evt_clock_offset, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
+ }
- return offset;
+ return offset;
}
@@ -2365,244 +2365,244 @@ dissect_bthci_evt_inq_result(tvbuff_t *tvb, int offset, packet_info *pinfo _U_,
static int
dissect_bthci_evt(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
{
- proto_item *ti;
- proto_tree *bthci_evt_tree=NULL;
- guint8 param_length, evt_code;
- int offset=0;
+ proto_item *ti;
+ proto_tree *bthci_evt_tree = NULL;
+ guint8 param_length, evt_code;
+ int offset = 0;
- if(tree){
- ti=proto_tree_add_item(tree, proto_bthci_evt, tvb, offset, -1, ENC_NA);
- bthci_evt_tree=proto_item_add_subtree(ti, ett_bthci_evt);
- }
+ if(tree){
+ ti=proto_tree_add_item(tree, proto_bthci_evt, tvb, offset, -1, ENC_NA);
+ bthci_evt_tree=proto_item_add_subtree(ti, ett_bthci_evt);
+ }
- evt_code = tvb_get_guint8(tvb, offset);
- proto_tree_add_item(bthci_evt_tree, hf_bthci_evt_code, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- proto_item_append_text(bthci_evt_tree, " - %s", val_to_str(evt_code, evt_code_vals, "Unknown 0x%08x"));
- offset++;
+ evt_code = tvb_get_guint8(tvb, offset);
+ proto_tree_add_item(bthci_evt_tree, hf_bthci_evt_code, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ proto_item_append_text(bthci_evt_tree, " - %s", val_to_str(evt_code, evt_code_vals, "Unknown 0x%08x"));
+ offset++;
- param_length = tvb_get_guint8(tvb, offset);
- proto_tree_add_item(bthci_evt_tree, hf_bthci_evt_param_length, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ param_length = tvb_get_guint8(tvb, offset);
+ proto_tree_add_item(bthci_evt_tree, hf_bthci_evt_param_length, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- col_set_str(pinfo->cinfo, COL_PROTOCOL, "HCI_EVT");
+ col_set_str(pinfo->cinfo, COL_PROTOCOL, "HCI_EVT");
- col_append_fstr(pinfo->cinfo, COL_INFO, " %s", val_to_str(evt_code, evt_code_vals, "Unknown 0x%08x"));
+ col_append_fstr(pinfo->cinfo, COL_INFO, " %s", val_to_str(evt_code, evt_code_vals, "Unknown 0x%08x"));
- if (param_length > 0) {
- switch(evt_code) {
- case 0x01: /* Inquiry Complete */
- offset=dissect_bthci_evt_inq_complete(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ if (param_length > 0) {
+ switch(evt_code) {
+ case 0x01: /* Inquiry Complete */
+ offset=dissect_bthci_evt_inq_complete(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x02: /* Inquiry result event */
- offset=dissect_bthci_evt_inq_result(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x02: /* Inquiry result event */
+ offset=dissect_bthci_evt_inq_result(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x03: /* Connection Complete */
- offset=dissect_bthci_evt_conn_complete(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x03: /* Connection Complete */
+ offset=dissect_bthci_evt_conn_complete(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x04: /* Connection Request */
- offset=dissect_bthci_evt_conn_request(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x04: /* Connection Request */
+ offset=dissect_bthci_evt_conn_request(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x05: /* Disconnection Complete */
- offset=dissect_bthci_evt_disconn_complete(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x05: /* Disconnection Complete */
+ offset=dissect_bthci_evt_disconn_complete(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x06: /* Authentication Complete */
- offset=dissect_bthci_evt_auth_complete(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x06: /* Authentication Complete */
+ offset=dissect_bthci_evt_auth_complete(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x07: /* Remote Name Request Complete */
- offset=dissect_bthci_evt_remote_name_req_complete(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x07: /* Remote Name Request Complete */
+ offset=dissect_bthci_evt_remote_name_req_complete(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x08: /* Encryption Change */
- offset=dissect_bthci_evt_encryption_change(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x08: /* Encryption Change */
+ offset=dissect_bthci_evt_encryption_change(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x09: /* Change Connection Link Key Complete */
- offset=dissect_bthci_evt_change_conn_link_key_complete(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x09: /* Change Connection Link Key Complete */
+ offset=dissect_bthci_evt_change_conn_link_key_complete(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x0a: /* Master Link Key Complete */
- offset=dissect_bthci_evt_master_link_key_complete(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x0a: /* Master Link Key Complete */
+ offset=dissect_bthci_evt_master_link_key_complete(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x0b: /* Read Remote Support Features Complete */
- offset=dissect_bthci_evt_read_remote_support_features_complete(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x0b: /* Read Remote Support Features Complete */
+ offset=dissect_bthci_evt_read_remote_support_features_complete(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x0c: /* Read Remote Version Information Complete */
- offset=dissect_bthci_evt_read_remote_version_information_complete(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x0c: /* Read Remote Version Information Complete */
+ offset=dissect_bthci_evt_read_remote_version_information_complete(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x0d: /* QoS Setup Complete */
- offset=dissect_bthci_evt_qos_setup_complete(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x0d: /* QoS Setup Complete */
+ offset=dissect_bthci_evt_qos_setup_complete(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x0e: /* Command Complete */
- offset=dissect_bthci_evt_command_complete(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x0e: /* Command Complete */
+ offset=dissect_bthci_evt_command_complete(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x0f: /* Command Status */
- offset=dissect_bthci_evt_command_status(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x0f: /* Command Status */
+ offset=dissect_bthci_evt_command_status(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x10: /* Hardware Error */
- offset=dissect_bthci_evt_hardware_error(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x10: /* Hardware Error */
+ offset=dissect_bthci_evt_hardware_error(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x11: /* Flush Occurred */
- offset=dissect_bthci_evt_flush_occured(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x11: /* Flush Occurred */
+ offset=dissect_bthci_evt_flush_occured(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x12: /* Role Change */
- offset=dissect_bthci_evt_role_change(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x12: /* Role Change */
+ offset=dissect_bthci_evt_role_change(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x13: /* Number Of Completed Packets */
- offset=dissect_bthci_evt_number_of_completed_packets(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x13: /* Number Of Completed Packets */
+ offset=dissect_bthci_evt_number_of_completed_packets(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x14: /* Mode Change */
- offset=dissect_bthci_evt_mode_change(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x14: /* Mode Change */
+ offset=dissect_bthci_evt_mode_change(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x15: /* Return Link Keys */
- offset=dissect_bthci_evt_return_link_keys(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x15: /* Return Link Keys */
+ offset=dissect_bthci_evt_return_link_keys(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x16: /* PIN Code Request */
- offset=dissect_bthci_evt_pin_code_request(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x16: /* PIN Code Request */
+ offset=dissect_bthci_evt_pin_code_request(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x17: /* Link Key Request */
- offset=dissect_bthci_evt_link_key_request(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x17: /* Link Key Request */
+ offset=dissect_bthci_evt_link_key_request(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x18: /* Link Key Notification */
- offset=dissect_bthci_evt_link_key_notification(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x18: /* Link Key Notification */
+ offset=dissect_bthci_evt_link_key_notification(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x19: /* Loopback Command */
- offset=dissect_bthci_evt_loopback_command(tvb, offset, pinfo, bthci_evt_tree);
- break;
-
- case 0x1a: /* Data Buffer Overflow */
- offset=dissect_bthci_evt_data_buffer_overflow(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x19: /* Loopback Command */
+ offset=dissect_bthci_evt_loopback_command(tvb, offset, pinfo, bthci_evt_tree);
+ break;
+
+ case 0x1a: /* Data Buffer Overflow */
+ offset=dissect_bthci_evt_data_buffer_overflow(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x1b: /* Max Slots Change */
- offset=dissect_bthci_evt_max_slots_change(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x1b: /* Max Slots Change */
+ offset=dissect_bthci_evt_max_slots_change(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x1c: /* Read Clock Offset Complete */
- offset=dissect_bthci_evt_read_clock_offset_complete(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x1c: /* Read Clock Offset Complete */
+ offset=dissect_bthci_evt_read_clock_offset_complete(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x1d: /* Connection Packet Type Changed */
- offset=dissect_bthci_evt_conn_packet_type_changed(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x1d: /* Connection Packet Type Changed */
+ offset=dissect_bthci_evt_conn_packet_type_changed(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x1e: /* QoS Violation */
- offset=dissect_bthci_evt_qos_violation(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x1e: /* QoS Violation */
+ offset=dissect_bthci_evt_qos_violation(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x1f: /* Page Scan Mode Change */
- offset=dissect_bthci_evt_page_scan_mode_change(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x1f: /* Page Scan Mode Change */
+ offset=dissect_bthci_evt_page_scan_mode_change(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x20: /* Page Scan Repetition Mode Change */
- offset=dissect_bthci_evt_page_scan_repetition_mode_change(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x20: /* Page Scan Repetition Mode Change */
+ offset=dissect_bthci_evt_page_scan_repetition_mode_change(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x21: /* Flow Specification Complete */
- offset=dissect_bthci_evt_flow_specification_complete(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x21: /* Flow Specification Complete */
+ offset=dissect_bthci_evt_flow_specification_complete(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x22: /* Inquiry Result with RSSI */
- offset=dissect_bthci_evt_inq_result_with_rssi(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x22: /* Inquiry Result with RSSI */
+ offset=dissect_bthci_evt_inq_result_with_rssi(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x23: /* Read Remote Extended Features Complete */
- offset=dissect_bthci_evt_read_remote_ext_features_complete(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x23: /* Read Remote Extended Features Complete */
+ offset=dissect_bthci_evt_read_remote_ext_features_complete(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x2c: /* Synchronous Connection Complete */
- offset=dissect_bthci_evt_sync_connection_complete(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x2c: /* Synchronous Connection Complete */
+ offset=dissect_bthci_evt_sync_connection_complete(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x2d: /* Synchronous Connection Changed */
- offset=dissect_bthci_evt_sync_connection_changed(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x2d: /* Synchronous Connection Changed */
+ offset=dissect_bthci_evt_sync_connection_changed(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x2e: /* Sniff Subrating */
- offset=dissect_bthci_evt_sniff_subrating(tvb, offset, pinfo, bthci_evt_tree);
- break;
+ case 0x2e: /* Sniff Subrating */
+ offset=dissect_bthci_evt_sniff_subrating(tvb, offset, pinfo, bthci_evt_tree);
+ break;
- case 0x2f: /* Extended Inquiry Result */
- offset=dissect_bthci_evt_inq_result_with_rssi(tvb, offset, pinfo, bthci_evt_tree);
- offset=dissect_bthci_evt_ext_inquiry_response(tvb, offset, pinfo, bthci_evt_tree);
- break;
-
- case 0x30: /* Encryption Key Refresh Complete */
- offset=dissect_bthci_evt_encryption_key_refresh_complete(tvb, offset, pinfo, bthci_evt_tree);
- break;
-
- case 0x31: /* IO Capability Request */
- offset=dissect_bthci_evt_io_capability_request(tvb, offset, pinfo, bthci_evt_tree);
- break;
-
- case 0x32: /* IO Capability Response */
- offset=dissect_bthci_evt_io_capability_response(tvb, offset, pinfo, bthci_evt_tree);
- break;
-
- case 0x33: /* User Confirmation Request */
- offset=dissect_bthci_evt_user_confirmation_request(tvb, offset, pinfo, bthci_evt_tree);
- break;
-
- case 0x34: /* User Passkey Request */
- offset=dissect_bthci_evt_user_passkey_request(tvb, offset, pinfo, bthci_evt_tree);
- break;
-
- case 0x35: /* Remote OOB Data Request */
- offset=dissect_bthci_evt_remote_oob_data_request(tvb, offset, pinfo, bthci_evt_tree);
- break;
-
- case 0x36: /* Simple Pairing Complete */
- offset=dissect_bthci_evt_simple_pairing_complete(tvb, offset, pinfo, bthci_evt_tree);
- break;
-
- case 0x38: /* Link Supervision Timeout Changed */
- offset=dissect_bthci_evt_link_supervision_timeout_changed(tvb, offset, pinfo, bthci_evt_tree);
- break;
-
- case 0x39: /* Enhanced Flush Complete */
- offset=dissect_bthci_evt_enhanced_flush_complete(tvb, offset, pinfo, bthci_evt_tree);
- break;
-
- case 0x3b: /* Enhanced Flush Complete */
- offset=dissect_bthci_evt_user_passkey_notification(tvb, offset, pinfo, bthci_evt_tree);
- break;
-
- case 0x3c: /* Enhanced Flush Complete */
- offset=dissect_bthci_evt_keypress_notification(tvb, offset, pinfo, bthci_evt_tree);
- break;
-
- case 0x3d: /* Remote Host Supported Features Notification */
- offset=dissect_bthci_evt_remote_host_sup_feat_notification(tvb, offset, pinfo, bthci_evt_tree);
- break;
-
- default:
- proto_tree_add_item(bthci_evt_tree, hf_bthci_evt_params, tvb, 2, -1, ENC_NA);
- offset+=tvb_length_remaining(tvb, offset);
- break;
- }
+ case 0x2f: /* Extended Inquiry Result */
+ offset=dissect_bthci_evt_inq_result_with_rssi(tvb, offset, pinfo, bthci_evt_tree);
+ offset=dissect_bthci_evt_ext_inquiry_response(tvb, offset, pinfo, bthci_evt_tree);
+ break;
+
+ case 0x30: /* Encryption Key Refresh Complete */
+ offset=dissect_bthci_evt_encryption_key_refresh_complete(tvb, offset, pinfo, bthci_evt_tree);
+ break;
+
+ case 0x31: /* IO Capability Request */
+ offset=dissect_bthci_evt_io_capability_request(tvb, offset, pinfo, bthci_evt_tree);
+ break;
+
+ case 0x32: /* IO Capability Response */
+ offset=dissect_bthci_evt_io_capability_response(tvb, offset, pinfo, bthci_evt_tree);
+ break;
+
+ case 0x33: /* User Confirmation Request */
+ offset=dissect_bthci_evt_user_confirmation_request(tvb, offset, pinfo, bthci_evt_tree);
+ break;
+
+ case 0x34: /* User Passkey Request */
+ offset=dissect_bthci_evt_user_passkey_request(tvb, offset, pinfo, bthci_evt_tree);
+ break;
+
+ case 0x35: /* Remote OOB Data Request */
+ offset=dissect_bthci_evt_remote_oob_data_request(tvb, offset, pinfo, bthci_evt_tree);
+ break;
+
+ case 0x36: /* Simple Pairing Complete */
+ offset=dissect_bthci_evt_simple_pairing_complete(tvb, offset, pinfo, bthci_evt_tree);
+ break;
+
+ case 0x38: /* Link Supervision Timeout Changed */
+ offset=dissect_bthci_evt_link_supervision_timeout_changed(tvb, offset, pinfo, bthci_evt_tree);
+ break;
+
+ case 0x39: /* Enhanced Flush Complete */
+ offset=dissect_bthci_evt_enhanced_flush_complete(tvb, offset, pinfo, bthci_evt_tree);
+ break;
+
+ case 0x3b: /* Enhanced Flush Complete */
+ offset=dissect_bthci_evt_user_passkey_notification(tvb, offset, pinfo, bthci_evt_tree);
+ break;
+
+ case 0x3c: /* Enhanced Flush Complete */
+ offset=dissect_bthci_evt_keypress_notification(tvb, offset, pinfo, bthci_evt_tree);
+ break;
+
+ case 0x3d: /* Remote Host Supported Features Notification */
+ offset=dissect_bthci_evt_remote_host_sup_feat_notification(tvb, offset, pinfo, bthci_evt_tree);
+ break;
+
+ default:
+ proto_tree_add_item(bthci_evt_tree, hf_bthci_evt_params, tvb, 2, -1, ENC_NA);
+ offset+=tvb_length_remaining(tvb, offset);
+ break;
+ }
- }
+ }
return offset;
}
@@ -2617,978 +2617,978 @@ void
proto_register_bthci_evt(void)
{
- /* Setup list of header fields See Section 1.6.1 for details*/
- static hf_register_info hf[] = {
- { &hf_bthci_evt_code,
- { "Event Code", "bthci_evt.code",
- FT_UINT8, BASE_HEX, VALS(evt_code_vals), 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_evt_param_length,
- { "Parameter Total Length", "bthci_evt.param_length",
- FT_UINT8, BASE_DEC, NULL, 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_evt_params,
- { "Event Parameter", "bthci_evt.params",
- FT_NONE, BASE_NONE, NULL, 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_evt_num_command_packets,
- { "Number of Allowed Command Packets", "bthci_evt.num_command_packets",
- FT_UINT8, BASE_DEC, NULL, 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_evt_num_handles,
- { "Number of Connection Handles", "bthci_evt.num_handles",
- FT_UINT8, BASE_DEC, NULL, 0x0,
- "Number of Connection Handles and Num_HCI_Data_Packets parameter pairs", HFILL }
- },
- { &hf_bthci_evt_connection_handle,
- { "Connection Handle", "bthci_evt.connection_handle",
- FT_UINT16, BASE_HEX, NULL, 0x0,
- NULL, HFILL }
- },
-
- { &hf_bthci_evt_num_compl_packets,
- { "Number of Completed Packets", "bthci_evt.num_compl_packets",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- "The number of HCI Data Packets that have been completed", HFILL }
- },
-
- { &hf_bthci_evt_com_opcode,
- { "Command Opcode", "bthci_evt.com_opcode",
- FT_UINT16, BASE_HEX|BASE_EXT_STRING, &bthci_cmd_opcode_vals_ext, 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_evt_ogf,
- { "ogf", "bthci_evt.ogf",
- FT_UINT16, BASE_HEX|BASE_EXT_STRING, &bthci_ogf_vals_ext, 0xfc00,
- "Opcode Group Field", HFILL }
- },
- { &hf_bthci_evt_ocf,
- { "ocf", "bthci_evt.ocf",
- FT_UINT16, BASE_HEX, NULL, 0x03ff,
- "Opcode Command Field", HFILL }
- },
- { &hf_bthci_evt_ret_params,
- { "Return Parameter", "bthci_evt.ret_params",
- FT_NONE, BASE_NONE, NULL, 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_evt_status,
- { "Status", "bthci_evt.status",
- FT_UINT8, BASE_HEX|BASE_EXT_STRING, &bthci_cmd_status_vals_ext, 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_evt_status_pending,
- { "Status", "bthci_evt.status",
- FT_UINT8, BASE_HEX, VALS(bthci_cmd_status_pending_vals), 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_evt_bd_addr,
- { "BD_ADDR:", "bthci_evt.bd_addr",
- FT_NONE, BASE_NONE, NULL, 0x0,
- "Bluetooth Device Address", HFILL}
- },
- { &hf_bthci_evt_class_of_device,
- { "Class of Device", "bthci_evt.class_of_device",
- FT_UINT24, BASE_HEX, NULL, 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_evt_link_type,
- { "Link Type", "bthci_evt.link_type",
- FT_UINT8, BASE_HEX, VALS(evt_link_types), 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_evt_encryption_mode,
- { "Encryption Mode", "bthci_evt.encryption_mode",
- FT_UINT8, BASE_HEX, VALS(evt_encryption_modes), 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_evt_reason,
- { "Reason", "bthci_evt.reason",
- FT_UINT8, BASE_HEX|BASE_EXT_STRING, &bthci_cmd_status_vals_ext, 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_evt_remote_name,
- { "Remote Name", "bthci_evt.remote_name",
- FT_STRINGZ, BASE_NONE, NULL, 0x0,
- "Userfriendly descriptive name for the remote device", HFILL }
- },
- { &hf_bthci_evt_encryption_enable,
- { "Encryption Enable", "bthci_evt.encryption_enable",
- FT_UINT8, BASE_HEX, VALS(evt_encryption_enable), 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_evt_key_flag,
- { "Key Flag", "bthci_evt.key_flag",
- FT_UINT8, BASE_HEX, VALS(evt_key_flag), 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_evt_vers_nr,
- { "LMP Version", "bthci_evt.lmp_vers_nr",
- FT_UINT8, BASE_HEX, VALS(evt_lmp_vers_nr), 0x0,
- "Version of the Current LMP", HFILL }
- },
- { &hf_bthci_evt_hci_vers_nr,
- { "HCI Version", "bthci_evt.hci_vers_nr",
- FT_UINT8, BASE_HEX, VALS(evt_hci_vers_nr), 0x0,
- "Version of the Current HCI", HFILL }
- },
- { &hf_bthci_evt_hci_revision,
- { "HCI Revision", "bthci_evt.hci_vers_nr",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- "Revision of the Current HCI", HFILL }
- },
- { &hf_bthci_evt_comp_id,
- { "Manufacturer Name", "bthci_evt.comp_id",
- FT_UINT16, BASE_HEX, VALS(evt_comp_id), 0x0,
- "Manufacturer Name of Bluetooth Hardware", HFILL }
- },
- { &hf_bthci_evt_sub_vers_nr,
- { "LMP Subversion", "bthci_evt.lmp_sub_vers_nr",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- "Subversion of the Current LMP", HFILL }
- },
- { &hf_bthci_evt_flags,
- { "Flags", "bthci_evt.flags",
- FT_UINT8, BASE_HEX, NULL, 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_evt_service_type,
- { "Service Type", "bthci_evt.service_type",
- FT_UINT8, BASE_HEX, VALS(evt_service_types), 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_evt_token_rate,
- { "Available Token Rate", "bthci_evt.token_rate",
- FT_UINT32, BASE_DEC, NULL, 0x0,
- "Available Token Rate, in bytes per second", HFILL }
- },
- { &hf_bthci_evt_peak_bandwidth,
- { "Available Peak Bandwidth", "bthci_evt.peak_bandwidth",
- FT_UINT32, BASE_DEC, NULL, 0x0,
- "Available Peak Bandwidth, in bytes per second", HFILL }
- },
- { &hf_bthci_evt_latency,
- { "Available Latency", "bthci_evt.latency",
- FT_UINT32, BASE_DEC, NULL, 0x0,
- "Available Latency, in microseconds", HFILL }
- },
- { &hf_bthci_evt_delay_variation,
- { "Available Delay Variation", "bthci_evt.delay_variation",
- FT_UINT32, BASE_DEC, NULL, 0x0,
- "Available Delay Variation, in microseconds", HFILL }
- },
- { &hf_bthci_evt_hardware_code,
- { "Hardware Code", "bthci_evt.hardware_code",
- FT_UINT8, BASE_HEX, NULL, 0x0,
- "Hardware Code (implementation specific)", HFILL }
- },
- { &hf_bthci_evt_role,
- { "Role", "bthci_evt.role",
- FT_UINT8, BASE_HEX, VALS(evt_role_vals), 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_evt_curr_mode,
- { "Current Mode", "bthci_evt.current_mode",
- FT_UINT8, BASE_HEX, VALS(evt_modes), 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_evt_interval,
- { "Interval", "bthci_evt.interval",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- "Interval - Number of Baseband slots", HFILL }
- },
- { &hf_bthci_evt_link_key,
- { "Link Key", "bthci_evt.link_key",
- FT_BYTES, BASE_NONE, NULL, 0x0,
- "Link Key for the associated BD_ADDR", HFILL }
- },
- { &hf_bthci_evt_key_type,
- { "Key Type", "bthci_evt.key_type",
- FT_UINT8, BASE_HEX, VALS(evt_key_types), 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_evt_max_slots,
- { "Maximum Number of Slots", "bthci_evt.max_slots",
- FT_UINT8, BASE_DEC, NULL, 0x0,
- "Maximum Number of slots allowed for baseband packets", HFILL }
- },
- { &hf_bthci_evt_clock_offset,
- { "Clock Offset", "bthci_evt.clock_offset",
- FT_UINT16, BASE_HEX, NULL, 0x7FFF,
- "Bit 2-16 of the Clock Offset between CLKmaster-CLKslave", HFILL }
- },
- { &hf_bthci_evt_page_scan_mode,
- { "Page Scan Mode", "bthci_evt.page_scan_mode",
- FT_UINT8, BASE_HEX, VALS(evt_page_scan_modes), 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_evt_page_scan_repetition_mode,
- { "Page Scan Repetition Mode", "bthci_evt.page_scan_repetition_mode",
- FT_UINT8, BASE_HEX, VALS(evt_page_scan_repetition_modes), 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_evt_page_scan_period_mode,
- { "Page Scan Period Mode", "bthci_evt.page_scan_period_mode",
- FT_UINT8, BASE_HEX, VALS(evt_page_scan_period_modes), 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_evt_link_type_2dh1,
- { "ACL Link Type 2-DH1", "bthci_evt.link_type_2dh1",
- FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x0002,
- NULL, HFILL }
- },
- { &hf_bthci_evt_link_type_3dh1,
- { "ACL Link Type 3-DH1", "bthci_evt.link_type_3dh1",
- FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x0004,
- NULL, HFILL }
- },
- { &hf_bthci_evt_link_type_dm1,
- { "ACL Link Type DM1", "bthci_evt.link_type_dm1",
- FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x0008,
- NULL, HFILL }
- },
- { &hf_bthci_evt_link_type_dh1,
- { "ACL Link Type DH1", "bthci_evt.link_type_dh1",
- FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x0010,
- NULL, HFILL }
- },
- { &hf_bthci_evt_link_type_2dh3,
- { "ACL Link Type 2-DH3", "bthci_evt.link_type_2dh3",
- FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x0100,
- NULL, HFILL }
- },
- { &hf_bthci_evt_link_type_3dh3,
- { "ACL Link Type 3-DH3", "bthci_evt.link_type_3dh3",
- FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x0200,
- NULL, HFILL }
- },
- { &hf_bthci_evt_link_type_dm3,
- { "ACL Link Type DM3", "bthci_evt.link_type_dm3",
- FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x0400,
- NULL, HFILL }
- },
- { &hf_bthci_evt_link_type_dh3,
- { "ACL Link Type DH3", "bthci_evt.link_type_dh3",
- FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x0800,
- NULL, HFILL }
- },
- { &hf_bthci_evt_link_type_2dh5,
- { "ACL Link Type 2-DH5", "bthci_evt.link_type_2dh5",
- FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x1000,
- NULL, HFILL }
- },
- { &hf_bthci_evt_link_type_3dh5,
- { "ACL Link Type 3-DH5", "bthci_evt.link_type_3dh5",
- FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x2000,
- NULL, HFILL }
- },
- { &hf_bthci_evt_link_type_dm5,
- { "ACL Link Type DM5", "bthci_evt.link_type_dm5",
- FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x4000,
- NULL, HFILL }
- },
- { &hf_bthci_evt_link_type_dh5,
- { "ACL Link Type DH5", "bthci_evt.link_type_dh5",
- FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x8000,
- NULL, HFILL }
- },
- { &hf_bthci_evt_link_type_hv1,
- { "SCO Link Type HV1", "bthci_evt.link_type_hv1",
- FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x0020,
- NULL, HFILL }
- },
- { &hf_bthci_evt_link_type_hv2,
- { "SCO Link Type HV2", "bthci_evt.link_type_hv2",
- FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x0040,
- NULL, HFILL }
- },
- { &hf_bthci_evt_link_type_hv3,
- { "SCO Link Type HV3", "bthci_evt.link_type_hv3",
- FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x0080,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_00,
- { "3-slot packets", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x01,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_01,
- { "5-slot packets", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x02,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_02,
- { "encryption", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x04,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_03,
- { "slot offset", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x08,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_04,
- { "timing accuracy", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x10,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_05,
- { "master/slave switch", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x20,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_06,
- { "hold mode", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x40,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_07,
- { "sniff mode", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x80,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_10,
- { "park mode", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x01,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_11,
- { "RSSI", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x02,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_12,
- { "channel quality driven data rate", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x04,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_13,
- { "SCO link", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x08,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_14,
- { "HV2 packets", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x10,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_15,
- { "HV3 packets", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x20,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_16,
- { "u-law log", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x40,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_17,
- { "A-law log", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x80,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_20,
- { "CVSD", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x01,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_21,
- { "paging scheme", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x02,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_22,
- { "power control", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x04,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_23,
- { "transparent SCO data", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x08,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_24,
- { "Flow control lag", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, NULL, 0x70,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_27,
- { "broadband encryption", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x80,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_31,
- { "EDR ACL 2 Mbps mode", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x02,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_32,
- { "EDR ACL 3 Mbps mode", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x04,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_33,
- { "enhanced inquiry scan", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x08,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_34,
- { "interlaced inquiry scan", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x10,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_35,
- { "interlaced page scan", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x20,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_36,
- { "RSSI with inquiry results", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x40,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_37,
- { "eSCO EV3 packets", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x80,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_40,
- { "eSCO EV4 packets", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x01,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_41,
- { "eSCO EV5 packets", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x02,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_43,
- { "AFH capable slave", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x08,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_44,
- { "AFH classification slave", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x10,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_47,
- { "3-slot EDR ACL packets", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x80,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_50,
- { "5-slot EDR ACL packets", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x01,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_51,
- { "sniff subrating", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x02,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_52,
- { "pause encryption", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x04,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_53,
- { "AFH capable master", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x08,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_54,
- { "AFH classification master", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x10,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_55,
- { "EDR eSCO 2 Mbps mode", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x20,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_56,
- { "EDR eSCO 3 Mbps mode", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x40,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_57,
- { "3-slot EDR eSCO packets", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x80,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_60,
- { "extended inquiry response", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x01,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_63,
- { "secure simple pairing", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x08,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_64,
- { "encapsulated PDU", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x10,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_65,
- { "erroneous data reporting", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x20,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_66,
- { "non-flushable packet boundary flag", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x40,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_70,
- { "link supervision timeout changed event", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x01,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_71,
- { "inquiry response TX power level", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x02,
- NULL, HFILL }
- },
- { &hf_bthci_evt_lmp_feature_77,
- { "extended features", "bthci_evt.lmp_feature",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x80,
- NULL, HFILL }
- },
- { &hf_bthci_evt_num_keys,
- { "Number of Link Keys", "bthci_evt.num_keys",
- FT_UINT8, BASE_DEC, NULL, 0x0,
- "Number of Link Keys contained", HFILL }
- },
- { &hf_bthci_evt_num_keys_read,
- { "Number of Link Keys Read", "bthci_evt.num_keys_read",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_evt_num_keys_deleted,
- { "Number of Link Keys Deleted", "bthci_evt.num_keys_deleted",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_evt_num_keys_written,
- { "Number of Link Keys Written", "bthci_evt.num_keys_written",
- FT_UINT8, BASE_DEC, NULL, 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_evt_max_num_keys,
- { "Max Num Keys", "bthci_evt.max_num_keys",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- "Total Number of Link Keys that the Host Controller can store", HFILL }
- },
- { &hf_bthci_evt_num_responses,
- { "Number of responses", "bthci_evt.num_responses",
- FT_UINT8, BASE_DEC, NULL, 0x0,
- "Number of Responses from Inquiry", HFILL }
- },
- { &hf_bthci_evt_link_policy_setting_switch,
- { "Enable Master Slave Switch", "bthci_evt.link_policy_switch",
- FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x0001,
- NULL, HFILL }
- },
- { &hf_bthci_evt_link_policy_setting_hold,
- { "Enable Hold Mode", "bthci_evt.link_policy_hold",
- FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x0002,
- NULL, HFILL }
- },
- { &hf_bthci_evt_link_policy_setting_sniff,
- { "Enable Sniff Mode", "bthci_evt.link_policy_sniff",
- FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x0004,
- NULL, HFILL }
- },
- { &hf_bthci_evt_link_policy_setting_park,
- { "Enable Park Mode", "bthci_evt.link_policy_park",
- FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x0008,
- NULL, HFILL }
- },
- { &hf_bthci_evt_curr_role,
- { "Current Role", "bthci_evt.curr_role",
- FT_UINT8, BASE_HEX, VALS(evt_role_vals_handle), 0x0,
- "Current role for this connection handle", HFILL }
- },
- { &hf_bthci_evt_pin_type,
- { "PIN Type", "bthci_evt.pin_type",
- FT_UINT8, BASE_HEX, VALS(evt_pin_types), 0x0,
- "PIN Types", HFILL }
- },
- { &hf_bthci_evt_device_name,
- { "Device Name", "bthci_evt.device_name",
- FT_STRINGZ, BASE_NONE, NULL, 0x0,
- "Userfriendly descriptive name for the device", HFILL }
- },
- { &hf_bthci_evt_timeout,
- { "Timeout", "bthci_evt.timeout",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- "Number of Baseband slots for timeout.", HFILL }
- },
- { &hf_bthci_evt_scan_enable,
- { "Scan", "bthci_evt.scan_enable",
- FT_UINT8, BASE_HEX, VALS(evt_scan_enable_values), 0x0,
- "Scan Enable", HFILL }
- },
- { &hf_bthci_evt_authentication_enable,
- { "Authentication", "bthci_evt.auth_enable",
- FT_UINT8, BASE_HEX, VALS(evt_auth_enable_values), 0x0,
- "Authentication Enable", HFILL }
- },
- { &hf_bthci_evt_sco_flow_cont_enable,
- { "SCO Flow Control", "bthci_evt.sco_flow_cont_enable",
- FT_UINT8, BASE_HEX, VALS(evt_enable_values), 0x0,
- "SCO Flow Control Enable", HFILL }
- },
- { &hf_bthci_evt_window,
- { "Interval", "bthci_evt.window",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- "Window", HFILL }
- },
- { &hf_bthci_evt_input_coding,
- { "Input Coding", "bthci_evt.input_coding",
- FT_UINT16, BASE_DEC, VALS(evt_input_coding_values), 0x0300,
- "Authentication Enable", HFILL }
- },
- { &hf_bthci_evt_input_data_format,
- { "Input Data Format", "bthci_evt.input_data_format",
- FT_UINT16, BASE_DEC, VALS(evt_input_data_format_values), 0x00c0,
- NULL, HFILL }
- },
- { &hf_bthci_evt_input_sample_size,
- { "Input Sample Size", "bthci_evt.input_sample_size",
- FT_UINT16, BASE_DEC, VALS(evt_input_sample_size_values), 0x0020,
- NULL, HFILL }
- },
- { &hf_bthci_evt_num_broadcast_retransm,
- { "Num Broadcast Retran", "bthci_evt.num_broad_retran",
- FT_UINT8, BASE_DEC, NULL, 0x0,
- "Number of Broadcast Retransmissions", HFILL }
- },
- { &hf_bthci_evt_hold_mode_act_page,
- { "Suspend Page Scan", "bthci_evt.hold_mode_page",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x1,
- "Device can enter low power state", HFILL }
- },
- { &hf_bthci_evt_hold_mode_act_inquiry,
- { "Suspend Inquiry Scan", "bthci_evt.hold_mode_inquiry",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x2,
- "Device can enter low power state", HFILL }
- },
- { &hf_bthci_evt_hold_mode_act_periodic,
- { "Suspend Periodic Inquiries", "bthci_evt.hold_mode_periodic",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x4,
- "Device can enter low power state", HFILL }
- },
- { &hf_bthci_evt_transmit_power_level,
- { "Transmit Power Level (dBm)", "bthci_evt.transmit_power_level",
- FT_INT8, BASE_DEC, NULL, 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_evt_num_supp_iac,
- {"Num Support IAC", "bthci_evt.num_supp_iac",
- FT_UINT8, BASE_DEC, NULL, 0x0,
- "Num of supported IAC the device can simultaneously listen", HFILL }
- },
- { &hf_bthci_evt_num_curr_iac,
- {"Num Current IAC", "bthci_evt.num_curr_iac",
- FT_UINT8, BASE_DEC, NULL, 0x0,
- "Num of IACs currently in use to simultaneously listen", HFILL }
- },
- { &hf_bthci_evt_iac_lap,
- { "IAC LAP", "bthci_evt.num_curr_iac",
- FT_UINT24, BASE_HEX, NULL, 0x0,
- "LAP(s)used to create IAC", HFILL }
- },
- { &hf_bthci_evt_loopback_mode,
- {"Loopback Mode", "bthci_evt.loopback_mode",
- FT_UINT8, BASE_HEX, VALS(evt_loopback_modes), 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_evt_country_code,
- {"Country Code", "bthci_evt.country_code",
- FT_UINT8, BASE_HEX, VALS(evt_country_code_values), 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_evt_failed_contact_counter,
- {"Failed Contact Counter", "bthci_evt.failed_contact_counter",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_evt_link_quality,
- {"Link Quality", "bthci_evt.link_quality",
- FT_UINT8, BASE_DEC, NULL, 0x0,
- "Link Quality (0x00 - 0xFF Higher Value = Better Link)", HFILL }
- },
- { &hf_bthci_evt_rssi,
- { "RSSI (dB)", "bthci_evt.rssi",
- FT_INT8, BASE_DEC, NULL, 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_evt_host_data_packet_length_acl,
- {"Host ACL Data Packet Length (bytes)", "bthci_evt.max_data_length_acl",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- "Max Host ACL Data Packet length of data portion host is able to accept", HFILL }
- },
- { &hf_bthci_evt_host_data_packet_length_sco,
- {"Host SCO Data Packet Length (bytes)", "bthci_evt.max_data_length_sco",
- FT_UINT8, BASE_DEC, NULL, 0x0,
- "Max Host SCO Data Packet length of data portion host is able to accept", HFILL }
- },
- { &hf_bthci_evt_host_total_num_acl_data_packets,
- {"Host Total Num ACL Data Packets", "bthci_evt.max_data_num_acl",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- "Total Number of HCI ACL Data Packets that can be stored in the data buffers of the Host", HFILL }
- },
- { &hf_bthci_evt_host_total_num_sco_data_packets,
- {"Host Total Num SCO Data Packets", "bthci_evt.max_data_num_sco",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- "Total Number of HCI SCO Data Packets that can be stored in the data buffers of the Host", HFILL }
- },
- { &hf_bthci_evt_page_number,
- {"Page Number", "bthci_evt.page_number",
- FT_UINT8, BASE_DEC, NULL, 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_evt_max_page_number,
- {"Max. Page Number", "bthci_evt.max_page_number",
- FT_UINT8, BASE_DEC, NULL, 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_evt_local_supported_cmds,
- { "Local Supported Commands", "bthci_evt.local_supported_cmds",
- FT_BYTES, BASE_NONE, NULL, 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_evt_fec_required,
- {"FEC Required", "bthci_evt.fec_required",
- FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_evt_err_data_reporting,
- {"Erroneous Data Reporting", "bthci_evt.err_data_reporting",
- FT_UINT8, BASE_DEC, VALS(evt_enable_values), 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_evt_scan_type,
- {"Scan Type", "bthci_evt.inq_scan_type",
- FT_UINT8, BASE_DEC, VALS(evt_scan_types), 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_evt_inq_mode,
- {"Inquiry Mode", "bthci_evt.inq_scan_type",
- FT_UINT8, BASE_DEC, VALS(evt_inq_modes), 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_evt_power_level_type,
- {"Type", "bthci_evt.power_level_type",
- FT_UINT8, BASE_HEX, VALS(evt_power_level_types), 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_evt_ext_lmp_features,
- {"Ext. LMP Features", "bthci_evt.page_number",
- FT_UINT64, BASE_HEX, NULL, 0x0,
- "Extended LMP Features", HFILL}
- },
- { &hf_bthci_evt_sync_link_type,
- {"Link Type", "bthci_evt.sync_link_type",
- FT_UINT8, BASE_HEX, VALS(evt_sync_link_types), 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_evt_sync_tx_interval,
- {"Transmit Interval", "bthci_evt.sync_tx_interval",
- FT_UINT8, BASE_DEC, NULL, 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_evt_sync_rtx_window,
- {"Retransmit Window", "bthci_evt.sync_rtx_window",
- FT_UINT8, BASE_DEC, NULL, 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_evt_sync_rx_packet_length,
- {"Rx Packet Length", "bthci_evt.sync_rx_pkt_len",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_evt_sync_tx_packet_length,
- {"Tx Packet Length", "bthci_evt.sync_tx_pkt_len",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_evt_air_mode,
- {"Air Mode", "bthci_evt.air_mode",
- FT_UINT8, BASE_DEC, VALS(evt_air_mode_values), 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_evt_max_tx_latency,
- {"Max. Tx Latency", "bthci_evt.max_tx_latency",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_evt_max_rx_latency,
- {"Max. Rx Latency", "bthci_evt.max_rx_latency",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_evt_min_remote_timeout,
- {"Min. Remote Timeout", "bthci_evt.min_remote_timeout",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_evt_min_local_timeout,
- {"Min. Local Timeout", "bthci_evt.min_local_timeout",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_evt_link_supervision_timeout,
- {"Link Supervision Timeout", "bthci_evt.link_supervision_timeout",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_evt_token_bucket_size,
- { "Token Bucket Size", "bthci_evt.token_bucket_size",
- FT_UINT32, BASE_DEC, NULL, 0x0,
- "Token Bucket Size (bytes)", HFILL }
- },
- { &hf_bthci_evt_flow_direction,
- {"Flow Direction", "bthci_evt.flow_direction",
- FT_UINT8, BASE_DEC, VALS(evt_flow_direction_values), 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_evt_afh_ch_assessment_mode,
- {"AFH Channel Assessment Mode", "bthci_evt.afh_ch_assessment_mode",
- FT_UINT8, BASE_DEC, VALS(evt_enable_values), 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_evt_lmp_handle,
- { "LMP Handle", "bthci_evt.lmp_handle",
- FT_UINT16, BASE_HEX, NULL, 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_evt_clock,
- { "Clock", "bthci_evt.clock",
- FT_UINT32, BASE_HEX, NULL, 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_evt_clock_accuracy,
- { "Clock", "bthci_evt.clock_accuracy",
- FT_UINT16, BASE_HEX, NULL, 0x0,
- NULL, HFILL }
- },
- { &hf_bthci_evt_afh_mode,
- {"AFH Mode", "bthci_evt.afh_mode",
- FT_UINT8, BASE_DEC, VALS(evt_enable_values), 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_evt_afh_channel_map,
- {"AFH Channel Map", "bthci_evt.afh_channel_map",
- FT_UINT_BYTES, BASE_NONE, NULL, 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_evt_simple_pairing_mode,
- {"Simple Pairing Mode", "bthci_evt.simple_pairing_mode",
- FT_UINT8, BASE_DEC, VALS(evt_enable_values), 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_evt_hash_c,
- {"Hash C", "bthci_evt.hash_c",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_evt_randomizer_r,
- {"Randomizer R", "bthci_evt.randomizer_r",
- FT_UINT16, BASE_DEC, NULL, 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_evt_io_capability,
- {"IO Capability", "bthci_evt.io_capability",
- FT_UINT8, BASE_HEX, VALS(bthci_cmd_io_capability_vals), 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_evt_oob_data_present,
- {"OOB Data Present", "bthci_evt.oob_data_present",
- FT_UINT8, BASE_DEC, VALS(bthci_cmd_oob_data_present_vals), 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_evt_auth_requirements,
- {"Authentication Requirements", "bthci_evt.auth_requirements",
- FT_UINT8, BASE_DEC|BASE_EXT_STRING, &bthci_cmd_auth_req_vals_ext, 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_evt_numeric_value,
- {"Numeric Value", "bthci_evt.numeric_value",
- FT_UINT32, BASE_DEC, NULL, 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_evt_passkey,
- {"Passkey", "bthci_evt.passkey",
- FT_UINT32, BASE_DEC, NULL, 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_evt_notification_type,
- {"Notification Type", "bthci_evt.notification_type",
- FT_UINT8, BASE_DEC, VALS(evt_notification_type_vals), 0x0,
- NULL, HFILL}
- },
- { &hf_bthci_evt_eir_data,
- {"Data", "bthci_evt.eir_data",
- FT_BYTES, BASE_NONE, NULL, 0x0,
- "EIR Data", HFILL}
- },
- { &hf_bthci_evt_eir_struct_length,
- { "Length", "bthci_evt.eir_struct_length",
- FT_UINT8, BASE_DEC, NULL, 0x0,
- "Structure Length", HFILL }
- },
- { &hf_bthci_evt_eir_struct_type,
- { "Type", "bthci_evt.eir_data_type",
- FT_UINT8, BASE_HEX|BASE_EXT_STRING, &bthci_cmd_eir_data_type_vals_ext, 0x0,
- "Data Type", HFILL }
- },
- { &hf_bthci_evt_sc_uuid16,
- { "UUID", "bthci_evt.service_class_uuid16",
- FT_UINT16, BASE_HEX|BASE_EXT_STRING, &bthci_cmd_service_class_type_vals_ext, 0x0,
- "16-bit Service Class UUID", HFILL }
- },
- { &hf_bthci_evt_sc_uuid32,
- { "UUID", "bthci_evt.service_class_uuid32",
- FT_UINT32, BASE_HEX, NULL, 0x0,
- "32-bit Service Class UUID", HFILL }
- },
- { &hf_bthci_evt_sc_uuid128,
- { "UUID", "bthci_evt.service_class_uuid128",
- FT_BYTES, BASE_NONE, NULL, 0x0,
- "128-bit Service Class UUID", HFILL }
- }
- };
-
- /* Setup protocol subtree array */
- static gint *ett[] = {
- &ett_bthci_evt,
- &ett_opcode,
- &ett_lmp_subtree,
- &ett_ptype_subtree,
- &ett_eir_subtree,
- &ett_eir_struct_subtree
- };
-
- /* Register the protocol name and description */
- proto_bthci_evt = proto_register_protocol("Bluetooth HCI Event",
- "HCI_EVT", "bthci_evt");
-
- new_register_dissector("bthci_evt", dissect_bthci_evt, proto_bthci_evt);
-
-
-
- /* Required function calls to register the header fields and subtrees used */
- proto_register_field_array(proto_bthci_evt, hf, array_length(hf));
- proto_register_subtree_array(ett, array_length(ett));
+ /* Setup list of header fields See Section 1.6.1 for details*/
+ static hf_register_info hf[] = {
+ { &hf_bthci_evt_code,
+ { "Event Code", "bthci_evt.code",
+ FT_UINT8, BASE_HEX, VALS(evt_code_vals), 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_param_length,
+ { "Parameter Total Length", "bthci_evt.param_length",
+ FT_UINT8, BASE_DEC, NULL, 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_params,
+ { "Event Parameter", "bthci_evt.params",
+ FT_NONE, BASE_NONE, NULL, 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_num_command_packets,
+ { "Number of Allowed Command Packets", "bthci_evt.num_command_packets",
+ FT_UINT8, BASE_DEC, NULL, 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_num_handles,
+ { "Number of Connection Handles", "bthci_evt.num_handles",
+ FT_UINT8, BASE_DEC, NULL, 0x0,
+ "Number of Connection Handles and Num_HCI_Data_Packets parameter pairs", HFILL }
+ },
+ { &hf_bthci_evt_connection_handle,
+ { "Connection Handle", "bthci_evt.connection_handle",
+ FT_UINT16, BASE_HEX, NULL, 0x0,
+ NULL, HFILL }
+ },
+
+ { &hf_bthci_evt_num_compl_packets,
+ { "Number of Completed Packets", "bthci_evt.num_compl_packets",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ "The number of HCI Data Packets that have been completed", HFILL }
+ },
+
+ { &hf_bthci_evt_com_opcode,
+ { "Command Opcode", "bthci_evt.com_opcode",
+ FT_UINT16, BASE_HEX|BASE_EXT_STRING, &bthci_cmd_opcode_vals_ext, 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_ogf,
+ { "ogf", "bthci_evt.ogf",
+ FT_UINT16, BASE_HEX|BASE_EXT_STRING, &bthci_ogf_vals_ext, 0xfc00,
+ "Opcode Group Field", HFILL }
+ },
+ { &hf_bthci_evt_ocf,
+ { "ocf", "bthci_evt.ocf",
+ FT_UINT16, BASE_HEX, NULL, 0x03ff,
+ "Opcode Command Field", HFILL }
+ },
+ { &hf_bthci_evt_ret_params,
+ { "Return Parameter", "bthci_evt.ret_params",
+ FT_NONE, BASE_NONE, NULL, 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_status,
+ { "Status", "bthci_evt.status",
+ FT_UINT8, BASE_HEX|BASE_EXT_STRING, &bthci_cmd_status_vals_ext, 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_status_pending,
+ { "Status", "bthci_evt.status",
+ FT_UINT8, BASE_HEX, VALS(bthci_cmd_status_pending_vals), 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_bd_addr,
+ { "BD_ADDR:", "bthci_evt.bd_addr",
+ FT_NONE, BASE_NONE, NULL, 0x0,
+ "Bluetooth Device Address", HFILL}
+ },
+ { &hf_bthci_evt_class_of_device,
+ { "Class of Device", "bthci_evt.class_of_device",
+ FT_UINT24, BASE_HEX, NULL, 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_link_type,
+ { "Link Type", "bthci_evt.link_type",
+ FT_UINT8, BASE_HEX, VALS(evt_link_types), 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_encryption_mode,
+ { "Encryption Mode", "bthci_evt.encryption_mode",
+ FT_UINT8, BASE_HEX, VALS(evt_encryption_modes), 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_reason,
+ { "Reason", "bthci_evt.reason",
+ FT_UINT8, BASE_HEX|BASE_EXT_STRING, &bthci_cmd_status_vals_ext, 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_remote_name,
+ { "Remote Name", "bthci_evt.remote_name",
+ FT_STRINGZ, BASE_NONE, NULL, 0x0,
+ "Userfriendly descriptive name for the remote device", HFILL }
+ },
+ { &hf_bthci_evt_encryption_enable,
+ { "Encryption Enable", "bthci_evt.encryption_enable",
+ FT_UINT8, BASE_HEX, VALS(evt_encryption_enable), 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_key_flag,
+ { "Key Flag", "bthci_evt.key_flag",
+ FT_UINT8, BASE_HEX, VALS(evt_key_flag), 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_vers_nr,
+ { "LMP Version", "bthci_evt.lmp_vers_nr",
+ FT_UINT8, BASE_HEX, VALS(evt_lmp_vers_nr), 0x0,
+ "Version of the Current LMP", HFILL }
+ },
+ { &hf_bthci_evt_hci_vers_nr,
+ { "HCI Version", "bthci_evt.hci_vers_nr",
+ FT_UINT8, BASE_HEX, VALS(evt_hci_vers_nr), 0x0,
+ "Version of the Current HCI", HFILL }
+ },
+ { &hf_bthci_evt_hci_revision,
+ { "HCI Revision", "bthci_evt.hci_vers_nr",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ "Revision of the Current HCI", HFILL }
+ },
+ { &hf_bthci_evt_comp_id,
+ { "Manufacturer Name", "bthci_evt.comp_id",
+ FT_UINT16, BASE_HEX, VALS(evt_comp_id), 0x0,
+ "Manufacturer Name of Bluetooth Hardware", HFILL }
+ },
+ { &hf_bthci_evt_sub_vers_nr,
+ { "LMP Subversion", "bthci_evt.lmp_sub_vers_nr",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ "Subversion of the Current LMP", HFILL }
+ },
+ { &hf_bthci_evt_flags,
+ { "Flags", "bthci_evt.flags",
+ FT_UINT8, BASE_HEX, NULL, 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_service_type,
+ { "Service Type", "bthci_evt.service_type",
+ FT_UINT8, BASE_HEX, VALS(evt_service_types), 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_token_rate,
+ { "Available Token Rate", "bthci_evt.token_rate",
+ FT_UINT32, BASE_DEC, NULL, 0x0,
+ "Available Token Rate, in bytes per second", HFILL }
+ },
+ { &hf_bthci_evt_peak_bandwidth,
+ { "Available Peak Bandwidth", "bthci_evt.peak_bandwidth",
+ FT_UINT32, BASE_DEC, NULL, 0x0,
+ "Available Peak Bandwidth, in bytes per second", HFILL }
+ },
+ { &hf_bthci_evt_latency,
+ { "Available Latency", "bthci_evt.latency",
+ FT_UINT32, BASE_DEC, NULL, 0x0,
+ "Available Latency, in microseconds", HFILL }
+ },
+ { &hf_bthci_evt_delay_variation,
+ { "Available Delay Variation", "bthci_evt.delay_variation",
+ FT_UINT32, BASE_DEC, NULL, 0x0,
+ "Available Delay Variation, in microseconds", HFILL }
+ },
+ { &hf_bthci_evt_hardware_code,
+ { "Hardware Code", "bthci_evt.hardware_code",
+ FT_UINT8, BASE_HEX, NULL, 0x0,
+ "Hardware Code (implementation specific)", HFILL }
+ },
+ { &hf_bthci_evt_role,
+ { "Role", "bthci_evt.role",
+ FT_UINT8, BASE_HEX, VALS(evt_role_vals), 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_curr_mode,
+ { "Current Mode", "bthci_evt.current_mode",
+ FT_UINT8, BASE_HEX, VALS(evt_modes), 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_interval,
+ { "Interval", "bthci_evt.interval",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ "Interval - Number of Baseband slots", HFILL }
+ },
+ { &hf_bthci_evt_link_key,
+ { "Link Key", "bthci_evt.link_key",
+ FT_BYTES, BASE_NONE, NULL, 0x0,
+ "Link Key for the associated BD_ADDR", HFILL }
+ },
+ { &hf_bthci_evt_key_type,
+ { "Key Type", "bthci_evt.key_type",
+ FT_UINT8, BASE_HEX, VALS(evt_key_types), 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_max_slots,
+ { "Maximum Number of Slots", "bthci_evt.max_slots",
+ FT_UINT8, BASE_DEC, NULL, 0x0,
+ "Maximum Number of slots allowed for baseband packets", HFILL }
+ },
+ { &hf_bthci_evt_clock_offset,
+ { "Clock Offset", "bthci_evt.clock_offset",
+ FT_UINT16, BASE_HEX, NULL, 0x7FFF,
+ "Bit 2-16 of the Clock Offset between CLKmaster-CLKslave", HFILL }
+ },
+ { &hf_bthci_evt_page_scan_mode,
+ { "Page Scan Mode", "bthci_evt.page_scan_mode",
+ FT_UINT8, BASE_HEX, VALS(evt_page_scan_modes), 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_page_scan_repetition_mode,
+ { "Page Scan Repetition Mode", "bthci_evt.page_scan_repetition_mode",
+ FT_UINT8, BASE_HEX, VALS(evt_page_scan_repetition_modes), 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_page_scan_period_mode,
+ { "Page Scan Period Mode", "bthci_evt.page_scan_period_mode",
+ FT_UINT8, BASE_HEX, VALS(evt_page_scan_period_modes), 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_link_type_2dh1,
+ { "ACL Link Type 2-DH1", "bthci_evt.link_type_2dh1",
+ FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x0002,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_link_type_3dh1,
+ { "ACL Link Type 3-DH1", "bthci_evt.link_type_3dh1",
+ FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x0004,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_link_type_dm1,
+ { "ACL Link Type DM1", "bthci_evt.link_type_dm1",
+ FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x0008,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_link_type_dh1,
+ { "ACL Link Type DH1", "bthci_evt.link_type_dh1",
+ FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x0010,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_link_type_2dh3,
+ { "ACL Link Type 2-DH3", "bthci_evt.link_type_2dh3",
+ FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x0100,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_link_type_3dh3,
+ { "ACL Link Type 3-DH3", "bthci_evt.link_type_3dh3",
+ FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x0200,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_link_type_dm3,
+ { "ACL Link Type DM3", "bthci_evt.link_type_dm3",
+ FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x0400,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_link_type_dh3,
+ { "ACL Link Type DH3", "bthci_evt.link_type_dh3",
+ FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x0800,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_link_type_2dh5,
+ { "ACL Link Type 2-DH5", "bthci_evt.link_type_2dh5",
+ FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x1000,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_link_type_3dh5,
+ { "ACL Link Type 3-DH5", "bthci_evt.link_type_3dh5",
+ FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x2000,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_link_type_dm5,
+ { "ACL Link Type DM5", "bthci_evt.link_type_dm5",
+ FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x4000,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_link_type_dh5,
+ { "ACL Link Type DH5", "bthci_evt.link_type_dh5",
+ FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x8000,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_link_type_hv1,
+ { "SCO Link Type HV1", "bthci_evt.link_type_hv1",
+ FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x0020,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_link_type_hv2,
+ { "SCO Link Type HV2", "bthci_evt.link_type_hv2",
+ FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x0040,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_link_type_hv3,
+ { "SCO Link Type HV3", "bthci_evt.link_type_hv3",
+ FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x0080,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_00,
+ { "3-slot packets", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x01,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_01,
+ { "5-slot packets", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x02,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_02,
+ { "encryption", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x04,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_03,
+ { "slot offset", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x08,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_04,
+ { "timing accuracy", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x10,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_05,
+ { "master/slave switch", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x20,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_06,
+ { "hold mode", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x40,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_07,
+ { "sniff mode", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x80,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_10,
+ { "park mode", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x01,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_11,
+ { "RSSI", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x02,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_12,
+ { "channel quality driven data rate", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x04,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_13,
+ { "SCO link", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x08,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_14,
+ { "HV2 packets", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x10,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_15,
+ { "HV3 packets", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x20,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_16,
+ { "u-law log", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x40,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_17,
+ { "A-law log", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x80,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_20,
+ { "CVSD", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x01,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_21,
+ { "paging scheme", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x02,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_22,
+ { "power control", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x04,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_23,
+ { "transparent SCO data", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x08,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_24,
+ { "Flow control lag", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, NULL, 0x70,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_27,
+ { "broadband encryption", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x80,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_31,
+ { "EDR ACL 2 Mbps mode", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x02,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_32,
+ { "EDR ACL 3 Mbps mode", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x04,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_33,
+ { "enhanced inquiry scan", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x08,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_34,
+ { "interlaced inquiry scan", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x10,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_35,
+ { "interlaced page scan", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x20,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_36,
+ { "RSSI with inquiry results", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x40,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_37,
+ { "eSCO EV3 packets", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x80,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_40,
+ { "eSCO EV4 packets", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x01,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_41,
+ { "eSCO EV5 packets", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x02,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_43,
+ { "AFH capable slave", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x08,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_44,
+ { "AFH classification slave", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x10,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_47,
+ { "3-slot EDR ACL packets", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x80,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_50,
+ { "5-slot EDR ACL packets", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x01,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_51,
+ { "sniff subrating", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x02,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_52,
+ { "pause encryption", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x04,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_53,
+ { "AFH capable master", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x08,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_54,
+ { "AFH classification master", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x10,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_55,
+ { "EDR eSCO 2 Mbps mode", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x20,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_56,
+ { "EDR eSCO 3 Mbps mode", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x40,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_57,
+ { "3-slot EDR eSCO packets", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x80,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_60,
+ { "extended inquiry response", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x01,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_63,
+ { "secure simple pairing", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x08,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_64,
+ { "encapsulated PDU", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x10,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_65,
+ { "erroneous data reporting", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x20,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_66,
+ { "non-flushable packet boundary flag", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x40,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_70,
+ { "link supervision timeout changed event", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x01,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_71,
+ { "inquiry response TX power level", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x02,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_lmp_feature_77,
+ { "extended features", "bthci_evt.lmp_feature",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x80,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_num_keys,
+ { "Number of Link Keys", "bthci_evt.num_keys",
+ FT_UINT8, BASE_DEC, NULL, 0x0,
+ "Number of Link Keys contained", HFILL }
+ },
+ { &hf_bthci_evt_num_keys_read,
+ { "Number of Link Keys Read", "bthci_evt.num_keys_read",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_num_keys_deleted,
+ { "Number of Link Keys Deleted", "bthci_evt.num_keys_deleted",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_num_keys_written,
+ { "Number of Link Keys Written", "bthci_evt.num_keys_written",
+ FT_UINT8, BASE_DEC, NULL, 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_max_num_keys,
+ { "Max Num Keys", "bthci_evt.max_num_keys",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ "Total Number of Link Keys that the Host Controller can store", HFILL }
+ },
+ { &hf_bthci_evt_num_responses,
+ { "Number of responses", "bthci_evt.num_responses",
+ FT_UINT8, BASE_DEC, NULL, 0x0,
+ "Number of Responses from Inquiry", HFILL }
+ },
+ { &hf_bthci_evt_link_policy_setting_switch,
+ { "Enable Master Slave Switch", "bthci_evt.link_policy_switch",
+ FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x0001,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_link_policy_setting_hold,
+ { "Enable Hold Mode", "bthci_evt.link_policy_hold",
+ FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x0002,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_link_policy_setting_sniff,
+ { "Enable Sniff Mode", "bthci_evt.link_policy_sniff",
+ FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x0004,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_link_policy_setting_park,
+ { "Enable Park Mode", "bthci_evt.link_policy_park",
+ FT_UINT16, BASE_DEC, VALS(evt_boolean), 0x0008,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_curr_role,
+ { "Current Role", "bthci_evt.curr_role",
+ FT_UINT8, BASE_HEX, VALS(evt_role_vals_handle), 0x0,
+ "Current role for this connection handle", HFILL }
+ },
+ { &hf_bthci_evt_pin_type,
+ { "PIN Type", "bthci_evt.pin_type",
+ FT_UINT8, BASE_HEX, VALS(evt_pin_types), 0x0,
+ "PIN Types", HFILL }
+ },
+ { &hf_bthci_evt_device_name,
+ { "Device Name", "bthci_evt.device_name",
+ FT_STRINGZ, BASE_NONE, NULL, 0x0,
+ "Userfriendly descriptive name for the device", HFILL }
+ },
+ { &hf_bthci_evt_timeout,
+ { "Timeout", "bthci_evt.timeout",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ "Number of Baseband slots for timeout.", HFILL }
+ },
+ { &hf_bthci_evt_scan_enable,
+ { "Scan", "bthci_evt.scan_enable",
+ FT_UINT8, BASE_HEX, VALS(evt_scan_enable_values), 0x0,
+ "Scan Enable", HFILL }
+ },
+ { &hf_bthci_evt_authentication_enable,
+ { "Authentication", "bthci_evt.auth_enable",
+ FT_UINT8, BASE_HEX, VALS(evt_auth_enable_values), 0x0,
+ "Authentication Enable", HFILL }
+ },
+ { &hf_bthci_evt_sco_flow_cont_enable,
+ { "SCO Flow Control", "bthci_evt.sco_flow_cont_enable",
+ FT_UINT8, BASE_HEX, VALS(evt_enable_values), 0x0,
+ "SCO Flow Control Enable", HFILL }
+ },
+ { &hf_bthci_evt_window,
+ { "Interval", "bthci_evt.window",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ "Window", HFILL }
+ },
+ { &hf_bthci_evt_input_coding,
+ { "Input Coding", "bthci_evt.input_coding",
+ FT_UINT16, BASE_DEC, VALS(evt_input_coding_values), 0x0300,
+ "Authentication Enable", HFILL }
+ },
+ { &hf_bthci_evt_input_data_format,
+ { "Input Data Format", "bthci_evt.input_data_format",
+ FT_UINT16, BASE_DEC, VALS(evt_input_data_format_values), 0x00c0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_input_sample_size,
+ { "Input Sample Size", "bthci_evt.input_sample_size",
+ FT_UINT16, BASE_DEC, VALS(evt_input_sample_size_values), 0x0020,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_num_broadcast_retransm,
+ { "Num Broadcast Retran", "bthci_evt.num_broad_retran",
+ FT_UINT8, BASE_DEC, NULL, 0x0,
+ "Number of Broadcast Retransmissions", HFILL }
+ },
+ { &hf_bthci_evt_hold_mode_act_page,
+ { "Suspend Page Scan", "bthci_evt.hold_mode_page",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x1,
+ "Device can enter low power state", HFILL }
+ },
+ { &hf_bthci_evt_hold_mode_act_inquiry,
+ { "Suspend Inquiry Scan", "bthci_evt.hold_mode_inquiry",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x2,
+ "Device can enter low power state", HFILL }
+ },
+ { &hf_bthci_evt_hold_mode_act_periodic,
+ { "Suspend Periodic Inquiries", "bthci_evt.hold_mode_periodic",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x4,
+ "Device can enter low power state", HFILL }
+ },
+ { &hf_bthci_evt_transmit_power_level,
+ { "Transmit Power Level (dBm)", "bthci_evt.transmit_power_level",
+ FT_INT8, BASE_DEC, NULL, 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_num_supp_iac,
+ {"Num Support IAC", "bthci_evt.num_supp_iac",
+ FT_UINT8, BASE_DEC, NULL, 0x0,
+ "Num of supported IAC the device can simultaneously listen", HFILL }
+ },
+ { &hf_bthci_evt_num_curr_iac,
+ {"Num Current IAC", "bthci_evt.num_curr_iac",
+ FT_UINT8, BASE_DEC, NULL, 0x0,
+ "Num of IACs currently in use to simultaneously listen", HFILL }
+ },
+ { &hf_bthci_evt_iac_lap,
+ { "IAC LAP", "bthci_evt.num_curr_iac",
+ FT_UINT24, BASE_HEX, NULL, 0x0,
+ "LAP(s)used to create IAC", HFILL }
+ },
+ { &hf_bthci_evt_loopback_mode,
+ {"Loopback Mode", "bthci_evt.loopback_mode",
+ FT_UINT8, BASE_HEX, VALS(evt_loopback_modes), 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_country_code,
+ {"Country Code", "bthci_evt.country_code",
+ FT_UINT8, BASE_HEX, VALS(evt_country_code_values), 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_failed_contact_counter,
+ {"Failed Contact Counter", "bthci_evt.failed_contact_counter",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_link_quality,
+ {"Link Quality", "bthci_evt.link_quality",
+ FT_UINT8, BASE_DEC, NULL, 0x0,
+ "Link Quality (0x00 - 0xFF Higher Value = Better Link)", HFILL }
+ },
+ { &hf_bthci_evt_rssi,
+ { "RSSI (dB)", "bthci_evt.rssi",
+ FT_INT8, BASE_DEC, NULL, 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_host_data_packet_length_acl,
+ {"Host ACL Data Packet Length (bytes)", "bthci_evt.max_data_length_acl",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ "Max Host ACL Data Packet length of data portion host is able to accept", HFILL }
+ },
+ { &hf_bthci_evt_host_data_packet_length_sco,
+ {"Host SCO Data Packet Length (bytes)", "bthci_evt.max_data_length_sco",
+ FT_UINT8, BASE_DEC, NULL, 0x0,
+ "Max Host SCO Data Packet length of data portion host is able to accept", HFILL }
+ },
+ { &hf_bthci_evt_host_total_num_acl_data_packets,
+ {"Host Total Num ACL Data Packets", "bthci_evt.max_data_num_acl",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ "Total Number of HCI ACL Data Packets that can be stored in the data buffers of the Host", HFILL }
+ },
+ { &hf_bthci_evt_host_total_num_sco_data_packets,
+ {"Host Total Num SCO Data Packets", "bthci_evt.max_data_num_sco",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ "Total Number of HCI SCO Data Packets that can be stored in the data buffers of the Host", HFILL }
+ },
+ { &hf_bthci_evt_page_number,
+ {"Page Number", "bthci_evt.page_number",
+ FT_UINT8, BASE_DEC, NULL, 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_evt_max_page_number,
+ {"Max. Page Number", "bthci_evt.max_page_number",
+ FT_UINT8, BASE_DEC, NULL, 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_evt_local_supported_cmds,
+ { "Local Supported Commands", "bthci_evt.local_supported_cmds",
+ FT_BYTES, BASE_NONE, NULL, 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_fec_required,
+ {"FEC Required", "bthci_evt.fec_required",
+ FT_UINT8, BASE_DEC, VALS(evt_boolean), 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_evt_err_data_reporting,
+ {"Erroneous Data Reporting", "bthci_evt.err_data_reporting",
+ FT_UINT8, BASE_DEC, VALS(evt_enable_values), 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_evt_scan_type,
+ {"Scan Type", "bthci_evt.inq_scan_type",
+ FT_UINT8, BASE_DEC, VALS(evt_scan_types), 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_evt_inq_mode,
+ {"Inquiry Mode", "bthci_evt.inq_scan_type",
+ FT_UINT8, BASE_DEC, VALS(evt_inq_modes), 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_evt_power_level_type,
+ {"Type", "bthci_evt.power_level_type",
+ FT_UINT8, BASE_HEX, VALS(evt_power_level_types), 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_evt_ext_lmp_features,
+ {"Ext. LMP Features", "bthci_evt.page_number",
+ FT_UINT64, BASE_HEX, NULL, 0x0,
+ "Extended LMP Features", HFILL}
+ },
+ { &hf_bthci_evt_sync_link_type,
+ {"Link Type", "bthci_evt.sync_link_type",
+ FT_UINT8, BASE_HEX, VALS(evt_sync_link_types), 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_evt_sync_tx_interval,
+ {"Transmit Interval", "bthci_evt.sync_tx_interval",
+ FT_UINT8, BASE_DEC, NULL, 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_evt_sync_rtx_window,
+ {"Retransmit Window", "bthci_evt.sync_rtx_window",
+ FT_UINT8, BASE_DEC, NULL, 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_evt_sync_rx_packet_length,
+ {"Rx Packet Length", "bthci_evt.sync_rx_pkt_len",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_evt_sync_tx_packet_length,
+ {"Tx Packet Length", "bthci_evt.sync_tx_pkt_len",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_evt_air_mode,
+ {"Air Mode", "bthci_evt.air_mode",
+ FT_UINT8, BASE_DEC, VALS(evt_air_mode_values), 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_evt_max_tx_latency,
+ {"Max. Tx Latency", "bthci_evt.max_tx_latency",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_evt_max_rx_latency,
+ {"Max. Rx Latency", "bthci_evt.max_rx_latency",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_evt_min_remote_timeout,
+ {"Min. Remote Timeout", "bthci_evt.min_remote_timeout",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_evt_min_local_timeout,
+ {"Min. Local Timeout", "bthci_evt.min_local_timeout",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_evt_link_supervision_timeout,
+ {"Link Supervision Timeout", "bthci_evt.link_supervision_timeout",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_evt_token_bucket_size,
+ { "Token Bucket Size", "bthci_evt.token_bucket_size",
+ FT_UINT32, BASE_DEC, NULL, 0x0,
+ "Token Bucket Size (bytes)", HFILL }
+ },
+ { &hf_bthci_evt_flow_direction,
+ {"Flow Direction", "bthci_evt.flow_direction",
+ FT_UINT8, BASE_DEC, VALS(evt_flow_direction_values), 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_evt_afh_ch_assessment_mode,
+ {"AFH Channel Assessment Mode", "bthci_evt.afh_ch_assessment_mode",
+ FT_UINT8, BASE_DEC, VALS(evt_enable_values), 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_evt_lmp_handle,
+ { "LMP Handle", "bthci_evt.lmp_handle",
+ FT_UINT16, BASE_HEX, NULL, 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_clock,
+ { "Clock", "bthci_evt.clock",
+ FT_UINT32, BASE_HEX, NULL, 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_clock_accuracy,
+ { "Clock", "bthci_evt.clock_accuracy",
+ FT_UINT16, BASE_HEX, NULL, 0x0,
+ NULL, HFILL }
+ },
+ { &hf_bthci_evt_afh_mode,
+ {"AFH Mode", "bthci_evt.afh_mode",
+ FT_UINT8, BASE_DEC, VALS(evt_enable_values), 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_evt_afh_channel_map,
+ {"AFH Channel Map", "bthci_evt.afh_channel_map",
+ FT_UINT_BYTES, BASE_NONE, NULL, 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_evt_simple_pairing_mode,
+ {"Simple Pairing Mode", "bthci_evt.simple_pairing_mode",
+ FT_UINT8, BASE_DEC, VALS(evt_enable_values), 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_evt_hash_c,
+ {"Hash C", "bthci_evt.hash_c",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_evt_randomizer_r,
+ {"Randomizer R", "bthci_evt.randomizer_r",
+ FT_UINT16, BASE_DEC, NULL, 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_evt_io_capability,
+ {"IO Capability", "bthci_evt.io_capability",
+ FT_UINT8, BASE_HEX, VALS(bthci_cmd_io_capability_vals), 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_evt_oob_data_present,
+ {"OOB Data Present", "bthci_evt.oob_data_present",
+ FT_UINT8, BASE_DEC, VALS(bthci_cmd_oob_data_present_vals), 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_evt_auth_requirements,
+ {"Authentication Requirements", "bthci_evt.auth_requirements",
+ FT_UINT8, BASE_DEC|BASE_EXT_STRING, &bthci_cmd_auth_req_vals_ext, 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_evt_numeric_value,
+ {"Numeric Value", "bthci_evt.numeric_value",
+ FT_UINT32, BASE_DEC, NULL, 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_evt_passkey,
+ {"Passkey", "bthci_evt.passkey",
+ FT_UINT32, BASE_DEC, NULL, 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_evt_notification_type,
+ {"Notification Type", "bthci_evt.notification_type",
+ FT_UINT8, BASE_DEC, VALS(evt_notification_type_vals), 0x0,
+ NULL, HFILL}
+ },
+ { &hf_bthci_evt_eir_data,
+ {"Data", "bthci_evt.eir_data",
+ FT_BYTES, BASE_NONE, NULL, 0x0,
+ "EIR Data", HFILL}
+ },
+ { &hf_bthci_evt_eir_struct_length,
+ { "Length", "bthci_evt.eir_struct_length",
+ FT_UINT8, BASE_DEC, NULL, 0x0,
+ "Structure Length", HFILL }
+ },
+ { &hf_bthci_evt_eir_struct_type,
+ { "Type", "bthci_evt.eir_data_type",
+ FT_UINT8, BASE_HEX|BASE_EXT_STRING, &bthci_cmd_eir_data_type_vals_ext, 0x0,
+ "Data Type", HFILL }
+ },
+ { &hf_bthci_evt_sc_uuid16,
+ { "UUID", "bthci_evt.service_class_uuid16",
+ FT_UINT16, BASE_HEX|BASE_EXT_STRING, &bthci_cmd_service_class_type_vals_ext, 0x0,
+ "16-bit Service Class UUID", HFILL }
+ },
+ { &hf_bthci_evt_sc_uuid32,
+ { "UUID", "bthci_evt.service_class_uuid32",
+ FT_UINT32, BASE_HEX, NULL, 0x0,
+ "32-bit Service Class UUID", HFILL }
+ },
+ { &hf_bthci_evt_sc_uuid128,
+ { "UUID", "bthci_evt.service_class_uuid128",
+ FT_BYTES, BASE_NONE, NULL, 0x0,
+ "128-bit Service Class UUID", HFILL }
+ }
+ };
+
+ /* Setup protocol subtree array */
+ static gint *ett[] = {
+ &ett_bthci_evt,
+ &ett_opcode,
+ &ett_lmp_subtree,
+ &ett_ptype_subtree,
+ &ett_eir_subtree,
+ &ett_eir_struct_subtree
+ };
+
+ /* Register the protocol name and description */
+ proto_bthci_evt = proto_register_protocol("Bluetooth HCI Event",
+ "HCI_EVT", "bthci_evt");
+
+ new_register_dissector("bthci_evt", dissect_bthci_evt, proto_bthci_evt);
+
+
+
+ /* Required function calls to register the header fields and subtrees used */
+ proto_register_field_array(proto_bthci_evt, hf, array_length(hf));
+ proto_register_subtree_array(ett, array_length(ett));
}
@@ -3599,13 +3599,13 @@ proto_register_bthci_evt(void)
void
proto_reg_handoff_bthci_evt(void)
{
- dissector_handle_t bthci_evt_handle;
+ dissector_handle_t bthci_evt_handle;
- bthci_evt_handle = find_dissector("bthci_evt");
- dissector_add_uint("hci_h4.type", HCI_H4_TYPE_EVT, bthci_evt_handle);
- dissector_add_uint("hci_h1.type", BTHCI_CHANNEL_EVENT, bthci_evt_handle);
+ bthci_evt_handle = find_dissector("bthci_evt");
+ dissector_add_uint("hci_h4.type", HCI_H4_TYPE_EVT, bthci_evt_handle);
+ dissector_add_uint("hci_h1.type", BTHCI_CHANNEL_EVENT, bthci_evt_handle);
- bthci_com_handle = find_dissector("bthci_cmd");
+ bthci_com_handle = find_dissector("bthci_cmd");
}
diff --git a/epan/dissectors/packet-bthci_sco.c b/epan/dissectors/packet-bthci_sco.c
index 9072ff88f7..ea0438e503 100644
--- a/epan/dissectors/packet-bthci_sco.c
+++ b/epan/dissectors/packet-bthci_sco.c
@@ -49,68 +49,68 @@ static gint ett_btsco = -1;
static void
dissect_btsco(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *tree)
{
- proto_item *ti;
- proto_tree *btsco_tree;
- int offset=0;
+ proto_item *ti;
+ proto_tree *btsco_tree;
+ int offset = 0;
- ti = proto_tree_add_item(tree, proto_btsco, tvb, offset, -1, ENC_NA);
- btsco_tree = proto_item_add_subtree(ti, ett_btsco);
+ ti = proto_tree_add_item(tree, proto_btsco, tvb, offset, -1, ENC_NA);
+ btsco_tree = proto_item_add_subtree(ti, ett_btsco);
- proto_tree_add_item(btsco_tree, hf_btsco_chandle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
- offset+=2;
+ proto_tree_add_item(btsco_tree, hf_btsco_chandle, tvb, offset, 2, ENC_LITTLE_ENDIAN);
+ offset+=2;
- proto_tree_add_item(btsco_tree, hf_btsco_length, tvb, offset, 1, ENC_LITTLE_ENDIAN);
- offset++;
+ proto_tree_add_item(btsco_tree, hf_btsco_length, tvb, offset, 1, ENC_LITTLE_ENDIAN);
+ offset++;
- proto_tree_add_item(btsco_tree, hf_btsco_data, tvb, offset, -1, ENC_NA);
+ proto_tree_add_item(btsco_tree, hf_btsco_data, tvb, offset, -1, ENC_NA);
}
void
proto_register_btsco(void)
{
- static hf_register_info hf[] = {
- { &hf_btsco_chandle,
- { "Connection Handle", "bthci_sco.chandle",
- FT_UINT16, BASE_HEX, NULL, 0x0FFF,
- NULL, HFILL }
- },
- { &hf_btsco_length,
- { "Data Total Length", "bthci_sco.length",
- FT_UINT8, BASE_DEC, NULL, 0x0,
- NULL, HFILL }
- },
- { &hf_btsco_data,
- { "Data", "bthci_sco.data",
- FT_NONE, BASE_NONE, NULL, 0x0,
- NULL, HFILL }
- },
- };
-
- /* Setup protocol subtree array */
- static gint *ett[] = {
- &ett_btsco,
- };
-
- /* Register the protocol name and description */
- proto_btsco = proto_register_protocol("Bluetooth HCI SCO Packet", "HCI_SCO", "bthci_sco");
- register_dissector("bthci_sco", dissect_btsco, proto_btsco);
-
- /* Required function calls to register the header fields and subtrees used */
- proto_register_field_array(proto_btsco, hf, array_length(hf));
- proto_register_subtree_array(ett, array_length(ett));
+ static hf_register_info hf[] = {
+ { &hf_btsco_chandle,
+ { "Connection Handle", "bthci_sco.chandle",
+ FT_UINT16, BASE_HEX, NULL, 0x0FFF,
+ NULL, HFILL }
+ },
+ { &hf_btsco_length,
+ { "Data Total Length", "bthci_sco.length",
+ FT_UINT8, BASE_DEC, NULL, 0x0,
+ NULL, HFILL }
+ },
+ { &hf_btsco_data,
+ { "Data", "bthci_sco.data",
+ FT_NONE, BASE_NONE, NULL, 0x0,
+ NULL, HFILL }
+ },
+ };
+
+ /* Setup protocol subtree array */
+ static gint *ett[] = {
+ &ett_btsco,
+ };
+
+ /* Register the protocol name and description */
+ proto_btsco = proto_register_protocol("Bluetooth HCI SCO Packet", "HCI_SCO", "bthci_sco");
+ register_dissector("bthci_sco", dissect_btsco, proto_btsco);
+
+ /* Required function calls to register the header fields and subtrees used */
+ proto_register_field_array(proto_btsco, hf, array_length(hf));
+ proto_register_subtree_array(ett, array_length(ett));
}
void
proto_reg_handoff_btsco(void)
{
- dissector_handle_t bthci_sco_handle;
+ dissector_handle_t bthci_sco_handle;
- bthci_sco_handle = find_dissector("bthci_sco");
- dissector_add_uint("hci_h4.type", HCI_H4_TYPE_SCO, bthci_sco_handle);
- dissector_add_uint("hci_h1.type", BTHCI_CHANNEL_SCO, bthci_sco_handle);
+ bthci_sco_handle = find_dissector("bthci_sco");
+ dissector_add_uint("hci_h4.type", HCI_H4_TYPE_SCO, bthci_sco_handle);
+ dissector_add_uint("hci_h1.type", BTHCI_CHANNEL_SCO, bthci_sco_handle);
}