uint8_t data[0];
} __attribute__ ((packed));
+#define BT_HCI_EVT_LE_PER_SYNC_ESTABLISHED 0x0e
+struct bt_hci_evt_le_per_sync_established {
+ uint8_t status;
+ uint16_t handle;
+ uint8_t sid;
+ uint8_t addr_type;
+ uint8_t addr[6];
+ uint8_t phy;
+ uint16_t interval;
+ uint8_t clock_accuracy;
+} __attribute__ ((packed));
+
#define BT_HCI_EVT_LE_ADV_SET_TERM 0x12
struct bt_hci_evt_le_adv_set_term {
uint8_t status;
}
}
+static void le_per_adv_sync(const void *data, uint8_t size)
+{
+ const struct bt_hci_evt_le_per_sync_established *evt = data;
+
+ print_status(evt->status);
+ print_field("Sync handle: %d", evt->handle);
+ if (evt->sid > 0x0f)
+ print_field("Advertising SID: Reserved (0x%2.2x)", evt->sid);
+ else
+ print_field("Advertising SID: 0x%2.2x", evt->sid);
+
+ print_peer_addr_type("Advertiser address type", evt->addr_type);
+ print_addr("Advertiser address", evt->addr, evt->addr_type);
+ print_le_phy("Advertiser PHY", evt->phy);
+ print_slot_125("Periodic advertising invteral", evt->interval);
+ print_field("Advertiser clock accuracy: 0x%2.2x", evt->clock_accuracy);
+}
+
static void le_adv_set_term_evt(const void *data, uint8_t size)
{
const struct bt_hci_evt_le_adv_set_term *evt = data;
le_phy_update_complete_evt, 5, true},
{ 0x0d, "LE Extended Advertising Report",
le_ext_adv_report_evt, 1, false},
- { 0x0e, "LE Periodic Advertising Sync Established" },
+ { 0x0e, "LE Periodic Advertising Sync Established",
+ le_per_adv_sync, 15, true },
{ 0x0f, "LE Periodic Advertising Report" },
{ 0x10, "LE Periodic Advertising Sync Lost" },
{ 0x11, "LE Scan Timeout" },