summaryrefslogtreecommitdiff
path: root/monitor
diff options
context:
space:
mode:
authorJohan Hedberg <johan.hedberg@intel.com>2013-10-11 20:50:27 +0200
committerJohan Hedberg <johan.hedberg@intel.com>2013-10-11 21:02:07 +0200
commiteca8b2d24c6d0962f370f12f6582e74659807759 (patch)
tree6f10e2805781ea0d857a00fb4b8c65946173fadb /monitor
parent0b24507b8a3e0e003b57af0849c74d8d06b2e5b0 (diff)
monitor: Add ATT Read Multiple Request decoding
Diffstat (limited to 'monitor')
-rw-r--r--monitor/l2cap.c14
1 files changed, 13 insertions, 1 deletions
diff --git a/monitor/l2cap.c b/monitor/l2cap.c
index 04290b368..fd35feb03 100644
--- a/monitor/l2cap.c
+++ b/monitor/l2cap.c
@@ -1928,6 +1928,17 @@ static void att_read_blob_rsp(const struct l2cap_frame *frame)
packet_hexdump(frame->data, frame->size);
}
+static void att_read_multiple_req(const struct l2cap_frame *frame)
+{
+ int i, count;
+
+ count = frame->size / 2;
+
+ for (i = 0; i < count; i++)
+ print_field("Handle: 0x%4.4x",
+ bt_get_le16(frame->data + (i * 2)));
+}
+
static void att_read_group_type_req(const struct l2cap_frame *frame)
{
print_handle_range("Handle range", frame->data);
@@ -2014,7 +2025,8 @@ static const struct att_opcode_data att_opcode_table[] = {
att_read_blob_req, 4, true },
{ 0x0d, "Read Blob Response",
att_read_blob_rsp, 0, false },
- { 0x0e, "Read Multiple Request" },
+ { 0x0e, "Read Multiple Request",
+ att_read_multiple_req, 4, false },
{ 0x0f, "Read Multiple Response" },
{ 0x10, "Read By Group Type Request",
att_read_group_type_req, 6, false },