1 /* 2 * Copyright (C) 2016 BlueKitchen GmbH 3 * 4 * Redistribution and use in source and binary forms, with or without 5 * modification, are permitted provided that the following conditions 6 * are met: 7 * 8 * 1. Redistributions of source code must retain the above copyright 9 * notice, this list of conditions and the following disclaimer. 10 * 2. Redistributions in binary form must reproduce the above copyright 11 * notice, this list of conditions and the following disclaimer in the 12 * documentation and/or other materials provided with the distribution. 13 * 3. Neither the name of the copyright holders nor the names of 14 * contributors may be used to endorse or promote products derived 15 * from this software without specific prior written permission. 16 * 4. Any redistribution, use, or modification is done solely for 17 * personal benefit and not for any commercial purpose or for 18 * monetary gain. 19 * 20 * THIS SOFTWARE IS PROVIDED BY BLUEKITCHEN GMBH AND CONTRIBUTORS 21 * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 22 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 23 * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL MATTHIAS 24 * RINGWALD OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 25 * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 26 * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS 27 * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED 28 * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, 29 * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF 30 * THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 31 * SUCH DAMAGE. 32 * 33 * Please inquire about commercial licensing options at 34 * [email protected] 35 * 36 */ 37 38 39 /** 40 * HCI Event Getter 41 * 42 * Note: Don't edit this file. It is generated by tool/btstack_event_generator.py 43 * 44 */ 45 46 #ifndef BTSTACK_EVENT_H 47 #define BTSTACK_EVENT_H 48 49 #if defined __cplusplus 50 extern "C" { 51 #endif 52 53 #include "btstack_util.h" 54 #include <stdint.h> 55 56 #ifdef ENABLE_BLE 57 #include "ble/gatt_client.h" 58 #endif 59 60 /* API_START */ 61 62 /** 63 * @brief Get event type 64 * @param event 65 * @return type of event 66 */ 67 static inline uint8_t hci_event_packet_get_type(const uint8_t * event){ 68 return event[0]; 69 } 70 71 /*** 72 * @brief Get subevent code for a2dp event 73 * @param event packet 74 * @return subevent_code 75 */ 76 static inline uint8_t hci_event_a2dp_meta_get_subevent_code(const uint8_t * event){ 77 return event[2]; 78 } 79 /*** 80 * @brief Get subevent code for ancs event 81 * @param event packet 82 * @return subevent_code 83 */ 84 static inline uint8_t hci_event_ancs_meta_get_subevent_code(const uint8_t * event){ 85 return event[2]; 86 } 87 /*** 88 * @brief Get subevent code for avdtp event 89 * @param event packet 90 * @return subevent_code 91 */ 92 static inline uint8_t hci_event_avdtp_meta_get_subevent_code(const uint8_t * event){ 93 return event[2]; 94 } 95 /*** 96 * @brief Get subevent code for avrcp event 97 * @param event packet 98 * @return subevent_code 99 */ 100 static inline uint8_t hci_event_avrcp_meta_get_subevent_code(const uint8_t * event){ 101 return event[2]; 102 } 103 /*** 104 * @brief Get subevent code for gattservice event 105 * @param event packet 106 * @return subevent_code 107 */ 108 static inline uint8_t hci_event_gattservice_meta_get_subevent_code(const uint8_t * event){ 109 return event[2]; 110 } 111 /*** 112 * @brief Get subevent code for goep event 113 * @param event packet 114 * @return subevent_code 115 */ 116 static inline uint8_t hci_event_goep_meta_get_subevent_code(const uint8_t * event){ 117 return event[2]; 118 } 119 /*** 120 * @brief Get subevent code for hfp event 121 * @param event packet 122 * @return subevent_code 123 */ 124 static inline uint8_t hci_event_hfp_meta_get_subevent_code(const uint8_t * event){ 125 return event[2]; 126 } 127 /*** 128 * @brief Get subevent code for hid event 129 * @param event packet 130 * @return subevent_code 131 */ 132 static inline uint8_t hci_event_hid_meta_get_subevent_code(const uint8_t * event){ 133 return event[2]; 134 } 135 /*** 136 * @brief Get subevent code for hids event 137 * @param event packet 138 * @return subevent_code 139 */ 140 static inline uint8_t hci_event_hids_meta_get_subevent_code(const uint8_t * event){ 141 return event[2]; 142 } 143 /*** 144 * @brief Get subevent code for hsp event 145 * @param event packet 146 * @return subevent_code 147 */ 148 static inline uint8_t hci_event_hsp_meta_get_subevent_code(const uint8_t * event){ 149 return event[2]; 150 } 151 /*** 152 * @brief Get subevent code for le event 153 * @param event packet 154 * @return subevent_code 155 */ 156 static inline uint8_t hci_event_le_meta_get_subevent_code(const uint8_t * event){ 157 return event[2]; 158 } 159 /*** 160 * @brief Get subevent code for map event 161 * @param event packet 162 * @return subevent_code 163 */ 164 static inline uint8_t hci_event_map_meta_get_subevent_code(const uint8_t * event){ 165 return event[2]; 166 } 167 /*** 168 * @brief Get subevent code for mesh event 169 * @param event packet 170 * @return subevent_code 171 */ 172 static inline uint8_t hci_event_mesh_meta_get_subevent_code(const uint8_t * event){ 173 return event[2]; 174 } 175 /*** 176 * @brief Get subevent code for pbap event 177 * @param event packet 178 * @return subevent_code 179 */ 180 static inline uint8_t hci_event_pbap_meta_get_subevent_code(const uint8_t * event){ 181 return event[2]; 182 } 183 /** 184 * @brief Get field status from event HCI_EVENT_INQUIRY_COMPLETE 185 * @param event packet 186 * @return status 187 * @note: btstack_type 1 188 */ 189 static inline uint8_t hci_event_inquiry_complete_get_status(const uint8_t * event){ 190 return event[2]; 191 } 192 193 /** 194 * @brief Get field num_responses from event HCI_EVENT_INQUIRY_RESULT 195 * @param event packet 196 * @return num_responses 197 * @note: btstack_type 1 198 */ 199 static inline uint8_t hci_event_inquiry_result_get_num_responses(const uint8_t * event){ 200 return event[2]; 201 } 202 /** 203 * @brief Get field bd_addr from event HCI_EVENT_INQUIRY_RESULT 204 * @param event packet 205 * @param Pointer to storage for bd_addr 206 * @note: btstack_type B 207 */ 208 static inline void hci_event_inquiry_result_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 209 reverse_bytes(&event[3], bd_addr, 6); 210 } 211 /** 212 * @brief Get field page_scan_repetition_mode from event HCI_EVENT_INQUIRY_RESULT 213 * @param event packet 214 * @return page_scan_repetition_mode 215 * @note: btstack_type 1 216 */ 217 static inline uint8_t hci_event_inquiry_result_get_page_scan_repetition_mode(const uint8_t * event){ 218 return event[9]; 219 } 220 /** 221 * @brief Get field reserved1 from event HCI_EVENT_INQUIRY_RESULT 222 * @param event packet 223 * @return reserved1 224 * @note: btstack_type 1 225 */ 226 static inline uint8_t hci_event_inquiry_result_get_reserved1(const uint8_t * event){ 227 return event[10]; 228 } 229 /** 230 * @brief Get field reserved2 from event HCI_EVENT_INQUIRY_RESULT 231 * @param event packet 232 * @return reserved2 233 * @note: btstack_type 1 234 */ 235 static inline uint8_t hci_event_inquiry_result_get_reserved2(const uint8_t * event){ 236 return event[11]; 237 } 238 /** 239 * @brief Get field class_of_device from event HCI_EVENT_INQUIRY_RESULT 240 * @param event packet 241 * @return class_of_device 242 * @note: btstack_type 3 243 */ 244 static inline uint32_t hci_event_inquiry_result_get_class_of_device(const uint8_t * event){ 245 return little_endian_read_24(event, 12); 246 } 247 /** 248 * @brief Get field clock_offset from event HCI_EVENT_INQUIRY_RESULT 249 * @param event packet 250 * @return clock_offset 251 * @note: btstack_type 2 252 */ 253 static inline uint16_t hci_event_inquiry_result_get_clock_offset(const uint8_t * event){ 254 return little_endian_read_16(event, 15); 255 } 256 257 /** 258 * @brief Get field status from event HCI_EVENT_CONNECTION_COMPLETE 259 * @param event packet 260 * @return status 261 * @note: btstack_type 1 262 */ 263 static inline uint8_t hci_event_connection_complete_get_status(const uint8_t * event){ 264 return event[2]; 265 } 266 /** 267 * @brief Get field connection_handle from event HCI_EVENT_CONNECTION_COMPLETE 268 * @param event packet 269 * @return connection_handle 270 * @note: btstack_type 2 271 */ 272 static inline uint16_t hci_event_connection_complete_get_connection_handle(const uint8_t * event){ 273 return little_endian_read_16(event, 3); 274 } 275 /** 276 * @brief Get field bd_addr from event HCI_EVENT_CONNECTION_COMPLETE 277 * @param event packet 278 * @param Pointer to storage for bd_addr 279 * @note: btstack_type B 280 */ 281 static inline void hci_event_connection_complete_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 282 reverse_bytes(&event[5], bd_addr, 6); 283 } 284 /** 285 * @brief Get field link_type from event HCI_EVENT_CONNECTION_COMPLETE 286 * @param event packet 287 * @return link_type 288 * @note: btstack_type 1 289 */ 290 static inline uint8_t hci_event_connection_complete_get_link_type(const uint8_t * event){ 291 return event[11]; 292 } 293 /** 294 * @brief Get field encryption_enabled from event HCI_EVENT_CONNECTION_COMPLETE 295 * @param event packet 296 * @return encryption_enabled 297 * @note: btstack_type 1 298 */ 299 static inline uint8_t hci_event_connection_complete_get_encryption_enabled(const uint8_t * event){ 300 return event[12]; 301 } 302 303 /** 304 * @brief Get field bd_addr from event HCI_EVENT_CONNECTION_REQUEST 305 * @param event packet 306 * @param Pointer to storage for bd_addr 307 * @note: btstack_type B 308 */ 309 static inline void hci_event_connection_request_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 310 reverse_bytes(&event[2], bd_addr, 6); 311 } 312 /** 313 * @brief Get field class_of_device from event HCI_EVENT_CONNECTION_REQUEST 314 * @param event packet 315 * @return class_of_device 316 * @note: btstack_type 3 317 */ 318 static inline uint32_t hci_event_connection_request_get_class_of_device(const uint8_t * event){ 319 return little_endian_read_24(event, 8); 320 } 321 /** 322 * @brief Get field link_type from event HCI_EVENT_CONNECTION_REQUEST 323 * @param event packet 324 * @return link_type 325 * @note: btstack_type 1 326 */ 327 static inline uint8_t hci_event_connection_request_get_link_type(const uint8_t * event){ 328 return event[11]; 329 } 330 331 /** 332 * @brief Get field status from event HCI_EVENT_DISCONNECTION_COMPLETE 333 * @param event packet 334 * @return status 335 * @note: btstack_type 1 336 */ 337 static inline uint8_t hci_event_disconnection_complete_get_status(const uint8_t * event){ 338 return event[2]; 339 } 340 /** 341 * @brief Get field connection_handle from event HCI_EVENT_DISCONNECTION_COMPLETE 342 * @param event packet 343 * @return connection_handle 344 * @note: btstack_type 2 345 */ 346 static inline uint16_t hci_event_disconnection_complete_get_connection_handle(const uint8_t * event){ 347 return little_endian_read_16(event, 3); 348 } 349 /** 350 * @brief Get field reason from event HCI_EVENT_DISCONNECTION_COMPLETE 351 * @param event packet 352 * @return reason 353 * @note: btstack_type 1 354 */ 355 static inline uint8_t hci_event_disconnection_complete_get_reason(const uint8_t * event){ 356 return event[5]; 357 } 358 359 /** 360 * @brief Get field status from event HCI_EVENT_AUTHENTICATION_COMPLETE 361 * @param event packet 362 * @return status 363 * @note: btstack_type 1 364 */ 365 static inline uint8_t hci_event_authentication_complete_get_status(const uint8_t * event){ 366 return event[2]; 367 } 368 /** 369 * @brief Get field connection_handle from event HCI_EVENT_AUTHENTICATION_COMPLETE 370 * @param event packet 371 * @return connection_handle 372 * @note: btstack_type 2 373 */ 374 static inline uint16_t hci_event_authentication_complete_get_connection_handle(const uint8_t * event){ 375 return little_endian_read_16(event, 3); 376 } 377 378 /** 379 * @brief Get field status from event HCI_EVENT_REMOTE_NAME_REQUEST_COMPLETE 380 * @param event packet 381 * @return status 382 * @note: btstack_type 1 383 */ 384 static inline uint8_t hci_event_remote_name_request_complete_get_status(const uint8_t * event){ 385 return event[2]; 386 } 387 /** 388 * @brief Get field bd_addr from event HCI_EVENT_REMOTE_NAME_REQUEST_COMPLETE 389 * @param event packet 390 * @param Pointer to storage for bd_addr 391 * @note: btstack_type B 392 */ 393 static inline void hci_event_remote_name_request_complete_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 394 reverse_bytes(&event[3], bd_addr, 6); 395 } 396 /** 397 * @brief Get field remote_name from event HCI_EVENT_REMOTE_NAME_REQUEST_COMPLETE 398 * @param event packet 399 * @return remote_name 400 * @note: btstack_type N 401 */ 402 static inline const char * hci_event_remote_name_request_complete_get_remote_name(const uint8_t * event){ 403 return (const char *) &event[9]; 404 } 405 406 /** 407 * @brief Get field status from event HCI_EVENT_ENCRYPTION_CHANGE 408 * @param event packet 409 * @return status 410 * @note: btstack_type 1 411 */ 412 static inline uint8_t hci_event_encryption_change_get_status(const uint8_t * event){ 413 return event[2]; 414 } 415 /** 416 * @brief Get field connection_handle from event HCI_EVENT_ENCRYPTION_CHANGE 417 * @param event packet 418 * @return connection_handle 419 * @note: btstack_type 2 420 */ 421 static inline uint16_t hci_event_encryption_change_get_connection_handle(const uint8_t * event){ 422 return little_endian_read_16(event, 3); 423 } 424 /** 425 * @brief Get field encryption_enabled from event HCI_EVENT_ENCRYPTION_CHANGE 426 * @param event packet 427 * @return encryption_enabled 428 * @note: btstack_type 1 429 */ 430 static inline uint8_t hci_event_encryption_change_get_encryption_enabled(const uint8_t * event){ 431 return event[5]; 432 } 433 434 /** 435 * @brief Get field status from event HCI_EVENT_CHANGE_CONNECTION_LINK_KEY_COMPLETE 436 * @param event packet 437 * @return status 438 * @note: btstack_type 1 439 */ 440 static inline uint8_t hci_event_change_connection_link_key_complete_get_status(const uint8_t * event){ 441 return event[2]; 442 } 443 /** 444 * @brief Get field connection_handle from event HCI_EVENT_CHANGE_CONNECTION_LINK_KEY_COMPLETE 445 * @param event packet 446 * @return connection_handle 447 * @note: btstack_type 2 448 */ 449 static inline uint16_t hci_event_change_connection_link_key_complete_get_connection_handle(const uint8_t * event){ 450 return little_endian_read_16(event, 3); 451 } 452 453 /** 454 * @brief Get field status from event HCI_EVENT_MASTER_LINK_KEY_COMPLETE 455 * @param event packet 456 * @return status 457 * @note: btstack_type 1 458 */ 459 static inline uint8_t hci_event_master_link_key_complete_get_status(const uint8_t * event){ 460 return event[2]; 461 } 462 /** 463 * @brief Get field connection_handle from event HCI_EVENT_MASTER_LINK_KEY_COMPLETE 464 * @param event packet 465 * @return connection_handle 466 * @note: btstack_type 2 467 */ 468 static inline uint16_t hci_event_master_link_key_complete_get_connection_handle(const uint8_t * event){ 469 return little_endian_read_16(event, 3); 470 } 471 /** 472 * @brief Get field key_flag from event HCI_EVENT_MASTER_LINK_KEY_COMPLETE 473 * @param event packet 474 * @return key_flag 475 * @note: btstack_type 1 476 */ 477 static inline uint8_t hci_event_master_link_key_complete_get_key_flag(const uint8_t * event){ 478 return event[5]; 479 } 480 481 /** 482 * @brief Get field status from event HCI_EVENT_READ_REMOTE_VERSION_INFORMATION_COMPLETE 483 * @param event packet 484 * @return status 485 * @note: btstack_type 1 486 */ 487 static inline uint8_t hci_event_read_remote_version_information_complete_get_status(const uint8_t * event){ 488 return event[2]; 489 } 490 /** 491 * @brief Get field connection_handle from event HCI_EVENT_READ_REMOTE_VERSION_INFORMATION_COMPLETE 492 * @param event packet 493 * @return connection_handle 494 * @note: btstack_type 2 495 */ 496 static inline uint16_t hci_event_read_remote_version_information_complete_get_connection_handle(const uint8_t * event){ 497 return little_endian_read_16(event, 3); 498 } 499 /** 500 * @brief Get field version from event HCI_EVENT_READ_REMOTE_VERSION_INFORMATION_COMPLETE 501 * @param event packet 502 * @return version 503 * @note: btstack_type 1 504 */ 505 static inline uint8_t hci_event_read_remote_version_information_complete_get_version(const uint8_t * event){ 506 return event[5]; 507 } 508 /** 509 * @brief Get field manufacturer_name from event HCI_EVENT_READ_REMOTE_VERSION_INFORMATION_COMPLETE 510 * @param event packet 511 * @return manufacturer_name 512 * @note: btstack_type 2 513 */ 514 static inline uint16_t hci_event_read_remote_version_information_complete_get_manufacturer_name(const uint8_t * event){ 515 return little_endian_read_16(event, 6); 516 } 517 /** 518 * @brief Get field subversion from event HCI_EVENT_READ_REMOTE_VERSION_INFORMATION_COMPLETE 519 * @param event packet 520 * @return subversion 521 * @note: btstack_type 2 522 */ 523 static inline uint16_t hci_event_read_remote_version_information_complete_get_subversion(const uint8_t * event){ 524 return little_endian_read_16(event, 8); 525 } 526 527 /** 528 * @brief Get field num_hci_command_packets from event HCI_EVENT_COMMAND_COMPLETE 529 * @param event packet 530 * @return num_hci_command_packets 531 * @note: btstack_type 1 532 */ 533 static inline uint8_t hci_event_command_complete_get_num_hci_command_packets(const uint8_t * event){ 534 return event[2]; 535 } 536 /** 537 * @brief Get field command_opcode from event HCI_EVENT_COMMAND_COMPLETE 538 * @param event packet 539 * @return command_opcode 540 * @note: btstack_type 2 541 */ 542 static inline uint16_t hci_event_command_complete_get_command_opcode(const uint8_t * event){ 543 return little_endian_read_16(event, 3); 544 } 545 /** 546 * @brief Get field return_parameters from event HCI_EVENT_COMMAND_COMPLETE 547 * @param event packet 548 * @return return_parameters 549 * @note: btstack_type R 550 */ 551 static inline const uint8_t * hci_event_command_complete_get_return_parameters(const uint8_t * event){ 552 return &event[5]; 553 } 554 555 /** 556 * @brief Get field status from event HCI_EVENT_COMMAND_STATUS 557 * @param event packet 558 * @return status 559 * @note: btstack_type 1 560 */ 561 static inline uint8_t hci_event_command_status_get_status(const uint8_t * event){ 562 return event[2]; 563 } 564 /** 565 * @brief Get field num_hci_command_packets from event HCI_EVENT_COMMAND_STATUS 566 * @param event packet 567 * @return num_hci_command_packets 568 * @note: btstack_type 1 569 */ 570 static inline uint8_t hci_event_command_status_get_num_hci_command_packets(const uint8_t * event){ 571 return event[3]; 572 } 573 /** 574 * @brief Get field command_opcode from event HCI_EVENT_COMMAND_STATUS 575 * @param event packet 576 * @return command_opcode 577 * @note: btstack_type 2 578 */ 579 static inline uint16_t hci_event_command_status_get_command_opcode(const uint8_t * event){ 580 return little_endian_read_16(event, 4); 581 } 582 583 /** 584 * @brief Get field hardware_code from event HCI_EVENT_HARDWARE_ERROR 585 * @param event packet 586 * @return hardware_code 587 * @note: btstack_type 1 588 */ 589 static inline uint8_t hci_event_hardware_error_get_hardware_code(const uint8_t * event){ 590 return event[2]; 591 } 592 593 /** 594 * @brief Get field status from event HCI_EVENT_ROLE_CHANGE 595 * @param event packet 596 * @return status 597 * @note: btstack_type 1 598 */ 599 static inline uint8_t hci_event_role_change_get_status(const uint8_t * event){ 600 return event[2]; 601 } 602 /** 603 * @brief Get field bd_addr from event HCI_EVENT_ROLE_CHANGE 604 * @param event packet 605 * @param Pointer to storage for bd_addr 606 * @note: btstack_type B 607 */ 608 static inline void hci_event_role_change_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 609 reverse_bytes(&event[3], bd_addr, 6); 610 } 611 /** 612 * @brief Get field role from event HCI_EVENT_ROLE_CHANGE 613 * @param event packet 614 * @return role 615 * @note: btstack_type 1 616 */ 617 static inline uint8_t hci_event_role_change_get_role(const uint8_t * event){ 618 return event[9]; 619 } 620 621 /** 622 * @brief Get field status from event HCI_EVENT_MODE_CHANGE 623 * @param event packet 624 * @return status 625 * @note: btstack_type 1 626 */ 627 static inline uint8_t hci_event_mode_change_get_status(const uint8_t * event){ 628 return event[2]; 629 } 630 /** 631 * @brief Get field handle from event HCI_EVENT_MODE_CHANGE 632 * @param event packet 633 * @return handle 634 * @note: btstack_type H 635 */ 636 static inline hci_con_handle_t hci_event_mode_change_get_handle(const uint8_t * event){ 637 return little_endian_read_16(event, 3); 638 } 639 /** 640 * @brief Get field mode from event HCI_EVENT_MODE_CHANGE 641 * @param event packet 642 * @return mode 643 * @note: btstack_type 1 644 */ 645 static inline uint8_t hci_event_mode_change_get_mode(const uint8_t * event){ 646 return event[5]; 647 } 648 /** 649 * @brief Get field interval from event HCI_EVENT_MODE_CHANGE 650 * @param event packet 651 * @return interval 652 * @note: btstack_type 2 653 */ 654 static inline uint16_t hci_event_mode_change_get_interval(const uint8_t * event){ 655 return little_endian_read_16(event, 6); 656 } 657 658 /** 659 * @brief Get field bd_addr from event HCI_EVENT_PIN_CODE_REQUEST 660 * @param event packet 661 * @param Pointer to storage for bd_addr 662 * @note: btstack_type B 663 */ 664 static inline void hci_event_pin_code_request_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 665 reverse_bytes(&event[2], bd_addr, 6); 666 } 667 668 /** 669 * @brief Get field bd_addr from event HCI_EVENT_LINK_KEY_REQUEST 670 * @param event packet 671 * @param Pointer to storage for bd_addr 672 * @note: btstack_type B 673 */ 674 static inline void hci_event_link_key_request_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 675 reverse_bytes(&event[2], bd_addr, 6); 676 } 677 678 /** 679 * @brief Get field link_type from event HCI_EVENT_DATA_BUFFER_OVERFLOW 680 * @param event packet 681 * @return link_type 682 * @note: btstack_type 1 683 */ 684 static inline uint8_t hci_event_data_buffer_overflow_get_link_type(const uint8_t * event){ 685 return event[2]; 686 } 687 688 /** 689 * @brief Get field handle from event HCI_EVENT_MAX_SLOTS_CHANGED 690 * @param event packet 691 * @return handle 692 * @note: btstack_type H 693 */ 694 static inline hci_con_handle_t hci_event_max_slots_changed_get_handle(const uint8_t * event){ 695 return little_endian_read_16(event, 2); 696 } 697 /** 698 * @brief Get field lmp_max_slots from event HCI_EVENT_MAX_SLOTS_CHANGED 699 * @param event packet 700 * @return lmp_max_slots 701 * @note: btstack_type 1 702 */ 703 static inline uint8_t hci_event_max_slots_changed_get_lmp_max_slots(const uint8_t * event){ 704 return event[4]; 705 } 706 707 /** 708 * @brief Get field status from event HCI_EVENT_READ_CLOCK_OFFSET_COMPLETE 709 * @param event packet 710 * @return status 711 * @note: btstack_type 1 712 */ 713 static inline uint8_t hci_event_read_clock_offset_complete_get_status(const uint8_t * event){ 714 return event[2]; 715 } 716 /** 717 * @brief Get field handle from event HCI_EVENT_READ_CLOCK_OFFSET_COMPLETE 718 * @param event packet 719 * @return handle 720 * @note: btstack_type H 721 */ 722 static inline hci_con_handle_t hci_event_read_clock_offset_complete_get_handle(const uint8_t * event){ 723 return little_endian_read_16(event, 3); 724 } 725 /** 726 * @brief Get field clock_offset from event HCI_EVENT_READ_CLOCK_OFFSET_COMPLETE 727 * @param event packet 728 * @return clock_offset 729 * @note: btstack_type 2 730 */ 731 static inline uint16_t hci_event_read_clock_offset_complete_get_clock_offset(const uint8_t * event){ 732 return little_endian_read_16(event, 5); 733 } 734 735 /** 736 * @brief Get field status from event HCI_EVENT_CONNECTION_PACKET_TYPE_CHANGED 737 * @param event packet 738 * @return status 739 * @note: btstack_type 1 740 */ 741 static inline uint8_t hci_event_connection_packet_type_changed_get_status(const uint8_t * event){ 742 return event[2]; 743 } 744 /** 745 * @brief Get field handle from event HCI_EVENT_CONNECTION_PACKET_TYPE_CHANGED 746 * @param event packet 747 * @return handle 748 * @note: btstack_type H 749 */ 750 static inline hci_con_handle_t hci_event_connection_packet_type_changed_get_handle(const uint8_t * event){ 751 return little_endian_read_16(event, 3); 752 } 753 /** 754 * @brief Get field packet_types from event HCI_EVENT_CONNECTION_PACKET_TYPE_CHANGED 755 * @param event packet 756 * @return packet_types 757 * @note: btstack_type 2 758 */ 759 static inline uint16_t hci_event_connection_packet_type_changed_get_packet_types(const uint8_t * event){ 760 return little_endian_read_16(event, 5); 761 } 762 763 /** 764 * @brief Get field num_responses from event HCI_EVENT_INQUIRY_RESULT_WITH_RSSI 765 * @param event packet 766 * @return num_responses 767 * @note: btstack_type 1 768 */ 769 static inline uint8_t hci_event_inquiry_result_with_rssi_get_num_responses(const uint8_t * event){ 770 return event[2]; 771 } 772 /** 773 * @brief Get field bd_addr from event HCI_EVENT_INQUIRY_RESULT_WITH_RSSI 774 * @param event packet 775 * @param Pointer to storage for bd_addr 776 * @note: btstack_type B 777 */ 778 static inline void hci_event_inquiry_result_with_rssi_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 779 reverse_bytes(&event[3], bd_addr, 6); 780 } 781 /** 782 * @brief Get field page_scan_repetition_mode from event HCI_EVENT_INQUIRY_RESULT_WITH_RSSI 783 * @param event packet 784 * @return page_scan_repetition_mode 785 * @note: btstack_type 1 786 */ 787 static inline uint8_t hci_event_inquiry_result_with_rssi_get_page_scan_repetition_mode(const uint8_t * event){ 788 return event[9]; 789 } 790 /** 791 * @brief Get field reserved from event HCI_EVENT_INQUIRY_RESULT_WITH_RSSI 792 * @param event packet 793 * @return reserved 794 * @note: btstack_type 1 795 */ 796 static inline uint8_t hci_event_inquiry_result_with_rssi_get_reserved(const uint8_t * event){ 797 return event[10]; 798 } 799 /** 800 * @brief Get field class_of_device from event HCI_EVENT_INQUIRY_RESULT_WITH_RSSI 801 * @param event packet 802 * @return class_of_device 803 * @note: btstack_type 3 804 */ 805 static inline uint32_t hci_event_inquiry_result_with_rssi_get_class_of_device(const uint8_t * event){ 806 return little_endian_read_24(event, 11); 807 } 808 /** 809 * @brief Get field clock_offset from event HCI_EVENT_INQUIRY_RESULT_WITH_RSSI 810 * @param event packet 811 * @return clock_offset 812 * @note: btstack_type 2 813 */ 814 static inline uint16_t hci_event_inquiry_result_with_rssi_get_clock_offset(const uint8_t * event){ 815 return little_endian_read_16(event, 14); 816 } 817 /** 818 * @brief Get field rssi from event HCI_EVENT_INQUIRY_RESULT_WITH_RSSI 819 * @param event packet 820 * @return rssi 821 * @note: btstack_type 1 822 */ 823 static inline uint8_t hci_event_inquiry_result_with_rssi_get_rssi(const uint8_t * event){ 824 return event[16]; 825 } 826 827 /** 828 * @brief Get field status from event HCI_EVENT_SYNCHRONOUS_CONNECTION_COMPLETE 829 * @param event packet 830 * @return status 831 * @note: btstack_type 1 832 */ 833 static inline uint8_t hci_event_synchronous_connection_complete_get_status(const uint8_t * event){ 834 return event[2]; 835 } 836 /** 837 * @brief Get field handle from event HCI_EVENT_SYNCHRONOUS_CONNECTION_COMPLETE 838 * @param event packet 839 * @return handle 840 * @note: btstack_type H 841 */ 842 static inline hci_con_handle_t hci_event_synchronous_connection_complete_get_handle(const uint8_t * event){ 843 return little_endian_read_16(event, 3); 844 } 845 /** 846 * @brief Get field bd_addr from event HCI_EVENT_SYNCHRONOUS_CONNECTION_COMPLETE 847 * @param event packet 848 * @param Pointer to storage for bd_addr 849 * @note: btstack_type B 850 */ 851 static inline void hci_event_synchronous_connection_complete_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 852 reverse_bytes(&event[5], bd_addr, 6); 853 } 854 /** 855 * @brief Get field link_type from event HCI_EVENT_SYNCHRONOUS_CONNECTION_COMPLETE 856 * @param event packet 857 * @return link_type 858 * @note: btstack_type 1 859 */ 860 static inline uint8_t hci_event_synchronous_connection_complete_get_link_type(const uint8_t * event){ 861 return event[11]; 862 } 863 /** 864 * @brief Get field transmission_interval from event HCI_EVENT_SYNCHRONOUS_CONNECTION_COMPLETE 865 * @param event packet 866 * @return transmission_interval 867 * @note: btstack_type 1 868 */ 869 static inline uint8_t hci_event_synchronous_connection_complete_get_transmission_interval(const uint8_t * event){ 870 return event[12]; 871 } 872 /** 873 * @brief Get field retransmission_interval from event HCI_EVENT_SYNCHRONOUS_CONNECTION_COMPLETE 874 * @param event packet 875 * @return retransmission_interval 876 * @note: btstack_type 1 877 */ 878 static inline uint8_t hci_event_synchronous_connection_complete_get_retransmission_interval(const uint8_t * event){ 879 return event[13]; 880 } 881 /** 882 * @brief Get field rx_packet_length from event HCI_EVENT_SYNCHRONOUS_CONNECTION_COMPLETE 883 * @param event packet 884 * @return rx_packet_length 885 * @note: btstack_type 2 886 */ 887 static inline uint16_t hci_event_synchronous_connection_complete_get_rx_packet_length(const uint8_t * event){ 888 return little_endian_read_16(event, 14); 889 } 890 /** 891 * @brief Get field tx_packet_length from event HCI_EVENT_SYNCHRONOUS_CONNECTION_COMPLETE 892 * @param event packet 893 * @return tx_packet_length 894 * @note: btstack_type 2 895 */ 896 static inline uint16_t hci_event_synchronous_connection_complete_get_tx_packet_length(const uint8_t * event){ 897 return little_endian_read_16(event, 16); 898 } 899 /** 900 * @brief Get field air_mode from event HCI_EVENT_SYNCHRONOUS_CONNECTION_COMPLETE 901 * @param event packet 902 * @return air_mode 903 * @note: btstack_type 1 904 */ 905 static inline uint8_t hci_event_synchronous_connection_complete_get_air_mode(const uint8_t * event){ 906 return event[18]; 907 } 908 909 /** 910 * @brief Get field num_responses from event HCI_EVENT_EXTENDED_INQUIRY_RESPONSE 911 * @param event packet 912 * @return num_responses 913 * @note: btstack_type 1 914 */ 915 static inline uint8_t hci_event_extended_inquiry_response_get_num_responses(const uint8_t * event){ 916 return event[2]; 917 } 918 /** 919 * @brief Get field bd_addr from event HCI_EVENT_EXTENDED_INQUIRY_RESPONSE 920 * @param event packet 921 * @param Pointer to storage for bd_addr 922 * @note: btstack_type B 923 */ 924 static inline void hci_event_extended_inquiry_response_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 925 reverse_bytes(&event[3], bd_addr, 6); 926 } 927 /** 928 * @brief Get field page_scan_repetition_mode from event HCI_EVENT_EXTENDED_INQUIRY_RESPONSE 929 * @param event packet 930 * @return page_scan_repetition_mode 931 * @note: btstack_type 1 932 */ 933 static inline uint8_t hci_event_extended_inquiry_response_get_page_scan_repetition_mode(const uint8_t * event){ 934 return event[9]; 935 } 936 /** 937 * @brief Get field reserved from event HCI_EVENT_EXTENDED_INQUIRY_RESPONSE 938 * @param event packet 939 * @return reserved 940 * @note: btstack_type 1 941 */ 942 static inline uint8_t hci_event_extended_inquiry_response_get_reserved(const uint8_t * event){ 943 return event[10]; 944 } 945 /** 946 * @brief Get field class_of_device from event HCI_EVENT_EXTENDED_INQUIRY_RESPONSE 947 * @param event packet 948 * @return class_of_device 949 * @note: btstack_type 3 950 */ 951 static inline uint32_t hci_event_extended_inquiry_response_get_class_of_device(const uint8_t * event){ 952 return little_endian_read_24(event, 11); 953 } 954 /** 955 * @brief Get field clock_offset from event HCI_EVENT_EXTENDED_INQUIRY_RESPONSE 956 * @param event packet 957 * @return clock_offset 958 * @note: btstack_type 2 959 */ 960 static inline uint16_t hci_event_extended_inquiry_response_get_clock_offset(const uint8_t * event){ 961 return little_endian_read_16(event, 14); 962 } 963 /** 964 * @brief Get field rssi from event HCI_EVENT_EXTENDED_INQUIRY_RESPONSE 965 * @param event packet 966 * @return rssi 967 * @note: btstack_type 1 968 */ 969 static inline uint8_t hci_event_extended_inquiry_response_get_rssi(const uint8_t * event){ 970 return event[16]; 971 } 972 973 /** 974 * @brief Get field status from event HCI_EVENT_ENCRYPTION_KEY_REFRESH_COMPLETE 975 * @param event packet 976 * @return status 977 * @note: btstack_type 1 978 */ 979 static inline uint8_t hci_event_encryption_key_refresh_complete_get_status(const uint8_t * event){ 980 return event[2]; 981 } 982 /** 983 * @brief Get field handle from event HCI_EVENT_ENCRYPTION_KEY_REFRESH_COMPLETE 984 * @param event packet 985 * @return handle 986 * @note: btstack_type H 987 */ 988 static inline hci_con_handle_t hci_event_encryption_key_refresh_complete_get_handle(const uint8_t * event){ 989 return little_endian_read_16(event, 3); 990 } 991 992 /** 993 * @brief Get field bd_addr from event HCI_EVENT_IO_CAPABILITY_REQUEST 994 * @param event packet 995 * @param Pointer to storage for bd_addr 996 * @note: btstack_type B 997 */ 998 static inline void hci_event_io_capability_request_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 999 reverse_bytes(&event[2], bd_addr, 6); 1000 } 1001 1002 /** 1003 * @brief Get field bd_addr from event HCI_EVENT_IO_CAPABILITY_RESPONSE 1004 * @param event packet 1005 * @param Pointer to storage for bd_addr 1006 * @note: btstack_type B 1007 */ 1008 static inline void hci_event_io_capability_response_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 1009 reverse_bytes(&event[2], bd_addr, 6); 1010 } 1011 /** 1012 * @brief Get field io_capability from event HCI_EVENT_IO_CAPABILITY_RESPONSE 1013 * @param event packet 1014 * @return io_capability 1015 * @note: btstack_type 1 1016 */ 1017 static inline uint8_t hci_event_io_capability_response_get_io_capability(const uint8_t * event){ 1018 return event[8]; 1019 } 1020 /** 1021 * @brief Get field oob_data_present from event HCI_EVENT_IO_CAPABILITY_RESPONSE 1022 * @param event packet 1023 * @return oob_data_present 1024 * @note: btstack_type 1 1025 */ 1026 static inline uint8_t hci_event_io_capability_response_get_oob_data_present(const uint8_t * event){ 1027 return event[9]; 1028 } 1029 /** 1030 * @brief Get field authentication_requirements from event HCI_EVENT_IO_CAPABILITY_RESPONSE 1031 * @param event packet 1032 * @return authentication_requirements 1033 * @note: btstack_type 1 1034 */ 1035 static inline uint8_t hci_event_io_capability_response_get_authentication_requirements(const uint8_t * event){ 1036 return event[10]; 1037 } 1038 1039 /** 1040 * @brief Get field bd_addr from event HCI_EVENT_USER_CONFIRMATION_REQUEST 1041 * @param event packet 1042 * @param Pointer to storage for bd_addr 1043 * @note: btstack_type B 1044 */ 1045 static inline void hci_event_user_confirmation_request_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 1046 reverse_bytes(&event[2], bd_addr, 6); 1047 } 1048 /** 1049 * @brief Get field numeric_value from event HCI_EVENT_USER_CONFIRMATION_REQUEST 1050 * @param event packet 1051 * @return numeric_value 1052 * @note: btstack_type 4 1053 */ 1054 static inline uint32_t hci_event_user_confirmation_request_get_numeric_value(const uint8_t * event){ 1055 return little_endian_read_32(event, 8); 1056 } 1057 1058 /** 1059 * @brief Get field bd_addr from event HCI_EVENT_USER_PASSKEY_REQUEST 1060 * @param event packet 1061 * @param Pointer to storage for bd_addr 1062 * @note: btstack_type B 1063 */ 1064 static inline void hci_event_user_passkey_request_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 1065 reverse_bytes(&event[2], bd_addr, 6); 1066 } 1067 1068 /** 1069 * @brief Get field bd_addr from event HCI_EVENT_REMOTE_OOB_DATA_REQUEST 1070 * @param event packet 1071 * @param Pointer to storage for bd_addr 1072 * @note: btstack_type B 1073 */ 1074 static inline void hci_event_remote_oob_data_request_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 1075 reverse_bytes(&event[2], bd_addr, 6); 1076 } 1077 1078 /** 1079 * @brief Get field status from event HCI_EVENT_SIMPLE_PAIRING_COMPLETE 1080 * @param event packet 1081 * @return status 1082 * @note: btstack_type 1 1083 */ 1084 static inline uint8_t hci_event_simple_pairing_complete_get_status(const uint8_t * event){ 1085 return event[2]; 1086 } 1087 /** 1088 * @brief Get field bd_addr from event HCI_EVENT_SIMPLE_PAIRING_COMPLETE 1089 * @param event packet 1090 * @param Pointer to storage for bd_addr 1091 * @note: btstack_type B 1092 */ 1093 static inline void hci_event_simple_pairing_complete_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 1094 reverse_bytes(&event[3], bd_addr, 6); 1095 } 1096 1097 /** 1098 * @brief Get field bd_addr from event HCI_EVENT_USER_PASSKEY_NOTIFICATION 1099 * @param event packet 1100 * @param Pointer to storage for bd_addr 1101 * @note: btstack_type B 1102 */ 1103 static inline void hci_event_user_passkey_notification_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 1104 reverse_bytes(&event[2], bd_addr, 6); 1105 } 1106 /** 1107 * @brief Get field numeric_value from event HCI_EVENT_USER_PASSKEY_NOTIFICATION 1108 * @param event packet 1109 * @return numeric_value 1110 * @note: btstack_type 4 1111 */ 1112 static inline uint32_t hci_event_user_passkey_notification_get_numeric_value(const uint8_t * event){ 1113 return little_endian_read_32(event, 8); 1114 } 1115 1116 /** 1117 * @brief Get field bd_addr from event HCI_EVENT_KEYPRESS_NOTIFICATION 1118 * @param event packet 1119 * @param Pointer to storage for bd_addr 1120 * @note: btstack_type B 1121 */ 1122 static inline void hci_event_keypress_notification_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 1123 reverse_bytes(&event[2], bd_addr, 6); 1124 } 1125 /** 1126 * @brief Get field notification_type from event HCI_EVENT_KEYPRESS_NOTIFICATION 1127 * @param event packet 1128 * @return notification_type 1129 * @note: btstack_type 1 1130 */ 1131 static inline uint8_t hci_event_keypress_notification_get_notification_type(const uint8_t * event){ 1132 return event[8]; 1133 } 1134 1135 /** 1136 * @brief Get field state from event BTSTACK_EVENT_STATE 1137 * @param event packet 1138 * @return state 1139 * @note: btstack_type 1 1140 */ 1141 static inline uint8_t btstack_event_state_get_state(const uint8_t * event){ 1142 return event[2]; 1143 } 1144 1145 /** 1146 * @brief Get field number_connections from event BTSTACK_EVENT_NR_CONNECTIONS_CHANGED 1147 * @param event packet 1148 * @return number_connections 1149 * @note: btstack_type 1 1150 */ 1151 static inline uint8_t btstack_event_nr_connections_changed_get_number_connections(const uint8_t * event){ 1152 return event[2]; 1153 } 1154 1155 1156 /** 1157 * @brief Get field discoverable from event BTSTACK_EVENT_DISCOVERABLE_ENABLED 1158 * @param event packet 1159 * @return discoverable 1160 * @note: btstack_type 1 1161 */ 1162 static inline uint8_t btstack_event_discoverable_enabled_get_discoverable(const uint8_t * event){ 1163 return event[2]; 1164 } 1165 1166 /** 1167 * @brief Get field active from event HCI_EVENT_TRANSPORT_SLEEP_MODE 1168 * @param event packet 1169 * @return active 1170 * @note: btstack_type 1 1171 */ 1172 static inline uint8_t hci_event_transport_sleep_mode_get_active(const uint8_t * event){ 1173 return event[2]; 1174 } 1175 1176 /** 1177 * @brief Get field handle from event HCI_EVENT_SCO_CAN_SEND_NOW 1178 * @param event packet 1179 * @param Pointer to storage for handle 1180 * @note: btstack_type B 1181 */ 1182 static inline void hci_event_sco_can_send_now_get_handle(const uint8_t * event, bd_addr_t handle){ 1183 reverse_bytes(&event[2], handle, 6); 1184 } 1185 1186 /** 1187 * @brief Get field status from event L2CAP_EVENT_CHANNEL_OPENED 1188 * @param event packet 1189 * @return status 1190 * @note: btstack_type 1 1191 */ 1192 static inline uint8_t l2cap_event_channel_opened_get_status(const uint8_t * event){ 1193 return event[2]; 1194 } 1195 /** 1196 * @brief Get field address from event L2CAP_EVENT_CHANNEL_OPENED 1197 * @param event packet 1198 * @param Pointer to storage for address 1199 * @note: btstack_type B 1200 */ 1201 static inline void l2cap_event_channel_opened_get_address(const uint8_t * event, bd_addr_t address){ 1202 reverse_bytes(&event[3], address, 6); 1203 } 1204 /** 1205 * @brief Get field handle from event L2CAP_EVENT_CHANNEL_OPENED 1206 * @param event packet 1207 * @return handle 1208 * @note: btstack_type H 1209 */ 1210 static inline hci_con_handle_t l2cap_event_channel_opened_get_handle(const uint8_t * event){ 1211 return little_endian_read_16(event, 9); 1212 } 1213 /** 1214 * @brief Get field psm from event L2CAP_EVENT_CHANNEL_OPENED 1215 * @param event packet 1216 * @return psm 1217 * @note: btstack_type 2 1218 */ 1219 static inline uint16_t l2cap_event_channel_opened_get_psm(const uint8_t * event){ 1220 return little_endian_read_16(event, 11); 1221 } 1222 /** 1223 * @brief Get field local_cid from event L2CAP_EVENT_CHANNEL_OPENED 1224 * @param event packet 1225 * @return local_cid 1226 * @note: btstack_type 2 1227 */ 1228 static inline uint16_t l2cap_event_channel_opened_get_local_cid(const uint8_t * event){ 1229 return little_endian_read_16(event, 13); 1230 } 1231 /** 1232 * @brief Get field remote_cid from event L2CAP_EVENT_CHANNEL_OPENED 1233 * @param event packet 1234 * @return remote_cid 1235 * @note: btstack_type 2 1236 */ 1237 static inline uint16_t l2cap_event_channel_opened_get_remote_cid(const uint8_t * event){ 1238 return little_endian_read_16(event, 15); 1239 } 1240 /** 1241 * @brief Get field local_mtu from event L2CAP_EVENT_CHANNEL_OPENED 1242 * @param event packet 1243 * @return local_mtu 1244 * @note: btstack_type 2 1245 */ 1246 static inline uint16_t l2cap_event_channel_opened_get_local_mtu(const uint8_t * event){ 1247 return little_endian_read_16(event, 17); 1248 } 1249 /** 1250 * @brief Get field remote_mtu from event L2CAP_EVENT_CHANNEL_OPENED 1251 * @param event packet 1252 * @return remote_mtu 1253 * @note: btstack_type 2 1254 */ 1255 static inline uint16_t l2cap_event_channel_opened_get_remote_mtu(const uint8_t * event){ 1256 return little_endian_read_16(event, 19); 1257 } 1258 /** 1259 * @brief Get field flush_timeout from event L2CAP_EVENT_CHANNEL_OPENED 1260 * @param event packet 1261 * @return flush_timeout 1262 * @note: btstack_type 2 1263 */ 1264 static inline uint16_t l2cap_event_channel_opened_get_flush_timeout(const uint8_t * event){ 1265 return little_endian_read_16(event, 21); 1266 } 1267 /** 1268 * @brief Get field incoming from event L2CAP_EVENT_CHANNEL_OPENED 1269 * @param event packet 1270 * @return incoming 1271 * @note: btstack_type 1 1272 */ 1273 static inline uint8_t l2cap_event_channel_opened_get_incoming(const uint8_t * event){ 1274 return event[23]; 1275 } 1276 /** 1277 * @brief Get field mode from event L2CAP_EVENT_CHANNEL_OPENED 1278 * @param event packet 1279 * @return mode 1280 * @note: btstack_type 1 1281 */ 1282 static inline uint8_t l2cap_event_channel_opened_get_mode(const uint8_t * event){ 1283 return event[24]; 1284 } 1285 /** 1286 * @brief Get field fcs from event L2CAP_EVENT_CHANNEL_OPENED 1287 * @param event packet 1288 * @return fcs 1289 * @note: btstack_type 1 1290 */ 1291 static inline uint8_t l2cap_event_channel_opened_get_fcs(const uint8_t * event){ 1292 return event[25]; 1293 } 1294 1295 /** 1296 * @brief Get field local_cid from event L2CAP_EVENT_CHANNEL_CLOSED 1297 * @param event packet 1298 * @return local_cid 1299 * @note: btstack_type 2 1300 */ 1301 static inline uint16_t l2cap_event_channel_closed_get_local_cid(const uint8_t * event){ 1302 return little_endian_read_16(event, 2); 1303 } 1304 1305 /** 1306 * @brief Get field address from event L2CAP_EVENT_INCOMING_CONNECTION 1307 * @param event packet 1308 * @param Pointer to storage for address 1309 * @note: btstack_type B 1310 */ 1311 static inline void l2cap_event_incoming_connection_get_address(const uint8_t * event, bd_addr_t address){ 1312 reverse_bytes(&event[2], address, 6); 1313 } 1314 /** 1315 * @brief Get field handle from event L2CAP_EVENT_INCOMING_CONNECTION 1316 * @param event packet 1317 * @return handle 1318 * @note: btstack_type H 1319 */ 1320 static inline hci_con_handle_t l2cap_event_incoming_connection_get_handle(const uint8_t * event){ 1321 return little_endian_read_16(event, 8); 1322 } 1323 /** 1324 * @brief Get field psm from event L2CAP_EVENT_INCOMING_CONNECTION 1325 * @param event packet 1326 * @return psm 1327 * @note: btstack_type 2 1328 */ 1329 static inline uint16_t l2cap_event_incoming_connection_get_psm(const uint8_t * event){ 1330 return little_endian_read_16(event, 10); 1331 } 1332 /** 1333 * @brief Get field local_cid from event L2CAP_EVENT_INCOMING_CONNECTION 1334 * @param event packet 1335 * @return local_cid 1336 * @note: btstack_type 2 1337 */ 1338 static inline uint16_t l2cap_event_incoming_connection_get_local_cid(const uint8_t * event){ 1339 return little_endian_read_16(event, 12); 1340 } 1341 /** 1342 * @brief Get field remote_cid from event L2CAP_EVENT_INCOMING_CONNECTION 1343 * @param event packet 1344 * @return remote_cid 1345 * @note: btstack_type 2 1346 */ 1347 static inline uint16_t l2cap_event_incoming_connection_get_remote_cid(const uint8_t * event){ 1348 return little_endian_read_16(event, 14); 1349 } 1350 1351 /** 1352 * @brief Get field handle from event L2CAP_EVENT_CONNECTION_PARAMETER_UPDATE_REQUEST 1353 * @param event packet 1354 * @return handle 1355 * @note: btstack_type H 1356 */ 1357 static inline hci_con_handle_t l2cap_event_connection_parameter_update_request_get_handle(const uint8_t * event){ 1358 return little_endian_read_16(event, 2); 1359 } 1360 /** 1361 * @brief Get field interval_min from event L2CAP_EVENT_CONNECTION_PARAMETER_UPDATE_REQUEST 1362 * @param event packet 1363 * @return interval_min 1364 * @note: btstack_type 2 1365 */ 1366 static inline uint16_t l2cap_event_connection_parameter_update_request_get_interval_min(const uint8_t * event){ 1367 return little_endian_read_16(event, 4); 1368 } 1369 /** 1370 * @brief Get field interval_max from event L2CAP_EVENT_CONNECTION_PARAMETER_UPDATE_REQUEST 1371 * @param event packet 1372 * @return interval_max 1373 * @note: btstack_type 2 1374 */ 1375 static inline uint16_t l2cap_event_connection_parameter_update_request_get_interval_max(const uint8_t * event){ 1376 return little_endian_read_16(event, 6); 1377 } 1378 /** 1379 * @brief Get field latencey from event L2CAP_EVENT_CONNECTION_PARAMETER_UPDATE_REQUEST 1380 * @param event packet 1381 * @return latencey 1382 * @note: btstack_type 2 1383 */ 1384 static inline uint16_t l2cap_event_connection_parameter_update_request_get_latencey(const uint8_t * event){ 1385 return little_endian_read_16(event, 8); 1386 } 1387 /** 1388 * @brief Get field timeout_multiplier from event L2CAP_EVENT_CONNECTION_PARAMETER_UPDATE_REQUEST 1389 * @param event packet 1390 * @return timeout_multiplier 1391 * @note: btstack_type 2 1392 */ 1393 static inline uint16_t l2cap_event_connection_parameter_update_request_get_timeout_multiplier(const uint8_t * event){ 1394 return little_endian_read_16(event, 10); 1395 } 1396 1397 /** 1398 * @brief Get field handle from event L2CAP_EVENT_CONNECTION_PARAMETER_UPDATE_RESPONSE 1399 * @param event packet 1400 * @return handle 1401 * @note: btstack_type H 1402 */ 1403 static inline hci_con_handle_t l2cap_event_connection_parameter_update_response_get_handle(const uint8_t * event){ 1404 return little_endian_read_16(event, 2); 1405 } 1406 /** 1407 * @brief Get field result from event L2CAP_EVENT_CONNECTION_PARAMETER_UPDATE_RESPONSE 1408 * @param event packet 1409 * @return result 1410 * @note: btstack_type 2 1411 */ 1412 static inline uint16_t l2cap_event_connection_parameter_update_response_get_result(const uint8_t * event){ 1413 return little_endian_read_16(event, 4); 1414 } 1415 1416 /** 1417 * @brief Get field local_cid from event L2CAP_EVENT_CAN_SEND_NOW 1418 * @param event packet 1419 * @return local_cid 1420 * @note: btstack_type 2 1421 */ 1422 static inline uint16_t l2cap_event_can_send_now_get_local_cid(const uint8_t * event){ 1423 return little_endian_read_16(event, 2); 1424 } 1425 1426 /** 1427 * @brief Get field address_type from event L2CAP_EVENT_LE_INCOMING_CONNECTION 1428 * @param event packet 1429 * @return address_type 1430 * @note: btstack_type 1 1431 */ 1432 static inline uint8_t l2cap_event_le_incoming_connection_get_address_type(const uint8_t * event){ 1433 return event[2]; 1434 } 1435 /** 1436 * @brief Get field address from event L2CAP_EVENT_LE_INCOMING_CONNECTION 1437 * @param event packet 1438 * @param Pointer to storage for address 1439 * @note: btstack_type B 1440 */ 1441 static inline void l2cap_event_le_incoming_connection_get_address(const uint8_t * event, bd_addr_t address){ 1442 reverse_bytes(&event[3], address, 6); 1443 } 1444 /** 1445 * @brief Get field handle from event L2CAP_EVENT_LE_INCOMING_CONNECTION 1446 * @param event packet 1447 * @return handle 1448 * @note: btstack_type H 1449 */ 1450 static inline hci_con_handle_t l2cap_event_le_incoming_connection_get_handle(const uint8_t * event){ 1451 return little_endian_read_16(event, 9); 1452 } 1453 /** 1454 * @brief Get field psm from event L2CAP_EVENT_LE_INCOMING_CONNECTION 1455 * @param event packet 1456 * @return psm 1457 * @note: btstack_type 2 1458 */ 1459 static inline uint16_t l2cap_event_le_incoming_connection_get_psm(const uint8_t * event){ 1460 return little_endian_read_16(event, 11); 1461 } 1462 /** 1463 * @brief Get field local_cid from event L2CAP_EVENT_LE_INCOMING_CONNECTION 1464 * @param event packet 1465 * @return local_cid 1466 * @note: btstack_type 2 1467 */ 1468 static inline uint16_t l2cap_event_le_incoming_connection_get_local_cid(const uint8_t * event){ 1469 return little_endian_read_16(event, 13); 1470 } 1471 /** 1472 * @brief Get field remote_cid from event L2CAP_EVENT_LE_INCOMING_CONNECTION 1473 * @param event packet 1474 * @return remote_cid 1475 * @note: btstack_type 2 1476 */ 1477 static inline uint16_t l2cap_event_le_incoming_connection_get_remote_cid(const uint8_t * event){ 1478 return little_endian_read_16(event, 15); 1479 } 1480 /** 1481 * @brief Get field remote_mtu from event L2CAP_EVENT_LE_INCOMING_CONNECTION 1482 * @param event packet 1483 * @return remote_mtu 1484 * @note: btstack_type 2 1485 */ 1486 static inline uint16_t l2cap_event_le_incoming_connection_get_remote_mtu(const uint8_t * event){ 1487 return little_endian_read_16(event, 17); 1488 } 1489 1490 /** 1491 * @brief Get field status from event L2CAP_EVENT_LE_CHANNEL_OPENED 1492 * @param event packet 1493 * @return status 1494 * @note: btstack_type 1 1495 */ 1496 static inline uint8_t l2cap_event_le_channel_opened_get_status(const uint8_t * event){ 1497 return event[2]; 1498 } 1499 /** 1500 * @brief Get field address_type from event L2CAP_EVENT_LE_CHANNEL_OPENED 1501 * @param event packet 1502 * @return address_type 1503 * @note: btstack_type 1 1504 */ 1505 static inline uint8_t l2cap_event_le_channel_opened_get_address_type(const uint8_t * event){ 1506 return event[3]; 1507 } 1508 /** 1509 * @brief Get field address from event L2CAP_EVENT_LE_CHANNEL_OPENED 1510 * @param event packet 1511 * @param Pointer to storage for address 1512 * @note: btstack_type B 1513 */ 1514 static inline void l2cap_event_le_channel_opened_get_address(const uint8_t * event, bd_addr_t address){ 1515 reverse_bytes(&event[4], address, 6); 1516 } 1517 /** 1518 * @brief Get field handle from event L2CAP_EVENT_LE_CHANNEL_OPENED 1519 * @param event packet 1520 * @return handle 1521 * @note: btstack_type H 1522 */ 1523 static inline hci_con_handle_t l2cap_event_le_channel_opened_get_handle(const uint8_t * event){ 1524 return little_endian_read_16(event, 10); 1525 } 1526 /** 1527 * @brief Get field incoming from event L2CAP_EVENT_LE_CHANNEL_OPENED 1528 * @param event packet 1529 * @return incoming 1530 * @note: btstack_type 1 1531 */ 1532 static inline uint8_t l2cap_event_le_channel_opened_get_incoming(const uint8_t * event){ 1533 return event[12]; 1534 } 1535 /** 1536 * @brief Get field psm from event L2CAP_EVENT_LE_CHANNEL_OPENED 1537 * @param event packet 1538 * @return psm 1539 * @note: btstack_type 2 1540 */ 1541 static inline uint16_t l2cap_event_le_channel_opened_get_psm(const uint8_t * event){ 1542 return little_endian_read_16(event, 13); 1543 } 1544 /** 1545 * @brief Get field local_cid from event L2CAP_EVENT_LE_CHANNEL_OPENED 1546 * @param event packet 1547 * @return local_cid 1548 * @note: btstack_type 2 1549 */ 1550 static inline uint16_t l2cap_event_le_channel_opened_get_local_cid(const uint8_t * event){ 1551 return little_endian_read_16(event, 15); 1552 } 1553 /** 1554 * @brief Get field remote_cid from event L2CAP_EVENT_LE_CHANNEL_OPENED 1555 * @param event packet 1556 * @return remote_cid 1557 * @note: btstack_type 2 1558 */ 1559 static inline uint16_t l2cap_event_le_channel_opened_get_remote_cid(const uint8_t * event){ 1560 return little_endian_read_16(event, 17); 1561 } 1562 /** 1563 * @brief Get field local_mtu from event L2CAP_EVENT_LE_CHANNEL_OPENED 1564 * @param event packet 1565 * @return local_mtu 1566 * @note: btstack_type 2 1567 */ 1568 static inline uint16_t l2cap_event_le_channel_opened_get_local_mtu(const uint8_t * event){ 1569 return little_endian_read_16(event, 19); 1570 } 1571 /** 1572 * @brief Get field remote_mtu from event L2CAP_EVENT_LE_CHANNEL_OPENED 1573 * @param event packet 1574 * @return remote_mtu 1575 * @note: btstack_type 2 1576 */ 1577 static inline uint16_t l2cap_event_le_channel_opened_get_remote_mtu(const uint8_t * event){ 1578 return little_endian_read_16(event, 21); 1579 } 1580 1581 /** 1582 * @brief Get field local_cid from event L2CAP_EVENT_LE_CHANNEL_CLOSED 1583 * @param event packet 1584 * @return local_cid 1585 * @note: btstack_type 2 1586 */ 1587 static inline uint16_t l2cap_event_le_channel_closed_get_local_cid(const uint8_t * event){ 1588 return little_endian_read_16(event, 2); 1589 } 1590 1591 /** 1592 * @brief Get field local_cid from event L2CAP_EVENT_LE_CAN_SEND_NOW 1593 * @param event packet 1594 * @return local_cid 1595 * @note: btstack_type 2 1596 */ 1597 static inline uint16_t l2cap_event_le_can_send_now_get_local_cid(const uint8_t * event){ 1598 return little_endian_read_16(event, 2); 1599 } 1600 1601 /** 1602 * @brief Get field local_cid from event L2CAP_EVENT_LE_PACKET_SENT 1603 * @param event packet 1604 * @return local_cid 1605 * @note: btstack_type 2 1606 */ 1607 static inline uint16_t l2cap_event_le_packet_sent_get_local_cid(const uint8_t * event){ 1608 return little_endian_read_16(event, 2); 1609 } 1610 1611 /** 1612 * @brief Get field local_cid from event L2CAP_EVENT_ERTM_BUFFER_RELEASED 1613 * @param event packet 1614 * @return local_cid 1615 * @note: btstack_type 2 1616 */ 1617 static inline uint16_t l2cap_event_ertm_buffer_released_get_local_cid(const uint8_t * event){ 1618 return little_endian_read_16(event, 2); 1619 } 1620 1621 1622 /** 1623 * @brief Get field con_handle from event L2CAP_EVENT_INFORMATION_RESPONSE 1624 * @param event packet 1625 * @return con_handle 1626 * @note: btstack_type H 1627 */ 1628 static inline hci_con_handle_t l2cap_event_information_response_get_con_handle(const uint8_t * event){ 1629 return little_endian_read_16(event, 2); 1630 } 1631 /** 1632 * @brief Get field extended_feature_mask from event L2CAP_EVENT_INFORMATION_RESPONSE 1633 * @param event packet 1634 * @return extended_feature_mask 1635 * @note: btstack_type 2 1636 */ 1637 static inline uint16_t l2cap_event_information_response_get_extended_feature_mask(const uint8_t * event){ 1638 return little_endian_read_16(event, 4); 1639 } 1640 /** 1641 * @brief Get field fixed_channels_supported from event L2CAP_EVENT_INFORMATION_RESPONSE 1642 * @param event packet 1643 * @return fixed_channels_supported 1644 * @note: btstack_type 2 1645 */ 1646 static inline uint16_t l2cap_event_information_response_get_fixed_channels_supported(const uint8_t * event){ 1647 return little_endian_read_16(event, 6); 1648 } 1649 1650 /** 1651 * @brief Get field status from event RFCOMM_EVENT_CHANNEL_OPENED 1652 * @param event packet 1653 * @return status 1654 * @note: btstack_type 1 1655 */ 1656 static inline uint8_t rfcomm_event_channel_opened_get_status(const uint8_t * event){ 1657 return event[2]; 1658 } 1659 /** 1660 * @brief Get field bd_addr from event RFCOMM_EVENT_CHANNEL_OPENED 1661 * @param event packet 1662 * @param Pointer to storage for bd_addr 1663 * @note: btstack_type B 1664 */ 1665 static inline void rfcomm_event_channel_opened_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 1666 reverse_bytes(&event[3], bd_addr, 6); 1667 } 1668 /** 1669 * @brief Get field con_handle from event RFCOMM_EVENT_CHANNEL_OPENED 1670 * @param event packet 1671 * @return con_handle 1672 * @note: btstack_type 2 1673 */ 1674 static inline uint16_t rfcomm_event_channel_opened_get_con_handle(const uint8_t * event){ 1675 return little_endian_read_16(event, 9); 1676 } 1677 /** 1678 * @brief Get field server_channel from event RFCOMM_EVENT_CHANNEL_OPENED 1679 * @param event packet 1680 * @return server_channel 1681 * @note: btstack_type 1 1682 */ 1683 static inline uint8_t rfcomm_event_channel_opened_get_server_channel(const uint8_t * event){ 1684 return event[11]; 1685 } 1686 /** 1687 * @brief Get field rfcomm_cid from event RFCOMM_EVENT_CHANNEL_OPENED 1688 * @param event packet 1689 * @return rfcomm_cid 1690 * @note: btstack_type 2 1691 */ 1692 static inline uint16_t rfcomm_event_channel_opened_get_rfcomm_cid(const uint8_t * event){ 1693 return little_endian_read_16(event, 12); 1694 } 1695 /** 1696 * @brief Get field max_frame_size from event RFCOMM_EVENT_CHANNEL_OPENED 1697 * @param event packet 1698 * @return max_frame_size 1699 * @note: btstack_type 2 1700 */ 1701 static inline uint16_t rfcomm_event_channel_opened_get_max_frame_size(const uint8_t * event){ 1702 return little_endian_read_16(event, 14); 1703 } 1704 /** 1705 * @brief Get field incoming from event RFCOMM_EVENT_CHANNEL_OPENED 1706 * @param event packet 1707 * @return incoming 1708 * @note: btstack_type 1 1709 */ 1710 static inline uint8_t rfcomm_event_channel_opened_get_incoming(const uint8_t * event){ 1711 return event[16]; 1712 } 1713 1714 /** 1715 * @brief Get field rfcomm_cid from event RFCOMM_EVENT_CHANNEL_CLOSED 1716 * @param event packet 1717 * @return rfcomm_cid 1718 * @note: btstack_type 2 1719 */ 1720 static inline uint16_t rfcomm_event_channel_closed_get_rfcomm_cid(const uint8_t * event){ 1721 return little_endian_read_16(event, 2); 1722 } 1723 1724 /** 1725 * @brief Get field bd_addr from event RFCOMM_EVENT_INCOMING_CONNECTION 1726 * @param event packet 1727 * @param Pointer to storage for bd_addr 1728 * @note: btstack_type B 1729 */ 1730 static inline void rfcomm_event_incoming_connection_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 1731 reverse_bytes(&event[2], bd_addr, 6); 1732 } 1733 /** 1734 * @brief Get field server_channel from event RFCOMM_EVENT_INCOMING_CONNECTION 1735 * @param event packet 1736 * @return server_channel 1737 * @note: btstack_type 1 1738 */ 1739 static inline uint8_t rfcomm_event_incoming_connection_get_server_channel(const uint8_t * event){ 1740 return event[8]; 1741 } 1742 /** 1743 * @brief Get field rfcomm_cid from event RFCOMM_EVENT_INCOMING_CONNECTION 1744 * @param event packet 1745 * @return rfcomm_cid 1746 * @note: btstack_type 2 1747 */ 1748 static inline uint16_t rfcomm_event_incoming_connection_get_rfcomm_cid(const uint8_t * event){ 1749 return little_endian_read_16(event, 9); 1750 } 1751 /** 1752 * @brief Get field con_handle from event RFCOMM_EVENT_INCOMING_CONNECTION 1753 * @param event packet 1754 * @return con_handle 1755 * @note: btstack_type H 1756 */ 1757 static inline hci_con_handle_t rfcomm_event_incoming_connection_get_con_handle(const uint8_t * event){ 1758 return little_endian_read_16(event, 11); 1759 } 1760 1761 /** 1762 * @brief Get field rfcomm_cid from event RFCOMM_EVENT_REMOTE_LINE_STATUS 1763 * @param event packet 1764 * @return rfcomm_cid 1765 * @note: btstack_type 2 1766 */ 1767 static inline uint16_t rfcomm_event_remote_line_status_get_rfcomm_cid(const uint8_t * event){ 1768 return little_endian_read_16(event, 2); 1769 } 1770 /** 1771 * @brief Get field line_status from event RFCOMM_EVENT_REMOTE_LINE_STATUS 1772 * @param event packet 1773 * @return line_status 1774 * @note: btstack_type 1 1775 */ 1776 static inline uint8_t rfcomm_event_remote_line_status_get_line_status(const uint8_t * event){ 1777 return event[4]; 1778 } 1779 1780 /** 1781 * @brief Get field rfcomm_cid from event RFCOMM_EVENT_REMOTE_MODEM_STATUS 1782 * @param event packet 1783 * @return rfcomm_cid 1784 * @note: btstack_type 2 1785 */ 1786 static inline uint16_t rfcomm_event_remote_modem_status_get_rfcomm_cid(const uint8_t * event){ 1787 return little_endian_read_16(event, 2); 1788 } 1789 /** 1790 * @brief Get field modem_status from event RFCOMM_EVENT_REMOTE_MODEM_STATUS 1791 * @param event packet 1792 * @return modem_status 1793 * @note: btstack_type 1 1794 */ 1795 static inline uint8_t rfcomm_event_remote_modem_status_get_modem_status(const uint8_t * event){ 1796 return event[4]; 1797 } 1798 1799 /** 1800 * @brief Get field rfcomm_cid from event RFCOMM_EVENT_CAN_SEND_NOW 1801 * @param event packet 1802 * @return rfcomm_cid 1803 * @note: btstack_type 2 1804 */ 1805 static inline uint16_t rfcomm_event_can_send_now_get_rfcomm_cid(const uint8_t * event){ 1806 return little_endian_read_16(event, 2); 1807 } 1808 1809 /** 1810 * @brief Get field status from event SDP_EVENT_QUERY_COMPLETE 1811 * @param event packet 1812 * @return status 1813 * @note: btstack_type 1 1814 */ 1815 static inline uint8_t sdp_event_query_complete_get_status(const uint8_t * event){ 1816 return event[2]; 1817 } 1818 1819 /** 1820 * @brief Get field rfcomm_channel from event SDP_EVENT_QUERY_RFCOMM_SERVICE 1821 * @param event packet 1822 * @return rfcomm_channel 1823 * @note: btstack_type 1 1824 */ 1825 static inline uint8_t sdp_event_query_rfcomm_service_get_rfcomm_channel(const uint8_t * event){ 1826 return event[2]; 1827 } 1828 /** 1829 * @brief Get field name from event SDP_EVENT_QUERY_RFCOMM_SERVICE 1830 * @param event packet 1831 * @return name 1832 * @note: btstack_type T 1833 */ 1834 static inline const char * sdp_event_query_rfcomm_service_get_name(const uint8_t * event){ 1835 return (const char *) &event[3]; 1836 } 1837 1838 /** 1839 * @brief Get field record_id from event SDP_EVENT_QUERY_ATTRIBUTE_BYTE 1840 * @param event packet 1841 * @return record_id 1842 * @note: btstack_type 2 1843 */ 1844 static inline uint16_t sdp_event_query_attribute_byte_get_record_id(const uint8_t * event){ 1845 return little_endian_read_16(event, 2); 1846 } 1847 /** 1848 * @brief Get field attribute_id from event SDP_EVENT_QUERY_ATTRIBUTE_BYTE 1849 * @param event packet 1850 * @return attribute_id 1851 * @note: btstack_type 2 1852 */ 1853 static inline uint16_t sdp_event_query_attribute_byte_get_attribute_id(const uint8_t * event){ 1854 return little_endian_read_16(event, 4); 1855 } 1856 /** 1857 * @brief Get field attribute_length from event SDP_EVENT_QUERY_ATTRIBUTE_BYTE 1858 * @param event packet 1859 * @return attribute_length 1860 * @note: btstack_type 2 1861 */ 1862 static inline uint16_t sdp_event_query_attribute_byte_get_attribute_length(const uint8_t * event){ 1863 return little_endian_read_16(event, 6); 1864 } 1865 /** 1866 * @brief Get field data_offset from event SDP_EVENT_QUERY_ATTRIBUTE_BYTE 1867 * @param event packet 1868 * @return data_offset 1869 * @note: btstack_type 2 1870 */ 1871 static inline uint16_t sdp_event_query_attribute_byte_get_data_offset(const uint8_t * event){ 1872 return little_endian_read_16(event, 8); 1873 } 1874 /** 1875 * @brief Get field data from event SDP_EVENT_QUERY_ATTRIBUTE_BYTE 1876 * @param event packet 1877 * @return data 1878 * @note: btstack_type 1 1879 */ 1880 static inline uint8_t sdp_event_query_attribute_byte_get_data(const uint8_t * event){ 1881 return event[10]; 1882 } 1883 1884 /** 1885 * @brief Get field record_id from event SDP_EVENT_QUERY_ATTRIBUTE_VALUE 1886 * @param event packet 1887 * @return record_id 1888 * @note: btstack_type 2 1889 */ 1890 static inline uint16_t sdp_event_query_attribute_value_get_record_id(const uint8_t * event){ 1891 return little_endian_read_16(event, 2); 1892 } 1893 /** 1894 * @brief Get field attribute_id from event SDP_EVENT_QUERY_ATTRIBUTE_VALUE 1895 * @param event packet 1896 * @return attribute_id 1897 * @note: btstack_type 2 1898 */ 1899 static inline uint16_t sdp_event_query_attribute_value_get_attribute_id(const uint8_t * event){ 1900 return little_endian_read_16(event, 4); 1901 } 1902 /** 1903 * @brief Get field attribute_length from event SDP_EVENT_QUERY_ATTRIBUTE_VALUE 1904 * @param event packet 1905 * @return attribute_length 1906 * @note: btstack_type L 1907 */ 1908 static inline uint16_t sdp_event_query_attribute_value_get_attribute_length(const uint8_t * event){ 1909 return little_endian_read_16(event, 6); 1910 } 1911 /** 1912 * @brief Get field attribute_value from event SDP_EVENT_QUERY_ATTRIBUTE_VALUE 1913 * @param event packet 1914 * @return attribute_value 1915 * @note: btstack_type V 1916 */ 1917 static inline const uint8_t * sdp_event_query_attribute_value_get_attribute_value(const uint8_t * event){ 1918 return &event[8]; 1919 } 1920 1921 /** 1922 * @brief Get field total_count from event SDP_EVENT_QUERY_SERVICE_RECORD_HANDLE 1923 * @param event packet 1924 * @return total_count 1925 * @note: btstack_type 2 1926 */ 1927 static inline uint16_t sdp_event_query_service_record_handle_get_total_count(const uint8_t * event){ 1928 return little_endian_read_16(event, 2); 1929 } 1930 /** 1931 * @brief Get field record_index from event SDP_EVENT_QUERY_SERVICE_RECORD_HANDLE 1932 * @param event packet 1933 * @return record_index 1934 * @note: btstack_type 2 1935 */ 1936 static inline uint16_t sdp_event_query_service_record_handle_get_record_index(const uint8_t * event){ 1937 return little_endian_read_16(event, 4); 1938 } 1939 /** 1940 * @brief Get field record_handle from event SDP_EVENT_QUERY_SERVICE_RECORD_HANDLE 1941 * @param event packet 1942 * @return record_handle 1943 * @note: btstack_type 4 1944 */ 1945 static inline uint32_t sdp_event_query_service_record_handle_get_record_handle(const uint8_t * event){ 1946 return little_endian_read_32(event, 6); 1947 } 1948 1949 #ifdef ENABLE_BLE 1950 /** 1951 * @brief Get field handle from event GATT_EVENT_QUERY_COMPLETE 1952 * @param event packet 1953 * @return handle 1954 * @note: btstack_type H 1955 */ 1956 static inline hci_con_handle_t gatt_event_query_complete_get_handle(const uint8_t * event){ 1957 return little_endian_read_16(event, 2); 1958 } 1959 /** 1960 * @brief Get field att_status from event GATT_EVENT_QUERY_COMPLETE 1961 * @param event packet 1962 * @return att_status 1963 * @note: btstack_type 1 1964 */ 1965 static inline uint8_t gatt_event_query_complete_get_att_status(const uint8_t * event){ 1966 return event[4]; 1967 } 1968 #endif 1969 1970 #ifdef ENABLE_BLE 1971 /** 1972 * @brief Get field handle from event GATT_EVENT_SERVICE_QUERY_RESULT 1973 * @param event packet 1974 * @return handle 1975 * @note: btstack_type H 1976 */ 1977 static inline hci_con_handle_t gatt_event_service_query_result_get_handle(const uint8_t * event){ 1978 return little_endian_read_16(event, 2); 1979 } 1980 /** 1981 * @brief Get field service from event GATT_EVENT_SERVICE_QUERY_RESULT 1982 * @param event packet 1983 * @param Pointer to storage for service 1984 * @note: btstack_type X 1985 */ 1986 static inline void gatt_event_service_query_result_get_service(const uint8_t * event, gatt_client_service_t * service){ 1987 gatt_client_deserialize_service(event, 4, service); 1988 } 1989 #endif 1990 1991 #ifdef ENABLE_BLE 1992 /** 1993 * @brief Get field handle from event GATT_EVENT_CHARACTERISTIC_QUERY_RESULT 1994 * @param event packet 1995 * @return handle 1996 * @note: btstack_type H 1997 */ 1998 static inline hci_con_handle_t gatt_event_characteristic_query_result_get_handle(const uint8_t * event){ 1999 return little_endian_read_16(event, 2); 2000 } 2001 /** 2002 * @brief Get field characteristic from event GATT_EVENT_CHARACTERISTIC_QUERY_RESULT 2003 * @param event packet 2004 * @param Pointer to storage for characteristic 2005 * @note: btstack_type Y 2006 */ 2007 static inline void gatt_event_characteristic_query_result_get_characteristic(const uint8_t * event, gatt_client_characteristic_t * characteristic){ 2008 gatt_client_deserialize_characteristic(event, 4, characteristic); 2009 } 2010 #endif 2011 2012 #ifdef ENABLE_BLE 2013 /** 2014 * @brief Get field handle from event GATT_EVENT_INCLUDED_SERVICE_QUERY_RESULT 2015 * @param event packet 2016 * @return handle 2017 * @note: btstack_type H 2018 */ 2019 static inline hci_con_handle_t gatt_event_included_service_query_result_get_handle(const uint8_t * event){ 2020 return little_endian_read_16(event, 2); 2021 } 2022 /** 2023 * @brief Get field include_handle from event GATT_EVENT_INCLUDED_SERVICE_QUERY_RESULT 2024 * @param event packet 2025 * @return include_handle 2026 * @note: btstack_type 2 2027 */ 2028 static inline uint16_t gatt_event_included_service_query_result_get_include_handle(const uint8_t * event){ 2029 return little_endian_read_16(event, 4); 2030 } 2031 /** 2032 * @brief Get field service from event GATT_EVENT_INCLUDED_SERVICE_QUERY_RESULT 2033 * @param event packet 2034 * @param Pointer to storage for service 2035 * @note: btstack_type X 2036 */ 2037 static inline void gatt_event_included_service_query_result_get_service(const uint8_t * event, gatt_client_service_t * service){ 2038 gatt_client_deserialize_service(event, 6, service); 2039 } 2040 #endif 2041 2042 #ifdef ENABLE_BLE 2043 /** 2044 * @brief Get field handle from event GATT_EVENT_ALL_CHARACTERISTIC_DESCRIPTORS_QUERY_RESULT 2045 * @param event packet 2046 * @return handle 2047 * @note: btstack_type H 2048 */ 2049 static inline hci_con_handle_t gatt_event_all_characteristic_descriptors_query_result_get_handle(const uint8_t * event){ 2050 return little_endian_read_16(event, 2); 2051 } 2052 /** 2053 * @brief Get field characteristic_descriptor from event GATT_EVENT_ALL_CHARACTERISTIC_DESCRIPTORS_QUERY_RESULT 2054 * @param event packet 2055 * @param Pointer to storage for characteristic_descriptor 2056 * @note: btstack_type Z 2057 */ 2058 static inline void gatt_event_all_characteristic_descriptors_query_result_get_characteristic_descriptor(const uint8_t * event, gatt_client_characteristic_descriptor_t * characteristic_descriptor){ 2059 gatt_client_deserialize_characteristic_descriptor(event, 4, characteristic_descriptor); 2060 } 2061 #endif 2062 2063 #ifdef ENABLE_BLE 2064 /** 2065 * @brief Get field handle from event GATT_EVENT_CHARACTERISTIC_VALUE_QUERY_RESULT 2066 * @param event packet 2067 * @return handle 2068 * @note: btstack_type H 2069 */ 2070 static inline hci_con_handle_t gatt_event_characteristic_value_query_result_get_handle(const uint8_t * event){ 2071 return little_endian_read_16(event, 2); 2072 } 2073 /** 2074 * @brief Get field value_handle from event GATT_EVENT_CHARACTERISTIC_VALUE_QUERY_RESULT 2075 * @param event packet 2076 * @return value_handle 2077 * @note: btstack_type 2 2078 */ 2079 static inline uint16_t gatt_event_characteristic_value_query_result_get_value_handle(const uint8_t * event){ 2080 return little_endian_read_16(event, 4); 2081 } 2082 /** 2083 * @brief Get field value_length from event GATT_EVENT_CHARACTERISTIC_VALUE_QUERY_RESULT 2084 * @param event packet 2085 * @return value_length 2086 * @note: btstack_type L 2087 */ 2088 static inline uint16_t gatt_event_characteristic_value_query_result_get_value_length(const uint8_t * event){ 2089 return little_endian_read_16(event, 6); 2090 } 2091 /** 2092 * @brief Get field value from event GATT_EVENT_CHARACTERISTIC_VALUE_QUERY_RESULT 2093 * @param event packet 2094 * @return value 2095 * @note: btstack_type V 2096 */ 2097 static inline const uint8_t * gatt_event_characteristic_value_query_result_get_value(const uint8_t * event){ 2098 return &event[8]; 2099 } 2100 #endif 2101 2102 #ifdef ENABLE_BLE 2103 /** 2104 * @brief Get field handle from event GATT_EVENT_LONG_CHARACTERISTIC_VALUE_QUERY_RESULT 2105 * @param event packet 2106 * @return handle 2107 * @note: btstack_type H 2108 */ 2109 static inline hci_con_handle_t gatt_event_long_characteristic_value_query_result_get_handle(const uint8_t * event){ 2110 return little_endian_read_16(event, 2); 2111 } 2112 /** 2113 * @brief Get field value_handle from event GATT_EVENT_LONG_CHARACTERISTIC_VALUE_QUERY_RESULT 2114 * @param event packet 2115 * @return value_handle 2116 * @note: btstack_type 2 2117 */ 2118 static inline uint16_t gatt_event_long_characteristic_value_query_result_get_value_handle(const uint8_t * event){ 2119 return little_endian_read_16(event, 4); 2120 } 2121 /** 2122 * @brief Get field value_offset from event GATT_EVENT_LONG_CHARACTERISTIC_VALUE_QUERY_RESULT 2123 * @param event packet 2124 * @return value_offset 2125 * @note: btstack_type 2 2126 */ 2127 static inline uint16_t gatt_event_long_characteristic_value_query_result_get_value_offset(const uint8_t * event){ 2128 return little_endian_read_16(event, 6); 2129 } 2130 /** 2131 * @brief Get field value_length from event GATT_EVENT_LONG_CHARACTERISTIC_VALUE_QUERY_RESULT 2132 * @param event packet 2133 * @return value_length 2134 * @note: btstack_type L 2135 */ 2136 static inline uint16_t gatt_event_long_characteristic_value_query_result_get_value_length(const uint8_t * event){ 2137 return little_endian_read_16(event, 8); 2138 } 2139 /** 2140 * @brief Get field value from event GATT_EVENT_LONG_CHARACTERISTIC_VALUE_QUERY_RESULT 2141 * @param event packet 2142 * @return value 2143 * @note: btstack_type V 2144 */ 2145 static inline const uint8_t * gatt_event_long_characteristic_value_query_result_get_value(const uint8_t * event){ 2146 return &event[10]; 2147 } 2148 #endif 2149 2150 #ifdef ENABLE_BLE 2151 /** 2152 * @brief Get field handle from event GATT_EVENT_NOTIFICATION 2153 * @param event packet 2154 * @return handle 2155 * @note: btstack_type H 2156 */ 2157 static inline hci_con_handle_t gatt_event_notification_get_handle(const uint8_t * event){ 2158 return little_endian_read_16(event, 2); 2159 } 2160 /** 2161 * @brief Get field value_handle from event GATT_EVENT_NOTIFICATION 2162 * @param event packet 2163 * @return value_handle 2164 * @note: btstack_type 2 2165 */ 2166 static inline uint16_t gatt_event_notification_get_value_handle(const uint8_t * event){ 2167 return little_endian_read_16(event, 4); 2168 } 2169 /** 2170 * @brief Get field value_length from event GATT_EVENT_NOTIFICATION 2171 * @param event packet 2172 * @return value_length 2173 * @note: btstack_type L 2174 */ 2175 static inline uint16_t gatt_event_notification_get_value_length(const uint8_t * event){ 2176 return little_endian_read_16(event, 6); 2177 } 2178 /** 2179 * @brief Get field value from event GATT_EVENT_NOTIFICATION 2180 * @param event packet 2181 * @return value 2182 * @note: btstack_type V 2183 */ 2184 static inline const uint8_t * gatt_event_notification_get_value(const uint8_t * event){ 2185 return &event[8]; 2186 } 2187 #endif 2188 2189 #ifdef ENABLE_BLE 2190 /** 2191 * @brief Get field handle from event GATT_EVENT_INDICATION 2192 * @param event packet 2193 * @return handle 2194 * @note: btstack_type H 2195 */ 2196 static inline hci_con_handle_t gatt_event_indication_get_handle(const uint8_t * event){ 2197 return little_endian_read_16(event, 2); 2198 } 2199 /** 2200 * @brief Get field value_handle from event GATT_EVENT_INDICATION 2201 * @param event packet 2202 * @return value_handle 2203 * @note: btstack_type 2 2204 */ 2205 static inline uint16_t gatt_event_indication_get_value_handle(const uint8_t * event){ 2206 return little_endian_read_16(event, 4); 2207 } 2208 /** 2209 * @brief Get field value_length from event GATT_EVENT_INDICATION 2210 * @param event packet 2211 * @return value_length 2212 * @note: btstack_type L 2213 */ 2214 static inline uint16_t gatt_event_indication_get_value_length(const uint8_t * event){ 2215 return little_endian_read_16(event, 6); 2216 } 2217 /** 2218 * @brief Get field value from event GATT_EVENT_INDICATION 2219 * @param event packet 2220 * @return value 2221 * @note: btstack_type V 2222 */ 2223 static inline const uint8_t * gatt_event_indication_get_value(const uint8_t * event){ 2224 return &event[8]; 2225 } 2226 #endif 2227 2228 #ifdef ENABLE_BLE 2229 /** 2230 * @brief Get field handle from event GATT_EVENT_CHARACTERISTIC_DESCRIPTOR_QUERY_RESULT 2231 * @param event packet 2232 * @return handle 2233 * @note: btstack_type H 2234 */ 2235 static inline hci_con_handle_t gatt_event_characteristic_descriptor_query_result_get_handle(const uint8_t * event){ 2236 return little_endian_read_16(event, 2); 2237 } 2238 /** 2239 * @brief Get field descriptor_handle from event GATT_EVENT_CHARACTERISTIC_DESCRIPTOR_QUERY_RESULT 2240 * @param event packet 2241 * @return descriptor_handle 2242 * @note: btstack_type 2 2243 */ 2244 static inline uint16_t gatt_event_characteristic_descriptor_query_result_get_descriptor_handle(const uint8_t * event){ 2245 return little_endian_read_16(event, 4); 2246 } 2247 /** 2248 * @brief Get field descriptor_length from event GATT_EVENT_CHARACTERISTIC_DESCRIPTOR_QUERY_RESULT 2249 * @param event packet 2250 * @return descriptor_length 2251 * @note: btstack_type L 2252 */ 2253 static inline uint16_t gatt_event_characteristic_descriptor_query_result_get_descriptor_length(const uint8_t * event){ 2254 return little_endian_read_16(event, 6); 2255 } 2256 /** 2257 * @brief Get field descriptor from event GATT_EVENT_CHARACTERISTIC_DESCRIPTOR_QUERY_RESULT 2258 * @param event packet 2259 * @return descriptor 2260 * @note: btstack_type V 2261 */ 2262 static inline const uint8_t * gatt_event_characteristic_descriptor_query_result_get_descriptor(const uint8_t * event){ 2263 return &event[8]; 2264 } 2265 #endif 2266 2267 #ifdef ENABLE_BLE 2268 /** 2269 * @brief Get field handle from event GATT_EVENT_LONG_CHARACTERISTIC_DESCRIPTOR_QUERY_RESULT 2270 * @param event packet 2271 * @return handle 2272 * @note: btstack_type H 2273 */ 2274 static inline hci_con_handle_t gatt_event_long_characteristic_descriptor_query_result_get_handle(const uint8_t * event){ 2275 return little_endian_read_16(event, 2); 2276 } 2277 /** 2278 * @brief Get field descriptor_offset from event GATT_EVENT_LONG_CHARACTERISTIC_DESCRIPTOR_QUERY_RESULT 2279 * @param event packet 2280 * @return descriptor_offset 2281 * @note: btstack_type 2 2282 */ 2283 static inline uint16_t gatt_event_long_characteristic_descriptor_query_result_get_descriptor_offset(const uint8_t * event){ 2284 return little_endian_read_16(event, 4); 2285 } 2286 /** 2287 * @brief Get field descriptor_length from event GATT_EVENT_LONG_CHARACTERISTIC_DESCRIPTOR_QUERY_RESULT 2288 * @param event packet 2289 * @return descriptor_length 2290 * @note: btstack_type L 2291 */ 2292 static inline uint16_t gatt_event_long_characteristic_descriptor_query_result_get_descriptor_length(const uint8_t * event){ 2293 return little_endian_read_16(event, 6); 2294 } 2295 /** 2296 * @brief Get field descriptor from event GATT_EVENT_LONG_CHARACTERISTIC_DESCRIPTOR_QUERY_RESULT 2297 * @param event packet 2298 * @return descriptor 2299 * @note: btstack_type V 2300 */ 2301 static inline const uint8_t * gatt_event_long_characteristic_descriptor_query_result_get_descriptor(const uint8_t * event){ 2302 return &event[8]; 2303 } 2304 #endif 2305 2306 #ifdef ENABLE_BLE 2307 /** 2308 * @brief Get field handle from event GATT_EVENT_MTU 2309 * @param event packet 2310 * @return handle 2311 * @note: btstack_type H 2312 */ 2313 static inline hci_con_handle_t gatt_event_mtu_get_handle(const uint8_t * event){ 2314 return little_endian_read_16(event, 2); 2315 } 2316 /** 2317 * @brief Get field MTU from event GATT_EVENT_MTU 2318 * @param event packet 2319 * @return MTU 2320 * @note: btstack_type 2 2321 */ 2322 static inline uint16_t gatt_event_mtu_get_MTU(const uint8_t * event){ 2323 return little_endian_read_16(event, 4); 2324 } 2325 #endif 2326 2327 #ifdef ENABLE_BLE 2328 /** 2329 * @brief Get field handle from event GATT_EVENT_CAN_WRITE_WITHOUT_RESPONSE 2330 * @param event packet 2331 * @return handle 2332 * @note: btstack_type H 2333 */ 2334 static inline hci_con_handle_t gatt_event_can_write_without_response_get_handle(const uint8_t * event){ 2335 return little_endian_read_16(event, 2); 2336 } 2337 #endif 2338 2339 /** 2340 * @brief Get field address_type from event ATT_EVENT_CONNECTED 2341 * @param event packet 2342 * @return address_type 2343 * @note: btstack_type 1 2344 */ 2345 static inline uint8_t att_event_connected_get_address_type(const uint8_t * event){ 2346 return event[2]; 2347 } 2348 /** 2349 * @brief Get field address from event ATT_EVENT_CONNECTED 2350 * @param event packet 2351 * @param Pointer to storage for address 2352 * @note: btstack_type B 2353 */ 2354 static inline void att_event_connected_get_address(const uint8_t * event, bd_addr_t address){ 2355 reverse_bytes(&event[3], address, 6); 2356 } 2357 /** 2358 * @brief Get field handle from event ATT_EVENT_CONNECTED 2359 * @param event packet 2360 * @return handle 2361 * @note: btstack_type H 2362 */ 2363 static inline hci_con_handle_t att_event_connected_get_handle(const uint8_t * event){ 2364 return little_endian_read_16(event, 9); 2365 } 2366 2367 /** 2368 * @brief Get field handle from event ATT_EVENT_DISCONNECTED 2369 * @param event packet 2370 * @return handle 2371 * @note: btstack_type H 2372 */ 2373 static inline hci_con_handle_t att_event_disconnected_get_handle(const uint8_t * event){ 2374 return little_endian_read_16(event, 2); 2375 } 2376 2377 /** 2378 * @brief Get field handle from event ATT_EVENT_MTU_EXCHANGE_COMPLETE 2379 * @param event packet 2380 * @return handle 2381 * @note: btstack_type H 2382 */ 2383 static inline hci_con_handle_t att_event_mtu_exchange_complete_get_handle(const uint8_t * event){ 2384 return little_endian_read_16(event, 2); 2385 } 2386 /** 2387 * @brief Get field MTU from event ATT_EVENT_MTU_EXCHANGE_COMPLETE 2388 * @param event packet 2389 * @return MTU 2390 * @note: btstack_type 2 2391 */ 2392 static inline uint16_t att_event_mtu_exchange_complete_get_MTU(const uint8_t * event){ 2393 return little_endian_read_16(event, 4); 2394 } 2395 2396 /** 2397 * @brief Get field status from event ATT_EVENT_HANDLE_VALUE_INDICATION_COMPLETE 2398 * @param event packet 2399 * @return status 2400 * @note: btstack_type 1 2401 */ 2402 static inline uint8_t att_event_handle_value_indication_complete_get_status(const uint8_t * event){ 2403 return event[2]; 2404 } 2405 /** 2406 * @brief Get field conn_handle from event ATT_EVENT_HANDLE_VALUE_INDICATION_COMPLETE 2407 * @param event packet 2408 * @return conn_handle 2409 * @note: btstack_type H 2410 */ 2411 static inline hci_con_handle_t att_event_handle_value_indication_complete_get_conn_handle(const uint8_t * event){ 2412 return little_endian_read_16(event, 3); 2413 } 2414 /** 2415 * @brief Get field attribute_handle from event ATT_EVENT_HANDLE_VALUE_INDICATION_COMPLETE 2416 * @param event packet 2417 * @return attribute_handle 2418 * @note: btstack_type 2 2419 */ 2420 static inline uint16_t att_event_handle_value_indication_complete_get_attribute_handle(const uint8_t * event){ 2421 return little_endian_read_16(event, 5); 2422 } 2423 2424 2425 /** 2426 * @brief Get field status from event BNEP_EVENT_SERVICE_REGISTERED 2427 * @param event packet 2428 * @return status 2429 * @note: btstack_type 1 2430 */ 2431 static inline uint8_t bnep_event_service_registered_get_status(const uint8_t * event){ 2432 return event[2]; 2433 } 2434 /** 2435 * @brief Get field service_uuid from event BNEP_EVENT_SERVICE_REGISTERED 2436 * @param event packet 2437 * @return service_uuid 2438 * @note: btstack_type 2 2439 */ 2440 static inline uint16_t bnep_event_service_registered_get_service_uuid(const uint8_t * event){ 2441 return little_endian_read_16(event, 3); 2442 } 2443 2444 /** 2445 * @brief Get field status from event BNEP_EVENT_CHANNEL_OPENED 2446 * @param event packet 2447 * @return status 2448 * @note: btstack_type 1 2449 */ 2450 static inline uint8_t bnep_event_channel_opened_get_status(const uint8_t * event){ 2451 return event[2]; 2452 } 2453 /** 2454 * @brief Get field bnep_cid from event BNEP_EVENT_CHANNEL_OPENED 2455 * @param event packet 2456 * @return bnep_cid 2457 * @note: btstack_type 2 2458 */ 2459 static inline uint16_t bnep_event_channel_opened_get_bnep_cid(const uint8_t * event){ 2460 return little_endian_read_16(event, 3); 2461 } 2462 /** 2463 * @brief Get field source_uuid from event BNEP_EVENT_CHANNEL_OPENED 2464 * @param event packet 2465 * @return source_uuid 2466 * @note: btstack_type 2 2467 */ 2468 static inline uint16_t bnep_event_channel_opened_get_source_uuid(const uint8_t * event){ 2469 return little_endian_read_16(event, 5); 2470 } 2471 /** 2472 * @brief Get field destination_uuid from event BNEP_EVENT_CHANNEL_OPENED 2473 * @param event packet 2474 * @return destination_uuid 2475 * @note: btstack_type 2 2476 */ 2477 static inline uint16_t bnep_event_channel_opened_get_destination_uuid(const uint8_t * event){ 2478 return little_endian_read_16(event, 7); 2479 } 2480 /** 2481 * @brief Get field mtu from event BNEP_EVENT_CHANNEL_OPENED 2482 * @param event packet 2483 * @return mtu 2484 * @note: btstack_type 2 2485 */ 2486 static inline uint16_t bnep_event_channel_opened_get_mtu(const uint8_t * event){ 2487 return little_endian_read_16(event, 9); 2488 } 2489 /** 2490 * @brief Get field remote_address from event BNEP_EVENT_CHANNEL_OPENED 2491 * @param event packet 2492 * @param Pointer to storage for remote_address 2493 * @note: btstack_type B 2494 */ 2495 static inline void bnep_event_channel_opened_get_remote_address(const uint8_t * event, bd_addr_t remote_address){ 2496 reverse_bytes(&event[11], remote_address, 6); 2497 } 2498 /** 2499 * @brief Get field con_handle from event BNEP_EVENT_CHANNEL_OPENED 2500 * @param event packet 2501 * @return con_handle 2502 * @note: btstack_type H 2503 */ 2504 static inline hci_con_handle_t bnep_event_channel_opened_get_con_handle(const uint8_t * event){ 2505 return little_endian_read_16(event, 17); 2506 } 2507 2508 /** 2509 * @brief Get field bnep_cid from event BNEP_EVENT_CHANNEL_CLOSED 2510 * @param event packet 2511 * @return bnep_cid 2512 * @note: btstack_type 2 2513 */ 2514 static inline uint16_t bnep_event_channel_closed_get_bnep_cid(const uint8_t * event){ 2515 return little_endian_read_16(event, 2); 2516 } 2517 /** 2518 * @brief Get field source_uuid from event BNEP_EVENT_CHANNEL_CLOSED 2519 * @param event packet 2520 * @return source_uuid 2521 * @note: btstack_type 2 2522 */ 2523 static inline uint16_t bnep_event_channel_closed_get_source_uuid(const uint8_t * event){ 2524 return little_endian_read_16(event, 4); 2525 } 2526 /** 2527 * @brief Get field destination_uuid from event BNEP_EVENT_CHANNEL_CLOSED 2528 * @param event packet 2529 * @return destination_uuid 2530 * @note: btstack_type 2 2531 */ 2532 static inline uint16_t bnep_event_channel_closed_get_destination_uuid(const uint8_t * event){ 2533 return little_endian_read_16(event, 6); 2534 } 2535 /** 2536 * @brief Get field remote_address from event BNEP_EVENT_CHANNEL_CLOSED 2537 * @param event packet 2538 * @param Pointer to storage for remote_address 2539 * @note: btstack_type B 2540 */ 2541 static inline void bnep_event_channel_closed_get_remote_address(const uint8_t * event, bd_addr_t remote_address){ 2542 reverse_bytes(&event[8], remote_address, 6); 2543 } 2544 2545 /** 2546 * @brief Get field bnep_cid from event BNEP_EVENT_CHANNEL_TIMEOUT 2547 * @param event packet 2548 * @return bnep_cid 2549 * @note: btstack_type 2 2550 */ 2551 static inline uint16_t bnep_event_channel_timeout_get_bnep_cid(const uint8_t * event){ 2552 return little_endian_read_16(event, 2); 2553 } 2554 /** 2555 * @brief Get field source_uuid from event BNEP_EVENT_CHANNEL_TIMEOUT 2556 * @param event packet 2557 * @return source_uuid 2558 * @note: btstack_type 2 2559 */ 2560 static inline uint16_t bnep_event_channel_timeout_get_source_uuid(const uint8_t * event){ 2561 return little_endian_read_16(event, 4); 2562 } 2563 /** 2564 * @brief Get field destination_uuid from event BNEP_EVENT_CHANNEL_TIMEOUT 2565 * @param event packet 2566 * @return destination_uuid 2567 * @note: btstack_type 2 2568 */ 2569 static inline uint16_t bnep_event_channel_timeout_get_destination_uuid(const uint8_t * event){ 2570 return little_endian_read_16(event, 6); 2571 } 2572 /** 2573 * @brief Get field remote_address from event BNEP_EVENT_CHANNEL_TIMEOUT 2574 * @param event packet 2575 * @param Pointer to storage for remote_address 2576 * @note: btstack_type B 2577 */ 2578 static inline void bnep_event_channel_timeout_get_remote_address(const uint8_t * event, bd_addr_t remote_address){ 2579 reverse_bytes(&event[8], remote_address, 6); 2580 } 2581 /** 2582 * @brief Get field channel_state from event BNEP_EVENT_CHANNEL_TIMEOUT 2583 * @param event packet 2584 * @return channel_state 2585 * @note: btstack_type 1 2586 */ 2587 static inline uint8_t bnep_event_channel_timeout_get_channel_state(const uint8_t * event){ 2588 return event[14]; 2589 } 2590 2591 /** 2592 * @brief Get field bnep_cid from event BNEP_EVENT_CAN_SEND_NOW 2593 * @param event packet 2594 * @return bnep_cid 2595 * @note: btstack_type 2 2596 */ 2597 static inline uint16_t bnep_event_can_send_now_get_bnep_cid(const uint8_t * event){ 2598 return little_endian_read_16(event, 2); 2599 } 2600 /** 2601 * @brief Get field source_uuid from event BNEP_EVENT_CAN_SEND_NOW 2602 * @param event packet 2603 * @return source_uuid 2604 * @note: btstack_type 2 2605 */ 2606 static inline uint16_t bnep_event_can_send_now_get_source_uuid(const uint8_t * event){ 2607 return little_endian_read_16(event, 4); 2608 } 2609 /** 2610 * @brief Get field destination_uuid from event BNEP_EVENT_CAN_SEND_NOW 2611 * @param event packet 2612 * @return destination_uuid 2613 * @note: btstack_type 2 2614 */ 2615 static inline uint16_t bnep_event_can_send_now_get_destination_uuid(const uint8_t * event){ 2616 return little_endian_read_16(event, 6); 2617 } 2618 /** 2619 * @brief Get field remote_address from event BNEP_EVENT_CAN_SEND_NOW 2620 * @param event packet 2621 * @param Pointer to storage for remote_address 2622 * @note: btstack_type B 2623 */ 2624 static inline void bnep_event_can_send_now_get_remote_address(const uint8_t * event, bd_addr_t remote_address){ 2625 reverse_bytes(&event[8], remote_address, 6); 2626 } 2627 2628 #ifdef ENABLE_BLE 2629 /** 2630 * @brief Get field handle from event SM_EVENT_JUST_WORKS_REQUEST 2631 * @param event packet 2632 * @return handle 2633 * @note: btstack_type H 2634 */ 2635 static inline hci_con_handle_t sm_event_just_works_request_get_handle(const uint8_t * event){ 2636 return little_endian_read_16(event, 2); 2637 } 2638 /** 2639 * @brief Get field addr_type from event SM_EVENT_JUST_WORKS_REQUEST 2640 * @param event packet 2641 * @return addr_type 2642 * @note: btstack_type 1 2643 */ 2644 static inline uint8_t sm_event_just_works_request_get_addr_type(const uint8_t * event){ 2645 return event[4]; 2646 } 2647 /** 2648 * @brief Get field address from event SM_EVENT_JUST_WORKS_REQUEST 2649 * @param event packet 2650 * @param Pointer to storage for address 2651 * @note: btstack_type B 2652 */ 2653 static inline void sm_event_just_works_request_get_address(const uint8_t * event, bd_addr_t address){ 2654 reverse_bytes(&event[5], address, 6); 2655 } 2656 #endif 2657 2658 #ifdef ENABLE_BLE 2659 /** 2660 * @brief Get field handle from event SM_EVENT_PASSKEY_DISPLAY_NUMBER 2661 * @param event packet 2662 * @return handle 2663 * @note: btstack_type H 2664 */ 2665 static inline hci_con_handle_t sm_event_passkey_display_number_get_handle(const uint8_t * event){ 2666 return little_endian_read_16(event, 2); 2667 } 2668 /** 2669 * @brief Get field addr_type from event SM_EVENT_PASSKEY_DISPLAY_NUMBER 2670 * @param event packet 2671 * @return addr_type 2672 * @note: btstack_type 1 2673 */ 2674 static inline uint8_t sm_event_passkey_display_number_get_addr_type(const uint8_t * event){ 2675 return event[4]; 2676 } 2677 /** 2678 * @brief Get field address from event SM_EVENT_PASSKEY_DISPLAY_NUMBER 2679 * @param event packet 2680 * @param Pointer to storage for address 2681 * @note: btstack_type B 2682 */ 2683 static inline void sm_event_passkey_display_number_get_address(const uint8_t * event, bd_addr_t address){ 2684 reverse_bytes(&event[5], address, 6); 2685 } 2686 /** 2687 * @brief Get field passkey from event SM_EVENT_PASSKEY_DISPLAY_NUMBER 2688 * @param event packet 2689 * @return passkey 2690 * @note: btstack_type 4 2691 */ 2692 static inline uint32_t sm_event_passkey_display_number_get_passkey(const uint8_t * event){ 2693 return little_endian_read_32(event, 11); 2694 } 2695 #endif 2696 2697 #ifdef ENABLE_BLE 2698 /** 2699 * @brief Get field handle from event SM_EVENT_PASSKEY_DISPLAY_CANCEL 2700 * @param event packet 2701 * @return handle 2702 * @note: btstack_type H 2703 */ 2704 static inline hci_con_handle_t sm_event_passkey_display_cancel_get_handle(const uint8_t * event){ 2705 return little_endian_read_16(event, 2); 2706 } 2707 /** 2708 * @brief Get field addr_type from event SM_EVENT_PASSKEY_DISPLAY_CANCEL 2709 * @param event packet 2710 * @return addr_type 2711 * @note: btstack_type 1 2712 */ 2713 static inline uint8_t sm_event_passkey_display_cancel_get_addr_type(const uint8_t * event){ 2714 return event[4]; 2715 } 2716 /** 2717 * @brief Get field address from event SM_EVENT_PASSKEY_DISPLAY_CANCEL 2718 * @param event packet 2719 * @param Pointer to storage for address 2720 * @note: btstack_type B 2721 */ 2722 static inline void sm_event_passkey_display_cancel_get_address(const uint8_t * event, bd_addr_t address){ 2723 reverse_bytes(&event[5], address, 6); 2724 } 2725 #endif 2726 2727 #ifdef ENABLE_BLE 2728 /** 2729 * @brief Get field handle from event SM_EVENT_PASSKEY_INPUT_NUMBER 2730 * @param event packet 2731 * @return handle 2732 * @note: btstack_type H 2733 */ 2734 static inline hci_con_handle_t sm_event_passkey_input_number_get_handle(const uint8_t * event){ 2735 return little_endian_read_16(event, 2); 2736 } 2737 /** 2738 * @brief Get field addr_type from event SM_EVENT_PASSKEY_INPUT_NUMBER 2739 * @param event packet 2740 * @return addr_type 2741 * @note: btstack_type 1 2742 */ 2743 static inline uint8_t sm_event_passkey_input_number_get_addr_type(const uint8_t * event){ 2744 return event[4]; 2745 } 2746 /** 2747 * @brief Get field address from event SM_EVENT_PASSKEY_INPUT_NUMBER 2748 * @param event packet 2749 * @param Pointer to storage for address 2750 * @note: btstack_type B 2751 */ 2752 static inline void sm_event_passkey_input_number_get_address(const uint8_t * event, bd_addr_t address){ 2753 reverse_bytes(&event[5], address, 6); 2754 } 2755 #endif 2756 2757 #ifdef ENABLE_BLE 2758 /** 2759 * @brief Get field handle from event SM_EVENT_NUMERIC_COMPARISON_REQUEST 2760 * @param event packet 2761 * @return handle 2762 * @note: btstack_type H 2763 */ 2764 static inline hci_con_handle_t sm_event_numeric_comparison_request_get_handle(const uint8_t * event){ 2765 return little_endian_read_16(event, 2); 2766 } 2767 /** 2768 * @brief Get field addr_type from event SM_EVENT_NUMERIC_COMPARISON_REQUEST 2769 * @param event packet 2770 * @return addr_type 2771 * @note: btstack_type 1 2772 */ 2773 static inline uint8_t sm_event_numeric_comparison_request_get_addr_type(const uint8_t * event){ 2774 return event[4]; 2775 } 2776 /** 2777 * @brief Get field address from event SM_EVENT_NUMERIC_COMPARISON_REQUEST 2778 * @param event packet 2779 * @param Pointer to storage for address 2780 * @note: btstack_type B 2781 */ 2782 static inline void sm_event_numeric_comparison_request_get_address(const uint8_t * event, bd_addr_t address){ 2783 reverse_bytes(&event[5], address, 6); 2784 } 2785 /** 2786 * @brief Get field passkey from event SM_EVENT_NUMERIC_COMPARISON_REQUEST 2787 * @param event packet 2788 * @return passkey 2789 * @note: btstack_type 4 2790 */ 2791 static inline uint32_t sm_event_numeric_comparison_request_get_passkey(const uint8_t * event){ 2792 return little_endian_read_32(event, 11); 2793 } 2794 #endif 2795 2796 #ifdef ENABLE_BLE 2797 /** 2798 * @brief Get field handle from event SM_EVENT_IDENTITY_RESOLVING_STARTED 2799 * @param event packet 2800 * @return handle 2801 * @note: btstack_type H 2802 */ 2803 static inline hci_con_handle_t sm_event_identity_resolving_started_get_handle(const uint8_t * event){ 2804 return little_endian_read_16(event, 2); 2805 } 2806 /** 2807 * @brief Get field addr_type from event SM_EVENT_IDENTITY_RESOLVING_STARTED 2808 * @param event packet 2809 * @return addr_type 2810 * @note: btstack_type 1 2811 */ 2812 static inline uint8_t sm_event_identity_resolving_started_get_addr_type(const uint8_t * event){ 2813 return event[4]; 2814 } 2815 /** 2816 * @brief Get field address from event SM_EVENT_IDENTITY_RESOLVING_STARTED 2817 * @param event packet 2818 * @param Pointer to storage for address 2819 * @note: btstack_type B 2820 */ 2821 static inline void sm_event_identity_resolving_started_get_address(const uint8_t * event, bd_addr_t address){ 2822 reverse_bytes(&event[5], address, 6); 2823 } 2824 #endif 2825 2826 #ifdef ENABLE_BLE 2827 /** 2828 * @brief Get field handle from event SM_EVENT_IDENTITY_RESOLVING_FAILED 2829 * @param event packet 2830 * @return handle 2831 * @note: btstack_type H 2832 */ 2833 static inline hci_con_handle_t sm_event_identity_resolving_failed_get_handle(const uint8_t * event){ 2834 return little_endian_read_16(event, 2); 2835 } 2836 /** 2837 * @brief Get field addr_type from event SM_EVENT_IDENTITY_RESOLVING_FAILED 2838 * @param event packet 2839 * @return addr_type 2840 * @note: btstack_type 1 2841 */ 2842 static inline uint8_t sm_event_identity_resolving_failed_get_addr_type(const uint8_t * event){ 2843 return event[4]; 2844 } 2845 /** 2846 * @brief Get field address from event SM_EVENT_IDENTITY_RESOLVING_FAILED 2847 * @param event packet 2848 * @param Pointer to storage for address 2849 * @note: btstack_type B 2850 */ 2851 static inline void sm_event_identity_resolving_failed_get_address(const uint8_t * event, bd_addr_t address){ 2852 reverse_bytes(&event[5], address, 6); 2853 } 2854 #endif 2855 2856 #ifdef ENABLE_BLE 2857 /** 2858 * @brief Get field handle from event SM_EVENT_IDENTITY_RESOLVING_SUCCEEDED 2859 * @param event packet 2860 * @return handle 2861 * @note: btstack_type H 2862 */ 2863 static inline hci_con_handle_t sm_event_identity_resolving_succeeded_get_handle(const uint8_t * event){ 2864 return little_endian_read_16(event, 2); 2865 } 2866 /** 2867 * @brief Get field addr_type from event SM_EVENT_IDENTITY_RESOLVING_SUCCEEDED 2868 * @param event packet 2869 * @return addr_type 2870 * @note: btstack_type 1 2871 */ 2872 static inline uint8_t sm_event_identity_resolving_succeeded_get_addr_type(const uint8_t * event){ 2873 return event[4]; 2874 } 2875 /** 2876 * @brief Get field address from event SM_EVENT_IDENTITY_RESOLVING_SUCCEEDED 2877 * @param event packet 2878 * @param Pointer to storage for address 2879 * @note: btstack_type B 2880 */ 2881 static inline void sm_event_identity_resolving_succeeded_get_address(const uint8_t * event, bd_addr_t address){ 2882 reverse_bytes(&event[5], address, 6); 2883 } 2884 /** 2885 * @brief Get field identity_addr_type from event SM_EVENT_IDENTITY_RESOLVING_SUCCEEDED 2886 * @param event packet 2887 * @return identity_addr_type 2888 * @note: btstack_type 1 2889 */ 2890 static inline uint8_t sm_event_identity_resolving_succeeded_get_identity_addr_type(const uint8_t * event){ 2891 return event[11]; 2892 } 2893 /** 2894 * @brief Get field identity_address from event SM_EVENT_IDENTITY_RESOLVING_SUCCEEDED 2895 * @param event packet 2896 * @param Pointer to storage for identity_address 2897 * @note: btstack_type B 2898 */ 2899 static inline void sm_event_identity_resolving_succeeded_get_identity_address(const uint8_t * event, bd_addr_t identity_address){ 2900 reverse_bytes(&event[12], identity_address, 6); 2901 } 2902 /** 2903 * @brief Get field index from event SM_EVENT_IDENTITY_RESOLVING_SUCCEEDED 2904 * @param event packet 2905 * @return index 2906 * @note: btstack_type 2 2907 */ 2908 static inline uint16_t sm_event_identity_resolving_succeeded_get_index(const uint8_t * event){ 2909 return little_endian_read_16(event, 18); 2910 } 2911 #endif 2912 2913 #ifdef ENABLE_BLE 2914 /** 2915 * @brief Get field handle from event SM_EVENT_AUTHORIZATION_REQUEST 2916 * @param event packet 2917 * @return handle 2918 * @note: btstack_type H 2919 */ 2920 static inline hci_con_handle_t sm_event_authorization_request_get_handle(const uint8_t * event){ 2921 return little_endian_read_16(event, 2); 2922 } 2923 /** 2924 * @brief Get field addr_type from event SM_EVENT_AUTHORIZATION_REQUEST 2925 * @param event packet 2926 * @return addr_type 2927 * @note: btstack_type 1 2928 */ 2929 static inline uint8_t sm_event_authorization_request_get_addr_type(const uint8_t * event){ 2930 return event[4]; 2931 } 2932 /** 2933 * @brief Get field address from event SM_EVENT_AUTHORIZATION_REQUEST 2934 * @param event packet 2935 * @param Pointer to storage for address 2936 * @note: btstack_type B 2937 */ 2938 static inline void sm_event_authorization_request_get_address(const uint8_t * event, bd_addr_t address){ 2939 reverse_bytes(&event[5], address, 6); 2940 } 2941 #endif 2942 2943 #ifdef ENABLE_BLE 2944 /** 2945 * @brief Get field handle from event SM_EVENT_AUTHORIZATION_RESULT 2946 * @param event packet 2947 * @return handle 2948 * @note: btstack_type H 2949 */ 2950 static inline hci_con_handle_t sm_event_authorization_result_get_handle(const uint8_t * event){ 2951 return little_endian_read_16(event, 2); 2952 } 2953 /** 2954 * @brief Get field addr_type from event SM_EVENT_AUTHORIZATION_RESULT 2955 * @param event packet 2956 * @return addr_type 2957 * @note: btstack_type 1 2958 */ 2959 static inline uint8_t sm_event_authorization_result_get_addr_type(const uint8_t * event){ 2960 return event[4]; 2961 } 2962 /** 2963 * @brief Get field address from event SM_EVENT_AUTHORIZATION_RESULT 2964 * @param event packet 2965 * @param Pointer to storage for address 2966 * @note: btstack_type B 2967 */ 2968 static inline void sm_event_authorization_result_get_address(const uint8_t * event, bd_addr_t address){ 2969 reverse_bytes(&event[5], address, 6); 2970 } 2971 /** 2972 * @brief Get field authorization_result from event SM_EVENT_AUTHORIZATION_RESULT 2973 * @param event packet 2974 * @return authorization_result 2975 * @note: btstack_type 1 2976 */ 2977 static inline uint8_t sm_event_authorization_result_get_authorization_result(const uint8_t * event){ 2978 return event[11]; 2979 } 2980 #endif 2981 2982 #ifdef ENABLE_BLE 2983 /** 2984 * @brief Get field handle from event SM_EVENT_KEYPRESS_NOTIFICATION 2985 * @param event packet 2986 * @return handle 2987 * @note: btstack_type H 2988 */ 2989 static inline hci_con_handle_t sm_event_keypress_notification_get_handle(const uint8_t * event){ 2990 return little_endian_read_16(event, 2); 2991 } 2992 /** 2993 * @brief Get field action from event SM_EVENT_KEYPRESS_NOTIFICATION 2994 * @param event packet 2995 * @return action 2996 * @note: btstack_type 1 2997 */ 2998 static inline uint8_t sm_event_keypress_notification_get_action(const uint8_t * event){ 2999 return event[4]; 3000 } 3001 #endif 3002 3003 #ifdef ENABLE_BLE 3004 /** 3005 * @brief Get field handle from event SM_EVENT_IDENTITY_CREATED 3006 * @param event packet 3007 * @return handle 3008 * @note: btstack_type H 3009 */ 3010 static inline hci_con_handle_t sm_event_identity_created_get_handle(const uint8_t * event){ 3011 return little_endian_read_16(event, 2); 3012 } 3013 /** 3014 * @brief Get field addr_type from event SM_EVENT_IDENTITY_CREATED 3015 * @param event packet 3016 * @return addr_type 3017 * @note: btstack_type 1 3018 */ 3019 static inline uint8_t sm_event_identity_created_get_addr_type(const uint8_t * event){ 3020 return event[4]; 3021 } 3022 /** 3023 * @brief Get field address from event SM_EVENT_IDENTITY_CREATED 3024 * @param event packet 3025 * @param Pointer to storage for address 3026 * @note: btstack_type B 3027 */ 3028 static inline void sm_event_identity_created_get_address(const uint8_t * event, bd_addr_t address){ 3029 reverse_bytes(&event[5], address, 6); 3030 } 3031 /** 3032 * @brief Get field identity_addr_type from event SM_EVENT_IDENTITY_CREATED 3033 * @param event packet 3034 * @return identity_addr_type 3035 * @note: btstack_type 1 3036 */ 3037 static inline uint8_t sm_event_identity_created_get_identity_addr_type(const uint8_t * event){ 3038 return event[11]; 3039 } 3040 /** 3041 * @brief Get field identity_address from event SM_EVENT_IDENTITY_CREATED 3042 * @param event packet 3043 * @param Pointer to storage for identity_address 3044 * @note: btstack_type B 3045 */ 3046 static inline void sm_event_identity_created_get_identity_address(const uint8_t * event, bd_addr_t identity_address){ 3047 reverse_bytes(&event[12], identity_address, 6); 3048 } 3049 /** 3050 * @brief Get field index from event SM_EVENT_IDENTITY_CREATED 3051 * @param event packet 3052 * @return index 3053 * @note: btstack_type 2 3054 */ 3055 static inline uint16_t sm_event_identity_created_get_index(const uint8_t * event){ 3056 return little_endian_read_16(event, 18); 3057 } 3058 #endif 3059 3060 #ifdef ENABLE_BLE 3061 /** 3062 * @brief Get field handle from event SM_EVENT_PAIRING_STARTED 3063 * @param event packet 3064 * @return handle 3065 * @note: btstack_type H 3066 */ 3067 static inline hci_con_handle_t sm_event_pairing_started_get_handle(const uint8_t * event){ 3068 return little_endian_read_16(event, 2); 3069 } 3070 /** 3071 * @brief Get field addr_type from event SM_EVENT_PAIRING_STARTED 3072 * @param event packet 3073 * @return addr_type 3074 * @note: btstack_type 1 3075 */ 3076 static inline uint8_t sm_event_pairing_started_get_addr_type(const uint8_t * event){ 3077 return event[4]; 3078 } 3079 /** 3080 * @brief Get field address from event SM_EVENT_PAIRING_STARTED 3081 * @param event packet 3082 * @param Pointer to storage for address 3083 * @note: btstack_type B 3084 */ 3085 static inline void sm_event_pairing_started_get_address(const uint8_t * event, bd_addr_t address){ 3086 reverse_bytes(&event[5], address, 6); 3087 } 3088 #endif 3089 3090 #ifdef ENABLE_BLE 3091 /** 3092 * @brief Get field handle from event SM_EVENT_PAIRING_COMPLETE 3093 * @param event packet 3094 * @return handle 3095 * @note: btstack_type H 3096 */ 3097 static inline hci_con_handle_t sm_event_pairing_complete_get_handle(const uint8_t * event){ 3098 return little_endian_read_16(event, 2); 3099 } 3100 /** 3101 * @brief Get field addr_type from event SM_EVENT_PAIRING_COMPLETE 3102 * @param event packet 3103 * @return addr_type 3104 * @note: btstack_type 1 3105 */ 3106 static inline uint8_t sm_event_pairing_complete_get_addr_type(const uint8_t * event){ 3107 return event[4]; 3108 } 3109 /** 3110 * @brief Get field address from event SM_EVENT_PAIRING_COMPLETE 3111 * @param event packet 3112 * @param Pointer to storage for address 3113 * @note: btstack_type B 3114 */ 3115 static inline void sm_event_pairing_complete_get_address(const uint8_t * event, bd_addr_t address){ 3116 reverse_bytes(&event[5], address, 6); 3117 } 3118 /** 3119 * @brief Get field status from event SM_EVENT_PAIRING_COMPLETE 3120 * @param event packet 3121 * @return status 3122 * @note: btstack_type 1 3123 */ 3124 static inline uint8_t sm_event_pairing_complete_get_status(const uint8_t * event){ 3125 return event[11]; 3126 } 3127 /** 3128 * @brief Get field reason from event SM_EVENT_PAIRING_COMPLETE 3129 * @param event packet 3130 * @return reason 3131 * @note: btstack_type 1 3132 */ 3133 static inline uint8_t sm_event_pairing_complete_get_reason(const uint8_t * event){ 3134 return event[12]; 3135 } 3136 #endif 3137 3138 #ifdef ENABLE_BLE 3139 /** 3140 * @brief Get field handle from event SM_EVENT_REENCRYPTION_STARTED 3141 * @param event packet 3142 * @return handle 3143 * @note: btstack_type H 3144 */ 3145 static inline hci_con_handle_t sm_event_reencryption_started_get_handle(const uint8_t * event){ 3146 return little_endian_read_16(event, 2); 3147 } 3148 /** 3149 * @brief Get field addr_type from event SM_EVENT_REENCRYPTION_STARTED 3150 * @param event packet 3151 * @return addr_type 3152 * @note: btstack_type 1 3153 */ 3154 static inline uint8_t sm_event_reencryption_started_get_addr_type(const uint8_t * event){ 3155 return event[4]; 3156 } 3157 /** 3158 * @brief Get field address from event SM_EVENT_REENCRYPTION_STARTED 3159 * @param event packet 3160 * @param Pointer to storage for address 3161 * @note: btstack_type B 3162 */ 3163 static inline void sm_event_reencryption_started_get_address(const uint8_t * event, bd_addr_t address){ 3164 reverse_bytes(&event[5], address, 6); 3165 } 3166 #endif 3167 3168 #ifdef ENABLE_BLE 3169 /** 3170 * @brief Get field handle from event SM_EVENT_REENCRYPTION_COMPLETE 3171 * @param event packet 3172 * @return handle 3173 * @note: btstack_type H 3174 */ 3175 static inline hci_con_handle_t sm_event_reencryption_complete_get_handle(const uint8_t * event){ 3176 return little_endian_read_16(event, 2); 3177 } 3178 /** 3179 * @brief Get field addr_type from event SM_EVENT_REENCRYPTION_COMPLETE 3180 * @param event packet 3181 * @return addr_type 3182 * @note: btstack_type 1 3183 */ 3184 static inline uint8_t sm_event_reencryption_complete_get_addr_type(const uint8_t * event){ 3185 return event[4]; 3186 } 3187 /** 3188 * @brief Get field address from event SM_EVENT_REENCRYPTION_COMPLETE 3189 * @param event packet 3190 * @param Pointer to storage for address 3191 * @note: btstack_type B 3192 */ 3193 static inline void sm_event_reencryption_complete_get_address(const uint8_t * event, bd_addr_t address){ 3194 reverse_bytes(&event[5], address, 6); 3195 } 3196 /** 3197 * @brief Get field status from event SM_EVENT_REENCRYPTION_COMPLETE 3198 * @param event packet 3199 * @return status 3200 * @note: btstack_type 1 3201 */ 3202 static inline uint8_t sm_event_reencryption_complete_get_status(const uint8_t * event){ 3203 return event[11]; 3204 } 3205 #endif 3206 3207 /** 3208 * @brief Get field handle from event GAP_EVENT_SECURITY_LEVEL 3209 * @param event packet 3210 * @return handle 3211 * @note: btstack_type H 3212 */ 3213 static inline hci_con_handle_t gap_event_security_level_get_handle(const uint8_t * event){ 3214 return little_endian_read_16(event, 2); 3215 } 3216 /** 3217 * @brief Get field security_level from event GAP_EVENT_SECURITY_LEVEL 3218 * @param event packet 3219 * @return security_level 3220 * @note: btstack_type 1 3221 */ 3222 static inline uint8_t gap_event_security_level_get_security_level(const uint8_t * event){ 3223 return event[4]; 3224 } 3225 3226 /** 3227 * @brief Get field status from event GAP_EVENT_DEDICATED_BONDING_COMPLETED 3228 * @param event packet 3229 * @return status 3230 * @note: btstack_type 1 3231 */ 3232 static inline uint8_t gap_event_dedicated_bonding_completed_get_status(const uint8_t * event){ 3233 return event[2]; 3234 } 3235 /** 3236 * @brief Get field address from event GAP_EVENT_DEDICATED_BONDING_COMPLETED 3237 * @param event packet 3238 * @param Pointer to storage for address 3239 * @note: btstack_type B 3240 */ 3241 static inline void gap_event_dedicated_bonding_completed_get_address(const uint8_t * event, bd_addr_t address){ 3242 reverse_bytes(&event[3], address, 6); 3243 } 3244 3245 /** 3246 * @brief Get field advertising_event_type from event GAP_EVENT_ADVERTISING_REPORT 3247 * @param event packet 3248 * @return advertising_event_type 3249 * @note: btstack_type 1 3250 */ 3251 static inline uint8_t gap_event_advertising_report_get_advertising_event_type(const uint8_t * event){ 3252 return event[2]; 3253 } 3254 /** 3255 * @brief Get field address_type from event GAP_EVENT_ADVERTISING_REPORT 3256 * @param event packet 3257 * @return address_type 3258 * @note: btstack_type 1 3259 */ 3260 static inline uint8_t gap_event_advertising_report_get_address_type(const uint8_t * event){ 3261 return event[3]; 3262 } 3263 /** 3264 * @brief Get field address from event GAP_EVENT_ADVERTISING_REPORT 3265 * @param event packet 3266 * @param Pointer to storage for address 3267 * @note: btstack_type B 3268 */ 3269 static inline void gap_event_advertising_report_get_address(const uint8_t * event, bd_addr_t address){ 3270 reverse_bytes(&event[4], address, 6); 3271 } 3272 /** 3273 * @brief Get field rssi from event GAP_EVENT_ADVERTISING_REPORT 3274 * @param event packet 3275 * @return rssi 3276 * @note: btstack_type 1 3277 */ 3278 static inline uint8_t gap_event_advertising_report_get_rssi(const uint8_t * event){ 3279 return event[10]; 3280 } 3281 /** 3282 * @brief Get field data_length from event GAP_EVENT_ADVERTISING_REPORT 3283 * @param event packet 3284 * @return data_length 3285 * @note: btstack_type J 3286 */ 3287 static inline uint8_t gap_event_advertising_report_get_data_length(const uint8_t * event){ 3288 return event[11]; 3289 } 3290 /** 3291 * @brief Get field data from event GAP_EVENT_ADVERTISING_REPORT 3292 * @param event packet 3293 * @return data 3294 * @note: btstack_type V 3295 */ 3296 static inline const uint8_t * gap_event_advertising_report_get_data(const uint8_t * event){ 3297 return &event[12]; 3298 } 3299 3300 /** 3301 * @brief Get field bd_addr from event GAP_EVENT_INQUIRY_RESULT 3302 * @param event packet 3303 * @param Pointer to storage for bd_addr 3304 * @note: btstack_type B 3305 */ 3306 static inline void gap_event_inquiry_result_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 3307 reverse_bytes(&event[2], bd_addr, 6); 3308 } 3309 /** 3310 * @brief Get field page_scan_repetition_mode from event GAP_EVENT_INQUIRY_RESULT 3311 * @param event packet 3312 * @return page_scan_repetition_mode 3313 * @note: btstack_type 1 3314 */ 3315 static inline uint8_t gap_event_inquiry_result_get_page_scan_repetition_mode(const uint8_t * event){ 3316 return event[8]; 3317 } 3318 /** 3319 * @brief Get field class_of_device from event GAP_EVENT_INQUIRY_RESULT 3320 * @param event packet 3321 * @return class_of_device 3322 * @note: btstack_type 3 3323 */ 3324 static inline uint32_t gap_event_inquiry_result_get_class_of_device(const uint8_t * event){ 3325 return little_endian_read_24(event, 9); 3326 } 3327 /** 3328 * @brief Get field clock_offset from event GAP_EVENT_INQUIRY_RESULT 3329 * @param event packet 3330 * @return clock_offset 3331 * @note: btstack_type 2 3332 */ 3333 static inline uint16_t gap_event_inquiry_result_get_clock_offset(const uint8_t * event){ 3334 return little_endian_read_16(event, 12); 3335 } 3336 /** 3337 * @brief Get field rssi_available from event GAP_EVENT_INQUIRY_RESULT 3338 * @param event packet 3339 * @return rssi_available 3340 * @note: btstack_type 1 3341 */ 3342 static inline uint8_t gap_event_inquiry_result_get_rssi_available(const uint8_t * event){ 3343 return event[14]; 3344 } 3345 /** 3346 * @brief Get field rssi from event GAP_EVENT_INQUIRY_RESULT 3347 * @param event packet 3348 * @return rssi 3349 * @note: btstack_type 1 3350 */ 3351 static inline uint8_t gap_event_inquiry_result_get_rssi(const uint8_t * event){ 3352 return event[15]; 3353 } 3354 /** 3355 * @brief Get field device_id_available from event GAP_EVENT_INQUIRY_RESULT 3356 * @param event packet 3357 * @return device_id_available 3358 * @note: btstack_type 1 3359 */ 3360 static inline uint8_t gap_event_inquiry_result_get_device_id_available(const uint8_t * event){ 3361 return event[16]; 3362 } 3363 /** 3364 * @brief Get field device_id_vendor_id_source from event GAP_EVENT_INQUIRY_RESULT 3365 * @param event packet 3366 * @return device_id_vendor_id_source 3367 * @note: btstack_type 2 3368 */ 3369 static inline uint16_t gap_event_inquiry_result_get_device_id_vendor_id_source(const uint8_t * event){ 3370 return little_endian_read_16(event, 17); 3371 } 3372 /** 3373 * @brief Get field device_id_vendor_id from event GAP_EVENT_INQUIRY_RESULT 3374 * @param event packet 3375 * @return device_id_vendor_id 3376 * @note: btstack_type 2 3377 */ 3378 static inline uint16_t gap_event_inquiry_result_get_device_id_vendor_id(const uint8_t * event){ 3379 return little_endian_read_16(event, 19); 3380 } 3381 /** 3382 * @brief Get field device_id_product_id from event GAP_EVENT_INQUIRY_RESULT 3383 * @param event packet 3384 * @return device_id_product_id 3385 * @note: btstack_type 2 3386 */ 3387 static inline uint16_t gap_event_inquiry_result_get_device_id_product_id(const uint8_t * event){ 3388 return little_endian_read_16(event, 21); 3389 } 3390 /** 3391 * @brief Get field device_id_version from event GAP_EVENT_INQUIRY_RESULT 3392 * @param event packet 3393 * @return device_id_version 3394 * @note: btstack_type 2 3395 */ 3396 static inline uint16_t gap_event_inquiry_result_get_device_id_version(const uint8_t * event){ 3397 return little_endian_read_16(event, 23); 3398 } 3399 /** 3400 * @brief Get field name_available from event GAP_EVENT_INQUIRY_RESULT 3401 * @param event packet 3402 * @return name_available 3403 * @note: btstack_type 1 3404 */ 3405 static inline uint8_t gap_event_inquiry_result_get_name_available(const uint8_t * event){ 3406 return event[25]; 3407 } 3408 /** 3409 * @brief Get field name_len from event GAP_EVENT_INQUIRY_RESULT 3410 * @param event packet 3411 * @return name_len 3412 * @note: btstack_type J 3413 */ 3414 static inline uint8_t gap_event_inquiry_result_get_name_len(const uint8_t * event){ 3415 return event[26]; 3416 } 3417 /** 3418 * @brief Get field name from event GAP_EVENT_INQUIRY_RESULT 3419 * @param event packet 3420 * @return name 3421 * @note: btstack_type V 3422 */ 3423 static inline const uint8_t * gap_event_inquiry_result_get_name(const uint8_t * event){ 3424 return &event[27]; 3425 } 3426 3427 /** 3428 * @brief Get field status from event GAP_EVENT_INQUIRY_COMPLETE 3429 * @param event packet 3430 * @return status 3431 * @note: btstack_type 1 3432 */ 3433 static inline uint8_t gap_event_inquiry_complete_get_status(const uint8_t * event){ 3434 return event[2]; 3435 } 3436 3437 /** 3438 * @brief Get field con_handle from event GAP_EVENT_RSSI_MEASUREMENT 3439 * @param event packet 3440 * @return con_handle 3441 * @note: btstack_type H 3442 */ 3443 static inline hci_con_handle_t gap_event_rssi_measurement_get_con_handle(const uint8_t * event){ 3444 return little_endian_read_16(event, 2); 3445 } 3446 /** 3447 * @brief Get field rssi from event GAP_EVENT_RSSI_MEASUREMENT 3448 * @param event packet 3449 * @return rssi 3450 * @note: btstack_type 1 3451 */ 3452 static inline uint8_t gap_event_rssi_measurement_get_rssi(const uint8_t * event){ 3453 return event[4]; 3454 } 3455 3456 /** 3457 * @brief Get field oob_data_present from event GAP_EVENT_LOCAL_OOB_DATA 3458 * @param event packet 3459 * @return oob_data_present 3460 * @note: btstack_type 1 3461 */ 3462 static inline uint8_t gap_event_local_oob_data_get_oob_data_present(const uint8_t * event){ 3463 return event[2]; 3464 } 3465 /** 3466 * @brief Get field c_192 from event GAP_EVENT_LOCAL_OOB_DATA 3467 * @param event packet 3468 * @param Pointer to storage for c_192 3469 * @note: btstack_type K 3470 */ 3471 static inline void gap_event_local_oob_data_get_c_192(const uint8_t * event, uint8_t * c_192){ 3472 reverse_bytes(&event[3], c_192, 16); 3473 } 3474 /** 3475 * @brief Get field r_192 from event GAP_EVENT_LOCAL_OOB_DATA 3476 * @param event packet 3477 * @param Pointer to storage for r_192 3478 * @note: btstack_type K 3479 */ 3480 static inline void gap_event_local_oob_data_get_r_192(const uint8_t * event, uint8_t * r_192){ 3481 reverse_bytes(&event[19], r_192, 16); 3482 } 3483 /** 3484 * @brief Get field c_256 from event GAP_EVENT_LOCAL_OOB_DATA 3485 * @param event packet 3486 * @param Pointer to storage for c_256 3487 * @note: btstack_type K 3488 */ 3489 static inline void gap_event_local_oob_data_get_c_256(const uint8_t * event, uint8_t * c_256){ 3490 reverse_bytes(&event[35], c_256, 16); 3491 } 3492 /** 3493 * @brief Get field r_256 from event GAP_EVENT_LOCAL_OOB_DATA 3494 * @param event packet 3495 * @param Pointer to storage for r_256 3496 * @note: btstack_type K 3497 */ 3498 static inline void gap_event_local_oob_data_get_r_256(const uint8_t * event, uint8_t * r_256){ 3499 reverse_bytes(&event[51], r_256, 16); 3500 } 3501 3502 /** 3503 * @brief Get field con_handle from event GAP_EVENT_PAIRING_STARTED 3504 * @param event packet 3505 * @return con_handle 3506 * @note: btstack_type H 3507 */ 3508 static inline hci_con_handle_t gap_event_pairing_started_get_con_handle(const uint8_t * event){ 3509 return little_endian_read_16(event, 2); 3510 } 3511 /** 3512 * @brief Get field bd_addr from event GAP_EVENT_PAIRING_STARTED 3513 * @param event packet 3514 * @param Pointer to storage for bd_addr 3515 * @note: btstack_type B 3516 */ 3517 static inline void gap_event_pairing_started_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 3518 reverse_bytes(&event[4], bd_addr, 6); 3519 } 3520 /** 3521 * @brief Get field ssp from event GAP_EVENT_PAIRING_STARTED 3522 * @param event packet 3523 * @return ssp 3524 * @note: btstack_type 1 3525 */ 3526 static inline uint8_t gap_event_pairing_started_get_ssp(const uint8_t * event){ 3527 return event[10]; 3528 } 3529 /** 3530 * @brief Get field initiator from event GAP_EVENT_PAIRING_STARTED 3531 * @param event packet 3532 * @return initiator 3533 * @note: btstack_type 1 3534 */ 3535 static inline uint8_t gap_event_pairing_started_get_initiator(const uint8_t * event){ 3536 return event[11]; 3537 } 3538 3539 /** 3540 * @brief Get field con_handle from event GAP_EVENT_PAIRING_COMPLETE 3541 * @param event packet 3542 * @return con_handle 3543 * @note: btstack_type H 3544 */ 3545 static inline hci_con_handle_t gap_event_pairing_complete_get_con_handle(const uint8_t * event){ 3546 return little_endian_read_16(event, 2); 3547 } 3548 /** 3549 * @brief Get field bd_addr from event GAP_EVENT_PAIRING_COMPLETE 3550 * @param event packet 3551 * @param Pointer to storage for bd_addr 3552 * @note: btstack_type B 3553 */ 3554 static inline void gap_event_pairing_complete_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 3555 reverse_bytes(&event[4], bd_addr, 6); 3556 } 3557 /** 3558 * @brief Get field status from event GAP_EVENT_PAIRING_COMPLETE 3559 * @param event packet 3560 * @return status 3561 * @note: btstack_type 1 3562 */ 3563 static inline uint8_t gap_event_pairing_complete_get_status(const uint8_t * event){ 3564 return event[10]; 3565 } 3566 3567 /** 3568 * @brief Get field status from event HCI_SUBEVENT_LE_CONNECTION_COMPLETE 3569 * @param event packet 3570 * @return status 3571 * @note: btstack_type 1 3572 */ 3573 static inline uint8_t hci_subevent_le_connection_complete_get_status(const uint8_t * event){ 3574 return event[3]; 3575 } 3576 /** 3577 * @brief Get field connection_handle from event HCI_SUBEVENT_LE_CONNECTION_COMPLETE 3578 * @param event packet 3579 * @return connection_handle 3580 * @note: btstack_type H 3581 */ 3582 static inline hci_con_handle_t hci_subevent_le_connection_complete_get_connection_handle(const uint8_t * event){ 3583 return little_endian_read_16(event, 4); 3584 } 3585 /** 3586 * @brief Get field role from event HCI_SUBEVENT_LE_CONNECTION_COMPLETE 3587 * @param event packet 3588 * @return role 3589 * @note: btstack_type 1 3590 */ 3591 static inline uint8_t hci_subevent_le_connection_complete_get_role(const uint8_t * event){ 3592 return event[6]; 3593 } 3594 /** 3595 * @brief Get field peer_address_type from event HCI_SUBEVENT_LE_CONNECTION_COMPLETE 3596 * @param event packet 3597 * @return peer_address_type 3598 * @note: btstack_type 1 3599 */ 3600 static inline uint8_t hci_subevent_le_connection_complete_get_peer_address_type(const uint8_t * event){ 3601 return event[7]; 3602 } 3603 /** 3604 * @brief Get field peer_address from event HCI_SUBEVENT_LE_CONNECTION_COMPLETE 3605 * @param event packet 3606 * @param Pointer to storage for peer_address 3607 * @note: btstack_type B 3608 */ 3609 static inline void hci_subevent_le_connection_complete_get_peer_address(const uint8_t * event, bd_addr_t peer_address){ 3610 reverse_bytes(&event[8], peer_address, 6); 3611 } 3612 /** 3613 * @brief Get field conn_interval from event HCI_SUBEVENT_LE_CONNECTION_COMPLETE 3614 * @param event packet 3615 * @return conn_interval 3616 * @note: btstack_type 2 3617 */ 3618 static inline uint16_t hci_subevent_le_connection_complete_get_conn_interval(const uint8_t * event){ 3619 return little_endian_read_16(event, 14); 3620 } 3621 /** 3622 * @brief Get field conn_latency from event HCI_SUBEVENT_LE_CONNECTION_COMPLETE 3623 * @param event packet 3624 * @return conn_latency 3625 * @note: btstack_type 2 3626 */ 3627 static inline uint16_t hci_subevent_le_connection_complete_get_conn_latency(const uint8_t * event){ 3628 return little_endian_read_16(event, 16); 3629 } 3630 /** 3631 * @brief Get field supervision_timeout from event HCI_SUBEVENT_LE_CONNECTION_COMPLETE 3632 * @param event packet 3633 * @return supervision_timeout 3634 * @note: btstack_type 2 3635 */ 3636 static inline uint16_t hci_subevent_le_connection_complete_get_supervision_timeout(const uint8_t * event){ 3637 return little_endian_read_16(event, 18); 3638 } 3639 /** 3640 * @brief Get field master_clock_accuracy from event HCI_SUBEVENT_LE_CONNECTION_COMPLETE 3641 * @param event packet 3642 * @return master_clock_accuracy 3643 * @note: btstack_type 1 3644 */ 3645 static inline uint8_t hci_subevent_le_connection_complete_get_master_clock_accuracy(const uint8_t * event){ 3646 return event[20]; 3647 } 3648 3649 /** 3650 * @brief Get field status from event HCI_SUBEVENT_LE_CONNECTION_UPDATE_COMPLETE 3651 * @param event packet 3652 * @return status 3653 * @note: btstack_type 1 3654 */ 3655 static inline uint8_t hci_subevent_le_connection_update_complete_get_status(const uint8_t * event){ 3656 return event[3]; 3657 } 3658 /** 3659 * @brief Get field connection_handle from event HCI_SUBEVENT_LE_CONNECTION_UPDATE_COMPLETE 3660 * @param event packet 3661 * @return connection_handle 3662 * @note: btstack_type H 3663 */ 3664 static inline hci_con_handle_t hci_subevent_le_connection_update_complete_get_connection_handle(const uint8_t * event){ 3665 return little_endian_read_16(event, 4); 3666 } 3667 /** 3668 * @brief Get field conn_interval from event HCI_SUBEVENT_LE_CONNECTION_UPDATE_COMPLETE 3669 * @param event packet 3670 * @return conn_interval 3671 * @note: btstack_type 2 3672 */ 3673 static inline uint16_t hci_subevent_le_connection_update_complete_get_conn_interval(const uint8_t * event){ 3674 return little_endian_read_16(event, 6); 3675 } 3676 /** 3677 * @brief Get field conn_latency from event HCI_SUBEVENT_LE_CONNECTION_UPDATE_COMPLETE 3678 * @param event packet 3679 * @return conn_latency 3680 * @note: btstack_type 2 3681 */ 3682 static inline uint16_t hci_subevent_le_connection_update_complete_get_conn_latency(const uint8_t * event){ 3683 return little_endian_read_16(event, 8); 3684 } 3685 /** 3686 * @brief Get field supervision_timeout from event HCI_SUBEVENT_LE_CONNECTION_UPDATE_COMPLETE 3687 * @param event packet 3688 * @return supervision_timeout 3689 * @note: btstack_type 2 3690 */ 3691 static inline uint16_t hci_subevent_le_connection_update_complete_get_supervision_timeout(const uint8_t * event){ 3692 return little_endian_read_16(event, 10); 3693 } 3694 3695 /** 3696 * @brief Get field connection_handle from event HCI_SUBEVENT_LE_READ_REMOTE_FEATURES_COMPLETE 3697 * @param event packet 3698 * @return connection_handle 3699 * @note: btstack_type H 3700 */ 3701 static inline hci_con_handle_t hci_subevent_le_read_remote_features_complete_get_connection_handle(const uint8_t * event){ 3702 return little_endian_read_16(event, 3); 3703 } 3704 /** 3705 * @brief Get field le_features from event HCI_SUBEVENT_LE_READ_REMOTE_FEATURES_COMPLETE 3706 * @param event packet 3707 * @return le_features 3708 * @note: btstack_type D 3709 */ 3710 static inline const uint8_t * hci_subevent_le_read_remote_features_complete_get_le_features(const uint8_t * event){ 3711 return (const uint8_t *) &event[5]; 3712 } 3713 3714 /** 3715 * @brief Get field connection_handle from event HCI_SUBEVENT_LE_LONG_TERM_KEY_REQUEST 3716 * @param event packet 3717 * @return connection_handle 3718 * @note: btstack_type H 3719 */ 3720 static inline hci_con_handle_t hci_subevent_le_long_term_key_request_get_connection_handle(const uint8_t * event){ 3721 return little_endian_read_16(event, 3); 3722 } 3723 /** 3724 * @brief Get field random_number from event HCI_SUBEVENT_LE_LONG_TERM_KEY_REQUEST 3725 * @param event packet 3726 * @return random_number 3727 * @note: btstack_type D 3728 */ 3729 static inline const uint8_t * hci_subevent_le_long_term_key_request_get_random_number(const uint8_t * event){ 3730 return (const uint8_t *) &event[5]; 3731 } 3732 /** 3733 * @brief Get field encryption_diversifier from event HCI_SUBEVENT_LE_LONG_TERM_KEY_REQUEST 3734 * @param event packet 3735 * @return encryption_diversifier 3736 * @note: btstack_type 2 3737 */ 3738 static inline uint16_t hci_subevent_le_long_term_key_request_get_encryption_diversifier(const uint8_t * event){ 3739 return little_endian_read_16(event, 13); 3740 } 3741 3742 /** 3743 * @brief Get field connection_handle from event HCI_SUBEVENT_LE_REMOTE_CONNECTION_PARAMETER_REQUEST 3744 * @param event packet 3745 * @return connection_handle 3746 * @note: btstack_type H 3747 */ 3748 static inline hci_con_handle_t hci_subevent_le_remote_connection_parameter_request_get_connection_handle(const uint8_t * event){ 3749 return little_endian_read_16(event, 3); 3750 } 3751 /** 3752 * @brief Get field interval_min from event HCI_SUBEVENT_LE_REMOTE_CONNECTION_PARAMETER_REQUEST 3753 * @param event packet 3754 * @return interval_min 3755 * @note: btstack_type 2 3756 */ 3757 static inline uint16_t hci_subevent_le_remote_connection_parameter_request_get_interval_min(const uint8_t * event){ 3758 return little_endian_read_16(event, 5); 3759 } 3760 /** 3761 * @brief Get field interval_max from event HCI_SUBEVENT_LE_REMOTE_CONNECTION_PARAMETER_REQUEST 3762 * @param event packet 3763 * @return interval_max 3764 * @note: btstack_type 2 3765 */ 3766 static inline uint16_t hci_subevent_le_remote_connection_parameter_request_get_interval_max(const uint8_t * event){ 3767 return little_endian_read_16(event, 7); 3768 } 3769 /** 3770 * @brief Get field latency from event HCI_SUBEVENT_LE_REMOTE_CONNECTION_PARAMETER_REQUEST 3771 * @param event packet 3772 * @return latency 3773 * @note: btstack_type 2 3774 */ 3775 static inline uint16_t hci_subevent_le_remote_connection_parameter_request_get_latency(const uint8_t * event){ 3776 return little_endian_read_16(event, 9); 3777 } 3778 /** 3779 * @brief Get field timeout from event HCI_SUBEVENT_LE_REMOTE_CONNECTION_PARAMETER_REQUEST 3780 * @param event packet 3781 * @return timeout 3782 * @note: btstack_type 2 3783 */ 3784 static inline uint16_t hci_subevent_le_remote_connection_parameter_request_get_timeout(const uint8_t * event){ 3785 return little_endian_read_16(event, 11); 3786 } 3787 3788 /** 3789 * @brief Get field connection_handle from event HCI_SUBEVENT_LE_DATA_LENGTH_CHANGE 3790 * @param event packet 3791 * @return connection_handle 3792 * @note: btstack_type H 3793 */ 3794 static inline hci_con_handle_t hci_subevent_le_data_length_change_get_connection_handle(const uint8_t * event){ 3795 return little_endian_read_16(event, 3); 3796 } 3797 /** 3798 * @brief Get field max_tx_octets from event HCI_SUBEVENT_LE_DATA_LENGTH_CHANGE 3799 * @param event packet 3800 * @return max_tx_octets 3801 * @note: btstack_type 2 3802 */ 3803 static inline uint16_t hci_subevent_le_data_length_change_get_max_tx_octets(const uint8_t * event){ 3804 return little_endian_read_16(event, 5); 3805 } 3806 /** 3807 * @brief Get field max_tx_time from event HCI_SUBEVENT_LE_DATA_LENGTH_CHANGE 3808 * @param event packet 3809 * @return max_tx_time 3810 * @note: btstack_type 2 3811 */ 3812 static inline uint16_t hci_subevent_le_data_length_change_get_max_tx_time(const uint8_t * event){ 3813 return little_endian_read_16(event, 7); 3814 } 3815 /** 3816 * @brief Get field max_rx_octets from event HCI_SUBEVENT_LE_DATA_LENGTH_CHANGE 3817 * @param event packet 3818 * @return max_rx_octets 3819 * @note: btstack_type 2 3820 */ 3821 static inline uint16_t hci_subevent_le_data_length_change_get_max_rx_octets(const uint8_t * event){ 3822 return little_endian_read_16(event, 9); 3823 } 3824 /** 3825 * @brief Get field max_rx_time from event HCI_SUBEVENT_LE_DATA_LENGTH_CHANGE 3826 * @param event packet 3827 * @return max_rx_time 3828 * @note: btstack_type 2 3829 */ 3830 static inline uint16_t hci_subevent_le_data_length_change_get_max_rx_time(const uint8_t * event){ 3831 return little_endian_read_16(event, 11); 3832 } 3833 3834 /** 3835 * @brief Get field status from event HCI_SUBEVENT_LE_READ_LOCAL_P256_PUBLIC_KEY_COMPLETE 3836 * @param event packet 3837 * @return status 3838 * @note: btstack_type 1 3839 */ 3840 static inline uint8_t hci_subevent_le_read_local_p256_public_key_complete_get_status(const uint8_t * event){ 3841 return event[3]; 3842 } 3843 /** 3844 * @brief Get field dhkey_x from event HCI_SUBEVENT_LE_READ_LOCAL_P256_PUBLIC_KEY_COMPLETE 3845 * @param event packet 3846 * @param Pointer to storage for dhkey_x 3847 * @note: btstack_type Q 3848 */ 3849 static inline void hci_subevent_le_read_local_p256_public_key_complete_get_dhkey_x(const uint8_t * event, uint8_t * dhkey_x){ 3850 reverse_bytes(&event[4], dhkey_x, 32); 3851 } 3852 /** 3853 * @brief Get field dhkey_y from event HCI_SUBEVENT_LE_READ_LOCAL_P256_PUBLIC_KEY_COMPLETE 3854 * @param event packet 3855 * @param Pointer to storage for dhkey_y 3856 * @note: btstack_type Q 3857 */ 3858 static inline void hci_subevent_le_read_local_p256_public_key_complete_get_dhkey_y(const uint8_t * event, uint8_t * dhkey_y){ 3859 reverse_bytes(&event[36], dhkey_y, 32); 3860 } 3861 3862 /** 3863 * @brief Get field status from event HCI_SUBEVENT_LE_GENERATE_DHKEY_COMPLETE 3864 * @param event packet 3865 * @return status 3866 * @note: btstack_type 1 3867 */ 3868 static inline uint8_t hci_subevent_le_generate_dhkey_complete_get_status(const uint8_t * event){ 3869 return event[3]; 3870 } 3871 /** 3872 * @brief Get field dhkey from event HCI_SUBEVENT_LE_GENERATE_DHKEY_COMPLETE 3873 * @param event packet 3874 * @param Pointer to storage for dhkey 3875 * @note: btstack_type Q 3876 */ 3877 static inline void hci_subevent_le_generate_dhkey_complete_get_dhkey(const uint8_t * event, uint8_t * dhkey){ 3878 reverse_bytes(&event[4], dhkey, 32); 3879 } 3880 3881 /** 3882 * @brief Get field status from event HCI_SUBEVENT_LE_ENHANCED_CONNECTION_COMPLETE 3883 * @param event packet 3884 * @return status 3885 * @note: btstack_type 1 3886 */ 3887 static inline uint8_t hci_subevent_le_enhanced_connection_complete_get_status(const uint8_t * event){ 3888 return event[3]; 3889 } 3890 /** 3891 * @brief Get field connection_handle from event HCI_SUBEVENT_LE_ENHANCED_CONNECTION_COMPLETE 3892 * @param event packet 3893 * @return connection_handle 3894 * @note: btstack_type H 3895 */ 3896 static inline hci_con_handle_t hci_subevent_le_enhanced_connection_complete_get_connection_handle(const uint8_t * event){ 3897 return little_endian_read_16(event, 4); 3898 } 3899 /** 3900 * @brief Get field role from event HCI_SUBEVENT_LE_ENHANCED_CONNECTION_COMPLETE 3901 * @param event packet 3902 * @return role 3903 * @note: btstack_type 1 3904 */ 3905 static inline uint8_t hci_subevent_le_enhanced_connection_complete_get_role(const uint8_t * event){ 3906 return event[6]; 3907 } 3908 /** 3909 * @brief Get field peer_address_type from event HCI_SUBEVENT_LE_ENHANCED_CONNECTION_COMPLETE 3910 * @param event packet 3911 * @return peer_address_type 3912 * @note: btstack_type 1 3913 */ 3914 static inline uint8_t hci_subevent_le_enhanced_connection_complete_get_peer_address_type(const uint8_t * event){ 3915 return event[7]; 3916 } 3917 /** 3918 * @brief Get field perr_addresss from event HCI_SUBEVENT_LE_ENHANCED_CONNECTION_COMPLETE 3919 * @param event packet 3920 * @param Pointer to storage for perr_addresss 3921 * @note: btstack_type B 3922 */ 3923 static inline void hci_subevent_le_enhanced_connection_complete_get_perr_addresss(const uint8_t * event, bd_addr_t perr_addresss){ 3924 reverse_bytes(&event[8], perr_addresss, 6); 3925 } 3926 /** 3927 * @brief Get field local_resolvable_private_addres from event HCI_SUBEVENT_LE_ENHANCED_CONNECTION_COMPLETE 3928 * @param event packet 3929 * @param Pointer to storage for local_resolvable_private_addres 3930 * @note: btstack_type B 3931 */ 3932 static inline void hci_subevent_le_enhanced_connection_complete_get_local_resolvable_private_addres(const uint8_t * event, bd_addr_t local_resolvable_private_addres){ 3933 reverse_bytes(&event[14], local_resolvable_private_addres, 6); 3934 } 3935 /** 3936 * @brief Get field peer_resolvable_private_addres from event HCI_SUBEVENT_LE_ENHANCED_CONNECTION_COMPLETE 3937 * @param event packet 3938 * @param Pointer to storage for peer_resolvable_private_addres 3939 * @note: btstack_type B 3940 */ 3941 static inline void hci_subevent_le_enhanced_connection_complete_get_peer_resolvable_private_addres(const uint8_t * event, bd_addr_t peer_resolvable_private_addres){ 3942 reverse_bytes(&event[20], peer_resolvable_private_addres, 6); 3943 } 3944 /** 3945 * @brief Get field conn_interval from event HCI_SUBEVENT_LE_ENHANCED_CONNECTION_COMPLETE 3946 * @param event packet 3947 * @return conn_interval 3948 * @note: btstack_type 2 3949 */ 3950 static inline uint16_t hci_subevent_le_enhanced_connection_complete_get_conn_interval(const uint8_t * event){ 3951 return little_endian_read_16(event, 26); 3952 } 3953 /** 3954 * @brief Get field conn_latency from event HCI_SUBEVENT_LE_ENHANCED_CONNECTION_COMPLETE 3955 * @param event packet 3956 * @return conn_latency 3957 * @note: btstack_type 2 3958 */ 3959 static inline uint16_t hci_subevent_le_enhanced_connection_complete_get_conn_latency(const uint8_t * event){ 3960 return little_endian_read_16(event, 28); 3961 } 3962 /** 3963 * @brief Get field supervision_timeout from event HCI_SUBEVENT_LE_ENHANCED_CONNECTION_COMPLETE 3964 * @param event packet 3965 * @return supervision_timeout 3966 * @note: btstack_type 2 3967 */ 3968 static inline uint16_t hci_subevent_le_enhanced_connection_complete_get_supervision_timeout(const uint8_t * event){ 3969 return little_endian_read_16(event, 30); 3970 } 3971 /** 3972 * @brief Get field master_clock_accuracy from event HCI_SUBEVENT_LE_ENHANCED_CONNECTION_COMPLETE 3973 * @param event packet 3974 * @return master_clock_accuracy 3975 * @note: btstack_type 1 3976 */ 3977 static inline uint8_t hci_subevent_le_enhanced_connection_complete_get_master_clock_accuracy(const uint8_t * event){ 3978 return event[32]; 3979 } 3980 3981 /** 3982 * @brief Get field status from event HSP_SUBEVENT_RFCOMM_CONNECTION_COMPLETE 3983 * @param event packet 3984 * @return status 3985 * @note: btstack_type 1 3986 */ 3987 static inline uint8_t hsp_subevent_rfcomm_connection_complete_get_status(const uint8_t * event){ 3988 return event[3]; 3989 } 3990 3991 /** 3992 * @brief Get field status from event HSP_SUBEVENT_RFCOMM_DISCONNECTION_COMPLETE 3993 * @param event packet 3994 * @return status 3995 * @note: btstack_type 1 3996 */ 3997 static inline uint8_t hsp_subevent_rfcomm_disconnection_complete_get_status(const uint8_t * event){ 3998 return event[3]; 3999 } 4000 4001 /** 4002 * @brief Get field status from event HSP_SUBEVENT_AUDIO_CONNECTION_COMPLETE 4003 * @param event packet 4004 * @return status 4005 * @note: btstack_type 1 4006 */ 4007 static inline uint8_t hsp_subevent_audio_connection_complete_get_status(const uint8_t * event){ 4008 return event[3]; 4009 } 4010 /** 4011 * @brief Get field handle from event HSP_SUBEVENT_AUDIO_CONNECTION_COMPLETE 4012 * @param event packet 4013 * @return handle 4014 * @note: btstack_type H 4015 */ 4016 static inline hci_con_handle_t hsp_subevent_audio_connection_complete_get_handle(const uint8_t * event){ 4017 return little_endian_read_16(event, 4); 4018 } 4019 4020 /** 4021 * @brief Get field status from event HSP_SUBEVENT_AUDIO_DISCONNECTION_COMPLETE 4022 * @param event packet 4023 * @return status 4024 * @note: btstack_type 1 4025 */ 4026 static inline uint8_t hsp_subevent_audio_disconnection_complete_get_status(const uint8_t * event){ 4027 return event[3]; 4028 } 4029 4030 4031 /** 4032 * @brief Get field gain from event HSP_SUBEVENT_MICROPHONE_GAIN_CHANGED 4033 * @param event packet 4034 * @return gain 4035 * @note: btstack_type 1 4036 */ 4037 static inline uint8_t hsp_subevent_microphone_gain_changed_get_gain(const uint8_t * event){ 4038 return event[3]; 4039 } 4040 4041 /** 4042 * @brief Get field gain from event HSP_SUBEVENT_SPEAKER_GAIN_CHANGED 4043 * @param event packet 4044 * @return gain 4045 * @note: btstack_type 1 4046 */ 4047 static inline uint8_t hsp_subevent_speaker_gain_changed_get_gain(const uint8_t * event){ 4048 return event[3]; 4049 } 4050 4051 /** 4052 * @brief Get field value_length from event HSP_SUBEVENT_HS_COMMAND 4053 * @param event packet 4054 * @return value_length 4055 * @note: btstack_type J 4056 */ 4057 static inline uint8_t hsp_subevent_hs_command_get_value_length(const uint8_t * event){ 4058 return event[3]; 4059 } 4060 /** 4061 * @brief Get field value from event HSP_SUBEVENT_HS_COMMAND 4062 * @param event packet 4063 * @return value 4064 * @note: btstack_type V 4065 */ 4066 static inline const uint8_t * hsp_subevent_hs_command_get_value(const uint8_t * event){ 4067 return &event[4]; 4068 } 4069 4070 /** 4071 * @brief Get field value_length from event HSP_SUBEVENT_AG_INDICATION 4072 * @param event packet 4073 * @return value_length 4074 * @note: btstack_type J 4075 */ 4076 static inline uint8_t hsp_subevent_ag_indication_get_value_length(const uint8_t * event){ 4077 return event[3]; 4078 } 4079 /** 4080 * @brief Get field value from event HSP_SUBEVENT_AG_INDICATION 4081 * @param event packet 4082 * @return value 4083 * @note: btstack_type V 4084 */ 4085 static inline const uint8_t * hsp_subevent_ag_indication_get_value(const uint8_t * event){ 4086 return &event[4]; 4087 } 4088 4089 4090 /** 4091 * @brief Get field acl_handle from event HFP_SUBEVENT_SERVICE_LEVEL_CONNECTION_ESTABLISHED 4092 * @param event packet 4093 * @return acl_handle 4094 * @note: btstack_type H 4095 */ 4096 static inline hci_con_handle_t hfp_subevent_service_level_connection_established_get_acl_handle(const uint8_t * event){ 4097 return little_endian_read_16(event, 3); 4098 } 4099 /** 4100 * @brief Get field status from event HFP_SUBEVENT_SERVICE_LEVEL_CONNECTION_ESTABLISHED 4101 * @param event packet 4102 * @return status 4103 * @note: btstack_type 1 4104 */ 4105 static inline uint8_t hfp_subevent_service_level_connection_established_get_status(const uint8_t * event){ 4106 return event[5]; 4107 } 4108 /** 4109 * @brief Get field bd_addr from event HFP_SUBEVENT_SERVICE_LEVEL_CONNECTION_ESTABLISHED 4110 * @param event packet 4111 * @param Pointer to storage for bd_addr 4112 * @note: btstack_type B 4113 */ 4114 static inline void hfp_subevent_service_level_connection_established_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 4115 reverse_bytes(&event[6], bd_addr, 6); 4116 } 4117 4118 /** 4119 * @brief Get field acl_handle from event HFP_SUBEVENT_SERVICE_LEVEL_CONNECTION_RELEASED 4120 * @param event packet 4121 * @return acl_handle 4122 * @note: btstack_type H 4123 */ 4124 static inline hci_con_handle_t hfp_subevent_service_level_connection_released_get_acl_handle(const uint8_t * event){ 4125 return little_endian_read_16(event, 3); 4126 } 4127 4128 /** 4129 * @brief Get field acl_handle from event HFP_SUBEVENT_AUDIO_CONNECTION_ESTABLISHED 4130 * @param event packet 4131 * @return acl_handle 4132 * @note: btstack_type H 4133 */ 4134 static inline hci_con_handle_t hfp_subevent_audio_connection_established_get_acl_handle(const uint8_t * event){ 4135 return little_endian_read_16(event, 3); 4136 } 4137 /** 4138 * @brief Get field status from event HFP_SUBEVENT_AUDIO_CONNECTION_ESTABLISHED 4139 * @param event packet 4140 * @return status 4141 * @note: btstack_type 1 4142 */ 4143 static inline uint8_t hfp_subevent_audio_connection_established_get_status(const uint8_t * event){ 4144 return event[5]; 4145 } 4146 /** 4147 * @brief Get field sco_handle from event HFP_SUBEVENT_AUDIO_CONNECTION_ESTABLISHED 4148 * @param event packet 4149 * @return sco_handle 4150 * @note: btstack_type H 4151 */ 4152 static inline hci_con_handle_t hfp_subevent_audio_connection_established_get_sco_handle(const uint8_t * event){ 4153 return little_endian_read_16(event, 6); 4154 } 4155 /** 4156 * @brief Get field bd_addr from event HFP_SUBEVENT_AUDIO_CONNECTION_ESTABLISHED 4157 * @param event packet 4158 * @param Pointer to storage for bd_addr 4159 * @note: btstack_type B 4160 */ 4161 static inline void hfp_subevent_audio_connection_established_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 4162 reverse_bytes(&event[8], bd_addr, 6); 4163 } 4164 /** 4165 * @brief Get field negotiated_codec from event HFP_SUBEVENT_AUDIO_CONNECTION_ESTABLISHED 4166 * @param event packet 4167 * @return negotiated_codec 4168 * @note: btstack_type 1 4169 */ 4170 static inline uint8_t hfp_subevent_audio_connection_established_get_negotiated_codec(const uint8_t * event){ 4171 return event[14]; 4172 } 4173 4174 /** 4175 * @brief Get field acl_handle from event HFP_SUBEVENT_AUDIO_CONNECTION_RELEASED 4176 * @param event packet 4177 * @return acl_handle 4178 * @note: btstack_type H 4179 */ 4180 static inline hci_con_handle_t hfp_subevent_audio_connection_released_get_acl_handle(const uint8_t * event){ 4181 return little_endian_read_16(event, 3); 4182 } 4183 /** 4184 * @brief Get field sco_handle from event HFP_SUBEVENT_AUDIO_CONNECTION_RELEASED 4185 * @param event packet 4186 * @return sco_handle 4187 * @note: btstack_type H 4188 */ 4189 static inline hci_con_handle_t hfp_subevent_audio_connection_released_get_sco_handle(const uint8_t * event){ 4190 return little_endian_read_16(event, 5); 4191 } 4192 4193 /** 4194 * @brief Get field acl_handle from event HFP_SUBEVENT_COMPLETE 4195 * @param event packet 4196 * @return acl_handle 4197 * @note: btstack_type H 4198 */ 4199 static inline hci_con_handle_t hfp_subevent_complete_get_acl_handle(const uint8_t * event){ 4200 return little_endian_read_16(event, 3); 4201 } 4202 /** 4203 * @brief Get field status from event HFP_SUBEVENT_COMPLETE 4204 * @param event packet 4205 * @return status 4206 * @note: btstack_type 1 4207 */ 4208 static inline uint8_t hfp_subevent_complete_get_status(const uint8_t * event){ 4209 return event[5]; 4210 } 4211 4212 /** 4213 * @brief Get field acl_handle from event HFP_SUBEVENT_AG_INDICATOR_MAPPING 4214 * @param event packet 4215 * @return acl_handle 4216 * @note: btstack_type H 4217 */ 4218 static inline hci_con_handle_t hfp_subevent_ag_indicator_mapping_get_acl_handle(const uint8_t * event){ 4219 return little_endian_read_16(event, 3); 4220 } 4221 /** 4222 * @brief Get field indicator_index from event HFP_SUBEVENT_AG_INDICATOR_MAPPING 4223 * @param event packet 4224 * @return indicator_index 4225 * @note: btstack_type 1 4226 */ 4227 static inline uint8_t hfp_subevent_ag_indicator_mapping_get_indicator_index(const uint8_t * event){ 4228 return event[5]; 4229 } 4230 /** 4231 * @brief Get field indicator_min_range from event HFP_SUBEVENT_AG_INDICATOR_MAPPING 4232 * @param event packet 4233 * @return indicator_min_range 4234 * @note: btstack_type 1 4235 */ 4236 static inline uint8_t hfp_subevent_ag_indicator_mapping_get_indicator_min_range(const uint8_t * event){ 4237 return event[6]; 4238 } 4239 /** 4240 * @brief Get field indicator_max_range from event HFP_SUBEVENT_AG_INDICATOR_MAPPING 4241 * @param event packet 4242 * @return indicator_max_range 4243 * @note: btstack_type 1 4244 */ 4245 static inline uint8_t hfp_subevent_ag_indicator_mapping_get_indicator_max_range(const uint8_t * event){ 4246 return event[7]; 4247 } 4248 /** 4249 * @brief Get field indicator_name from event HFP_SUBEVENT_AG_INDICATOR_MAPPING 4250 * @param event packet 4251 * @return indicator_name 4252 * @note: btstack_type T 4253 */ 4254 static inline const char * hfp_subevent_ag_indicator_mapping_get_indicator_name(const uint8_t * event){ 4255 return (const char *) &event[8]; 4256 } 4257 4258 /** 4259 * @brief Get field acl_handle from event HFP_SUBEVENT_AG_INDICATOR_STATUS_CHANGED 4260 * @param event packet 4261 * @return acl_handle 4262 * @note: btstack_type H 4263 */ 4264 static inline hci_con_handle_t hfp_subevent_ag_indicator_status_changed_get_acl_handle(const uint8_t * event){ 4265 return little_endian_read_16(event, 3); 4266 } 4267 /** 4268 * @brief Get field indicator_index from event HFP_SUBEVENT_AG_INDICATOR_STATUS_CHANGED 4269 * @param event packet 4270 * @return indicator_index 4271 * @note: btstack_type 1 4272 */ 4273 static inline uint8_t hfp_subevent_ag_indicator_status_changed_get_indicator_index(const uint8_t * event){ 4274 return event[5]; 4275 } 4276 /** 4277 * @brief Get field indicator_status from event HFP_SUBEVENT_AG_INDICATOR_STATUS_CHANGED 4278 * @param event packet 4279 * @return indicator_status 4280 * @note: btstack_type 1 4281 */ 4282 static inline uint8_t hfp_subevent_ag_indicator_status_changed_get_indicator_status(const uint8_t * event){ 4283 return event[6]; 4284 } 4285 /** 4286 * @brief Get field indicator_min_range from event HFP_SUBEVENT_AG_INDICATOR_STATUS_CHANGED 4287 * @param event packet 4288 * @return indicator_min_range 4289 * @note: btstack_type 1 4290 */ 4291 static inline uint8_t hfp_subevent_ag_indicator_status_changed_get_indicator_min_range(const uint8_t * event){ 4292 return event[7]; 4293 } 4294 /** 4295 * @brief Get field indicator_max_range from event HFP_SUBEVENT_AG_INDICATOR_STATUS_CHANGED 4296 * @param event packet 4297 * @return indicator_max_range 4298 * @note: btstack_type 1 4299 */ 4300 static inline uint8_t hfp_subevent_ag_indicator_status_changed_get_indicator_max_range(const uint8_t * event){ 4301 return event[8]; 4302 } 4303 /** 4304 * @brief Get field indicator_mandatory from event HFP_SUBEVENT_AG_INDICATOR_STATUS_CHANGED 4305 * @param event packet 4306 * @return indicator_mandatory 4307 * @note: btstack_type 1 4308 */ 4309 static inline uint8_t hfp_subevent_ag_indicator_status_changed_get_indicator_mandatory(const uint8_t * event){ 4310 return event[9]; 4311 } 4312 /** 4313 * @brief Get field indicator_enabled from event HFP_SUBEVENT_AG_INDICATOR_STATUS_CHANGED 4314 * @param event packet 4315 * @return indicator_enabled 4316 * @note: btstack_type 1 4317 */ 4318 static inline uint8_t hfp_subevent_ag_indicator_status_changed_get_indicator_enabled(const uint8_t * event){ 4319 return event[10]; 4320 } 4321 /** 4322 * @brief Get field indicator_status_changed from event HFP_SUBEVENT_AG_INDICATOR_STATUS_CHANGED 4323 * @param event packet 4324 * @return indicator_status_changed 4325 * @note: btstack_type 1 4326 */ 4327 static inline uint8_t hfp_subevent_ag_indicator_status_changed_get_indicator_status_changed(const uint8_t * event){ 4328 return event[11]; 4329 } 4330 /** 4331 * @brief Get field indicator_name from event HFP_SUBEVENT_AG_INDICATOR_STATUS_CHANGED 4332 * @param event packet 4333 * @return indicator_name 4334 * @note: btstack_type T 4335 */ 4336 static inline const char * hfp_subevent_ag_indicator_status_changed_get_indicator_name(const uint8_t * event){ 4337 return (const char *) &event[12]; 4338 } 4339 4340 /** 4341 * @brief Get field acl_handle from event HFP_SUBEVENT_NETWORK_OPERATOR_CHANGED 4342 * @param event packet 4343 * @return acl_handle 4344 * @note: btstack_type H 4345 */ 4346 static inline hci_con_handle_t hfp_subevent_network_operator_changed_get_acl_handle(const uint8_t * event){ 4347 return little_endian_read_16(event, 3); 4348 } 4349 /** 4350 * @brief Get field network_operator_mode from event HFP_SUBEVENT_NETWORK_OPERATOR_CHANGED 4351 * @param event packet 4352 * @return network_operator_mode 4353 * @note: btstack_type 1 4354 */ 4355 static inline uint8_t hfp_subevent_network_operator_changed_get_network_operator_mode(const uint8_t * event){ 4356 return event[5]; 4357 } 4358 /** 4359 * @brief Get field network_operator_format from event HFP_SUBEVENT_NETWORK_OPERATOR_CHANGED 4360 * @param event packet 4361 * @return network_operator_format 4362 * @note: btstack_type 1 4363 */ 4364 static inline uint8_t hfp_subevent_network_operator_changed_get_network_operator_format(const uint8_t * event){ 4365 return event[6]; 4366 } 4367 /** 4368 * @brief Get field network_operator_name from event HFP_SUBEVENT_NETWORK_OPERATOR_CHANGED 4369 * @param event packet 4370 * @return network_operator_name 4371 * @note: btstack_type T 4372 */ 4373 static inline const char * hfp_subevent_network_operator_changed_get_network_operator_name(const uint8_t * event){ 4374 return (const char *) &event[7]; 4375 } 4376 4377 /** 4378 * @brief Get field acl_handle from event HFP_SUBEVENT_EXTENDED_AUDIO_GATEWAY_ERROR 4379 * @param event packet 4380 * @return acl_handle 4381 * @note: btstack_type H 4382 */ 4383 static inline hci_con_handle_t hfp_subevent_extended_audio_gateway_error_get_acl_handle(const uint8_t * event){ 4384 return little_endian_read_16(event, 3); 4385 } 4386 /** 4387 * @brief Get field error from event HFP_SUBEVENT_EXTENDED_AUDIO_GATEWAY_ERROR 4388 * @param event packet 4389 * @return error 4390 * @note: btstack_type 1 4391 */ 4392 static inline uint8_t hfp_subevent_extended_audio_gateway_error_get_error(const uint8_t * event){ 4393 return event[5]; 4394 } 4395 4396 /** 4397 * @brief Get field acl_handle from event HFP_SUBEVENT_START_RINGING 4398 * @param event packet 4399 * @return acl_handle 4400 * @note: btstack_type H 4401 */ 4402 static inline hci_con_handle_t hfp_subevent_start_ringing_get_acl_handle(const uint8_t * event){ 4403 return little_endian_read_16(event, 3); 4404 } 4405 4406 /** 4407 * @brief Get field acl_handle from event HFP_SUBEVENT_RING 4408 * @param event packet 4409 * @return acl_handle 4410 * @note: btstack_type H 4411 */ 4412 static inline hci_con_handle_t hfp_subevent_ring_get_acl_handle(const uint8_t * event){ 4413 return little_endian_read_16(event, 3); 4414 } 4415 4416 /** 4417 * @brief Get field acl_handle from event HFP_SUBEVENT_STOP_RINGING 4418 * @param event packet 4419 * @return acl_handle 4420 * @note: btstack_type H 4421 */ 4422 static inline hci_con_handle_t hfp_subevent_stop_ringing_get_acl_handle(const uint8_t * event){ 4423 return little_endian_read_16(event, 3); 4424 } 4425 4426 /** 4427 * @brief Get field acl_handle from event HFP_SUBEVENT_PLACE_CALL_WITH_NUMBER 4428 * @param event packet 4429 * @return acl_handle 4430 * @note: btstack_type H 4431 */ 4432 static inline hci_con_handle_t hfp_subevent_place_call_with_number_get_acl_handle(const uint8_t * event){ 4433 return little_endian_read_16(event, 3); 4434 } 4435 /** 4436 * @brief Get field number from event HFP_SUBEVENT_PLACE_CALL_WITH_NUMBER 4437 * @param event packet 4438 * @return number 4439 * @note: btstack_type T 4440 */ 4441 static inline const char * hfp_subevent_place_call_with_number_get_number(const uint8_t * event){ 4442 return (const char *) &event[5]; 4443 } 4444 4445 /** 4446 * @brief Get field acl_handle from event HFP_SUBEVENT_ATTACH_NUMBER_TO_VOICE_TAG 4447 * @param event packet 4448 * @return acl_handle 4449 * @note: btstack_type H 4450 */ 4451 static inline hci_con_handle_t hfp_subevent_attach_number_to_voice_tag_get_acl_handle(const uint8_t * event){ 4452 return little_endian_read_16(event, 3); 4453 } 4454 4455 /** 4456 * @brief Get field acl_handle from event HFP_SUBEVENT_NUMBER_FOR_VOICE_TAG 4457 * @param event packet 4458 * @return acl_handle 4459 * @note: btstack_type H 4460 */ 4461 static inline hci_con_handle_t hfp_subevent_number_for_voice_tag_get_acl_handle(const uint8_t * event){ 4462 return little_endian_read_16(event, 3); 4463 } 4464 /** 4465 * @brief Get field number from event HFP_SUBEVENT_NUMBER_FOR_VOICE_TAG 4466 * @param event packet 4467 * @return number 4468 * @note: btstack_type T 4469 */ 4470 static inline const char * hfp_subevent_number_for_voice_tag_get_number(const uint8_t * event){ 4471 return (const char *) &event[5]; 4472 } 4473 4474 /** 4475 * @brief Get field acl_handle from event HFP_SUBEVENT_TRANSMIT_DTMF_CODES 4476 * @param event packet 4477 * @return acl_handle 4478 * @note: btstack_type H 4479 */ 4480 static inline hci_con_handle_t hfp_subevent_transmit_dtmf_codes_get_acl_handle(const uint8_t * event){ 4481 return little_endian_read_16(event, 3); 4482 } 4483 /** 4484 * @brief Get field dtmf from event HFP_SUBEVENT_TRANSMIT_DTMF_CODES 4485 * @param event packet 4486 * @return dtmf 4487 * @note: btstack_type T 4488 */ 4489 static inline const char * hfp_subevent_transmit_dtmf_codes_get_dtmf(const uint8_t * event){ 4490 return (const char *) &event[5]; 4491 } 4492 4493 /** 4494 * @brief Get field acl_handle from event HFP_SUBEVENT_CALL_ANSWERED 4495 * @param event packet 4496 * @return acl_handle 4497 * @note: btstack_type H 4498 */ 4499 static inline hci_con_handle_t hfp_subevent_call_answered_get_acl_handle(const uint8_t * event){ 4500 return little_endian_read_16(event, 3); 4501 } 4502 4503 /** 4504 * @brief Get field acl_handle from event HFP_SUBEVENT_CALL_TERMINATED 4505 * @param event packet 4506 * @return acl_handle 4507 * @note: btstack_type H 4508 */ 4509 static inline hci_con_handle_t hfp_subevent_call_terminated_get_acl_handle(const uint8_t * event){ 4510 return little_endian_read_16(event, 3); 4511 } 4512 4513 /** 4514 * @brief Get field acl_handle from event HFP_SUBEVENT_CONFERENCE_CALL 4515 * @param event packet 4516 * @return acl_handle 4517 * @note: btstack_type H 4518 */ 4519 static inline hci_con_handle_t hfp_subevent_conference_call_get_acl_handle(const uint8_t * event){ 4520 return little_endian_read_16(event, 3); 4521 } 4522 4523 /** 4524 * @brief Get field acl_handle from event HFP_SUBEVENT_SPEAKER_VOLUME 4525 * @param event packet 4526 * @return acl_handle 4527 * @note: btstack_type H 4528 */ 4529 static inline hci_con_handle_t hfp_subevent_speaker_volume_get_acl_handle(const uint8_t * event){ 4530 return little_endian_read_16(event, 3); 4531 } 4532 /** 4533 * @brief Get field gain from event HFP_SUBEVENT_SPEAKER_VOLUME 4534 * @param event packet 4535 * @return gain 4536 * @note: btstack_type 1 4537 */ 4538 static inline uint8_t hfp_subevent_speaker_volume_get_gain(const uint8_t * event){ 4539 return event[5]; 4540 } 4541 4542 /** 4543 * @brief Get field acl_handle from event HFP_SUBEVENT_MICROPHONE_VOLUME 4544 * @param event packet 4545 * @return acl_handle 4546 * @note: btstack_type H 4547 */ 4548 static inline hci_con_handle_t hfp_subevent_microphone_volume_get_acl_handle(const uint8_t * event){ 4549 return little_endian_read_16(event, 3); 4550 } 4551 /** 4552 * @brief Get field gain from event HFP_SUBEVENT_MICROPHONE_VOLUME 4553 * @param event packet 4554 * @return gain 4555 * @note: btstack_type 1 4556 */ 4557 static inline uint8_t hfp_subevent_microphone_volume_get_gain(const uint8_t * event){ 4558 return event[5]; 4559 } 4560 4561 /** 4562 * @brief Get field acl_handle from event HFP_SUBEVENT_CALL_WAITING_NOTIFICATION 4563 * @param event packet 4564 * @return acl_handle 4565 * @note: btstack_type H 4566 */ 4567 static inline hci_con_handle_t hfp_subevent_call_waiting_notification_get_acl_handle(const uint8_t * event){ 4568 return little_endian_read_16(event, 3); 4569 } 4570 /** 4571 * @brief Get field type from event HFP_SUBEVENT_CALL_WAITING_NOTIFICATION 4572 * @param event packet 4573 * @return type 4574 * @note: btstack_type 1 4575 */ 4576 static inline uint8_t hfp_subevent_call_waiting_notification_get_type(const uint8_t * event){ 4577 return event[5]; 4578 } 4579 /** 4580 * @brief Get field number from event HFP_SUBEVENT_CALL_WAITING_NOTIFICATION 4581 * @param event packet 4582 * @return number 4583 * @note: btstack_type T 4584 */ 4585 static inline const char * hfp_subevent_call_waiting_notification_get_number(const uint8_t * event){ 4586 return (const char *) &event[6]; 4587 } 4588 4589 /** 4590 * @brief Get field acl_handle from event HFP_SUBEVENT_CALLING_LINE_IDENTIFICATION_NOTIFICATION 4591 * @param event packet 4592 * @return acl_handle 4593 * @note: btstack_type H 4594 */ 4595 static inline hci_con_handle_t hfp_subevent_calling_line_identification_notification_get_acl_handle(const uint8_t * event){ 4596 return little_endian_read_16(event, 3); 4597 } 4598 /** 4599 * @brief Get field type from event HFP_SUBEVENT_CALLING_LINE_IDENTIFICATION_NOTIFICATION 4600 * @param event packet 4601 * @return type 4602 * @note: btstack_type 1 4603 */ 4604 static inline uint8_t hfp_subevent_calling_line_identification_notification_get_type(const uint8_t * event){ 4605 return event[5]; 4606 } 4607 /** 4608 * @brief Get field number from event HFP_SUBEVENT_CALLING_LINE_IDENTIFICATION_NOTIFICATION 4609 * @param event packet 4610 * @return number 4611 * @note: btstack_type T 4612 */ 4613 static inline const char * hfp_subevent_calling_line_identification_notification_get_number(const uint8_t * event){ 4614 return (const char *) &event[6]; 4615 } 4616 4617 /** 4618 * @brief Get field acl_handle from event HFP_SUBEVENT_ENHANCED_CALL_STATUS 4619 * @param event packet 4620 * @return acl_handle 4621 * @note: btstack_type H 4622 */ 4623 static inline hci_con_handle_t hfp_subevent_enhanced_call_status_get_acl_handle(const uint8_t * event){ 4624 return little_endian_read_16(event, 3); 4625 } 4626 /** 4627 * @brief Get field clcc_idx from event HFP_SUBEVENT_ENHANCED_CALL_STATUS 4628 * @param event packet 4629 * @return clcc_idx 4630 * @note: btstack_type 1 4631 */ 4632 static inline uint8_t hfp_subevent_enhanced_call_status_get_clcc_idx(const uint8_t * event){ 4633 return event[5]; 4634 } 4635 /** 4636 * @brief Get field clcc_dir from event HFP_SUBEVENT_ENHANCED_CALL_STATUS 4637 * @param event packet 4638 * @return clcc_dir 4639 * @note: btstack_type 1 4640 */ 4641 static inline uint8_t hfp_subevent_enhanced_call_status_get_clcc_dir(const uint8_t * event){ 4642 return event[6]; 4643 } 4644 /** 4645 * @brief Get field clcc_status from event HFP_SUBEVENT_ENHANCED_CALL_STATUS 4646 * @param event packet 4647 * @return clcc_status 4648 * @note: btstack_type 1 4649 */ 4650 static inline uint8_t hfp_subevent_enhanced_call_status_get_clcc_status(const uint8_t * event){ 4651 return event[7]; 4652 } 4653 /** 4654 * @brief Get field clcc_mode from event HFP_SUBEVENT_ENHANCED_CALL_STATUS 4655 * @param event packet 4656 * @return clcc_mode 4657 * @note: btstack_type 1 4658 */ 4659 static inline uint8_t hfp_subevent_enhanced_call_status_get_clcc_mode(const uint8_t * event){ 4660 return event[8]; 4661 } 4662 /** 4663 * @brief Get field clcc_mpty from event HFP_SUBEVENT_ENHANCED_CALL_STATUS 4664 * @param event packet 4665 * @return clcc_mpty 4666 * @note: btstack_type 1 4667 */ 4668 static inline uint8_t hfp_subevent_enhanced_call_status_get_clcc_mpty(const uint8_t * event){ 4669 return event[9]; 4670 } 4671 /** 4672 * @brief Get field bnip_type from event HFP_SUBEVENT_ENHANCED_CALL_STATUS 4673 * @param event packet 4674 * @return bnip_type 4675 * @note: btstack_type 1 4676 */ 4677 static inline uint8_t hfp_subevent_enhanced_call_status_get_bnip_type(const uint8_t * event){ 4678 return event[10]; 4679 } 4680 /** 4681 * @brief Get field bnip_number from event HFP_SUBEVENT_ENHANCED_CALL_STATUS 4682 * @param event packet 4683 * @return bnip_number 4684 * @note: btstack_type T 4685 */ 4686 static inline const char * hfp_subevent_enhanced_call_status_get_bnip_number(const uint8_t * event){ 4687 return (const char *) &event[11]; 4688 } 4689 4690 /** 4691 * @brief Get field acl_handle from event HFP_SUBEVENT_SUBSCRIBER_NUMBER_INFORMATION 4692 * @param event packet 4693 * @return acl_handle 4694 * @note: btstack_type H 4695 */ 4696 static inline hci_con_handle_t hfp_subevent_subscriber_number_information_get_acl_handle(const uint8_t * event){ 4697 return little_endian_read_16(event, 3); 4698 } 4699 /** 4700 * @brief Get field status from event HFP_SUBEVENT_SUBSCRIBER_NUMBER_INFORMATION 4701 * @param event packet 4702 * @return status 4703 * @note: btstack_type 1 4704 */ 4705 static inline uint8_t hfp_subevent_subscriber_number_information_get_status(const uint8_t * event){ 4706 return event[5]; 4707 } 4708 /** 4709 * @brief Get field bnip_type from event HFP_SUBEVENT_SUBSCRIBER_NUMBER_INFORMATION 4710 * @param event packet 4711 * @return bnip_type 4712 * @note: btstack_type 1 4713 */ 4714 static inline uint8_t hfp_subevent_subscriber_number_information_get_bnip_type(const uint8_t * event){ 4715 return event[6]; 4716 } 4717 /** 4718 * @brief Get field bnip_number from event HFP_SUBEVENT_SUBSCRIBER_NUMBER_INFORMATION 4719 * @param event packet 4720 * @return bnip_number 4721 * @note: btstack_type T 4722 */ 4723 static inline const char * hfp_subevent_subscriber_number_information_get_bnip_number(const uint8_t * event){ 4724 return (const char *) &event[7]; 4725 } 4726 4727 /** 4728 * @brief Get field acl_handle from event HFP_SUBEVENT_RESPONSE_AND_HOLD_STATUS 4729 * @param event packet 4730 * @return acl_handle 4731 * @note: btstack_type H 4732 */ 4733 static inline hci_con_handle_t hfp_subevent_response_and_hold_status_get_acl_handle(const uint8_t * event){ 4734 return little_endian_read_16(event, 3); 4735 } 4736 /** 4737 * @brief Get field value from event HFP_SUBEVENT_RESPONSE_AND_HOLD_STATUS 4738 * @param event packet 4739 * @return value 4740 * @note: btstack_type T 4741 */ 4742 static inline const char * hfp_subevent_response_and_hold_status_get_value(const uint8_t * event){ 4743 return (const char *) &event[5]; 4744 } 4745 4746 /** 4747 * @brief Get field acl_handle from event HFP_SUBEVENT_AT_MESSAGE_SENT 4748 * @param event packet 4749 * @return acl_handle 4750 * @note: btstack_type H 4751 */ 4752 static inline hci_con_handle_t hfp_subevent_at_message_sent_get_acl_handle(const uint8_t * event){ 4753 return little_endian_read_16(event, 3); 4754 } 4755 /** 4756 * @brief Get field command from event HFP_SUBEVENT_AT_MESSAGE_SENT 4757 * @param event packet 4758 * @return command 4759 * @note: btstack_type T 4760 */ 4761 static inline const char * hfp_subevent_at_message_sent_get_command(const uint8_t * event){ 4762 return (const char *) &event[5]; 4763 } 4764 4765 /** 4766 * @brief Get field acl_handle from event HFP_SUBEVENT_AT_MESSAGE_RECEIVED 4767 * @param event packet 4768 * @return acl_handle 4769 * @note: btstack_type H 4770 */ 4771 static inline hci_con_handle_t hfp_subevent_at_message_received_get_acl_handle(const uint8_t * event){ 4772 return little_endian_read_16(event, 3); 4773 } 4774 /** 4775 * @brief Get field command from event HFP_SUBEVENT_AT_MESSAGE_RECEIVED 4776 * @param event packet 4777 * @return command 4778 * @note: btstack_type T 4779 */ 4780 static inline const char * hfp_subevent_at_message_received_get_command(const uint8_t * event){ 4781 return (const char *) &event[5]; 4782 } 4783 4784 /** 4785 * @brief Get field acl_handle from event HFP_SUBEVENT_IN_BAND_RING_TONE 4786 * @param event packet 4787 * @return acl_handle 4788 * @note: btstack_type H 4789 */ 4790 static inline hci_con_handle_t hfp_subevent_in_band_ring_tone_get_acl_handle(const uint8_t * event){ 4791 return little_endian_read_16(event, 3); 4792 } 4793 /** 4794 * @brief Get field status from event HFP_SUBEVENT_IN_BAND_RING_TONE 4795 * @param event packet 4796 * @return status 4797 * @note: btstack_type 1 4798 */ 4799 static inline uint8_t hfp_subevent_in_band_ring_tone_get_status(const uint8_t * event){ 4800 return event[5]; 4801 } 4802 4803 /** 4804 * @brief Get field acl_handle from event HFP_SUBEVENT_VOICE_RECOGNITION_ACTIVATED 4805 * @param event packet 4806 * @return acl_handle 4807 * @note: btstack_type H 4808 */ 4809 static inline hci_con_handle_t hfp_subevent_voice_recognition_activated_get_acl_handle(const uint8_t * event){ 4810 return little_endian_read_16(event, 3); 4811 } 4812 /** 4813 * @brief Get field status from event HFP_SUBEVENT_VOICE_RECOGNITION_ACTIVATED 4814 * @param event packet 4815 * @return status 4816 * @note: btstack_type 1 4817 */ 4818 static inline uint8_t hfp_subevent_voice_recognition_activated_get_status(const uint8_t * event){ 4819 return event[5]; 4820 } 4821 /** 4822 * @brief Get field enhanced from event HFP_SUBEVENT_VOICE_RECOGNITION_ACTIVATED 4823 * @param event packet 4824 * @return enhanced 4825 * @note: btstack_type 1 4826 */ 4827 static inline uint8_t hfp_subevent_voice_recognition_activated_get_enhanced(const uint8_t * event){ 4828 return event[6]; 4829 } 4830 4831 /** 4832 * @brief Get field acl_handle from event HFP_SUBEVENT_VOICE_RECOGNITION_DEACTIVATED 4833 * @param event packet 4834 * @return acl_handle 4835 * @note: btstack_type H 4836 */ 4837 static inline hci_con_handle_t hfp_subevent_voice_recognition_deactivated_get_acl_handle(const uint8_t * event){ 4838 return little_endian_read_16(event, 3); 4839 } 4840 /** 4841 * @brief Get field status from event HFP_SUBEVENT_VOICE_RECOGNITION_DEACTIVATED 4842 * @param event packet 4843 * @return status 4844 * @note: btstack_type 1 4845 */ 4846 static inline uint8_t hfp_subevent_voice_recognition_deactivated_get_status(const uint8_t * event){ 4847 return event[5]; 4848 } 4849 4850 /** 4851 * @brief Get field acl_handle from event HFP_SUBEVENT_ENHANCED_VOICE_RECOGNITION_HF_READY_FOR_AUDIO 4852 * @param event packet 4853 * @return acl_handle 4854 * @note: btstack_type H 4855 */ 4856 static inline hci_con_handle_t hfp_subevent_enhanced_voice_recognition_hf_ready_for_audio_get_acl_handle(const uint8_t * event){ 4857 return little_endian_read_16(event, 3); 4858 } 4859 /** 4860 * @brief Get field status from event HFP_SUBEVENT_ENHANCED_VOICE_RECOGNITION_HF_READY_FOR_AUDIO 4861 * @param event packet 4862 * @return status 4863 * @note: btstack_type 1 4864 */ 4865 static inline uint8_t hfp_subevent_enhanced_voice_recognition_hf_ready_for_audio_get_status(const uint8_t * event){ 4866 return event[5]; 4867 } 4868 4869 /** 4870 * @brief Get field acl_handle from event HFP_SUBEVENT_ENHANCED_VOICE_RECOGNITION_AG_READY_TO_ACCEPT_AUDIO_INPUT 4871 * @param event packet 4872 * @return acl_handle 4873 * @note: btstack_type H 4874 */ 4875 static inline hci_con_handle_t hfp_subevent_enhanced_voice_recognition_ag_ready_to_accept_audio_input_get_acl_handle(const uint8_t * event){ 4876 return little_endian_read_16(event, 3); 4877 } 4878 /** 4879 * @brief Get field status from event HFP_SUBEVENT_ENHANCED_VOICE_RECOGNITION_AG_READY_TO_ACCEPT_AUDIO_INPUT 4880 * @param event packet 4881 * @return status 4882 * @note: btstack_type 1 4883 */ 4884 static inline uint8_t hfp_subevent_enhanced_voice_recognition_ag_ready_to_accept_audio_input_get_status(const uint8_t * event){ 4885 return event[5]; 4886 } 4887 4888 /** 4889 * @brief Get field acl_handle from event HFP_SUBEVENT_ENHANCED_VOICE_RECOGNITION_AG_IS_STARTING_SOUND 4890 * @param event packet 4891 * @return acl_handle 4892 * @note: btstack_type H 4893 */ 4894 static inline hci_con_handle_t hfp_subevent_enhanced_voice_recognition_ag_is_starting_sound_get_acl_handle(const uint8_t * event){ 4895 return little_endian_read_16(event, 3); 4896 } 4897 /** 4898 * @brief Get field status from event HFP_SUBEVENT_ENHANCED_VOICE_RECOGNITION_AG_IS_STARTING_SOUND 4899 * @param event packet 4900 * @return status 4901 * @note: btstack_type 1 4902 */ 4903 static inline uint8_t hfp_subevent_enhanced_voice_recognition_ag_is_starting_sound_get_status(const uint8_t * event){ 4904 return event[5]; 4905 } 4906 4907 /** 4908 * @brief Get field acl_handle from event HFP_SUBEVENT_ENHANCED_VOICE_RECOGNITION_AG_IS_PROCESSING_AUDIO_INPUT 4909 * @param event packet 4910 * @return acl_handle 4911 * @note: btstack_type H 4912 */ 4913 static inline hci_con_handle_t hfp_subevent_enhanced_voice_recognition_ag_is_processing_audio_input_get_acl_handle(const uint8_t * event){ 4914 return little_endian_read_16(event, 3); 4915 } 4916 /** 4917 * @brief Get field status from event HFP_SUBEVENT_ENHANCED_VOICE_RECOGNITION_AG_IS_PROCESSING_AUDIO_INPUT 4918 * @param event packet 4919 * @return status 4920 * @note: btstack_type 1 4921 */ 4922 static inline uint8_t hfp_subevent_enhanced_voice_recognition_ag_is_processing_audio_input_get_status(const uint8_t * event){ 4923 return event[5]; 4924 } 4925 4926 /** 4927 * @brief Get field acl_handle from event HFP_SUBEVENT_ENHANCED_VOICE_RECOGNITION_AG_MESSAGE_SENT 4928 * @param event packet 4929 * @return acl_handle 4930 * @note: btstack_type H 4931 */ 4932 static inline hci_con_handle_t hfp_subevent_enhanced_voice_recognition_ag_message_sent_get_acl_handle(const uint8_t * event){ 4933 return little_endian_read_16(event, 3); 4934 } 4935 /** 4936 * @brief Get field status from event HFP_SUBEVENT_ENHANCED_VOICE_RECOGNITION_AG_MESSAGE_SENT 4937 * @param event packet 4938 * @return status 4939 * @note: btstack_type 1 4940 */ 4941 static inline uint8_t hfp_subevent_enhanced_voice_recognition_ag_message_sent_get_status(const uint8_t * event){ 4942 return event[5]; 4943 } 4944 4945 /** 4946 * @brief Get field acl_handle from event HFP_SUBEVENT_ENHANCED_VOICE_RECOGNITION_AG_MESSAGE 4947 * @param event packet 4948 * @return acl_handle 4949 * @note: btstack_type H 4950 */ 4951 static inline hci_con_handle_t hfp_subevent_enhanced_voice_recognition_ag_message_get_acl_handle(const uint8_t * event){ 4952 return little_endian_read_16(event, 3); 4953 } 4954 /** 4955 * @brief Get field text_id from event HFP_SUBEVENT_ENHANCED_VOICE_RECOGNITION_AG_MESSAGE 4956 * @param event packet 4957 * @return text_id 4958 * @note: btstack_type 2 4959 */ 4960 static inline uint16_t hfp_subevent_enhanced_voice_recognition_ag_message_get_text_id(const uint8_t * event){ 4961 return little_endian_read_16(event, 5); 4962 } 4963 /** 4964 * @brief Get field text_type from event HFP_SUBEVENT_ENHANCED_VOICE_RECOGNITION_AG_MESSAGE 4965 * @param event packet 4966 * @return text_type 4967 * @note: btstack_type 1 4968 */ 4969 static inline uint8_t hfp_subevent_enhanced_voice_recognition_ag_message_get_text_type(const uint8_t * event){ 4970 return event[7]; 4971 } 4972 /** 4973 * @brief Get field text_operation from event HFP_SUBEVENT_ENHANCED_VOICE_RECOGNITION_AG_MESSAGE 4974 * @param event packet 4975 * @return text_operation 4976 * @note: btstack_type 1 4977 */ 4978 static inline uint8_t hfp_subevent_enhanced_voice_recognition_ag_message_get_text_operation(const uint8_t * event){ 4979 return event[8]; 4980 } 4981 /** 4982 * @brief Get field text_length from event HFP_SUBEVENT_ENHANCED_VOICE_RECOGNITION_AG_MESSAGE 4983 * @param event packet 4984 * @return text_length 4985 * @note: btstack_type L 4986 */ 4987 static inline uint16_t hfp_subevent_enhanced_voice_recognition_ag_message_get_text_length(const uint8_t * event){ 4988 return little_endian_read_16(event, 9); 4989 } 4990 /** 4991 * @brief Get field text from event HFP_SUBEVENT_ENHANCED_VOICE_RECOGNITION_AG_MESSAGE 4992 * @param event packet 4993 * @return text 4994 * @note: btstack_type V 4995 */ 4996 static inline const uint8_t * hfp_subevent_enhanced_voice_recognition_ag_message_get_text(const uint8_t * event){ 4997 return &event[11]; 4998 } 4999 5000 /** 5001 * @brief Get field acl_handle from event HFP_SUBEVENT_ECHO_CANCELING_AND_NOISE_REDUCTION_DEACTIVATE 5002 * @param event packet 5003 * @return acl_handle 5004 * @note: btstack_type H 5005 */ 5006 static inline hci_con_handle_t hfp_subevent_echo_canceling_and_noise_reduction_deactivate_get_acl_handle(const uint8_t * event){ 5007 return little_endian_read_16(event, 3); 5008 } 5009 /** 5010 * @brief Get field status from event HFP_SUBEVENT_ECHO_CANCELING_AND_NOISE_REDUCTION_DEACTIVATE 5011 * @param event packet 5012 * @return status 5013 * @note: btstack_type 1 5014 */ 5015 static inline uint8_t hfp_subevent_echo_canceling_and_noise_reduction_deactivate_get_status(const uint8_t * event){ 5016 return event[5]; 5017 } 5018 5019 /** 5020 * @brief Get field acl_handle from event HFP_SUBEVENT_HF_INDICATOR 5021 * @param event packet 5022 * @return acl_handle 5023 * @note: btstack_type H 5024 */ 5025 static inline hci_con_handle_t hfp_subevent_hf_indicator_get_acl_handle(const uint8_t * event){ 5026 return little_endian_read_16(event, 3); 5027 } 5028 /** 5029 * @brief Get field uuid from event HFP_SUBEVENT_HF_INDICATOR 5030 * @param event packet 5031 * @return uuid 5032 * @note: btstack_type 2 5033 */ 5034 static inline uint16_t hfp_subevent_hf_indicator_get_uuid(const uint8_t * event){ 5035 return little_endian_read_16(event, 5); 5036 } 5037 /** 5038 * @brief Get field value from event HFP_SUBEVENT_HF_INDICATOR 5039 * @param event packet 5040 * @return value 5041 * @note: btstack_type 1 5042 */ 5043 static inline uint8_t hfp_subevent_hf_indicator_get_value(const uint8_t * event){ 5044 return event[7]; 5045 } 5046 5047 #ifdef ENABLE_BLE 5048 /** 5049 * @brief Get field handle from event ANCS_SUBEVENT_CLIENT_CONNECTED 5050 * @param event packet 5051 * @return handle 5052 * @note: btstack_type H 5053 */ 5054 static inline hci_con_handle_t ancs_subevent_client_connected_get_handle(const uint8_t * event){ 5055 return little_endian_read_16(event, 3); 5056 } 5057 #endif 5058 5059 #ifdef ENABLE_BLE 5060 /** 5061 * @brief Get field handle from event ANCS_SUBEVENT_CLIENT_NOTIFICATION 5062 * @param event packet 5063 * @return handle 5064 * @note: btstack_type H 5065 */ 5066 static inline hci_con_handle_t ancs_subevent_client_notification_get_handle(const uint8_t * event){ 5067 return little_endian_read_16(event, 3); 5068 } 5069 /** 5070 * @brief Get field attribute_id from event ANCS_SUBEVENT_CLIENT_NOTIFICATION 5071 * @param event packet 5072 * @return attribute_id 5073 * @note: btstack_type 2 5074 */ 5075 static inline uint16_t ancs_subevent_client_notification_get_attribute_id(const uint8_t * event){ 5076 return little_endian_read_16(event, 5); 5077 } 5078 /** 5079 * @brief Get field text from event ANCS_SUBEVENT_CLIENT_NOTIFICATION 5080 * @param event packet 5081 * @return text 5082 * @note: btstack_type T 5083 */ 5084 static inline const char * ancs_subevent_client_notification_get_text(const uint8_t * event){ 5085 return (const char *) &event[7]; 5086 } 5087 #endif 5088 5089 #ifdef ENABLE_BLE 5090 /** 5091 * @brief Get field handle from event ANCS_SUBEVENT_CLIENT_DISCONNECTED 5092 * @param event packet 5093 * @return handle 5094 * @note: btstack_type H 5095 */ 5096 static inline hci_con_handle_t ancs_subevent_client_disconnected_get_handle(const uint8_t * event){ 5097 return little_endian_read_16(event, 3); 5098 } 5099 #endif 5100 5101 /** 5102 * @brief Get field avdtp_cid from event AVDTP_SUBEVENT_SIGNALING_ACCEPT 5103 * @param event packet 5104 * @return avdtp_cid 5105 * @note: btstack_type 2 5106 */ 5107 static inline uint16_t avdtp_subevent_signaling_accept_get_avdtp_cid(const uint8_t * event){ 5108 return little_endian_read_16(event, 3); 5109 } 5110 /** 5111 * @brief Get field local_seid from event AVDTP_SUBEVENT_SIGNALING_ACCEPT 5112 * @param event packet 5113 * @return local_seid 5114 * @note: btstack_type 1 5115 */ 5116 static inline uint8_t avdtp_subevent_signaling_accept_get_local_seid(const uint8_t * event){ 5117 return event[5]; 5118 } 5119 /** 5120 * @brief Get field is_initiator from event AVDTP_SUBEVENT_SIGNALING_ACCEPT 5121 * @param event packet 5122 * @return is_initiator 5123 * @note: btstack_type 1 5124 */ 5125 static inline uint8_t avdtp_subevent_signaling_accept_get_is_initiator(const uint8_t * event){ 5126 return event[6]; 5127 } 5128 /** 5129 * @brief Get field signal_identifier from event AVDTP_SUBEVENT_SIGNALING_ACCEPT 5130 * @param event packet 5131 * @return signal_identifier 5132 * @note: btstack_type 1 5133 */ 5134 static inline uint8_t avdtp_subevent_signaling_accept_get_signal_identifier(const uint8_t * event){ 5135 return event[7]; 5136 } 5137 5138 /** 5139 * @brief Get field avdtp_cid from event AVDTP_SUBEVENT_SIGNALING_REJECT 5140 * @param event packet 5141 * @return avdtp_cid 5142 * @note: btstack_type 2 5143 */ 5144 static inline uint16_t avdtp_subevent_signaling_reject_get_avdtp_cid(const uint8_t * event){ 5145 return little_endian_read_16(event, 3); 5146 } 5147 /** 5148 * @brief Get field local_seid from event AVDTP_SUBEVENT_SIGNALING_REJECT 5149 * @param event packet 5150 * @return local_seid 5151 * @note: btstack_type 1 5152 */ 5153 static inline uint8_t avdtp_subevent_signaling_reject_get_local_seid(const uint8_t * event){ 5154 return event[5]; 5155 } 5156 /** 5157 * @brief Get field is_initiator from event AVDTP_SUBEVENT_SIGNALING_REJECT 5158 * @param event packet 5159 * @return is_initiator 5160 * @note: btstack_type 1 5161 */ 5162 static inline uint8_t avdtp_subevent_signaling_reject_get_is_initiator(const uint8_t * event){ 5163 return event[6]; 5164 } 5165 /** 5166 * @brief Get field signal_identifier from event AVDTP_SUBEVENT_SIGNALING_REJECT 5167 * @param event packet 5168 * @return signal_identifier 5169 * @note: btstack_type 1 5170 */ 5171 static inline uint8_t avdtp_subevent_signaling_reject_get_signal_identifier(const uint8_t * event){ 5172 return event[7]; 5173 } 5174 5175 /** 5176 * @brief Get field avdtp_cid from event AVDTP_SUBEVENT_SIGNALING_GENERAL_REJECT 5177 * @param event packet 5178 * @return avdtp_cid 5179 * @note: btstack_type 2 5180 */ 5181 static inline uint16_t avdtp_subevent_signaling_general_reject_get_avdtp_cid(const uint8_t * event){ 5182 return little_endian_read_16(event, 3); 5183 } 5184 /** 5185 * @brief Get field local_seid from event AVDTP_SUBEVENT_SIGNALING_GENERAL_REJECT 5186 * @param event packet 5187 * @return local_seid 5188 * @note: btstack_type 1 5189 */ 5190 static inline uint8_t avdtp_subevent_signaling_general_reject_get_local_seid(const uint8_t * event){ 5191 return event[5]; 5192 } 5193 /** 5194 * @brief Get field is_initiator from event AVDTP_SUBEVENT_SIGNALING_GENERAL_REJECT 5195 * @param event packet 5196 * @return is_initiator 5197 * @note: btstack_type 1 5198 */ 5199 static inline uint8_t avdtp_subevent_signaling_general_reject_get_is_initiator(const uint8_t * event){ 5200 return event[6]; 5201 } 5202 /** 5203 * @brief Get field signal_identifier from event AVDTP_SUBEVENT_SIGNALING_GENERAL_REJECT 5204 * @param event packet 5205 * @return signal_identifier 5206 * @note: btstack_type 1 5207 */ 5208 static inline uint8_t avdtp_subevent_signaling_general_reject_get_signal_identifier(const uint8_t * event){ 5209 return event[7]; 5210 } 5211 5212 /** 5213 * @brief Get field avdtp_cid from event AVDTP_SUBEVENT_SIGNALING_CONNECTION_ESTABLISHED 5214 * @param event packet 5215 * @return avdtp_cid 5216 * @note: btstack_type 2 5217 */ 5218 static inline uint16_t avdtp_subevent_signaling_connection_established_get_avdtp_cid(const uint8_t * event){ 5219 return little_endian_read_16(event, 3); 5220 } 5221 /** 5222 * @brief Get field bd_addr from event AVDTP_SUBEVENT_SIGNALING_CONNECTION_ESTABLISHED 5223 * @param event packet 5224 * @param Pointer to storage for bd_addr 5225 * @note: btstack_type B 5226 */ 5227 static inline void avdtp_subevent_signaling_connection_established_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 5228 reverse_bytes(&event[5], bd_addr, 6); 5229 } 5230 /** 5231 * @brief Get field con_handle from event AVDTP_SUBEVENT_SIGNALING_CONNECTION_ESTABLISHED 5232 * @param event packet 5233 * @return con_handle 5234 * @note: btstack_type 2 5235 */ 5236 static inline uint16_t avdtp_subevent_signaling_connection_established_get_con_handle(const uint8_t * event){ 5237 return little_endian_read_16(event, 11); 5238 } 5239 /** 5240 * @brief Get field status from event AVDTP_SUBEVENT_SIGNALING_CONNECTION_ESTABLISHED 5241 * @param event packet 5242 * @return status 5243 * @note: btstack_type 1 5244 */ 5245 static inline uint8_t avdtp_subevent_signaling_connection_established_get_status(const uint8_t * event){ 5246 return event[13]; 5247 } 5248 5249 /** 5250 * @brief Get field avdtp_cid from event AVDTP_SUBEVENT_SIGNALING_CONNECTION_RELEASED 5251 * @param event packet 5252 * @return avdtp_cid 5253 * @note: btstack_type 2 5254 */ 5255 static inline uint16_t avdtp_subevent_signaling_connection_released_get_avdtp_cid(const uint8_t * event){ 5256 return little_endian_read_16(event, 3); 5257 } 5258 5259 /** 5260 * @brief Get field avdtp_cid from event AVDTP_SUBEVENT_SIGNALING_SEP_FOUND 5261 * @param event packet 5262 * @return avdtp_cid 5263 * @note: btstack_type 2 5264 */ 5265 static inline uint16_t avdtp_subevent_signaling_sep_found_get_avdtp_cid(const uint8_t * event){ 5266 return little_endian_read_16(event, 3); 5267 } 5268 /** 5269 * @brief Get field remote_seid from event AVDTP_SUBEVENT_SIGNALING_SEP_FOUND 5270 * @param event packet 5271 * @return remote_seid 5272 * @note: btstack_type 1 5273 */ 5274 static inline uint8_t avdtp_subevent_signaling_sep_found_get_remote_seid(const uint8_t * event){ 5275 return event[5]; 5276 } 5277 /** 5278 * @brief Get field in_use from event AVDTP_SUBEVENT_SIGNALING_SEP_FOUND 5279 * @param event packet 5280 * @return in_use 5281 * @note: btstack_type 1 5282 */ 5283 static inline uint8_t avdtp_subevent_signaling_sep_found_get_in_use(const uint8_t * event){ 5284 return event[6]; 5285 } 5286 /** 5287 * @brief Get field media_type from event AVDTP_SUBEVENT_SIGNALING_SEP_FOUND 5288 * @param event packet 5289 * @return media_type 5290 * @note: btstack_type 1 5291 */ 5292 static inline uint8_t avdtp_subevent_signaling_sep_found_get_media_type(const uint8_t * event){ 5293 return event[7]; 5294 } 5295 /** 5296 * @brief Get field sep_type from event AVDTP_SUBEVENT_SIGNALING_SEP_FOUND 5297 * @param event packet 5298 * @return sep_type 5299 * @note: btstack_type 1 5300 */ 5301 static inline uint8_t avdtp_subevent_signaling_sep_found_get_sep_type(const uint8_t * event){ 5302 return event[8]; 5303 } 5304 5305 /** 5306 * @brief Get field avdtp_cid from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CAPABILITY 5307 * @param event packet 5308 * @return avdtp_cid 5309 * @note: btstack_type 2 5310 */ 5311 static inline uint16_t avdtp_subevent_signaling_media_codec_sbc_capability_get_avdtp_cid(const uint8_t * event){ 5312 return little_endian_read_16(event, 3); 5313 } 5314 /** 5315 * @brief Get field remote_seid from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CAPABILITY 5316 * @param event packet 5317 * @return remote_seid 5318 * @note: btstack_type 1 5319 */ 5320 static inline uint8_t avdtp_subevent_signaling_media_codec_sbc_capability_get_remote_seid(const uint8_t * event){ 5321 return event[5]; 5322 } 5323 /** 5324 * @brief Get field media_type from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CAPABILITY 5325 * @param event packet 5326 * @return media_type 5327 * @note: btstack_type 1 5328 */ 5329 static inline uint8_t avdtp_subevent_signaling_media_codec_sbc_capability_get_media_type(const uint8_t * event){ 5330 return event[6]; 5331 } 5332 /** 5333 * @brief Get field sampling_frequency_bitmap from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CAPABILITY 5334 * @param event packet 5335 * @return sampling_frequency_bitmap 5336 * @note: btstack_type 1 5337 */ 5338 static inline uint8_t avdtp_subevent_signaling_media_codec_sbc_capability_get_sampling_frequency_bitmap(const uint8_t * event){ 5339 return event[7]; 5340 } 5341 /** 5342 * @brief Get field channel_mode_bitmap from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CAPABILITY 5343 * @param event packet 5344 * @return channel_mode_bitmap 5345 * @note: btstack_type 1 5346 */ 5347 static inline uint8_t avdtp_subevent_signaling_media_codec_sbc_capability_get_channel_mode_bitmap(const uint8_t * event){ 5348 return event[8]; 5349 } 5350 /** 5351 * @brief Get field block_length_bitmap from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CAPABILITY 5352 * @param event packet 5353 * @return block_length_bitmap 5354 * @note: btstack_type 1 5355 */ 5356 static inline uint8_t avdtp_subevent_signaling_media_codec_sbc_capability_get_block_length_bitmap(const uint8_t * event){ 5357 return event[9]; 5358 } 5359 /** 5360 * @brief Get field subbands_bitmap from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CAPABILITY 5361 * @param event packet 5362 * @return subbands_bitmap 5363 * @note: btstack_type 1 5364 */ 5365 static inline uint8_t avdtp_subevent_signaling_media_codec_sbc_capability_get_subbands_bitmap(const uint8_t * event){ 5366 return event[10]; 5367 } 5368 /** 5369 * @brief Get field allocation_method_bitmap from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CAPABILITY 5370 * @param event packet 5371 * @return allocation_method_bitmap 5372 * @note: btstack_type 1 5373 */ 5374 static inline uint8_t avdtp_subevent_signaling_media_codec_sbc_capability_get_allocation_method_bitmap(const uint8_t * event){ 5375 return event[11]; 5376 } 5377 /** 5378 * @brief Get field min_bitpool_value from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CAPABILITY 5379 * @param event packet 5380 * @return min_bitpool_value 5381 * @note: btstack_type 1 5382 */ 5383 static inline uint8_t avdtp_subevent_signaling_media_codec_sbc_capability_get_min_bitpool_value(const uint8_t * event){ 5384 return event[12]; 5385 } 5386 /** 5387 * @brief Get field max_bitpool_value from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CAPABILITY 5388 * @param event packet 5389 * @return max_bitpool_value 5390 * @note: btstack_type 1 5391 */ 5392 static inline uint8_t avdtp_subevent_signaling_media_codec_sbc_capability_get_max_bitpool_value(const uint8_t * event){ 5393 return event[13]; 5394 } 5395 5396 /** 5397 * @brief Get field avdtp_cid from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CAPABILITY 5398 * @param event packet 5399 * @return avdtp_cid 5400 * @note: btstack_type 2 5401 */ 5402 static inline uint16_t avdtp_subevent_signaling_media_codec_mpeg_audio_capability_get_avdtp_cid(const uint8_t * event){ 5403 return little_endian_read_16(event, 3); 5404 } 5405 /** 5406 * @brief Get field remote_seid from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CAPABILITY 5407 * @param event packet 5408 * @return remote_seid 5409 * @note: btstack_type 1 5410 */ 5411 static inline uint8_t avdtp_subevent_signaling_media_codec_mpeg_audio_capability_get_remote_seid(const uint8_t * event){ 5412 return event[5]; 5413 } 5414 /** 5415 * @brief Get field media_type from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CAPABILITY 5416 * @param event packet 5417 * @return media_type 5418 * @note: btstack_type 1 5419 */ 5420 static inline uint8_t avdtp_subevent_signaling_media_codec_mpeg_audio_capability_get_media_type(const uint8_t * event){ 5421 return event[6]; 5422 } 5423 /** 5424 * @brief Get field layer_bitmap from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CAPABILITY 5425 * @param event packet 5426 * @return layer_bitmap 5427 * @note: btstack_type 1 5428 */ 5429 static inline uint8_t avdtp_subevent_signaling_media_codec_mpeg_audio_capability_get_layer_bitmap(const uint8_t * event){ 5430 return event[7]; 5431 } 5432 /** 5433 * @brief Get field crc from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CAPABILITY 5434 * @param event packet 5435 * @return crc 5436 * @note: btstack_type 1 5437 */ 5438 static inline uint8_t avdtp_subevent_signaling_media_codec_mpeg_audio_capability_get_crc(const uint8_t * event){ 5439 return event[8]; 5440 } 5441 /** 5442 * @brief Get field channel_mode_bitmap from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CAPABILITY 5443 * @param event packet 5444 * @return channel_mode_bitmap 5445 * @note: btstack_type 1 5446 */ 5447 static inline uint8_t avdtp_subevent_signaling_media_codec_mpeg_audio_capability_get_channel_mode_bitmap(const uint8_t * event){ 5448 return event[9]; 5449 } 5450 /** 5451 * @brief Get field media_payload_format from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CAPABILITY 5452 * @param event packet 5453 * @return media_payload_format 5454 * @note: btstack_type 1 5455 */ 5456 static inline uint8_t avdtp_subevent_signaling_media_codec_mpeg_audio_capability_get_media_payload_format(const uint8_t * event){ 5457 return event[10]; 5458 } 5459 /** 5460 * @brief Get field sampling_frequency_bitmap from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CAPABILITY 5461 * @param event packet 5462 * @return sampling_frequency_bitmap 5463 * @note: btstack_type 1 5464 */ 5465 static inline uint8_t avdtp_subevent_signaling_media_codec_mpeg_audio_capability_get_sampling_frequency_bitmap(const uint8_t * event){ 5466 return event[11]; 5467 } 5468 /** 5469 * @brief Get field vbr from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CAPABILITY 5470 * @param event packet 5471 * @return vbr 5472 * @note: btstack_type 1 5473 */ 5474 static inline uint8_t avdtp_subevent_signaling_media_codec_mpeg_audio_capability_get_vbr(const uint8_t * event){ 5475 return event[12]; 5476 } 5477 /** 5478 * @brief Get field bit_rate_index_bitmap from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CAPABILITY 5479 * @param event packet 5480 * @return bit_rate_index_bitmap 5481 * @note: btstack_type 2 5482 */ 5483 static inline uint16_t avdtp_subevent_signaling_media_codec_mpeg_audio_capability_get_bit_rate_index_bitmap(const uint8_t * event){ 5484 return little_endian_read_16(event, 13); 5485 } 5486 5487 /** 5488 * @brief Get field avdtp_cid from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CAPABILITY 5489 * @param event packet 5490 * @return avdtp_cid 5491 * @note: btstack_type 2 5492 */ 5493 static inline uint16_t avdtp_subevent_signaling_media_codec_mpeg_aac_capability_get_avdtp_cid(const uint8_t * event){ 5494 return little_endian_read_16(event, 3); 5495 } 5496 /** 5497 * @brief Get field remote_seid from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CAPABILITY 5498 * @param event packet 5499 * @return remote_seid 5500 * @note: btstack_type 1 5501 */ 5502 static inline uint8_t avdtp_subevent_signaling_media_codec_mpeg_aac_capability_get_remote_seid(const uint8_t * event){ 5503 return event[5]; 5504 } 5505 /** 5506 * @brief Get field media_type from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CAPABILITY 5507 * @param event packet 5508 * @return media_type 5509 * @note: btstack_type 1 5510 */ 5511 static inline uint8_t avdtp_subevent_signaling_media_codec_mpeg_aac_capability_get_media_type(const uint8_t * event){ 5512 return event[6]; 5513 } 5514 /** 5515 * @brief Get field object_type_bitmap from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CAPABILITY 5516 * @param event packet 5517 * @return object_type_bitmap 5518 * @note: btstack_type 1 5519 */ 5520 static inline uint8_t avdtp_subevent_signaling_media_codec_mpeg_aac_capability_get_object_type_bitmap(const uint8_t * event){ 5521 return event[7]; 5522 } 5523 /** 5524 * @brief Get field sampling_frequency_bitmap from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CAPABILITY 5525 * @param event packet 5526 * @return sampling_frequency_bitmap 5527 * @note: btstack_type 2 5528 */ 5529 static inline uint16_t avdtp_subevent_signaling_media_codec_mpeg_aac_capability_get_sampling_frequency_bitmap(const uint8_t * event){ 5530 return little_endian_read_16(event, 8); 5531 } 5532 /** 5533 * @brief Get field channels_bitmap from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CAPABILITY 5534 * @param event packet 5535 * @return channels_bitmap 5536 * @note: btstack_type 1 5537 */ 5538 static inline uint8_t avdtp_subevent_signaling_media_codec_mpeg_aac_capability_get_channels_bitmap(const uint8_t * event){ 5539 return event[10]; 5540 } 5541 /** 5542 * @brief Get field bit_rate from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CAPABILITY 5543 * @param event packet 5544 * @return bit_rate 5545 * @note: btstack_type 3 5546 */ 5547 static inline uint32_t avdtp_subevent_signaling_media_codec_mpeg_aac_capability_get_bit_rate(const uint8_t * event){ 5548 return little_endian_read_24(event, 11); 5549 } 5550 /** 5551 * @brief Get field vbr from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CAPABILITY 5552 * @param event packet 5553 * @return vbr 5554 * @note: btstack_type 1 5555 */ 5556 static inline uint8_t avdtp_subevent_signaling_media_codec_mpeg_aac_capability_get_vbr(const uint8_t * event){ 5557 return event[14]; 5558 } 5559 5560 /** 5561 * @brief Get field avdtp_cid from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CAPABILITY 5562 * @param event packet 5563 * @return avdtp_cid 5564 * @note: btstack_type 2 5565 */ 5566 static inline uint16_t avdtp_subevent_signaling_media_codec_atrac_capability_get_avdtp_cid(const uint8_t * event){ 5567 return little_endian_read_16(event, 3); 5568 } 5569 /** 5570 * @brief Get field remote_seid from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CAPABILITY 5571 * @param event packet 5572 * @return remote_seid 5573 * @note: btstack_type 1 5574 */ 5575 static inline uint8_t avdtp_subevent_signaling_media_codec_atrac_capability_get_remote_seid(const uint8_t * event){ 5576 return event[5]; 5577 } 5578 /** 5579 * @brief Get field media_type from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CAPABILITY 5580 * @param event packet 5581 * @return media_type 5582 * @note: btstack_type 1 5583 */ 5584 static inline uint8_t avdtp_subevent_signaling_media_codec_atrac_capability_get_media_type(const uint8_t * event){ 5585 return event[6]; 5586 } 5587 /** 5588 * @brief Get field version from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CAPABILITY 5589 * @param event packet 5590 * @return version 5591 * @note: btstack_type 1 5592 */ 5593 static inline uint8_t avdtp_subevent_signaling_media_codec_atrac_capability_get_version(const uint8_t * event){ 5594 return event[7]; 5595 } 5596 /** 5597 * @brief Get field channel_mode_bitmap from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CAPABILITY 5598 * @param event packet 5599 * @return channel_mode_bitmap 5600 * @note: btstack_type 1 5601 */ 5602 static inline uint8_t avdtp_subevent_signaling_media_codec_atrac_capability_get_channel_mode_bitmap(const uint8_t * event){ 5603 return event[8]; 5604 } 5605 /** 5606 * @brief Get field sampling_frequency_bitmap from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CAPABILITY 5607 * @param event packet 5608 * @return sampling_frequency_bitmap 5609 * @note: btstack_type 1 5610 */ 5611 static inline uint8_t avdtp_subevent_signaling_media_codec_atrac_capability_get_sampling_frequency_bitmap(const uint8_t * event){ 5612 return event[9]; 5613 } 5614 /** 5615 * @brief Get field vbr from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CAPABILITY 5616 * @param event packet 5617 * @return vbr 5618 * @note: btstack_type 1 5619 */ 5620 static inline uint8_t avdtp_subevent_signaling_media_codec_atrac_capability_get_vbr(const uint8_t * event){ 5621 return event[10]; 5622 } 5623 /** 5624 * @brief Get field bit_rate_index_bitmap from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CAPABILITY 5625 * @param event packet 5626 * @return bit_rate_index_bitmap 5627 * @note: btstack_type 3 5628 */ 5629 static inline uint32_t avdtp_subevent_signaling_media_codec_atrac_capability_get_bit_rate_index_bitmap(const uint8_t * event){ 5630 return little_endian_read_24(event, 11); 5631 } 5632 /** 5633 * @brief Get field maximum_sul from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CAPABILITY 5634 * @param event packet 5635 * @return maximum_sul 5636 * @note: btstack_type 2 5637 */ 5638 static inline uint16_t avdtp_subevent_signaling_media_codec_atrac_capability_get_maximum_sul(const uint8_t * event){ 5639 return little_endian_read_16(event, 14); 5640 } 5641 5642 /** 5643 * @brief Get field avdtp_cid from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_OTHER_CAPABILITY 5644 * @param event packet 5645 * @return avdtp_cid 5646 * @note: btstack_type 2 5647 */ 5648 static inline uint16_t avdtp_subevent_signaling_media_codec_other_capability_get_avdtp_cid(const uint8_t * event){ 5649 return little_endian_read_16(event, 3); 5650 } 5651 /** 5652 * @brief Get field remote_seid from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_OTHER_CAPABILITY 5653 * @param event packet 5654 * @return remote_seid 5655 * @note: btstack_type 1 5656 */ 5657 static inline uint8_t avdtp_subevent_signaling_media_codec_other_capability_get_remote_seid(const uint8_t * event){ 5658 return event[5]; 5659 } 5660 /** 5661 * @brief Get field media_type from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_OTHER_CAPABILITY 5662 * @param event packet 5663 * @return media_type 5664 * @note: btstack_type 1 5665 */ 5666 static inline uint8_t avdtp_subevent_signaling_media_codec_other_capability_get_media_type(const uint8_t * event){ 5667 return event[6]; 5668 } 5669 /** 5670 * @brief Get field media_codec_type from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_OTHER_CAPABILITY 5671 * @param event packet 5672 * @return media_codec_type 5673 * @note: btstack_type 2 5674 */ 5675 static inline uint16_t avdtp_subevent_signaling_media_codec_other_capability_get_media_codec_type(const uint8_t * event){ 5676 return little_endian_read_16(event, 7); 5677 } 5678 /** 5679 * @brief Get field media_codec_information_len from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_OTHER_CAPABILITY 5680 * @param event packet 5681 * @return media_codec_information_len 5682 * @note: btstack_type L 5683 */ 5684 static inline uint16_t avdtp_subevent_signaling_media_codec_other_capability_get_media_codec_information_len(const uint8_t * event){ 5685 return little_endian_read_16(event, 9); 5686 } 5687 /** 5688 * @brief Get field media_codec_information from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_OTHER_CAPABILITY 5689 * @param event packet 5690 * @return media_codec_information 5691 * @note: btstack_type V 5692 */ 5693 static inline const uint8_t * avdtp_subevent_signaling_media_codec_other_capability_get_media_codec_information(const uint8_t * event){ 5694 return &event[11]; 5695 } 5696 5697 /** 5698 * @brief Get field avdtp_cid from event AVDTP_SUBEVENT_SIGNALING_MEDIA_TRANSPORT_CAPABILITY 5699 * @param event packet 5700 * @return avdtp_cid 5701 * @note: btstack_type 2 5702 */ 5703 static inline uint16_t avdtp_subevent_signaling_media_transport_capability_get_avdtp_cid(const uint8_t * event){ 5704 return little_endian_read_16(event, 3); 5705 } 5706 /** 5707 * @brief Get field remote_seid from event AVDTP_SUBEVENT_SIGNALING_MEDIA_TRANSPORT_CAPABILITY 5708 * @param event packet 5709 * @return remote_seid 5710 * @note: btstack_type 1 5711 */ 5712 static inline uint8_t avdtp_subevent_signaling_media_transport_capability_get_remote_seid(const uint8_t * event){ 5713 return event[5]; 5714 } 5715 5716 /** 5717 * @brief Get field avdtp_cid from event AVDTP_SUBEVENT_SIGNALING_REPORTING_CAPABILITY 5718 * @param event packet 5719 * @return avdtp_cid 5720 * @note: btstack_type 2 5721 */ 5722 static inline uint16_t avdtp_subevent_signaling_reporting_capability_get_avdtp_cid(const uint8_t * event){ 5723 return little_endian_read_16(event, 3); 5724 } 5725 /** 5726 * @brief Get field remote_seid from event AVDTP_SUBEVENT_SIGNALING_REPORTING_CAPABILITY 5727 * @param event packet 5728 * @return remote_seid 5729 * @note: btstack_type 1 5730 */ 5731 static inline uint8_t avdtp_subevent_signaling_reporting_capability_get_remote_seid(const uint8_t * event){ 5732 return event[5]; 5733 } 5734 5735 /** 5736 * @brief Get field avdtp_cid from event AVDTP_SUBEVENT_SIGNALING_RECOVERY_CAPABILITY 5737 * @param event packet 5738 * @return avdtp_cid 5739 * @note: btstack_type 2 5740 */ 5741 static inline uint16_t avdtp_subevent_signaling_recovery_capability_get_avdtp_cid(const uint8_t * event){ 5742 return little_endian_read_16(event, 3); 5743 } 5744 /** 5745 * @brief Get field remote_seid from event AVDTP_SUBEVENT_SIGNALING_RECOVERY_CAPABILITY 5746 * @param event packet 5747 * @return remote_seid 5748 * @note: btstack_type 1 5749 */ 5750 static inline uint8_t avdtp_subevent_signaling_recovery_capability_get_remote_seid(const uint8_t * event){ 5751 return event[5]; 5752 } 5753 /** 5754 * @brief Get field recovery_type from event AVDTP_SUBEVENT_SIGNALING_RECOVERY_CAPABILITY 5755 * @param event packet 5756 * @return recovery_type 5757 * @note: btstack_type 1 5758 */ 5759 static inline uint8_t avdtp_subevent_signaling_recovery_capability_get_recovery_type(const uint8_t * event){ 5760 return event[6]; 5761 } 5762 /** 5763 * @brief Get field maximum_recovery_window_size from event AVDTP_SUBEVENT_SIGNALING_RECOVERY_CAPABILITY 5764 * @param event packet 5765 * @return maximum_recovery_window_size 5766 * @note: btstack_type 1 5767 */ 5768 static inline uint8_t avdtp_subevent_signaling_recovery_capability_get_maximum_recovery_window_size(const uint8_t * event){ 5769 return event[7]; 5770 } 5771 /** 5772 * @brief Get field maximum_number_media_packets from event AVDTP_SUBEVENT_SIGNALING_RECOVERY_CAPABILITY 5773 * @param event packet 5774 * @return maximum_number_media_packets 5775 * @note: btstack_type 1 5776 */ 5777 static inline uint8_t avdtp_subevent_signaling_recovery_capability_get_maximum_number_media_packets(const uint8_t * event){ 5778 return event[8]; 5779 } 5780 5781 /** 5782 * @brief Get field avdtp_cid from event AVDTP_SUBEVENT_SIGNALING_CONTENT_PROTECTION_CAPABILITY 5783 * @param event packet 5784 * @return avdtp_cid 5785 * @note: btstack_type 2 5786 */ 5787 static inline uint16_t avdtp_subevent_signaling_content_protection_capability_get_avdtp_cid(const uint8_t * event){ 5788 return little_endian_read_16(event, 3); 5789 } 5790 /** 5791 * @brief Get field remote_seid from event AVDTP_SUBEVENT_SIGNALING_CONTENT_PROTECTION_CAPABILITY 5792 * @param event packet 5793 * @return remote_seid 5794 * @note: btstack_type 1 5795 */ 5796 static inline uint8_t avdtp_subevent_signaling_content_protection_capability_get_remote_seid(const uint8_t * event){ 5797 return event[5]; 5798 } 5799 /** 5800 * @brief Get field cp_type from event AVDTP_SUBEVENT_SIGNALING_CONTENT_PROTECTION_CAPABILITY 5801 * @param event packet 5802 * @return cp_type 5803 * @note: btstack_type 2 5804 */ 5805 static inline uint16_t avdtp_subevent_signaling_content_protection_capability_get_cp_type(const uint8_t * event){ 5806 return little_endian_read_16(event, 6); 5807 } 5808 /** 5809 * @brief Get field cp_type_value_len from event AVDTP_SUBEVENT_SIGNALING_CONTENT_PROTECTION_CAPABILITY 5810 * @param event packet 5811 * @return cp_type_value_len 5812 * @note: btstack_type L 5813 */ 5814 static inline uint16_t avdtp_subevent_signaling_content_protection_capability_get_cp_type_value_len(const uint8_t * event){ 5815 return little_endian_read_16(event, 8); 5816 } 5817 /** 5818 * @brief Get field cp_type_value from event AVDTP_SUBEVENT_SIGNALING_CONTENT_PROTECTION_CAPABILITY 5819 * @param event packet 5820 * @return cp_type_value 5821 * @note: btstack_type V 5822 */ 5823 static inline const uint8_t * avdtp_subevent_signaling_content_protection_capability_get_cp_type_value(const uint8_t * event){ 5824 return &event[10]; 5825 } 5826 5827 /** 5828 * @brief Get field avdtp_cid from event AVDTP_SUBEVENT_SIGNALING_MULTIPLEXING_CAPABILITY 5829 * @param event packet 5830 * @return avdtp_cid 5831 * @note: btstack_type 2 5832 */ 5833 static inline uint16_t avdtp_subevent_signaling_multiplexing_capability_get_avdtp_cid(const uint8_t * event){ 5834 return little_endian_read_16(event, 3); 5835 } 5836 /** 5837 * @brief Get field remote_seid from event AVDTP_SUBEVENT_SIGNALING_MULTIPLEXING_CAPABILITY 5838 * @param event packet 5839 * @return remote_seid 5840 * @note: btstack_type 1 5841 */ 5842 static inline uint8_t avdtp_subevent_signaling_multiplexing_capability_get_remote_seid(const uint8_t * event){ 5843 return event[5]; 5844 } 5845 /** 5846 * @brief Get field fragmentation from event AVDTP_SUBEVENT_SIGNALING_MULTIPLEXING_CAPABILITY 5847 * @param event packet 5848 * @return fragmentation 5849 * @note: btstack_type 1 5850 */ 5851 static inline uint8_t avdtp_subevent_signaling_multiplexing_capability_get_fragmentation(const uint8_t * event){ 5852 return event[6]; 5853 } 5854 /** 5855 * @brief Get field transport_identifiers_num from event AVDTP_SUBEVENT_SIGNALING_MULTIPLEXING_CAPABILITY 5856 * @param event packet 5857 * @return transport_identifiers_num 5858 * @note: btstack_type 1 5859 */ 5860 static inline uint8_t avdtp_subevent_signaling_multiplexing_capability_get_transport_identifiers_num(const uint8_t * event){ 5861 return event[7]; 5862 } 5863 /** 5864 * @brief Get field transport_session_identifier_1 from event AVDTP_SUBEVENT_SIGNALING_MULTIPLEXING_CAPABILITY 5865 * @param event packet 5866 * @return transport_session_identifier_1 5867 * @note: btstack_type 1 5868 */ 5869 static inline uint8_t avdtp_subevent_signaling_multiplexing_capability_get_transport_session_identifier_1(const uint8_t * event){ 5870 return event[8]; 5871 } 5872 /** 5873 * @brief Get field transport_session_identifier_2 from event AVDTP_SUBEVENT_SIGNALING_MULTIPLEXING_CAPABILITY 5874 * @param event packet 5875 * @return transport_session_identifier_2 5876 * @note: btstack_type 1 5877 */ 5878 static inline uint8_t avdtp_subevent_signaling_multiplexing_capability_get_transport_session_identifier_2(const uint8_t * event){ 5879 return event[9]; 5880 } 5881 /** 5882 * @brief Get field transport_session_identifier_3 from event AVDTP_SUBEVENT_SIGNALING_MULTIPLEXING_CAPABILITY 5883 * @param event packet 5884 * @return transport_session_identifier_3 5885 * @note: btstack_type 1 5886 */ 5887 static inline uint8_t avdtp_subevent_signaling_multiplexing_capability_get_transport_session_identifier_3(const uint8_t * event){ 5888 return event[10]; 5889 } 5890 /** 5891 * @brief Get field tcid_1 from event AVDTP_SUBEVENT_SIGNALING_MULTIPLEXING_CAPABILITY 5892 * @param event packet 5893 * @return tcid_1 5894 * @note: btstack_type 1 5895 */ 5896 static inline uint8_t avdtp_subevent_signaling_multiplexing_capability_get_tcid_1(const uint8_t * event){ 5897 return event[11]; 5898 } 5899 /** 5900 * @brief Get field tcid_2 from event AVDTP_SUBEVENT_SIGNALING_MULTIPLEXING_CAPABILITY 5901 * @param event packet 5902 * @return tcid_2 5903 * @note: btstack_type 1 5904 */ 5905 static inline uint8_t avdtp_subevent_signaling_multiplexing_capability_get_tcid_2(const uint8_t * event){ 5906 return event[12]; 5907 } 5908 /** 5909 * @brief Get field tcid_3 from event AVDTP_SUBEVENT_SIGNALING_MULTIPLEXING_CAPABILITY 5910 * @param event packet 5911 * @return tcid_3 5912 * @note: btstack_type 1 5913 */ 5914 static inline uint8_t avdtp_subevent_signaling_multiplexing_capability_get_tcid_3(const uint8_t * event){ 5915 return event[13]; 5916 } 5917 5918 /** 5919 * @brief Get field avdtp_cid from event AVDTP_SUBEVENT_SIGNALING_DELAY_REPORTING_CAPABILITY 5920 * @param event packet 5921 * @return avdtp_cid 5922 * @note: btstack_type 2 5923 */ 5924 static inline uint16_t avdtp_subevent_signaling_delay_reporting_capability_get_avdtp_cid(const uint8_t * event){ 5925 return little_endian_read_16(event, 3); 5926 } 5927 /** 5928 * @brief Get field remote_seid from event AVDTP_SUBEVENT_SIGNALING_DELAY_REPORTING_CAPABILITY 5929 * @param event packet 5930 * @return remote_seid 5931 * @note: btstack_type 1 5932 */ 5933 static inline uint8_t avdtp_subevent_signaling_delay_reporting_capability_get_remote_seid(const uint8_t * event){ 5934 return event[5]; 5935 } 5936 5937 /** 5938 * @brief Get field avdtp_cid from event AVDTP_SUBEVENT_SIGNALING_HEADER_COMPRESSION_CAPABILITY 5939 * @param event packet 5940 * @return avdtp_cid 5941 * @note: btstack_type 2 5942 */ 5943 static inline uint16_t avdtp_subevent_signaling_header_compression_capability_get_avdtp_cid(const uint8_t * event){ 5944 return little_endian_read_16(event, 3); 5945 } 5946 /** 5947 * @brief Get field remote_seid from event AVDTP_SUBEVENT_SIGNALING_HEADER_COMPRESSION_CAPABILITY 5948 * @param event packet 5949 * @return remote_seid 5950 * @note: btstack_type 1 5951 */ 5952 static inline uint8_t avdtp_subevent_signaling_header_compression_capability_get_remote_seid(const uint8_t * event){ 5953 return event[5]; 5954 } 5955 /** 5956 * @brief Get field back_ch from event AVDTP_SUBEVENT_SIGNALING_HEADER_COMPRESSION_CAPABILITY 5957 * @param event packet 5958 * @return back_ch 5959 * @note: btstack_type 1 5960 */ 5961 static inline uint8_t avdtp_subevent_signaling_header_compression_capability_get_back_ch(const uint8_t * event){ 5962 return event[6]; 5963 } 5964 /** 5965 * @brief Get field media from event AVDTP_SUBEVENT_SIGNALING_HEADER_COMPRESSION_CAPABILITY 5966 * @param event packet 5967 * @return media 5968 * @note: btstack_type 1 5969 */ 5970 static inline uint8_t avdtp_subevent_signaling_header_compression_capability_get_media(const uint8_t * event){ 5971 return event[7]; 5972 } 5973 /** 5974 * @brief Get field recovery from event AVDTP_SUBEVENT_SIGNALING_HEADER_COMPRESSION_CAPABILITY 5975 * @param event packet 5976 * @return recovery 5977 * @note: btstack_type 1 5978 */ 5979 static inline uint8_t avdtp_subevent_signaling_header_compression_capability_get_recovery(const uint8_t * event){ 5980 return event[8]; 5981 } 5982 5983 /** 5984 * @brief Get field avdtp_cid from event AVDTP_SUBEVENT_SIGNALING_CAPABILITIES_DONE 5985 * @param event packet 5986 * @return avdtp_cid 5987 * @note: btstack_type 2 5988 */ 5989 static inline uint16_t avdtp_subevent_signaling_capabilities_done_get_avdtp_cid(const uint8_t * event){ 5990 return little_endian_read_16(event, 3); 5991 } 5992 /** 5993 * @brief Get field remote_seid from event AVDTP_SUBEVENT_SIGNALING_CAPABILITIES_DONE 5994 * @param event packet 5995 * @return remote_seid 5996 * @note: btstack_type 1 5997 */ 5998 static inline uint8_t avdtp_subevent_signaling_capabilities_done_get_remote_seid(const uint8_t * event){ 5999 return event[5]; 6000 } 6001 6002 /** 6003 * @brief Get field avdtp_cid from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CONFIGURATION 6004 * @param event packet 6005 * @return avdtp_cid 6006 * @note: btstack_type 2 6007 */ 6008 static inline uint16_t avdtp_subevent_signaling_media_codec_sbc_configuration_get_avdtp_cid(const uint8_t * event){ 6009 return little_endian_read_16(event, 3); 6010 } 6011 /** 6012 * @brief Get field local_seid from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CONFIGURATION 6013 * @param event packet 6014 * @return local_seid 6015 * @note: btstack_type 1 6016 */ 6017 static inline uint8_t avdtp_subevent_signaling_media_codec_sbc_configuration_get_local_seid(const uint8_t * event){ 6018 return event[5]; 6019 } 6020 /** 6021 * @brief Get field remote_seid from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CONFIGURATION 6022 * @param event packet 6023 * @return remote_seid 6024 * @note: btstack_type 1 6025 */ 6026 static inline uint8_t avdtp_subevent_signaling_media_codec_sbc_configuration_get_remote_seid(const uint8_t * event){ 6027 return event[6]; 6028 } 6029 /** 6030 * @brief Get field reconfigure from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CONFIGURATION 6031 * @param event packet 6032 * @return reconfigure 6033 * @note: btstack_type 1 6034 */ 6035 static inline uint8_t avdtp_subevent_signaling_media_codec_sbc_configuration_get_reconfigure(const uint8_t * event){ 6036 return event[7]; 6037 } 6038 /** 6039 * @brief Get field media_type from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CONFIGURATION 6040 * @param event packet 6041 * @return media_type 6042 * @note: btstack_type 1 6043 */ 6044 static inline uint8_t avdtp_subevent_signaling_media_codec_sbc_configuration_get_media_type(const uint8_t * event){ 6045 return event[8]; 6046 } 6047 /** 6048 * @brief Get field sampling_frequency from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CONFIGURATION 6049 * @param event packet 6050 * @return sampling_frequency 6051 * @note: btstack_type 2 6052 */ 6053 static inline uint16_t avdtp_subevent_signaling_media_codec_sbc_configuration_get_sampling_frequency(const uint8_t * event){ 6054 return little_endian_read_16(event, 9); 6055 } 6056 /** 6057 * @brief Get field channel_mode from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CONFIGURATION 6058 * @param event packet 6059 * @return channel_mode 6060 * @note: btstack_type 1 6061 */ 6062 static inline uint8_t avdtp_subevent_signaling_media_codec_sbc_configuration_get_channel_mode(const uint8_t * event){ 6063 return event[11]; 6064 } 6065 /** 6066 * @brief Get field num_channels from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CONFIGURATION 6067 * @param event packet 6068 * @return num_channels 6069 * @note: btstack_type 1 6070 */ 6071 static inline uint8_t avdtp_subevent_signaling_media_codec_sbc_configuration_get_num_channels(const uint8_t * event){ 6072 return event[12]; 6073 } 6074 /** 6075 * @brief Get field block_length from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CONFIGURATION 6076 * @param event packet 6077 * @return block_length 6078 * @note: btstack_type 1 6079 */ 6080 static inline uint8_t avdtp_subevent_signaling_media_codec_sbc_configuration_get_block_length(const uint8_t * event){ 6081 return event[13]; 6082 } 6083 /** 6084 * @brief Get field subbands from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CONFIGURATION 6085 * @param event packet 6086 * @return subbands 6087 * @note: btstack_type 1 6088 */ 6089 static inline uint8_t avdtp_subevent_signaling_media_codec_sbc_configuration_get_subbands(const uint8_t * event){ 6090 return event[14]; 6091 } 6092 /** 6093 * @brief Get field allocation_method from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CONFIGURATION 6094 * @param event packet 6095 * @return allocation_method 6096 * @note: btstack_type 1 6097 */ 6098 static inline uint8_t avdtp_subevent_signaling_media_codec_sbc_configuration_get_allocation_method(const uint8_t * event){ 6099 return event[15]; 6100 } 6101 /** 6102 * @brief Get field min_bitpool_value from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CONFIGURATION 6103 * @param event packet 6104 * @return min_bitpool_value 6105 * @note: btstack_type 1 6106 */ 6107 static inline uint8_t avdtp_subevent_signaling_media_codec_sbc_configuration_get_min_bitpool_value(const uint8_t * event){ 6108 return event[16]; 6109 } 6110 /** 6111 * @brief Get field max_bitpool_value from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CONFIGURATION 6112 * @param event packet 6113 * @return max_bitpool_value 6114 * @note: btstack_type 1 6115 */ 6116 static inline uint8_t avdtp_subevent_signaling_media_codec_sbc_configuration_get_max_bitpool_value(const uint8_t * event){ 6117 return event[17]; 6118 } 6119 6120 /** 6121 * @brief Get field avdtp_cid from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CONFIGURATION 6122 * @param event packet 6123 * @return avdtp_cid 6124 * @note: btstack_type 2 6125 */ 6126 static inline uint16_t avdtp_subevent_signaling_media_codec_mpeg_audio_configuration_get_avdtp_cid(const uint8_t * event){ 6127 return little_endian_read_16(event, 3); 6128 } 6129 /** 6130 * @brief Get field local_seid from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CONFIGURATION 6131 * @param event packet 6132 * @return local_seid 6133 * @note: btstack_type 1 6134 */ 6135 static inline uint8_t avdtp_subevent_signaling_media_codec_mpeg_audio_configuration_get_local_seid(const uint8_t * event){ 6136 return event[5]; 6137 } 6138 /** 6139 * @brief Get field remote_seid from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CONFIGURATION 6140 * @param event packet 6141 * @return remote_seid 6142 * @note: btstack_type 1 6143 */ 6144 static inline uint8_t avdtp_subevent_signaling_media_codec_mpeg_audio_configuration_get_remote_seid(const uint8_t * event){ 6145 return event[6]; 6146 } 6147 /** 6148 * @brief Get field reconfigure from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CONFIGURATION 6149 * @param event packet 6150 * @return reconfigure 6151 * @note: btstack_type 1 6152 */ 6153 static inline uint8_t avdtp_subevent_signaling_media_codec_mpeg_audio_configuration_get_reconfigure(const uint8_t * event){ 6154 return event[7]; 6155 } 6156 /** 6157 * @brief Get field media_type from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CONFIGURATION 6158 * @param event packet 6159 * @return media_type 6160 * @note: btstack_type 1 6161 */ 6162 static inline uint8_t avdtp_subevent_signaling_media_codec_mpeg_audio_configuration_get_media_type(const uint8_t * event){ 6163 return event[8]; 6164 } 6165 /** 6166 * @brief Get field layer from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CONFIGURATION 6167 * @param event packet 6168 * @return layer 6169 * @note: btstack_type 1 6170 */ 6171 static inline uint8_t avdtp_subevent_signaling_media_codec_mpeg_audio_configuration_get_layer(const uint8_t * event){ 6172 return event[9]; 6173 } 6174 /** 6175 * @brief Get field crc from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CONFIGURATION 6176 * @param event packet 6177 * @return crc 6178 * @note: btstack_type 1 6179 */ 6180 static inline uint8_t avdtp_subevent_signaling_media_codec_mpeg_audio_configuration_get_crc(const uint8_t * event){ 6181 return event[10]; 6182 } 6183 /** 6184 * @brief Get field channel_mode from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CONFIGURATION 6185 * @param event packet 6186 * @return channel_mode 6187 * @note: btstack_type 1 6188 */ 6189 static inline uint8_t avdtp_subevent_signaling_media_codec_mpeg_audio_configuration_get_channel_mode(const uint8_t * event){ 6190 return event[11]; 6191 } 6192 /** 6193 * @brief Get field num_channels from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CONFIGURATION 6194 * @param event packet 6195 * @return num_channels 6196 * @note: btstack_type 1 6197 */ 6198 static inline uint8_t avdtp_subevent_signaling_media_codec_mpeg_audio_configuration_get_num_channels(const uint8_t * event){ 6199 return event[12]; 6200 } 6201 /** 6202 * @brief Get field media_payload_format from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CONFIGURATION 6203 * @param event packet 6204 * @return media_payload_format 6205 * @note: btstack_type 1 6206 */ 6207 static inline uint8_t avdtp_subevent_signaling_media_codec_mpeg_audio_configuration_get_media_payload_format(const uint8_t * event){ 6208 return event[13]; 6209 } 6210 /** 6211 * @brief Get field sampling_frequency from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CONFIGURATION 6212 * @param event packet 6213 * @return sampling_frequency 6214 * @note: btstack_type 2 6215 */ 6216 static inline uint16_t avdtp_subevent_signaling_media_codec_mpeg_audio_configuration_get_sampling_frequency(const uint8_t * event){ 6217 return little_endian_read_16(event, 14); 6218 } 6219 /** 6220 * @brief Get field vbr from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CONFIGURATION 6221 * @param event packet 6222 * @return vbr 6223 * @note: btstack_type 1 6224 */ 6225 static inline uint8_t avdtp_subevent_signaling_media_codec_mpeg_audio_configuration_get_vbr(const uint8_t * event){ 6226 return event[16]; 6227 } 6228 /** 6229 * @brief Get field bit_rate_index from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CONFIGURATION 6230 * @param event packet 6231 * @return bit_rate_index 6232 * @note: btstack_type 1 6233 */ 6234 static inline uint8_t avdtp_subevent_signaling_media_codec_mpeg_audio_configuration_get_bit_rate_index(const uint8_t * event){ 6235 return event[17]; 6236 } 6237 6238 /** 6239 * @brief Get field avdtp_cid from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CONFIGURATION 6240 * @param event packet 6241 * @return avdtp_cid 6242 * @note: btstack_type 2 6243 */ 6244 static inline uint16_t avdtp_subevent_signaling_media_codec_mpeg_aac_configuration_get_avdtp_cid(const uint8_t * event){ 6245 return little_endian_read_16(event, 3); 6246 } 6247 /** 6248 * @brief Get field local_seid from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CONFIGURATION 6249 * @param event packet 6250 * @return local_seid 6251 * @note: btstack_type 1 6252 */ 6253 static inline uint8_t avdtp_subevent_signaling_media_codec_mpeg_aac_configuration_get_local_seid(const uint8_t * event){ 6254 return event[5]; 6255 } 6256 /** 6257 * @brief Get field remote_seid from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CONFIGURATION 6258 * @param event packet 6259 * @return remote_seid 6260 * @note: btstack_type 1 6261 */ 6262 static inline uint8_t avdtp_subevent_signaling_media_codec_mpeg_aac_configuration_get_remote_seid(const uint8_t * event){ 6263 return event[6]; 6264 } 6265 /** 6266 * @brief Get field reconfigure from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CONFIGURATION 6267 * @param event packet 6268 * @return reconfigure 6269 * @note: btstack_type 1 6270 */ 6271 static inline uint8_t avdtp_subevent_signaling_media_codec_mpeg_aac_configuration_get_reconfigure(const uint8_t * event){ 6272 return event[7]; 6273 } 6274 /** 6275 * @brief Get field media_type from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CONFIGURATION 6276 * @param event packet 6277 * @return media_type 6278 * @note: btstack_type 1 6279 */ 6280 static inline uint8_t avdtp_subevent_signaling_media_codec_mpeg_aac_configuration_get_media_type(const uint8_t * event){ 6281 return event[8]; 6282 } 6283 /** 6284 * @brief Get field object_type from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CONFIGURATION 6285 * @param event packet 6286 * @return object_type 6287 * @note: btstack_type 1 6288 */ 6289 static inline uint8_t avdtp_subevent_signaling_media_codec_mpeg_aac_configuration_get_object_type(const uint8_t * event){ 6290 return event[9]; 6291 } 6292 /** 6293 * @brief Get field sampling_frequency from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CONFIGURATION 6294 * @param event packet 6295 * @return sampling_frequency 6296 * @note: btstack_type 3 6297 */ 6298 static inline uint32_t avdtp_subevent_signaling_media_codec_mpeg_aac_configuration_get_sampling_frequency(const uint8_t * event){ 6299 return little_endian_read_24(event, 10); 6300 } 6301 /** 6302 * @brief Get field num_channels from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CONFIGURATION 6303 * @param event packet 6304 * @return num_channels 6305 * @note: btstack_type 1 6306 */ 6307 static inline uint8_t avdtp_subevent_signaling_media_codec_mpeg_aac_configuration_get_num_channels(const uint8_t * event){ 6308 return event[13]; 6309 } 6310 /** 6311 * @brief Get field bit_rate from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CONFIGURATION 6312 * @param event packet 6313 * @return bit_rate 6314 * @note: btstack_type 3 6315 */ 6316 static inline uint32_t avdtp_subevent_signaling_media_codec_mpeg_aac_configuration_get_bit_rate(const uint8_t * event){ 6317 return little_endian_read_24(event, 14); 6318 } 6319 /** 6320 * @brief Get field vbr from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CONFIGURATION 6321 * @param event packet 6322 * @return vbr 6323 * @note: btstack_type 1 6324 */ 6325 static inline uint8_t avdtp_subevent_signaling_media_codec_mpeg_aac_configuration_get_vbr(const uint8_t * event){ 6326 return event[17]; 6327 } 6328 6329 /** 6330 * @brief Get field avdtp_cid from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CONFIGURATION 6331 * @param event packet 6332 * @return avdtp_cid 6333 * @note: btstack_type 2 6334 */ 6335 static inline uint16_t avdtp_subevent_signaling_media_codec_atrac_configuration_get_avdtp_cid(const uint8_t * event){ 6336 return little_endian_read_16(event, 3); 6337 } 6338 /** 6339 * @brief Get field local_seid from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CONFIGURATION 6340 * @param event packet 6341 * @return local_seid 6342 * @note: btstack_type 1 6343 */ 6344 static inline uint8_t avdtp_subevent_signaling_media_codec_atrac_configuration_get_local_seid(const uint8_t * event){ 6345 return event[5]; 6346 } 6347 /** 6348 * @brief Get field remote_seid from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CONFIGURATION 6349 * @param event packet 6350 * @return remote_seid 6351 * @note: btstack_type 1 6352 */ 6353 static inline uint8_t avdtp_subevent_signaling_media_codec_atrac_configuration_get_remote_seid(const uint8_t * event){ 6354 return event[6]; 6355 } 6356 /** 6357 * @brief Get field reconfigure from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CONFIGURATION 6358 * @param event packet 6359 * @return reconfigure 6360 * @note: btstack_type 1 6361 */ 6362 static inline uint8_t avdtp_subevent_signaling_media_codec_atrac_configuration_get_reconfigure(const uint8_t * event){ 6363 return event[7]; 6364 } 6365 /** 6366 * @brief Get field media_type from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CONFIGURATION 6367 * @param event packet 6368 * @return media_type 6369 * @note: btstack_type 1 6370 */ 6371 static inline uint8_t avdtp_subevent_signaling_media_codec_atrac_configuration_get_media_type(const uint8_t * event){ 6372 return event[8]; 6373 } 6374 /** 6375 * @brief Get field version from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CONFIGURATION 6376 * @param event packet 6377 * @return version 6378 * @note: btstack_type 1 6379 */ 6380 static inline uint8_t avdtp_subevent_signaling_media_codec_atrac_configuration_get_version(const uint8_t * event){ 6381 return event[9]; 6382 } 6383 /** 6384 * @brief Get field channel_mode from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CONFIGURATION 6385 * @param event packet 6386 * @return channel_mode 6387 * @note: btstack_type 1 6388 */ 6389 static inline uint8_t avdtp_subevent_signaling_media_codec_atrac_configuration_get_channel_mode(const uint8_t * event){ 6390 return event[10]; 6391 } 6392 /** 6393 * @brief Get field num_channels from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CONFIGURATION 6394 * @param event packet 6395 * @return num_channels 6396 * @note: btstack_type 1 6397 */ 6398 static inline uint8_t avdtp_subevent_signaling_media_codec_atrac_configuration_get_num_channels(const uint8_t * event){ 6399 return event[11]; 6400 } 6401 /** 6402 * @brief Get field sampling_frequency from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CONFIGURATION 6403 * @param event packet 6404 * @return sampling_frequency 6405 * @note: btstack_type 2 6406 */ 6407 static inline uint16_t avdtp_subevent_signaling_media_codec_atrac_configuration_get_sampling_frequency(const uint8_t * event){ 6408 return little_endian_read_16(event, 12); 6409 } 6410 /** 6411 * @brief Get field vbr from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CONFIGURATION 6412 * @param event packet 6413 * @return vbr 6414 * @note: btstack_type 1 6415 */ 6416 static inline uint8_t avdtp_subevent_signaling_media_codec_atrac_configuration_get_vbr(const uint8_t * event){ 6417 return event[14]; 6418 } 6419 /** 6420 * @brief Get field bit_rate_index from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CONFIGURATION 6421 * @param event packet 6422 * @return bit_rate_index 6423 * @note: btstack_type 1 6424 */ 6425 static inline uint8_t avdtp_subevent_signaling_media_codec_atrac_configuration_get_bit_rate_index(const uint8_t * event){ 6426 return event[15]; 6427 } 6428 /** 6429 * @brief Get field maximum_sul from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CONFIGURATION 6430 * @param event packet 6431 * @return maximum_sul 6432 * @note: btstack_type 2 6433 */ 6434 static inline uint16_t avdtp_subevent_signaling_media_codec_atrac_configuration_get_maximum_sul(const uint8_t * event){ 6435 return little_endian_read_16(event, 16); 6436 } 6437 6438 /** 6439 * @brief Get field avdtp_cid from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_OTHER_CONFIGURATION 6440 * @param event packet 6441 * @return avdtp_cid 6442 * @note: btstack_type 2 6443 */ 6444 static inline uint16_t avdtp_subevent_signaling_media_codec_other_configuration_get_avdtp_cid(const uint8_t * event){ 6445 return little_endian_read_16(event, 3); 6446 } 6447 /** 6448 * @brief Get field local_seid from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_OTHER_CONFIGURATION 6449 * @param event packet 6450 * @return local_seid 6451 * @note: btstack_type 1 6452 */ 6453 static inline uint8_t avdtp_subevent_signaling_media_codec_other_configuration_get_local_seid(const uint8_t * event){ 6454 return event[5]; 6455 } 6456 /** 6457 * @brief Get field remote_seid from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_OTHER_CONFIGURATION 6458 * @param event packet 6459 * @return remote_seid 6460 * @note: btstack_type 1 6461 */ 6462 static inline uint8_t avdtp_subevent_signaling_media_codec_other_configuration_get_remote_seid(const uint8_t * event){ 6463 return event[6]; 6464 } 6465 /** 6466 * @brief Get field reconfigure from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_OTHER_CONFIGURATION 6467 * @param event packet 6468 * @return reconfigure 6469 * @note: btstack_type 1 6470 */ 6471 static inline uint8_t avdtp_subevent_signaling_media_codec_other_configuration_get_reconfigure(const uint8_t * event){ 6472 return event[7]; 6473 } 6474 /** 6475 * @brief Get field media_type from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_OTHER_CONFIGURATION 6476 * @param event packet 6477 * @return media_type 6478 * @note: btstack_type 1 6479 */ 6480 static inline uint8_t avdtp_subevent_signaling_media_codec_other_configuration_get_media_type(const uint8_t * event){ 6481 return event[8]; 6482 } 6483 /** 6484 * @brief Get field media_codec_type from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_OTHER_CONFIGURATION 6485 * @param event packet 6486 * @return media_codec_type 6487 * @note: btstack_type 2 6488 */ 6489 static inline uint16_t avdtp_subevent_signaling_media_codec_other_configuration_get_media_codec_type(const uint8_t * event){ 6490 return little_endian_read_16(event, 9); 6491 } 6492 /** 6493 * @brief Get field media_codec_information_len from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_OTHER_CONFIGURATION 6494 * @param event packet 6495 * @return media_codec_information_len 6496 * @note: btstack_type L 6497 */ 6498 static inline uint16_t avdtp_subevent_signaling_media_codec_other_configuration_get_media_codec_information_len(const uint8_t * event){ 6499 return little_endian_read_16(event, 11); 6500 } 6501 /** 6502 * @brief Get field media_codec_information from event AVDTP_SUBEVENT_SIGNALING_MEDIA_CODEC_OTHER_CONFIGURATION 6503 * @param event packet 6504 * @return media_codec_information 6505 * @note: btstack_type V 6506 */ 6507 static inline const uint8_t * avdtp_subevent_signaling_media_codec_other_configuration_get_media_codec_information(const uint8_t * event){ 6508 return &event[13]; 6509 } 6510 6511 /** 6512 * @brief Get field avdtp_cid from event AVDTP_SUBEVENT_STREAMING_CONNECTION_ESTABLISHED 6513 * @param event packet 6514 * @return avdtp_cid 6515 * @note: btstack_type 2 6516 */ 6517 static inline uint16_t avdtp_subevent_streaming_connection_established_get_avdtp_cid(const uint8_t * event){ 6518 return little_endian_read_16(event, 3); 6519 } 6520 /** 6521 * @brief Get field bd_addr from event AVDTP_SUBEVENT_STREAMING_CONNECTION_ESTABLISHED 6522 * @param event packet 6523 * @param Pointer to storage for bd_addr 6524 * @note: btstack_type B 6525 */ 6526 static inline void avdtp_subevent_streaming_connection_established_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 6527 reverse_bytes(&event[5], bd_addr, 6); 6528 } 6529 /** 6530 * @brief Get field local_seid from event AVDTP_SUBEVENT_STREAMING_CONNECTION_ESTABLISHED 6531 * @param event packet 6532 * @return local_seid 6533 * @note: btstack_type 1 6534 */ 6535 static inline uint8_t avdtp_subevent_streaming_connection_established_get_local_seid(const uint8_t * event){ 6536 return event[11]; 6537 } 6538 /** 6539 * @brief Get field remote_seid from event AVDTP_SUBEVENT_STREAMING_CONNECTION_ESTABLISHED 6540 * @param event packet 6541 * @return remote_seid 6542 * @note: btstack_type 1 6543 */ 6544 static inline uint8_t avdtp_subevent_streaming_connection_established_get_remote_seid(const uint8_t * event){ 6545 return event[12]; 6546 } 6547 /** 6548 * @brief Get field status from event AVDTP_SUBEVENT_STREAMING_CONNECTION_ESTABLISHED 6549 * @param event packet 6550 * @return status 6551 * @note: btstack_type 1 6552 */ 6553 static inline uint8_t avdtp_subevent_streaming_connection_established_get_status(const uint8_t * event){ 6554 return event[13]; 6555 } 6556 6557 /** 6558 * @brief Get field avdtp_cid from event AVDTP_SUBEVENT_STREAMING_CONNECTION_RELEASED 6559 * @param event packet 6560 * @return avdtp_cid 6561 * @note: btstack_type 2 6562 */ 6563 static inline uint16_t avdtp_subevent_streaming_connection_released_get_avdtp_cid(const uint8_t * event){ 6564 return little_endian_read_16(event, 3); 6565 } 6566 /** 6567 * @brief Get field local_seid from event AVDTP_SUBEVENT_STREAMING_CONNECTION_RELEASED 6568 * @param event packet 6569 * @return local_seid 6570 * @note: btstack_type 1 6571 */ 6572 static inline uint8_t avdtp_subevent_streaming_connection_released_get_local_seid(const uint8_t * event){ 6573 return event[5]; 6574 } 6575 6576 /** 6577 * @brief Get field avdtp_cid from event AVDTP_SUBEVENT_STREAMING_CAN_SEND_MEDIA_PACKET_NOW 6578 * @param event packet 6579 * @return avdtp_cid 6580 * @note: btstack_type 2 6581 */ 6582 static inline uint16_t avdtp_subevent_streaming_can_send_media_packet_now_get_avdtp_cid(const uint8_t * event){ 6583 return little_endian_read_16(event, 3); 6584 } 6585 /** 6586 * @brief Get field local_seid from event AVDTP_SUBEVENT_STREAMING_CAN_SEND_MEDIA_PACKET_NOW 6587 * @param event packet 6588 * @return local_seid 6589 * @note: btstack_type 1 6590 */ 6591 static inline uint8_t avdtp_subevent_streaming_can_send_media_packet_now_get_local_seid(const uint8_t * event){ 6592 return event[5]; 6593 } 6594 /** 6595 * @brief Get field sequence_number from event AVDTP_SUBEVENT_STREAMING_CAN_SEND_MEDIA_PACKET_NOW 6596 * @param event packet 6597 * @return sequence_number 6598 * @note: btstack_type 2 6599 */ 6600 static inline uint16_t avdtp_subevent_streaming_can_send_media_packet_now_get_sequence_number(const uint8_t * event){ 6601 return little_endian_read_16(event, 6); 6602 } 6603 6604 /** 6605 * @brief Get field avdtp_cid from event AVDTP_SUBEVENT_SIGNALING_SEP_DICOVERY_DONE 6606 * @param event packet 6607 * @return avdtp_cid 6608 * @note: btstack_type 2 6609 */ 6610 static inline uint16_t avdtp_subevent_signaling_sep_dicovery_done_get_avdtp_cid(const uint8_t * event){ 6611 return little_endian_read_16(event, 3); 6612 } 6613 6614 /** 6615 * @brief Get field avdtp_cid from event AVDTP_SUBEVENT_SIGNALING_DELAY_REPORT 6616 * @param event packet 6617 * @return avdtp_cid 6618 * @note: btstack_type 2 6619 */ 6620 static inline uint16_t avdtp_subevent_signaling_delay_report_get_avdtp_cid(const uint8_t * event){ 6621 return little_endian_read_16(event, 3); 6622 } 6623 /** 6624 * @brief Get field local_seid from event AVDTP_SUBEVENT_SIGNALING_DELAY_REPORT 6625 * @param event packet 6626 * @return local_seid 6627 * @note: btstack_type 1 6628 */ 6629 static inline uint8_t avdtp_subevent_signaling_delay_report_get_local_seid(const uint8_t * event){ 6630 return event[5]; 6631 } 6632 /** 6633 * @brief Get field delay_100us from event AVDTP_SUBEVENT_SIGNALING_DELAY_REPORT 6634 * @param event packet 6635 * @return delay_100us 6636 * @note: btstack_type 2 6637 */ 6638 static inline uint16_t avdtp_subevent_signaling_delay_report_get_delay_100us(const uint8_t * event){ 6639 return little_endian_read_16(event, 6); 6640 } 6641 6642 /** 6643 * @brief Get field a2dp_cid from event A2DP_SUBEVENT_STREAMING_CAN_SEND_MEDIA_PACKET_NOW 6644 * @param event packet 6645 * @return a2dp_cid 6646 * @note: btstack_type 2 6647 */ 6648 static inline uint16_t a2dp_subevent_streaming_can_send_media_packet_now_get_a2dp_cid(const uint8_t * event){ 6649 return little_endian_read_16(event, 3); 6650 } 6651 /** 6652 * @brief Get field local_seid from event A2DP_SUBEVENT_STREAMING_CAN_SEND_MEDIA_PACKET_NOW 6653 * @param event packet 6654 * @return local_seid 6655 * @note: btstack_type 1 6656 */ 6657 static inline uint8_t a2dp_subevent_streaming_can_send_media_packet_now_get_local_seid(const uint8_t * event){ 6658 return event[5]; 6659 } 6660 6661 /** 6662 * @brief Get field a2dp_cid from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CONFIGURATION 6663 * @param event packet 6664 * @return a2dp_cid 6665 * @note: btstack_type 2 6666 */ 6667 static inline uint16_t a2dp_subevent_signaling_media_codec_sbc_configuration_get_a2dp_cid(const uint8_t * event){ 6668 return little_endian_read_16(event, 3); 6669 } 6670 /** 6671 * @brief Get field local_seid from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CONFIGURATION 6672 * @param event packet 6673 * @return local_seid 6674 * @note: btstack_type 1 6675 */ 6676 static inline uint8_t a2dp_subevent_signaling_media_codec_sbc_configuration_get_local_seid(const uint8_t * event){ 6677 return event[5]; 6678 } 6679 /** 6680 * @brief Get field remote_seid from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CONFIGURATION 6681 * @param event packet 6682 * @return remote_seid 6683 * @note: btstack_type 1 6684 */ 6685 static inline uint8_t a2dp_subevent_signaling_media_codec_sbc_configuration_get_remote_seid(const uint8_t * event){ 6686 return event[6]; 6687 } 6688 /** 6689 * @brief Get field reconfigure from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CONFIGURATION 6690 * @param event packet 6691 * @return reconfigure 6692 * @note: btstack_type 1 6693 */ 6694 static inline uint8_t a2dp_subevent_signaling_media_codec_sbc_configuration_get_reconfigure(const uint8_t * event){ 6695 return event[7]; 6696 } 6697 /** 6698 * @brief Get field media_type from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CONFIGURATION 6699 * @param event packet 6700 * @return media_type 6701 * @note: btstack_type 1 6702 */ 6703 static inline uint8_t a2dp_subevent_signaling_media_codec_sbc_configuration_get_media_type(const uint8_t * event){ 6704 return event[8]; 6705 } 6706 /** 6707 * @brief Get field sampling_frequency from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CONFIGURATION 6708 * @param event packet 6709 * @return sampling_frequency 6710 * @note: btstack_type 2 6711 */ 6712 static inline uint16_t a2dp_subevent_signaling_media_codec_sbc_configuration_get_sampling_frequency(const uint8_t * event){ 6713 return little_endian_read_16(event, 9); 6714 } 6715 /** 6716 * @brief Get field channel_mode from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CONFIGURATION 6717 * @param event packet 6718 * @return channel_mode 6719 * @note: btstack_type 1 6720 */ 6721 static inline uint8_t a2dp_subevent_signaling_media_codec_sbc_configuration_get_channel_mode(const uint8_t * event){ 6722 return event[11]; 6723 } 6724 /** 6725 * @brief Get field num_channels from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CONFIGURATION 6726 * @param event packet 6727 * @return num_channels 6728 * @note: btstack_type 1 6729 */ 6730 static inline uint8_t a2dp_subevent_signaling_media_codec_sbc_configuration_get_num_channels(const uint8_t * event){ 6731 return event[12]; 6732 } 6733 /** 6734 * @brief Get field block_length from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CONFIGURATION 6735 * @param event packet 6736 * @return block_length 6737 * @note: btstack_type 1 6738 */ 6739 static inline uint8_t a2dp_subevent_signaling_media_codec_sbc_configuration_get_block_length(const uint8_t * event){ 6740 return event[13]; 6741 } 6742 /** 6743 * @brief Get field subbands from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CONFIGURATION 6744 * @param event packet 6745 * @return subbands 6746 * @note: btstack_type 1 6747 */ 6748 static inline uint8_t a2dp_subevent_signaling_media_codec_sbc_configuration_get_subbands(const uint8_t * event){ 6749 return event[14]; 6750 } 6751 /** 6752 * @brief Get field allocation_method from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CONFIGURATION 6753 * @param event packet 6754 * @return allocation_method 6755 * @note: btstack_type 1 6756 */ 6757 static inline uint8_t a2dp_subevent_signaling_media_codec_sbc_configuration_get_allocation_method(const uint8_t * event){ 6758 return event[15]; 6759 } 6760 /** 6761 * @brief Get field min_bitpool_value from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CONFIGURATION 6762 * @param event packet 6763 * @return min_bitpool_value 6764 * @note: btstack_type 1 6765 */ 6766 static inline uint8_t a2dp_subevent_signaling_media_codec_sbc_configuration_get_min_bitpool_value(const uint8_t * event){ 6767 return event[16]; 6768 } 6769 /** 6770 * @brief Get field max_bitpool_value from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CONFIGURATION 6771 * @param event packet 6772 * @return max_bitpool_value 6773 * @note: btstack_type 1 6774 */ 6775 static inline uint8_t a2dp_subevent_signaling_media_codec_sbc_configuration_get_max_bitpool_value(const uint8_t * event){ 6776 return event[17]; 6777 } 6778 6779 /** 6780 * @brief Get field a2dp_cid from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CONFIGURATION 6781 * @param event packet 6782 * @return a2dp_cid 6783 * @note: btstack_type 2 6784 */ 6785 static inline uint16_t a2dp_subevent_signaling_media_codec_mpeg_audio_configuration_get_a2dp_cid(const uint8_t * event){ 6786 return little_endian_read_16(event, 3); 6787 } 6788 /** 6789 * @brief Get field local_seid from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CONFIGURATION 6790 * @param event packet 6791 * @return local_seid 6792 * @note: btstack_type 1 6793 */ 6794 static inline uint8_t a2dp_subevent_signaling_media_codec_mpeg_audio_configuration_get_local_seid(const uint8_t * event){ 6795 return event[5]; 6796 } 6797 /** 6798 * @brief Get field remote_seid from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CONFIGURATION 6799 * @param event packet 6800 * @return remote_seid 6801 * @note: btstack_type 1 6802 */ 6803 static inline uint8_t a2dp_subevent_signaling_media_codec_mpeg_audio_configuration_get_remote_seid(const uint8_t * event){ 6804 return event[6]; 6805 } 6806 /** 6807 * @brief Get field reconfigure from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CONFIGURATION 6808 * @param event packet 6809 * @return reconfigure 6810 * @note: btstack_type 1 6811 */ 6812 static inline uint8_t a2dp_subevent_signaling_media_codec_mpeg_audio_configuration_get_reconfigure(const uint8_t * event){ 6813 return event[7]; 6814 } 6815 /** 6816 * @brief Get field media_type from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CONFIGURATION 6817 * @param event packet 6818 * @return media_type 6819 * @note: btstack_type 1 6820 */ 6821 static inline uint8_t a2dp_subevent_signaling_media_codec_mpeg_audio_configuration_get_media_type(const uint8_t * event){ 6822 return event[8]; 6823 } 6824 /** 6825 * @brief Get field layer from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CONFIGURATION 6826 * @param event packet 6827 * @return layer 6828 * @note: btstack_type 1 6829 */ 6830 static inline uint8_t a2dp_subevent_signaling_media_codec_mpeg_audio_configuration_get_layer(const uint8_t * event){ 6831 return event[9]; 6832 } 6833 /** 6834 * @brief Get field crc from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CONFIGURATION 6835 * @param event packet 6836 * @return crc 6837 * @note: btstack_type 1 6838 */ 6839 static inline uint8_t a2dp_subevent_signaling_media_codec_mpeg_audio_configuration_get_crc(const uint8_t * event){ 6840 return event[10]; 6841 } 6842 /** 6843 * @brief Get field channel_mode from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CONFIGURATION 6844 * @param event packet 6845 * @return channel_mode 6846 * @note: btstack_type 1 6847 */ 6848 static inline uint8_t a2dp_subevent_signaling_media_codec_mpeg_audio_configuration_get_channel_mode(const uint8_t * event){ 6849 return event[11]; 6850 } 6851 /** 6852 * @brief Get field num_channels from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CONFIGURATION 6853 * @param event packet 6854 * @return num_channels 6855 * @note: btstack_type 1 6856 */ 6857 static inline uint8_t a2dp_subevent_signaling_media_codec_mpeg_audio_configuration_get_num_channels(const uint8_t * event){ 6858 return event[12]; 6859 } 6860 /** 6861 * @brief Get field media_payload_format from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CONFIGURATION 6862 * @param event packet 6863 * @return media_payload_format 6864 * @note: btstack_type 1 6865 */ 6866 static inline uint8_t a2dp_subevent_signaling_media_codec_mpeg_audio_configuration_get_media_payload_format(const uint8_t * event){ 6867 return event[13]; 6868 } 6869 /** 6870 * @brief Get field sampling_frequency from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CONFIGURATION 6871 * @param event packet 6872 * @return sampling_frequency 6873 * @note: btstack_type 2 6874 */ 6875 static inline uint16_t a2dp_subevent_signaling_media_codec_mpeg_audio_configuration_get_sampling_frequency(const uint8_t * event){ 6876 return little_endian_read_16(event, 14); 6877 } 6878 /** 6879 * @brief Get field vbr from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CONFIGURATION 6880 * @param event packet 6881 * @return vbr 6882 * @note: btstack_type 1 6883 */ 6884 static inline uint8_t a2dp_subevent_signaling_media_codec_mpeg_audio_configuration_get_vbr(const uint8_t * event){ 6885 return event[16]; 6886 } 6887 /** 6888 * @brief Get field bit_rate_index from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CONFIGURATION 6889 * @param event packet 6890 * @return bit_rate_index 6891 * @note: btstack_type 1 6892 */ 6893 static inline uint8_t a2dp_subevent_signaling_media_codec_mpeg_audio_configuration_get_bit_rate_index(const uint8_t * event){ 6894 return event[17]; 6895 } 6896 6897 /** 6898 * @brief Get field a2dp_cid from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CONFIGURATION 6899 * @param event packet 6900 * @return a2dp_cid 6901 * @note: btstack_type 2 6902 */ 6903 static inline uint16_t a2dp_subevent_signaling_media_codec_mpeg_aac_configuration_get_a2dp_cid(const uint8_t * event){ 6904 return little_endian_read_16(event, 3); 6905 } 6906 /** 6907 * @brief Get field local_seid from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CONFIGURATION 6908 * @param event packet 6909 * @return local_seid 6910 * @note: btstack_type 1 6911 */ 6912 static inline uint8_t a2dp_subevent_signaling_media_codec_mpeg_aac_configuration_get_local_seid(const uint8_t * event){ 6913 return event[5]; 6914 } 6915 /** 6916 * @brief Get field remote_seid from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CONFIGURATION 6917 * @param event packet 6918 * @return remote_seid 6919 * @note: btstack_type 1 6920 */ 6921 static inline uint8_t a2dp_subevent_signaling_media_codec_mpeg_aac_configuration_get_remote_seid(const uint8_t * event){ 6922 return event[6]; 6923 } 6924 /** 6925 * @brief Get field reconfigure from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CONFIGURATION 6926 * @param event packet 6927 * @return reconfigure 6928 * @note: btstack_type 1 6929 */ 6930 static inline uint8_t a2dp_subevent_signaling_media_codec_mpeg_aac_configuration_get_reconfigure(const uint8_t * event){ 6931 return event[7]; 6932 } 6933 /** 6934 * @brief Get field media_type from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CONFIGURATION 6935 * @param event packet 6936 * @return media_type 6937 * @note: btstack_type 1 6938 */ 6939 static inline uint8_t a2dp_subevent_signaling_media_codec_mpeg_aac_configuration_get_media_type(const uint8_t * event){ 6940 return event[8]; 6941 } 6942 /** 6943 * @brief Get field object_type from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CONFIGURATION 6944 * @param event packet 6945 * @return object_type 6946 * @note: btstack_type 1 6947 */ 6948 static inline uint8_t a2dp_subevent_signaling_media_codec_mpeg_aac_configuration_get_object_type(const uint8_t * event){ 6949 return event[9]; 6950 } 6951 /** 6952 * @brief Get field sampling_frequency from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CONFIGURATION 6953 * @param event packet 6954 * @return sampling_frequency 6955 * @note: btstack_type 3 6956 */ 6957 static inline uint32_t a2dp_subevent_signaling_media_codec_mpeg_aac_configuration_get_sampling_frequency(const uint8_t * event){ 6958 return little_endian_read_24(event, 10); 6959 } 6960 /** 6961 * @brief Get field num_channels from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CONFIGURATION 6962 * @param event packet 6963 * @return num_channels 6964 * @note: btstack_type 1 6965 */ 6966 static inline uint8_t a2dp_subevent_signaling_media_codec_mpeg_aac_configuration_get_num_channels(const uint8_t * event){ 6967 return event[13]; 6968 } 6969 /** 6970 * @brief Get field bit_rate from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CONFIGURATION 6971 * @param event packet 6972 * @return bit_rate 6973 * @note: btstack_type 3 6974 */ 6975 static inline uint32_t a2dp_subevent_signaling_media_codec_mpeg_aac_configuration_get_bit_rate(const uint8_t * event){ 6976 return little_endian_read_24(event, 14); 6977 } 6978 /** 6979 * @brief Get field vbr from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CONFIGURATION 6980 * @param event packet 6981 * @return vbr 6982 * @note: btstack_type 1 6983 */ 6984 static inline uint8_t a2dp_subevent_signaling_media_codec_mpeg_aac_configuration_get_vbr(const uint8_t * event){ 6985 return event[17]; 6986 } 6987 6988 /** 6989 * @brief Get field a2dp_cid from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CONFIGURATION 6990 * @param event packet 6991 * @return a2dp_cid 6992 * @note: btstack_type 2 6993 */ 6994 static inline uint16_t a2dp_subevent_signaling_media_codec_atrac_configuration_get_a2dp_cid(const uint8_t * event){ 6995 return little_endian_read_16(event, 3); 6996 } 6997 /** 6998 * @brief Get field local_seid from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CONFIGURATION 6999 * @param event packet 7000 * @return local_seid 7001 * @note: btstack_type 1 7002 */ 7003 static inline uint8_t a2dp_subevent_signaling_media_codec_atrac_configuration_get_local_seid(const uint8_t * event){ 7004 return event[5]; 7005 } 7006 /** 7007 * @brief Get field remote_seid from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CONFIGURATION 7008 * @param event packet 7009 * @return remote_seid 7010 * @note: btstack_type 1 7011 */ 7012 static inline uint8_t a2dp_subevent_signaling_media_codec_atrac_configuration_get_remote_seid(const uint8_t * event){ 7013 return event[6]; 7014 } 7015 /** 7016 * @brief Get field reconfigure from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CONFIGURATION 7017 * @param event packet 7018 * @return reconfigure 7019 * @note: btstack_type 1 7020 */ 7021 static inline uint8_t a2dp_subevent_signaling_media_codec_atrac_configuration_get_reconfigure(const uint8_t * event){ 7022 return event[7]; 7023 } 7024 /** 7025 * @brief Get field media_type from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CONFIGURATION 7026 * @param event packet 7027 * @return media_type 7028 * @note: btstack_type 1 7029 */ 7030 static inline uint8_t a2dp_subevent_signaling_media_codec_atrac_configuration_get_media_type(const uint8_t * event){ 7031 return event[8]; 7032 } 7033 /** 7034 * @brief Get field version from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CONFIGURATION 7035 * @param event packet 7036 * @return version 7037 * @note: btstack_type 1 7038 */ 7039 static inline uint8_t a2dp_subevent_signaling_media_codec_atrac_configuration_get_version(const uint8_t * event){ 7040 return event[9]; 7041 } 7042 /** 7043 * @brief Get field channel_mode from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CONFIGURATION 7044 * @param event packet 7045 * @return channel_mode 7046 * @note: btstack_type 1 7047 */ 7048 static inline uint8_t a2dp_subevent_signaling_media_codec_atrac_configuration_get_channel_mode(const uint8_t * event){ 7049 return event[10]; 7050 } 7051 /** 7052 * @brief Get field num_channels from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CONFIGURATION 7053 * @param event packet 7054 * @return num_channels 7055 * @note: btstack_type 1 7056 */ 7057 static inline uint8_t a2dp_subevent_signaling_media_codec_atrac_configuration_get_num_channels(const uint8_t * event){ 7058 return event[11]; 7059 } 7060 /** 7061 * @brief Get field sampling_frequency from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CONFIGURATION 7062 * @param event packet 7063 * @return sampling_frequency 7064 * @note: btstack_type 2 7065 */ 7066 static inline uint16_t a2dp_subevent_signaling_media_codec_atrac_configuration_get_sampling_frequency(const uint8_t * event){ 7067 return little_endian_read_16(event, 12); 7068 } 7069 /** 7070 * @brief Get field vbr from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CONFIGURATION 7071 * @param event packet 7072 * @return vbr 7073 * @note: btstack_type 1 7074 */ 7075 static inline uint8_t a2dp_subevent_signaling_media_codec_atrac_configuration_get_vbr(const uint8_t * event){ 7076 return event[14]; 7077 } 7078 /** 7079 * @brief Get field bit_rate_index from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CONFIGURATION 7080 * @param event packet 7081 * @return bit_rate_index 7082 * @note: btstack_type 1 7083 */ 7084 static inline uint8_t a2dp_subevent_signaling_media_codec_atrac_configuration_get_bit_rate_index(const uint8_t * event){ 7085 return event[15]; 7086 } 7087 /** 7088 * @brief Get field maximum_sul from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CONFIGURATION 7089 * @param event packet 7090 * @return maximum_sul 7091 * @note: btstack_type 2 7092 */ 7093 static inline uint16_t a2dp_subevent_signaling_media_codec_atrac_configuration_get_maximum_sul(const uint8_t * event){ 7094 return little_endian_read_16(event, 16); 7095 } 7096 7097 /** 7098 * @brief Get field a2dp_cid from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_OTHER_CONFIGURATION 7099 * @param event packet 7100 * @return a2dp_cid 7101 * @note: btstack_type 2 7102 */ 7103 static inline uint16_t a2dp_subevent_signaling_media_codec_other_configuration_get_a2dp_cid(const uint8_t * event){ 7104 return little_endian_read_16(event, 3); 7105 } 7106 /** 7107 * @brief Get field local_seid from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_OTHER_CONFIGURATION 7108 * @param event packet 7109 * @return local_seid 7110 * @note: btstack_type 1 7111 */ 7112 static inline uint8_t a2dp_subevent_signaling_media_codec_other_configuration_get_local_seid(const uint8_t * event){ 7113 return event[5]; 7114 } 7115 /** 7116 * @brief Get field remote_seid from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_OTHER_CONFIGURATION 7117 * @param event packet 7118 * @return remote_seid 7119 * @note: btstack_type 1 7120 */ 7121 static inline uint8_t a2dp_subevent_signaling_media_codec_other_configuration_get_remote_seid(const uint8_t * event){ 7122 return event[6]; 7123 } 7124 /** 7125 * @brief Get field reconfigure from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_OTHER_CONFIGURATION 7126 * @param event packet 7127 * @return reconfigure 7128 * @note: btstack_type 1 7129 */ 7130 static inline uint8_t a2dp_subevent_signaling_media_codec_other_configuration_get_reconfigure(const uint8_t * event){ 7131 return event[7]; 7132 } 7133 /** 7134 * @brief Get field media_type from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_OTHER_CONFIGURATION 7135 * @param event packet 7136 * @return media_type 7137 * @note: btstack_type 1 7138 */ 7139 static inline uint8_t a2dp_subevent_signaling_media_codec_other_configuration_get_media_type(const uint8_t * event){ 7140 return event[8]; 7141 } 7142 /** 7143 * @brief Get field media_codec_type from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_OTHER_CONFIGURATION 7144 * @param event packet 7145 * @return media_codec_type 7146 * @note: btstack_type 2 7147 */ 7148 static inline uint16_t a2dp_subevent_signaling_media_codec_other_configuration_get_media_codec_type(const uint8_t * event){ 7149 return little_endian_read_16(event, 9); 7150 } 7151 /** 7152 * @brief Get field media_codec_information_len from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_OTHER_CONFIGURATION 7153 * @param event packet 7154 * @return media_codec_information_len 7155 * @note: btstack_type L 7156 */ 7157 static inline uint16_t a2dp_subevent_signaling_media_codec_other_configuration_get_media_codec_information_len(const uint8_t * event){ 7158 return little_endian_read_16(event, 11); 7159 } 7160 /** 7161 * @brief Get field media_codec_information from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_OTHER_CONFIGURATION 7162 * @param event packet 7163 * @return media_codec_information 7164 * @note: btstack_type V 7165 */ 7166 static inline const uint8_t * a2dp_subevent_signaling_media_codec_other_configuration_get_media_codec_information(const uint8_t * event){ 7167 return &event[13]; 7168 } 7169 7170 /** 7171 * @brief Get field a2dp_cid from event A2DP_SUBEVENT_STREAM_ESTABLISHED 7172 * @param event packet 7173 * @return a2dp_cid 7174 * @note: btstack_type 2 7175 */ 7176 static inline uint16_t a2dp_subevent_stream_established_get_a2dp_cid(const uint8_t * event){ 7177 return little_endian_read_16(event, 3); 7178 } 7179 /** 7180 * @brief Get field bd_addr from event A2DP_SUBEVENT_STREAM_ESTABLISHED 7181 * @param event packet 7182 * @param Pointer to storage for bd_addr 7183 * @note: btstack_type B 7184 */ 7185 static inline void a2dp_subevent_stream_established_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 7186 reverse_bytes(&event[5], bd_addr, 6); 7187 } 7188 /** 7189 * @brief Get field local_seid from event A2DP_SUBEVENT_STREAM_ESTABLISHED 7190 * @param event packet 7191 * @return local_seid 7192 * @note: btstack_type 1 7193 */ 7194 static inline uint8_t a2dp_subevent_stream_established_get_local_seid(const uint8_t * event){ 7195 return event[11]; 7196 } 7197 /** 7198 * @brief Get field remote_seid from event A2DP_SUBEVENT_STREAM_ESTABLISHED 7199 * @param event packet 7200 * @return remote_seid 7201 * @note: btstack_type 1 7202 */ 7203 static inline uint8_t a2dp_subevent_stream_established_get_remote_seid(const uint8_t * event){ 7204 return event[12]; 7205 } 7206 /** 7207 * @brief Get field status from event A2DP_SUBEVENT_STREAM_ESTABLISHED 7208 * @param event packet 7209 * @return status 7210 * @note: btstack_type 1 7211 */ 7212 static inline uint8_t a2dp_subevent_stream_established_get_status(const uint8_t * event){ 7213 return event[13]; 7214 } 7215 7216 /** 7217 * @brief Get field a2dp_cid from event A2DP_SUBEVENT_START_STREAM_REQUESTED 7218 * @param event packet 7219 * @return a2dp_cid 7220 * @note: btstack_type 2 7221 */ 7222 static inline uint16_t a2dp_subevent_start_stream_requested_get_a2dp_cid(const uint8_t * event){ 7223 return little_endian_read_16(event, 3); 7224 } 7225 /** 7226 * @brief Get field local_seid from event A2DP_SUBEVENT_START_STREAM_REQUESTED 7227 * @param event packet 7228 * @return local_seid 7229 * @note: btstack_type 1 7230 */ 7231 static inline uint8_t a2dp_subevent_start_stream_requested_get_local_seid(const uint8_t * event){ 7232 return event[5]; 7233 } 7234 7235 /** 7236 * @brief Get field a2dp_cid from event A2DP_SUBEVENT_STREAM_STARTED 7237 * @param event packet 7238 * @return a2dp_cid 7239 * @note: btstack_type 2 7240 */ 7241 static inline uint16_t a2dp_subevent_stream_started_get_a2dp_cid(const uint8_t * event){ 7242 return little_endian_read_16(event, 3); 7243 } 7244 /** 7245 * @brief Get field local_seid from event A2DP_SUBEVENT_STREAM_STARTED 7246 * @param event packet 7247 * @return local_seid 7248 * @note: btstack_type 1 7249 */ 7250 static inline uint8_t a2dp_subevent_stream_started_get_local_seid(const uint8_t * event){ 7251 return event[5]; 7252 } 7253 7254 /** 7255 * @brief Get field a2dp_cid from event A2DP_SUBEVENT_STREAM_SUSPENDED 7256 * @param event packet 7257 * @return a2dp_cid 7258 * @note: btstack_type 2 7259 */ 7260 static inline uint16_t a2dp_subevent_stream_suspended_get_a2dp_cid(const uint8_t * event){ 7261 return little_endian_read_16(event, 3); 7262 } 7263 /** 7264 * @brief Get field local_seid from event A2DP_SUBEVENT_STREAM_SUSPENDED 7265 * @param event packet 7266 * @return local_seid 7267 * @note: btstack_type 1 7268 */ 7269 static inline uint8_t a2dp_subevent_stream_suspended_get_local_seid(const uint8_t * event){ 7270 return event[5]; 7271 } 7272 7273 /** 7274 * @brief Get field a2dp_cid from event A2DP_SUBEVENT_STREAM_STOPPED 7275 * @param event packet 7276 * @return a2dp_cid 7277 * @note: btstack_type 2 7278 */ 7279 static inline uint16_t a2dp_subevent_stream_stopped_get_a2dp_cid(const uint8_t * event){ 7280 return little_endian_read_16(event, 3); 7281 } 7282 /** 7283 * @brief Get field local_seid from event A2DP_SUBEVENT_STREAM_STOPPED 7284 * @param event packet 7285 * @return local_seid 7286 * @note: btstack_type 1 7287 */ 7288 static inline uint8_t a2dp_subevent_stream_stopped_get_local_seid(const uint8_t * event){ 7289 return event[5]; 7290 } 7291 7292 /** 7293 * @brief Get field a2dp_cid from event A2DP_SUBEVENT_STREAM_RELEASED 7294 * @param event packet 7295 * @return a2dp_cid 7296 * @note: btstack_type 2 7297 */ 7298 static inline uint16_t a2dp_subevent_stream_released_get_a2dp_cid(const uint8_t * event){ 7299 return little_endian_read_16(event, 3); 7300 } 7301 /** 7302 * @brief Get field local_seid from event A2DP_SUBEVENT_STREAM_RELEASED 7303 * @param event packet 7304 * @return local_seid 7305 * @note: btstack_type 1 7306 */ 7307 static inline uint8_t a2dp_subevent_stream_released_get_local_seid(const uint8_t * event){ 7308 return event[5]; 7309 } 7310 7311 /** 7312 * @brief Get field a2dp_cid from event A2DP_SUBEVENT_COMMAND_ACCEPTED 7313 * @param event packet 7314 * @return a2dp_cid 7315 * @note: btstack_type 2 7316 */ 7317 static inline uint16_t a2dp_subevent_command_accepted_get_a2dp_cid(const uint8_t * event){ 7318 return little_endian_read_16(event, 3); 7319 } 7320 /** 7321 * @brief Get field local_seid from event A2DP_SUBEVENT_COMMAND_ACCEPTED 7322 * @param event packet 7323 * @return local_seid 7324 * @note: btstack_type 1 7325 */ 7326 static inline uint8_t a2dp_subevent_command_accepted_get_local_seid(const uint8_t * event){ 7327 return event[5]; 7328 } 7329 /** 7330 * @brief Get field signal_identifier from event A2DP_SUBEVENT_COMMAND_ACCEPTED 7331 * @param event packet 7332 * @return signal_identifier 7333 * @note: btstack_type 1 7334 */ 7335 static inline uint8_t a2dp_subevent_command_accepted_get_signal_identifier(const uint8_t * event){ 7336 return event[6]; 7337 } 7338 7339 /** 7340 * @brief Get field a2dp_cid from event A2DP_SUBEVENT_COMMAND_REJECTED 7341 * @param event packet 7342 * @return a2dp_cid 7343 * @note: btstack_type 2 7344 */ 7345 static inline uint16_t a2dp_subevent_command_rejected_get_a2dp_cid(const uint8_t * event){ 7346 return little_endian_read_16(event, 3); 7347 } 7348 /** 7349 * @brief Get field local_seid from event A2DP_SUBEVENT_COMMAND_REJECTED 7350 * @param event packet 7351 * @return local_seid 7352 * @note: btstack_type 1 7353 */ 7354 static inline uint8_t a2dp_subevent_command_rejected_get_local_seid(const uint8_t * event){ 7355 return event[5]; 7356 } 7357 /** 7358 * @brief Get field is_initiator from event A2DP_SUBEVENT_COMMAND_REJECTED 7359 * @param event packet 7360 * @return is_initiator 7361 * @note: btstack_type 1 7362 */ 7363 static inline uint8_t a2dp_subevent_command_rejected_get_is_initiator(const uint8_t * event){ 7364 return event[6]; 7365 } 7366 /** 7367 * @brief Get field signal_identifier from event A2DP_SUBEVENT_COMMAND_REJECTED 7368 * @param event packet 7369 * @return signal_identifier 7370 * @note: btstack_type 1 7371 */ 7372 static inline uint8_t a2dp_subevent_command_rejected_get_signal_identifier(const uint8_t * event){ 7373 return event[7]; 7374 } 7375 7376 /** 7377 * @brief Get field a2dp_cid from event A2DP_SUBEVENT_SIGNALING_CONNECTION_ESTABLISHED 7378 * @param event packet 7379 * @return a2dp_cid 7380 * @note: btstack_type 2 7381 */ 7382 static inline uint16_t a2dp_subevent_signaling_connection_established_get_a2dp_cid(const uint8_t * event){ 7383 return little_endian_read_16(event, 3); 7384 } 7385 /** 7386 * @brief Get field bd_addr from event A2DP_SUBEVENT_SIGNALING_CONNECTION_ESTABLISHED 7387 * @param event packet 7388 * @param Pointer to storage for bd_addr 7389 * @note: btstack_type B 7390 */ 7391 static inline void a2dp_subevent_signaling_connection_established_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 7392 reverse_bytes(&event[5], bd_addr, 6); 7393 } 7394 /** 7395 * @brief Get field con_handle from event A2DP_SUBEVENT_SIGNALING_CONNECTION_ESTABLISHED 7396 * @param event packet 7397 * @return con_handle 7398 * @note: btstack_type 2 7399 */ 7400 static inline uint16_t a2dp_subevent_signaling_connection_established_get_con_handle(const uint8_t * event){ 7401 return little_endian_read_16(event, 11); 7402 } 7403 /** 7404 * @brief Get field status from event A2DP_SUBEVENT_SIGNALING_CONNECTION_ESTABLISHED 7405 * @param event packet 7406 * @return status 7407 * @note: btstack_type 1 7408 */ 7409 static inline uint8_t a2dp_subevent_signaling_connection_established_get_status(const uint8_t * event){ 7410 return event[13]; 7411 } 7412 7413 /** 7414 * @brief Get field a2dp_cid from event A2DP_SUBEVENT_SIGNALING_CONNECTION_RELEASED 7415 * @param event packet 7416 * @return a2dp_cid 7417 * @note: btstack_type 2 7418 */ 7419 static inline uint16_t a2dp_subevent_signaling_connection_released_get_a2dp_cid(const uint8_t * event){ 7420 return little_endian_read_16(event, 3); 7421 } 7422 7423 /** 7424 * @brief Get field a2dp_cid from event A2DP_SUBEVENT_STREAM_RECONFIGURED 7425 * @param event packet 7426 * @return a2dp_cid 7427 * @note: btstack_type 2 7428 */ 7429 static inline uint16_t a2dp_subevent_stream_reconfigured_get_a2dp_cid(const uint8_t * event){ 7430 return little_endian_read_16(event, 3); 7431 } 7432 /** 7433 * @brief Get field local_seid from event A2DP_SUBEVENT_STREAM_RECONFIGURED 7434 * @param event packet 7435 * @return local_seid 7436 * @note: btstack_type 1 7437 */ 7438 static inline uint8_t a2dp_subevent_stream_reconfigured_get_local_seid(const uint8_t * event){ 7439 return event[5]; 7440 } 7441 /** 7442 * @brief Get field status from event A2DP_SUBEVENT_STREAM_RECONFIGURED 7443 * @param event packet 7444 * @return status 7445 * @note: btstack_type 1 7446 */ 7447 static inline uint8_t a2dp_subevent_stream_reconfigured_get_status(const uint8_t * event){ 7448 return event[6]; 7449 } 7450 7451 /** 7452 * @brief Get field a2dp_cid from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CAPABILITY 7453 * @param event packet 7454 * @return a2dp_cid 7455 * @note: btstack_type 2 7456 */ 7457 static inline uint16_t a2dp_subevent_signaling_media_codec_sbc_capability_get_a2dp_cid(const uint8_t * event){ 7458 return little_endian_read_16(event, 3); 7459 } 7460 /** 7461 * @brief Get field remote_seid from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CAPABILITY 7462 * @param event packet 7463 * @return remote_seid 7464 * @note: btstack_type 1 7465 */ 7466 static inline uint8_t a2dp_subevent_signaling_media_codec_sbc_capability_get_remote_seid(const uint8_t * event){ 7467 return event[5]; 7468 } 7469 /** 7470 * @brief Get field media_type from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CAPABILITY 7471 * @param event packet 7472 * @return media_type 7473 * @note: btstack_type 1 7474 */ 7475 static inline uint8_t a2dp_subevent_signaling_media_codec_sbc_capability_get_media_type(const uint8_t * event){ 7476 return event[6]; 7477 } 7478 /** 7479 * @brief Get field sampling_frequency_bitmap from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CAPABILITY 7480 * @param event packet 7481 * @return sampling_frequency_bitmap 7482 * @note: btstack_type 1 7483 */ 7484 static inline uint8_t a2dp_subevent_signaling_media_codec_sbc_capability_get_sampling_frequency_bitmap(const uint8_t * event){ 7485 return event[7]; 7486 } 7487 /** 7488 * @brief Get field channel_mode_bitmap from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CAPABILITY 7489 * @param event packet 7490 * @return channel_mode_bitmap 7491 * @note: btstack_type 1 7492 */ 7493 static inline uint8_t a2dp_subevent_signaling_media_codec_sbc_capability_get_channel_mode_bitmap(const uint8_t * event){ 7494 return event[8]; 7495 } 7496 /** 7497 * @brief Get field block_length_bitmap from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CAPABILITY 7498 * @param event packet 7499 * @return block_length_bitmap 7500 * @note: btstack_type 1 7501 */ 7502 static inline uint8_t a2dp_subevent_signaling_media_codec_sbc_capability_get_block_length_bitmap(const uint8_t * event){ 7503 return event[9]; 7504 } 7505 /** 7506 * @brief Get field subbands_bitmap from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CAPABILITY 7507 * @param event packet 7508 * @return subbands_bitmap 7509 * @note: btstack_type 1 7510 */ 7511 static inline uint8_t a2dp_subevent_signaling_media_codec_sbc_capability_get_subbands_bitmap(const uint8_t * event){ 7512 return event[10]; 7513 } 7514 /** 7515 * @brief Get field allocation_method_bitmap from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CAPABILITY 7516 * @param event packet 7517 * @return allocation_method_bitmap 7518 * @note: btstack_type 1 7519 */ 7520 static inline uint8_t a2dp_subevent_signaling_media_codec_sbc_capability_get_allocation_method_bitmap(const uint8_t * event){ 7521 return event[11]; 7522 } 7523 /** 7524 * @brief Get field min_bitpool_value from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CAPABILITY 7525 * @param event packet 7526 * @return min_bitpool_value 7527 * @note: btstack_type 1 7528 */ 7529 static inline uint8_t a2dp_subevent_signaling_media_codec_sbc_capability_get_min_bitpool_value(const uint8_t * event){ 7530 return event[12]; 7531 } 7532 /** 7533 * @brief Get field max_bitpool_value from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_SBC_CAPABILITY 7534 * @param event packet 7535 * @return max_bitpool_value 7536 * @note: btstack_type 1 7537 */ 7538 static inline uint8_t a2dp_subevent_signaling_media_codec_sbc_capability_get_max_bitpool_value(const uint8_t * event){ 7539 return event[13]; 7540 } 7541 7542 /** 7543 * @brief Get field a2dp_cid from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CAPABILITY 7544 * @param event packet 7545 * @return a2dp_cid 7546 * @note: btstack_type 2 7547 */ 7548 static inline uint16_t a2dp_subevent_signaling_media_codec_mpeg_audio_capability_get_a2dp_cid(const uint8_t * event){ 7549 return little_endian_read_16(event, 3); 7550 } 7551 /** 7552 * @brief Get field remote_seid from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CAPABILITY 7553 * @param event packet 7554 * @return remote_seid 7555 * @note: btstack_type 1 7556 */ 7557 static inline uint8_t a2dp_subevent_signaling_media_codec_mpeg_audio_capability_get_remote_seid(const uint8_t * event){ 7558 return event[5]; 7559 } 7560 /** 7561 * @brief Get field media_type from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CAPABILITY 7562 * @param event packet 7563 * @return media_type 7564 * @note: btstack_type 1 7565 */ 7566 static inline uint8_t a2dp_subevent_signaling_media_codec_mpeg_audio_capability_get_media_type(const uint8_t * event){ 7567 return event[6]; 7568 } 7569 /** 7570 * @brief Get field layer_bitmap from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CAPABILITY 7571 * @param event packet 7572 * @return layer_bitmap 7573 * @note: btstack_type 1 7574 */ 7575 static inline uint8_t a2dp_subevent_signaling_media_codec_mpeg_audio_capability_get_layer_bitmap(const uint8_t * event){ 7576 return event[7]; 7577 } 7578 /** 7579 * @brief Get field crc from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CAPABILITY 7580 * @param event packet 7581 * @return crc 7582 * @note: btstack_type 1 7583 */ 7584 static inline uint8_t a2dp_subevent_signaling_media_codec_mpeg_audio_capability_get_crc(const uint8_t * event){ 7585 return event[8]; 7586 } 7587 /** 7588 * @brief Get field channel_mode_bitmap from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CAPABILITY 7589 * @param event packet 7590 * @return channel_mode_bitmap 7591 * @note: btstack_type 1 7592 */ 7593 static inline uint8_t a2dp_subevent_signaling_media_codec_mpeg_audio_capability_get_channel_mode_bitmap(const uint8_t * event){ 7594 return event[9]; 7595 } 7596 /** 7597 * @brief Get field media_payload_format from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CAPABILITY 7598 * @param event packet 7599 * @return media_payload_format 7600 * @note: btstack_type 1 7601 */ 7602 static inline uint8_t a2dp_subevent_signaling_media_codec_mpeg_audio_capability_get_media_payload_format(const uint8_t * event){ 7603 return event[10]; 7604 } 7605 /** 7606 * @brief Get field sampling_frequency_bitmap from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CAPABILITY 7607 * @param event packet 7608 * @return sampling_frequency_bitmap 7609 * @note: btstack_type 1 7610 */ 7611 static inline uint8_t a2dp_subevent_signaling_media_codec_mpeg_audio_capability_get_sampling_frequency_bitmap(const uint8_t * event){ 7612 return event[11]; 7613 } 7614 /** 7615 * @brief Get field vbr from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CAPABILITY 7616 * @param event packet 7617 * @return vbr 7618 * @note: btstack_type 1 7619 */ 7620 static inline uint8_t a2dp_subevent_signaling_media_codec_mpeg_audio_capability_get_vbr(const uint8_t * event){ 7621 return event[12]; 7622 } 7623 /** 7624 * @brief Get field bit_rate_index_bitmap from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AUDIO_CAPABILITY 7625 * @param event packet 7626 * @return bit_rate_index_bitmap 7627 * @note: btstack_type 2 7628 */ 7629 static inline uint16_t a2dp_subevent_signaling_media_codec_mpeg_audio_capability_get_bit_rate_index_bitmap(const uint8_t * event){ 7630 return little_endian_read_16(event, 13); 7631 } 7632 7633 /** 7634 * @brief Get field a2dp_cid from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CAPABILITY 7635 * @param event packet 7636 * @return a2dp_cid 7637 * @note: btstack_type 2 7638 */ 7639 static inline uint16_t a2dp_subevent_signaling_media_codec_mpeg_aac_capability_get_a2dp_cid(const uint8_t * event){ 7640 return little_endian_read_16(event, 3); 7641 } 7642 /** 7643 * @brief Get field remote_seid from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CAPABILITY 7644 * @param event packet 7645 * @return remote_seid 7646 * @note: btstack_type 1 7647 */ 7648 static inline uint8_t a2dp_subevent_signaling_media_codec_mpeg_aac_capability_get_remote_seid(const uint8_t * event){ 7649 return event[5]; 7650 } 7651 /** 7652 * @brief Get field media_type from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CAPABILITY 7653 * @param event packet 7654 * @return media_type 7655 * @note: btstack_type 1 7656 */ 7657 static inline uint8_t a2dp_subevent_signaling_media_codec_mpeg_aac_capability_get_media_type(const uint8_t * event){ 7658 return event[6]; 7659 } 7660 /** 7661 * @brief Get field object_type_bitmap from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CAPABILITY 7662 * @param event packet 7663 * @return object_type_bitmap 7664 * @note: btstack_type 1 7665 */ 7666 static inline uint8_t a2dp_subevent_signaling_media_codec_mpeg_aac_capability_get_object_type_bitmap(const uint8_t * event){ 7667 return event[7]; 7668 } 7669 /** 7670 * @brief Get field sampling_frequency_bitmap from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CAPABILITY 7671 * @param event packet 7672 * @return sampling_frequency_bitmap 7673 * @note: btstack_type 2 7674 */ 7675 static inline uint16_t a2dp_subevent_signaling_media_codec_mpeg_aac_capability_get_sampling_frequency_bitmap(const uint8_t * event){ 7676 return little_endian_read_16(event, 8); 7677 } 7678 /** 7679 * @brief Get field channels_bitmap from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CAPABILITY 7680 * @param event packet 7681 * @return channels_bitmap 7682 * @note: btstack_type 1 7683 */ 7684 static inline uint8_t a2dp_subevent_signaling_media_codec_mpeg_aac_capability_get_channels_bitmap(const uint8_t * event){ 7685 return event[10]; 7686 } 7687 /** 7688 * @brief Get field bit_rate from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CAPABILITY 7689 * @param event packet 7690 * @return bit_rate 7691 * @note: btstack_type 3 7692 */ 7693 static inline uint32_t a2dp_subevent_signaling_media_codec_mpeg_aac_capability_get_bit_rate(const uint8_t * event){ 7694 return little_endian_read_24(event, 11); 7695 } 7696 /** 7697 * @brief Get field vbr from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_MPEG_AAC_CAPABILITY 7698 * @param event packet 7699 * @return vbr 7700 * @note: btstack_type 1 7701 */ 7702 static inline uint8_t a2dp_subevent_signaling_media_codec_mpeg_aac_capability_get_vbr(const uint8_t * event){ 7703 return event[14]; 7704 } 7705 7706 /** 7707 * @brief Get field a2dp_cid from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CAPABILITY 7708 * @param event packet 7709 * @return a2dp_cid 7710 * @note: btstack_type 2 7711 */ 7712 static inline uint16_t a2dp_subevent_signaling_media_codec_atrac_capability_get_a2dp_cid(const uint8_t * event){ 7713 return little_endian_read_16(event, 3); 7714 } 7715 /** 7716 * @brief Get field remote_seid from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CAPABILITY 7717 * @param event packet 7718 * @return remote_seid 7719 * @note: btstack_type 1 7720 */ 7721 static inline uint8_t a2dp_subevent_signaling_media_codec_atrac_capability_get_remote_seid(const uint8_t * event){ 7722 return event[5]; 7723 } 7724 /** 7725 * @brief Get field media_type from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CAPABILITY 7726 * @param event packet 7727 * @return media_type 7728 * @note: btstack_type 1 7729 */ 7730 static inline uint8_t a2dp_subevent_signaling_media_codec_atrac_capability_get_media_type(const uint8_t * event){ 7731 return event[6]; 7732 } 7733 /** 7734 * @brief Get field version from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CAPABILITY 7735 * @param event packet 7736 * @return version 7737 * @note: btstack_type 1 7738 */ 7739 static inline uint8_t a2dp_subevent_signaling_media_codec_atrac_capability_get_version(const uint8_t * event){ 7740 return event[7]; 7741 } 7742 /** 7743 * @brief Get field channel_mode_bitmap from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CAPABILITY 7744 * @param event packet 7745 * @return channel_mode_bitmap 7746 * @note: btstack_type 1 7747 */ 7748 static inline uint8_t a2dp_subevent_signaling_media_codec_atrac_capability_get_channel_mode_bitmap(const uint8_t * event){ 7749 return event[8]; 7750 } 7751 /** 7752 * @brief Get field sampling_frequency_bitmap from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CAPABILITY 7753 * @param event packet 7754 * @return sampling_frequency_bitmap 7755 * @note: btstack_type 1 7756 */ 7757 static inline uint8_t a2dp_subevent_signaling_media_codec_atrac_capability_get_sampling_frequency_bitmap(const uint8_t * event){ 7758 return event[9]; 7759 } 7760 /** 7761 * @brief Get field vbr from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CAPABILITY 7762 * @param event packet 7763 * @return vbr 7764 * @note: btstack_type 1 7765 */ 7766 static inline uint8_t a2dp_subevent_signaling_media_codec_atrac_capability_get_vbr(const uint8_t * event){ 7767 return event[10]; 7768 } 7769 /** 7770 * @brief Get field bit_rate_index_bitmap from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CAPABILITY 7771 * @param event packet 7772 * @return bit_rate_index_bitmap 7773 * @note: btstack_type 3 7774 */ 7775 static inline uint32_t a2dp_subevent_signaling_media_codec_atrac_capability_get_bit_rate_index_bitmap(const uint8_t * event){ 7776 return little_endian_read_24(event, 11); 7777 } 7778 /** 7779 * @brief Get field maximum_sul from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_ATRAC_CAPABILITY 7780 * @param event packet 7781 * @return maximum_sul 7782 * @note: btstack_type 2 7783 */ 7784 static inline uint16_t a2dp_subevent_signaling_media_codec_atrac_capability_get_maximum_sul(const uint8_t * event){ 7785 return little_endian_read_16(event, 14); 7786 } 7787 7788 /** 7789 * @brief Get field a2dp_cid from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_OTHER_CAPABILITY 7790 * @param event packet 7791 * @return a2dp_cid 7792 * @note: btstack_type 2 7793 */ 7794 static inline uint16_t a2dp_subevent_signaling_media_codec_other_capability_get_a2dp_cid(const uint8_t * event){ 7795 return little_endian_read_16(event, 3); 7796 } 7797 /** 7798 * @brief Get field remote_seid from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_OTHER_CAPABILITY 7799 * @param event packet 7800 * @return remote_seid 7801 * @note: btstack_type 1 7802 */ 7803 static inline uint8_t a2dp_subevent_signaling_media_codec_other_capability_get_remote_seid(const uint8_t * event){ 7804 return event[5]; 7805 } 7806 /** 7807 * @brief Get field media_type from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_OTHER_CAPABILITY 7808 * @param event packet 7809 * @return media_type 7810 * @note: btstack_type 1 7811 */ 7812 static inline uint8_t a2dp_subevent_signaling_media_codec_other_capability_get_media_type(const uint8_t * event){ 7813 return event[6]; 7814 } 7815 /** 7816 * @brief Get field media_codec_type from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_OTHER_CAPABILITY 7817 * @param event packet 7818 * @return media_codec_type 7819 * @note: btstack_type 2 7820 */ 7821 static inline uint16_t a2dp_subevent_signaling_media_codec_other_capability_get_media_codec_type(const uint8_t * event){ 7822 return little_endian_read_16(event, 7); 7823 } 7824 /** 7825 * @brief Get field media_codec_information_len from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_OTHER_CAPABILITY 7826 * @param event packet 7827 * @return media_codec_information_len 7828 * @note: btstack_type L 7829 */ 7830 static inline uint16_t a2dp_subevent_signaling_media_codec_other_capability_get_media_codec_information_len(const uint8_t * event){ 7831 return little_endian_read_16(event, 9); 7832 } 7833 /** 7834 * @brief Get field media_codec_information from event A2DP_SUBEVENT_SIGNALING_MEDIA_CODEC_OTHER_CAPABILITY 7835 * @param event packet 7836 * @return media_codec_information 7837 * @note: btstack_type V 7838 */ 7839 static inline const uint8_t * a2dp_subevent_signaling_media_codec_other_capability_get_media_codec_information(const uint8_t * event){ 7840 return &event[11]; 7841 } 7842 7843 /** 7844 * @brief Get field a2dp_cid from event A2DP_SUBEVENT_SIGNALING_DELAY_REPORTING_CAPABILITY 7845 * @param event packet 7846 * @return a2dp_cid 7847 * @note: btstack_type 2 7848 */ 7849 static inline uint16_t a2dp_subevent_signaling_delay_reporting_capability_get_a2dp_cid(const uint8_t * event){ 7850 return little_endian_read_16(event, 3); 7851 } 7852 /** 7853 * @brief Get field remote_seid from event A2DP_SUBEVENT_SIGNALING_DELAY_REPORTING_CAPABILITY 7854 * @param event packet 7855 * @return remote_seid 7856 * @note: btstack_type 1 7857 */ 7858 static inline uint8_t a2dp_subevent_signaling_delay_reporting_capability_get_remote_seid(const uint8_t * event){ 7859 return event[5]; 7860 } 7861 7862 /** 7863 * @brief Get field a2dp_cid from event A2DP_SUBEVENT_SIGNALING_DELAY_REPORT 7864 * @param event packet 7865 * @return a2dp_cid 7866 * @note: btstack_type 2 7867 */ 7868 static inline uint16_t a2dp_subevent_signaling_delay_report_get_a2dp_cid(const uint8_t * event){ 7869 return little_endian_read_16(event, 3); 7870 } 7871 /** 7872 * @brief Get field local_seid from event A2DP_SUBEVENT_SIGNALING_DELAY_REPORT 7873 * @param event packet 7874 * @return local_seid 7875 * @note: btstack_type 1 7876 */ 7877 static inline uint8_t a2dp_subevent_signaling_delay_report_get_local_seid(const uint8_t * event){ 7878 return event[5]; 7879 } 7880 /** 7881 * @brief Get field delay_100us from event A2DP_SUBEVENT_SIGNALING_DELAY_REPORT 7882 * @param event packet 7883 * @return delay_100us 7884 * @note: btstack_type 2 7885 */ 7886 static inline uint16_t a2dp_subevent_signaling_delay_report_get_delay_100us(const uint8_t * event){ 7887 return little_endian_read_16(event, 6); 7888 } 7889 7890 /** 7891 * @brief Get field a2dp_cid from event A2DP_SUBEVENT_SIGNALING_CAPABILITIES_DONE 7892 * @param event packet 7893 * @return a2dp_cid 7894 * @note: btstack_type 2 7895 */ 7896 static inline uint16_t a2dp_subevent_signaling_capabilities_done_get_a2dp_cid(const uint8_t * event){ 7897 return little_endian_read_16(event, 3); 7898 } 7899 /** 7900 * @brief Get field remote_seid from event A2DP_SUBEVENT_SIGNALING_CAPABILITIES_DONE 7901 * @param event packet 7902 * @return remote_seid 7903 * @note: btstack_type 1 7904 */ 7905 static inline uint8_t a2dp_subevent_signaling_capabilities_done_get_remote_seid(const uint8_t * event){ 7906 return event[5]; 7907 } 7908 7909 /** 7910 * @brief Get field a2dp_cid from event A2DP_SUBEVENT_SIGNALING_CAPABILITIES_COMPLETE 7911 * @param event packet 7912 * @return a2dp_cid 7913 * @note: btstack_type 2 7914 */ 7915 static inline uint16_t a2dp_subevent_signaling_capabilities_complete_get_a2dp_cid(const uint8_t * event){ 7916 return little_endian_read_16(event, 3); 7917 } 7918 7919 /** 7920 * @brief Get field avrcp_cid from event AVRCP_SUBEVENT_NOTIFICATION_PLAYBACK_STATUS_CHANGED 7921 * @param event packet 7922 * @return avrcp_cid 7923 * @note: btstack_type 2 7924 */ 7925 static inline uint16_t avrcp_subevent_notification_playback_status_changed_get_avrcp_cid(const uint8_t * event){ 7926 return little_endian_read_16(event, 3); 7927 } 7928 /** 7929 * @brief Get field command_type from event AVRCP_SUBEVENT_NOTIFICATION_PLAYBACK_STATUS_CHANGED 7930 * @param event packet 7931 * @return command_type 7932 * @note: btstack_type 1 7933 */ 7934 static inline uint8_t avrcp_subevent_notification_playback_status_changed_get_command_type(const uint8_t * event){ 7935 return event[5]; 7936 } 7937 /** 7938 * @brief Get field play_status from event AVRCP_SUBEVENT_NOTIFICATION_PLAYBACK_STATUS_CHANGED 7939 * @param event packet 7940 * @return play_status 7941 * @note: btstack_type 1 7942 */ 7943 static inline uint8_t avrcp_subevent_notification_playback_status_changed_get_play_status(const uint8_t * event){ 7944 return event[6]; 7945 } 7946 7947 /** 7948 * @brief Get field avrcp_cid from event AVRCP_SUBEVENT_NOTIFICATION_TRACK_CHANGED 7949 * @param event packet 7950 * @return avrcp_cid 7951 * @note: btstack_type 2 7952 */ 7953 static inline uint16_t avrcp_subevent_notification_track_changed_get_avrcp_cid(const uint8_t * event){ 7954 return little_endian_read_16(event, 3); 7955 } 7956 /** 7957 * @brief Get field command_type from event AVRCP_SUBEVENT_NOTIFICATION_TRACK_CHANGED 7958 * @param event packet 7959 * @return command_type 7960 * @note: btstack_type 1 7961 */ 7962 static inline uint8_t avrcp_subevent_notification_track_changed_get_command_type(const uint8_t * event){ 7963 return event[5]; 7964 } 7965 7966 /** 7967 * @brief Get field avrcp_cid from event AVRCP_SUBEVENT_NOTIFICATION_EVENT_TRACK_REACHED_END 7968 * @param event packet 7969 * @return avrcp_cid 7970 * @note: btstack_type 2 7971 */ 7972 static inline uint16_t avrcp_subevent_notification_event_track_reached_end_get_avrcp_cid(const uint8_t * event){ 7973 return little_endian_read_16(event, 3); 7974 } 7975 /** 7976 * @brief Get field command_type from event AVRCP_SUBEVENT_NOTIFICATION_EVENT_TRACK_REACHED_END 7977 * @param event packet 7978 * @return command_type 7979 * @note: btstack_type 1 7980 */ 7981 static inline uint8_t avrcp_subevent_notification_event_track_reached_end_get_command_type(const uint8_t * event){ 7982 return event[5]; 7983 } 7984 7985 /** 7986 * @brief Get field avrcp_cid from event AVRCP_SUBEVENT_NOTIFICATION_EVENT_TRACK_REACHED_START 7987 * @param event packet 7988 * @return avrcp_cid 7989 * @note: btstack_type 2 7990 */ 7991 static inline uint16_t avrcp_subevent_notification_event_track_reached_start_get_avrcp_cid(const uint8_t * event){ 7992 return little_endian_read_16(event, 3); 7993 } 7994 /** 7995 * @brief Get field command_type from event AVRCP_SUBEVENT_NOTIFICATION_EVENT_TRACK_REACHED_START 7996 * @param event packet 7997 * @return command_type 7998 * @note: btstack_type 1 7999 */ 8000 static inline uint8_t avrcp_subevent_notification_event_track_reached_start_get_command_type(const uint8_t * event){ 8001 return event[5]; 8002 } 8003 8004 /** 8005 * @brief Get field avrcp_cid from event AVRCP_SUBEVENT_NOTIFICATION_EVENT_PLAYBACK_POS_CHANGED 8006 * @param event packet 8007 * @return avrcp_cid 8008 * @note: btstack_type 2 8009 */ 8010 static inline uint16_t avrcp_subevent_notification_event_playback_pos_changed_get_avrcp_cid(const uint8_t * event){ 8011 return little_endian_read_16(event, 3); 8012 } 8013 /** 8014 * @brief Get field command_type from event AVRCP_SUBEVENT_NOTIFICATION_EVENT_PLAYBACK_POS_CHANGED 8015 * @param event packet 8016 * @return command_type 8017 * @note: btstack_type 1 8018 */ 8019 static inline uint8_t avrcp_subevent_notification_event_playback_pos_changed_get_command_type(const uint8_t * event){ 8020 return event[5]; 8021 } 8022 /** 8023 * @brief Get field playback_position from event AVRCP_SUBEVENT_NOTIFICATION_EVENT_PLAYBACK_POS_CHANGED 8024 * @param event packet 8025 * @return playback_position 8026 * @note: btstack_type 4 8027 */ 8028 static inline uint32_t avrcp_subevent_notification_event_playback_pos_changed_get_playback_position(const uint8_t * event){ 8029 return little_endian_read_32(event, 6); 8030 } 8031 8032 /** 8033 * @brief Get field avrcp_cid from event AVRCP_SUBEVENT_NOTIFICATION_EVENT_BATT_STATUS_CHANGED 8034 * @param event packet 8035 * @return avrcp_cid 8036 * @note: btstack_type 2 8037 */ 8038 static inline uint16_t avrcp_subevent_notification_event_batt_status_changed_get_avrcp_cid(const uint8_t * event){ 8039 return little_endian_read_16(event, 3); 8040 } 8041 /** 8042 * @brief Get field command_type from event AVRCP_SUBEVENT_NOTIFICATION_EVENT_BATT_STATUS_CHANGED 8043 * @param event packet 8044 * @return command_type 8045 * @note: btstack_type 1 8046 */ 8047 static inline uint8_t avrcp_subevent_notification_event_batt_status_changed_get_command_type(const uint8_t * event){ 8048 return event[5]; 8049 } 8050 /** 8051 * @brief Get field battery_status from event AVRCP_SUBEVENT_NOTIFICATION_EVENT_BATT_STATUS_CHANGED 8052 * @param event packet 8053 * @return battery_status 8054 * @note: btstack_type 1 8055 */ 8056 static inline uint8_t avrcp_subevent_notification_event_batt_status_changed_get_battery_status(const uint8_t * event){ 8057 return event[6]; 8058 } 8059 8060 /** 8061 * @brief Get field avrcp_cid from event AVRCP_SUBEVENT_NOTIFICATION_EVENT_SYSTEM_STATUS_CHANGED 8062 * @param event packet 8063 * @return avrcp_cid 8064 * @note: btstack_type 2 8065 */ 8066 static inline uint16_t avrcp_subevent_notification_event_system_status_changed_get_avrcp_cid(const uint8_t * event){ 8067 return little_endian_read_16(event, 3); 8068 } 8069 /** 8070 * @brief Get field command_type from event AVRCP_SUBEVENT_NOTIFICATION_EVENT_SYSTEM_STATUS_CHANGED 8071 * @param event packet 8072 * @return command_type 8073 * @note: btstack_type 1 8074 */ 8075 static inline uint8_t avrcp_subevent_notification_event_system_status_changed_get_command_type(const uint8_t * event){ 8076 return event[5]; 8077 } 8078 /** 8079 * @brief Get field system_status from event AVRCP_SUBEVENT_NOTIFICATION_EVENT_SYSTEM_STATUS_CHANGED 8080 * @param event packet 8081 * @return system_status 8082 * @note: btstack_type 1 8083 */ 8084 static inline uint8_t avrcp_subevent_notification_event_system_status_changed_get_system_status(const uint8_t * event){ 8085 return event[6]; 8086 } 8087 8088 /** 8089 * @brief Get field avrcp_cid from event AVRCP_SUBEVENT_NOTIFICATION_NOW_PLAYING_CONTENT_CHANGED 8090 * @param event packet 8091 * @return avrcp_cid 8092 * @note: btstack_type 2 8093 */ 8094 static inline uint16_t avrcp_subevent_notification_now_playing_content_changed_get_avrcp_cid(const uint8_t * event){ 8095 return little_endian_read_16(event, 3); 8096 } 8097 /** 8098 * @brief Get field command_type from event AVRCP_SUBEVENT_NOTIFICATION_NOW_PLAYING_CONTENT_CHANGED 8099 * @param event packet 8100 * @return command_type 8101 * @note: btstack_type 1 8102 */ 8103 static inline uint8_t avrcp_subevent_notification_now_playing_content_changed_get_command_type(const uint8_t * event){ 8104 return event[5]; 8105 } 8106 8107 /** 8108 * @brief Get field avrcp_cid from event AVRCP_SUBEVENT_NOTIFICATION_AVAILABLE_PLAYERS_CHANGED 8109 * @param event packet 8110 * @return avrcp_cid 8111 * @note: btstack_type 2 8112 */ 8113 static inline uint16_t avrcp_subevent_notification_available_players_changed_get_avrcp_cid(const uint8_t * event){ 8114 return little_endian_read_16(event, 3); 8115 } 8116 /** 8117 * @brief Get field command_type from event AVRCP_SUBEVENT_NOTIFICATION_AVAILABLE_PLAYERS_CHANGED 8118 * @param event packet 8119 * @return command_type 8120 * @note: btstack_type 1 8121 */ 8122 static inline uint8_t avrcp_subevent_notification_available_players_changed_get_command_type(const uint8_t * event){ 8123 return event[5]; 8124 } 8125 8126 /** 8127 * @brief Get field avrcp_cid from event AVRCP_SUBEVENT_NOTIFICATION_EVENT_UIDS_CHANGED 8128 * @param event packet 8129 * @return avrcp_cid 8130 * @note: btstack_type 2 8131 */ 8132 static inline uint16_t avrcp_subevent_notification_event_uids_changed_get_avrcp_cid(const uint8_t * event){ 8133 return little_endian_read_16(event, 3); 8134 } 8135 /** 8136 * @brief Get field command_type from event AVRCP_SUBEVENT_NOTIFICATION_EVENT_UIDS_CHANGED 8137 * @param event packet 8138 * @return command_type 8139 * @note: btstack_type 1 8140 */ 8141 static inline uint8_t avrcp_subevent_notification_event_uids_changed_get_command_type(const uint8_t * event){ 8142 return event[5]; 8143 } 8144 /** 8145 * @brief Get field uid_counter from event AVRCP_SUBEVENT_NOTIFICATION_EVENT_UIDS_CHANGED 8146 * @param event packet 8147 * @return uid_counter 8148 * @note: btstack_type 2 8149 */ 8150 static inline uint16_t avrcp_subevent_notification_event_uids_changed_get_uid_counter(const uint8_t * event){ 8151 return little_endian_read_16(event, 6); 8152 } 8153 8154 /** 8155 * @brief Get field avrcp_cid from event AVRCP_SUBEVENT_NOTIFICATION_VOLUME_CHANGED 8156 * @param event packet 8157 * @return avrcp_cid 8158 * @note: btstack_type 2 8159 */ 8160 static inline uint16_t avrcp_subevent_notification_volume_changed_get_avrcp_cid(const uint8_t * event){ 8161 return little_endian_read_16(event, 3); 8162 } 8163 /** 8164 * @brief Get field command_type from event AVRCP_SUBEVENT_NOTIFICATION_VOLUME_CHANGED 8165 * @param event packet 8166 * @return command_type 8167 * @note: btstack_type 1 8168 */ 8169 static inline uint8_t avrcp_subevent_notification_volume_changed_get_command_type(const uint8_t * event){ 8170 return event[5]; 8171 } 8172 /** 8173 * @brief Get field absolute_volume from event AVRCP_SUBEVENT_NOTIFICATION_VOLUME_CHANGED 8174 * @param event packet 8175 * @return absolute_volume 8176 * @note: btstack_type 1 8177 */ 8178 static inline uint8_t avrcp_subevent_notification_volume_changed_get_absolute_volume(const uint8_t * event){ 8179 return event[6]; 8180 } 8181 8182 /** 8183 * @brief Get field avrcp_cid from event AVRCP_SUBEVENT_SET_ABSOLUTE_VOLUME_RESPONSE 8184 * @param event packet 8185 * @return avrcp_cid 8186 * @note: btstack_type 2 8187 */ 8188 static inline uint16_t avrcp_subevent_set_absolute_volume_response_get_avrcp_cid(const uint8_t * event){ 8189 return little_endian_read_16(event, 3); 8190 } 8191 /** 8192 * @brief Get field command_type from event AVRCP_SUBEVENT_SET_ABSOLUTE_VOLUME_RESPONSE 8193 * @param event packet 8194 * @return command_type 8195 * @note: btstack_type 1 8196 */ 8197 static inline uint8_t avrcp_subevent_set_absolute_volume_response_get_command_type(const uint8_t * event){ 8198 return event[5]; 8199 } 8200 /** 8201 * @brief Get field absolute_volume from event AVRCP_SUBEVENT_SET_ABSOLUTE_VOLUME_RESPONSE 8202 * @param event packet 8203 * @return absolute_volume 8204 * @note: btstack_type 1 8205 */ 8206 static inline uint8_t avrcp_subevent_set_absolute_volume_response_get_absolute_volume(const uint8_t * event){ 8207 return event[6]; 8208 } 8209 8210 /** 8211 * @brief Get field avrcp_cid from event AVRCP_SUBEVENT_NOTIFICATION_STATE 8212 * @param event packet 8213 * @return avrcp_cid 8214 * @note: btstack_type 2 8215 */ 8216 static inline uint16_t avrcp_subevent_notification_state_get_avrcp_cid(const uint8_t * event){ 8217 return little_endian_read_16(event, 3); 8218 } 8219 /** 8220 * @brief Get field status from event AVRCP_SUBEVENT_NOTIFICATION_STATE 8221 * @param event packet 8222 * @return status 8223 * @note: btstack_type 1 8224 */ 8225 static inline uint8_t avrcp_subevent_notification_state_get_status(const uint8_t * event){ 8226 return event[5]; 8227 } 8228 /** 8229 * @brief Get field enabled from event AVRCP_SUBEVENT_NOTIFICATION_STATE 8230 * @param event packet 8231 * @return enabled 8232 * @note: btstack_type 1 8233 */ 8234 static inline uint8_t avrcp_subevent_notification_state_get_enabled(const uint8_t * event){ 8235 return event[6]; 8236 } 8237 /** 8238 * @brief Get field event_id from event AVRCP_SUBEVENT_NOTIFICATION_STATE 8239 * @param event packet 8240 * @return event_id 8241 * @note: btstack_type 1 8242 */ 8243 static inline uint8_t avrcp_subevent_notification_state_get_event_id(const uint8_t * event){ 8244 return event[7]; 8245 } 8246 8247 /** 8248 * @brief Get field status from event AVRCP_SUBEVENT_CONNECTION_ESTABLISHED 8249 * @param event packet 8250 * @return status 8251 * @note: btstack_type 1 8252 */ 8253 static inline uint8_t avrcp_subevent_connection_established_get_status(const uint8_t * event){ 8254 return event[3]; 8255 } 8256 /** 8257 * @brief Get field avrcp_cid from event AVRCP_SUBEVENT_CONNECTION_ESTABLISHED 8258 * @param event packet 8259 * @return avrcp_cid 8260 * @note: btstack_type 2 8261 */ 8262 static inline uint16_t avrcp_subevent_connection_established_get_avrcp_cid(const uint8_t * event){ 8263 return little_endian_read_16(event, 4); 8264 } 8265 /** 8266 * @brief Get field bd_addr from event AVRCP_SUBEVENT_CONNECTION_ESTABLISHED 8267 * @param event packet 8268 * @param Pointer to storage for bd_addr 8269 * @note: btstack_type B 8270 */ 8271 static inline void avrcp_subevent_connection_established_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 8272 reverse_bytes(&event[6], bd_addr, 6); 8273 } 8274 /** 8275 * @brief Get field con_handle from event AVRCP_SUBEVENT_CONNECTION_ESTABLISHED 8276 * @param event packet 8277 * @return con_handle 8278 * @note: btstack_type 2 8279 */ 8280 static inline uint16_t avrcp_subevent_connection_established_get_con_handle(const uint8_t * event){ 8281 return little_endian_read_16(event, 12); 8282 } 8283 8284 /** 8285 * @brief Get field avrcp_cid from event AVRCP_SUBEVENT_CONNECTION_RELEASED 8286 * @param event packet 8287 * @return avrcp_cid 8288 * @note: btstack_type 2 8289 */ 8290 static inline uint16_t avrcp_subevent_connection_released_get_avrcp_cid(const uint8_t * event){ 8291 return little_endian_read_16(event, 3); 8292 } 8293 8294 /** 8295 * @brief Get field avrcp_cid from event AVRCP_SUBEVENT_SHUFFLE_AND_REPEAT_MODE 8296 * @param event packet 8297 * @return avrcp_cid 8298 * @note: btstack_type 2 8299 */ 8300 static inline uint16_t avrcp_subevent_shuffle_and_repeat_mode_get_avrcp_cid(const uint8_t * event){ 8301 return little_endian_read_16(event, 3); 8302 } 8303 /** 8304 * @brief Get field command_type from event AVRCP_SUBEVENT_SHUFFLE_AND_REPEAT_MODE 8305 * @param event packet 8306 * @return command_type 8307 * @note: btstack_type 1 8308 */ 8309 static inline uint8_t avrcp_subevent_shuffle_and_repeat_mode_get_command_type(const uint8_t * event){ 8310 return event[5]; 8311 } 8312 /** 8313 * @brief Get field repeat_mode from event AVRCP_SUBEVENT_SHUFFLE_AND_REPEAT_MODE 8314 * @param event packet 8315 * @return repeat_mode 8316 * @note: btstack_type 1 8317 */ 8318 static inline uint8_t avrcp_subevent_shuffle_and_repeat_mode_get_repeat_mode(const uint8_t * event){ 8319 return event[6]; 8320 } 8321 /** 8322 * @brief Get field shuffle_mode from event AVRCP_SUBEVENT_SHUFFLE_AND_REPEAT_MODE 8323 * @param event packet 8324 * @return shuffle_mode 8325 * @note: btstack_type 1 8326 */ 8327 static inline uint8_t avrcp_subevent_shuffle_and_repeat_mode_get_shuffle_mode(const uint8_t * event){ 8328 return event[7]; 8329 } 8330 8331 /** 8332 * @brief Get field avrcp_cid from event AVRCP_SUBEVENT_PLAY_STATUS 8333 * @param event packet 8334 * @return avrcp_cid 8335 * @note: btstack_type 2 8336 */ 8337 static inline uint16_t avrcp_subevent_play_status_get_avrcp_cid(const uint8_t * event){ 8338 return little_endian_read_16(event, 3); 8339 } 8340 /** 8341 * @brief Get field command_type from event AVRCP_SUBEVENT_PLAY_STATUS 8342 * @param event packet 8343 * @return command_type 8344 * @note: btstack_type 1 8345 */ 8346 static inline uint8_t avrcp_subevent_play_status_get_command_type(const uint8_t * event){ 8347 return event[5]; 8348 } 8349 /** 8350 * @brief Get field song_length from event AVRCP_SUBEVENT_PLAY_STATUS 8351 * @param event packet 8352 * @return song_length 8353 * @note: btstack_type 4 8354 */ 8355 static inline uint32_t avrcp_subevent_play_status_get_song_length(const uint8_t * event){ 8356 return little_endian_read_32(event, 6); 8357 } 8358 /** 8359 * @brief Get field song_position from event AVRCP_SUBEVENT_PLAY_STATUS 8360 * @param event packet 8361 * @return song_position 8362 * @note: btstack_type 4 8363 */ 8364 static inline uint32_t avrcp_subevent_play_status_get_song_position(const uint8_t * event){ 8365 return little_endian_read_32(event, 10); 8366 } 8367 /** 8368 * @brief Get field play_status from event AVRCP_SUBEVENT_PLAY_STATUS 8369 * @param event packet 8370 * @return play_status 8371 * @note: btstack_type 1 8372 */ 8373 static inline uint8_t avrcp_subevent_play_status_get_play_status(const uint8_t * event){ 8374 return event[14]; 8375 } 8376 8377 /** 8378 * @brief Get field avrcp_cid from event AVRCP_SUBEVENT_OPERATION_START 8379 * @param event packet 8380 * @return avrcp_cid 8381 * @note: btstack_type 2 8382 */ 8383 static inline uint16_t avrcp_subevent_operation_start_get_avrcp_cid(const uint8_t * event){ 8384 return little_endian_read_16(event, 3); 8385 } 8386 /** 8387 * @brief Get field command_type from event AVRCP_SUBEVENT_OPERATION_START 8388 * @param event packet 8389 * @return command_type 8390 * @note: btstack_type 1 8391 */ 8392 static inline uint8_t avrcp_subevent_operation_start_get_command_type(const uint8_t * event){ 8393 return event[5]; 8394 } 8395 /** 8396 * @brief Get field operation_id from event AVRCP_SUBEVENT_OPERATION_START 8397 * @param event packet 8398 * @return operation_id 8399 * @note: btstack_type 1 8400 */ 8401 static inline uint8_t avrcp_subevent_operation_start_get_operation_id(const uint8_t * event){ 8402 return event[6]; 8403 } 8404 8405 /** 8406 * @brief Get field avrcp_cid from event AVRCP_SUBEVENT_OPERATION_COMPLETE 8407 * @param event packet 8408 * @return avrcp_cid 8409 * @note: btstack_type 2 8410 */ 8411 static inline uint16_t avrcp_subevent_operation_complete_get_avrcp_cid(const uint8_t * event){ 8412 return little_endian_read_16(event, 3); 8413 } 8414 /** 8415 * @brief Get field command_type from event AVRCP_SUBEVENT_OPERATION_COMPLETE 8416 * @param event packet 8417 * @return command_type 8418 * @note: btstack_type 1 8419 */ 8420 static inline uint8_t avrcp_subevent_operation_complete_get_command_type(const uint8_t * event){ 8421 return event[5]; 8422 } 8423 /** 8424 * @brief Get field operation_id from event AVRCP_SUBEVENT_OPERATION_COMPLETE 8425 * @param event packet 8426 * @return operation_id 8427 * @note: btstack_type 1 8428 */ 8429 static inline uint8_t avrcp_subevent_operation_complete_get_operation_id(const uint8_t * event){ 8430 return event[6]; 8431 } 8432 8433 /** 8434 * @brief Get field avrcp_cid from event AVRCP_SUBEVENT_PLAYER_APPLICATION_VALUE_RESPONSE 8435 * @param event packet 8436 * @return avrcp_cid 8437 * @note: btstack_type 2 8438 */ 8439 static inline uint16_t avrcp_subevent_player_application_value_response_get_avrcp_cid(const uint8_t * event){ 8440 return little_endian_read_16(event, 3); 8441 } 8442 /** 8443 * @brief Get field command_type from event AVRCP_SUBEVENT_PLAYER_APPLICATION_VALUE_RESPONSE 8444 * @param event packet 8445 * @return command_type 8446 * @note: btstack_type 1 8447 */ 8448 static inline uint8_t avrcp_subevent_player_application_value_response_get_command_type(const uint8_t * event){ 8449 return event[5]; 8450 } 8451 8452 /** 8453 * @brief Get field avrcp_cid from event AVRCP_SUBEVENT_PLAY_STATUS_QUERY 8454 * @param event packet 8455 * @return avrcp_cid 8456 * @note: btstack_type 2 8457 */ 8458 static inline uint16_t avrcp_subevent_play_status_query_get_avrcp_cid(const uint8_t * event){ 8459 return little_endian_read_16(event, 3); 8460 } 8461 8462 /** 8463 * @brief Get field avrcp_cid from event AVRCP_SUBEVENT_OPERATION 8464 * @param event packet 8465 * @return avrcp_cid 8466 * @note: btstack_type 2 8467 */ 8468 static inline uint16_t avrcp_subevent_operation_get_avrcp_cid(const uint8_t * event){ 8469 return little_endian_read_16(event, 3); 8470 } 8471 /** 8472 * @brief Get field operation_id from event AVRCP_SUBEVENT_OPERATION 8473 * @param event packet 8474 * @return operation_id 8475 * @note: btstack_type 1 8476 */ 8477 static inline uint8_t avrcp_subevent_operation_get_operation_id(const uint8_t * event){ 8478 return event[5]; 8479 } 8480 /** 8481 * @brief Get field button_pressed from event AVRCP_SUBEVENT_OPERATION 8482 * @param event packet 8483 * @return button_pressed 8484 * @note: btstack_type 1 8485 */ 8486 static inline uint8_t avrcp_subevent_operation_get_button_pressed(const uint8_t * event){ 8487 return event[6]; 8488 } 8489 /** 8490 * @brief Get field operands_length from event AVRCP_SUBEVENT_OPERATION 8491 * @param event packet 8492 * @return operands_length 8493 * @note: btstack_type 1 8494 */ 8495 static inline uint8_t avrcp_subevent_operation_get_operands_length(const uint8_t * event){ 8496 return event[7]; 8497 } 8498 /** 8499 * @brief Get field operand from event AVRCP_SUBEVENT_OPERATION 8500 * @param event packet 8501 * @return operand 8502 * @note: btstack_type 1 8503 */ 8504 static inline uint8_t avrcp_subevent_operation_get_operand(const uint8_t * event){ 8505 return event[8]; 8506 } 8507 8508 /** 8509 * @brief Get field avrcp_cid from event AVRCP_SUBEVENT_NOW_PLAYING_TRACK_INFO 8510 * @param event packet 8511 * @return avrcp_cid 8512 * @note: btstack_type 2 8513 */ 8514 static inline uint16_t avrcp_subevent_now_playing_track_info_get_avrcp_cid(const uint8_t * event){ 8515 return little_endian_read_16(event, 3); 8516 } 8517 /** 8518 * @brief Get field command_type from event AVRCP_SUBEVENT_NOW_PLAYING_TRACK_INFO 8519 * @param event packet 8520 * @return command_type 8521 * @note: btstack_type 1 8522 */ 8523 static inline uint8_t avrcp_subevent_now_playing_track_info_get_command_type(const uint8_t * event){ 8524 return event[5]; 8525 } 8526 /** 8527 * @brief Get field track from event AVRCP_SUBEVENT_NOW_PLAYING_TRACK_INFO 8528 * @param event packet 8529 * @return track 8530 * @note: btstack_type 1 8531 */ 8532 static inline uint8_t avrcp_subevent_now_playing_track_info_get_track(const uint8_t * event){ 8533 return event[6]; 8534 } 8535 8536 /** 8537 * @brief Get field avrcp_cid from event AVRCP_SUBEVENT_NOW_PLAYING_TOTAL_TRACKS_INFO 8538 * @param event packet 8539 * @return avrcp_cid 8540 * @note: btstack_type 2 8541 */ 8542 static inline uint16_t avrcp_subevent_now_playing_total_tracks_info_get_avrcp_cid(const uint8_t * event){ 8543 return little_endian_read_16(event, 3); 8544 } 8545 /** 8546 * @brief Get field command_type from event AVRCP_SUBEVENT_NOW_PLAYING_TOTAL_TRACKS_INFO 8547 * @param event packet 8548 * @return command_type 8549 * @note: btstack_type 1 8550 */ 8551 static inline uint8_t avrcp_subevent_now_playing_total_tracks_info_get_command_type(const uint8_t * event){ 8552 return event[5]; 8553 } 8554 /** 8555 * @brief Get field total_tracks from event AVRCP_SUBEVENT_NOW_PLAYING_TOTAL_TRACKS_INFO 8556 * @param event packet 8557 * @return total_tracks 8558 * @note: btstack_type 1 8559 */ 8560 static inline uint8_t avrcp_subevent_now_playing_total_tracks_info_get_total_tracks(const uint8_t * event){ 8561 return event[6]; 8562 } 8563 8564 /** 8565 * @brief Get field avrcp_cid from event AVRCP_SUBEVENT_NOW_PLAYING_SONG_LENGTH_MS_INFO 8566 * @param event packet 8567 * @return avrcp_cid 8568 * @note: btstack_type 2 8569 */ 8570 static inline uint16_t avrcp_subevent_now_playing_song_length_ms_info_get_avrcp_cid(const uint8_t * event){ 8571 return little_endian_read_16(event, 3); 8572 } 8573 /** 8574 * @brief Get field command_type from event AVRCP_SUBEVENT_NOW_PLAYING_SONG_LENGTH_MS_INFO 8575 * @param event packet 8576 * @return command_type 8577 * @note: btstack_type 1 8578 */ 8579 static inline uint8_t avrcp_subevent_now_playing_song_length_ms_info_get_command_type(const uint8_t * event){ 8580 return event[5]; 8581 } 8582 /** 8583 * @brief Get field song_length from event AVRCP_SUBEVENT_NOW_PLAYING_SONG_LENGTH_MS_INFO 8584 * @param event packet 8585 * @return song_length 8586 * @note: btstack_type 4 8587 */ 8588 static inline uint32_t avrcp_subevent_now_playing_song_length_ms_info_get_song_length(const uint8_t * event){ 8589 return little_endian_read_32(event, 6); 8590 } 8591 8592 /** 8593 * @brief Get field avrcp_cid from event AVRCP_SUBEVENT_NOW_PLAYING_TITLE_INFO 8594 * @param event packet 8595 * @return avrcp_cid 8596 * @note: btstack_type 2 8597 */ 8598 static inline uint16_t avrcp_subevent_now_playing_title_info_get_avrcp_cid(const uint8_t * event){ 8599 return little_endian_read_16(event, 3); 8600 } 8601 /** 8602 * @brief Get field command_type from event AVRCP_SUBEVENT_NOW_PLAYING_TITLE_INFO 8603 * @param event packet 8604 * @return command_type 8605 * @note: btstack_type 1 8606 */ 8607 static inline uint8_t avrcp_subevent_now_playing_title_info_get_command_type(const uint8_t * event){ 8608 return event[5]; 8609 } 8610 /** 8611 * @brief Get field value_len from event AVRCP_SUBEVENT_NOW_PLAYING_TITLE_INFO 8612 * @param event packet 8613 * @return value_len 8614 * @note: btstack_type J 8615 */ 8616 static inline uint8_t avrcp_subevent_now_playing_title_info_get_value_len(const uint8_t * event){ 8617 return event[6]; 8618 } 8619 /** 8620 * @brief Get field value from event AVRCP_SUBEVENT_NOW_PLAYING_TITLE_INFO 8621 * @param event packet 8622 * @return value 8623 * @note: btstack_type V 8624 */ 8625 static inline const uint8_t * avrcp_subevent_now_playing_title_info_get_value(const uint8_t * event){ 8626 return &event[7]; 8627 } 8628 8629 /** 8630 * @brief Get field avrcp_cid from event AVRCP_SUBEVENT_NOW_PLAYING_ARTIST_INFO 8631 * @param event packet 8632 * @return avrcp_cid 8633 * @note: btstack_type 2 8634 */ 8635 static inline uint16_t avrcp_subevent_now_playing_artist_info_get_avrcp_cid(const uint8_t * event){ 8636 return little_endian_read_16(event, 3); 8637 } 8638 /** 8639 * @brief Get field command_type from event AVRCP_SUBEVENT_NOW_PLAYING_ARTIST_INFO 8640 * @param event packet 8641 * @return command_type 8642 * @note: btstack_type 1 8643 */ 8644 static inline uint8_t avrcp_subevent_now_playing_artist_info_get_command_type(const uint8_t * event){ 8645 return event[5]; 8646 } 8647 /** 8648 * @brief Get field value_len from event AVRCP_SUBEVENT_NOW_PLAYING_ARTIST_INFO 8649 * @param event packet 8650 * @return value_len 8651 * @note: btstack_type J 8652 */ 8653 static inline uint8_t avrcp_subevent_now_playing_artist_info_get_value_len(const uint8_t * event){ 8654 return event[6]; 8655 } 8656 /** 8657 * @brief Get field value from event AVRCP_SUBEVENT_NOW_PLAYING_ARTIST_INFO 8658 * @param event packet 8659 * @return value 8660 * @note: btstack_type V 8661 */ 8662 static inline const uint8_t * avrcp_subevent_now_playing_artist_info_get_value(const uint8_t * event){ 8663 return &event[7]; 8664 } 8665 8666 /** 8667 * @brief Get field avrcp_cid from event AVRCP_SUBEVENT_NOW_PLAYING_ALBUM_INFO 8668 * @param event packet 8669 * @return avrcp_cid 8670 * @note: btstack_type 2 8671 */ 8672 static inline uint16_t avrcp_subevent_now_playing_album_info_get_avrcp_cid(const uint8_t * event){ 8673 return little_endian_read_16(event, 3); 8674 } 8675 /** 8676 * @brief Get field command_type from event AVRCP_SUBEVENT_NOW_PLAYING_ALBUM_INFO 8677 * @param event packet 8678 * @return command_type 8679 * @note: btstack_type 1 8680 */ 8681 static inline uint8_t avrcp_subevent_now_playing_album_info_get_command_type(const uint8_t * event){ 8682 return event[5]; 8683 } 8684 /** 8685 * @brief Get field value_len from event AVRCP_SUBEVENT_NOW_PLAYING_ALBUM_INFO 8686 * @param event packet 8687 * @return value_len 8688 * @note: btstack_type J 8689 */ 8690 static inline uint8_t avrcp_subevent_now_playing_album_info_get_value_len(const uint8_t * event){ 8691 return event[6]; 8692 } 8693 /** 8694 * @brief Get field value from event AVRCP_SUBEVENT_NOW_PLAYING_ALBUM_INFO 8695 * @param event packet 8696 * @return value 8697 * @note: btstack_type V 8698 */ 8699 static inline const uint8_t * avrcp_subevent_now_playing_album_info_get_value(const uint8_t * event){ 8700 return &event[7]; 8701 } 8702 8703 /** 8704 * @brief Get field avrcp_cid from event AVRCP_SUBEVENT_NOW_PLAYING_GENRE_INFO 8705 * @param event packet 8706 * @return avrcp_cid 8707 * @note: btstack_type 2 8708 */ 8709 static inline uint16_t avrcp_subevent_now_playing_genre_info_get_avrcp_cid(const uint8_t * event){ 8710 return little_endian_read_16(event, 3); 8711 } 8712 /** 8713 * @brief Get field command_type from event AVRCP_SUBEVENT_NOW_PLAYING_GENRE_INFO 8714 * @param event packet 8715 * @return command_type 8716 * @note: btstack_type 1 8717 */ 8718 static inline uint8_t avrcp_subevent_now_playing_genre_info_get_command_type(const uint8_t * event){ 8719 return event[5]; 8720 } 8721 /** 8722 * @brief Get field value_len from event AVRCP_SUBEVENT_NOW_PLAYING_GENRE_INFO 8723 * @param event packet 8724 * @return value_len 8725 * @note: btstack_type J 8726 */ 8727 static inline uint8_t avrcp_subevent_now_playing_genre_info_get_value_len(const uint8_t * event){ 8728 return event[6]; 8729 } 8730 /** 8731 * @brief Get field value from event AVRCP_SUBEVENT_NOW_PLAYING_GENRE_INFO 8732 * @param event packet 8733 * @return value 8734 * @note: btstack_type V 8735 */ 8736 static inline const uint8_t * avrcp_subevent_now_playing_genre_info_get_value(const uint8_t * event){ 8737 return &event[7]; 8738 } 8739 8740 /** 8741 * @brief Get field avrcp_cid from event AVRCP_SUBEVENT_NOW_PLAYING_INFO_DONE 8742 * @param event packet 8743 * @return avrcp_cid 8744 * @note: btstack_type 2 8745 */ 8746 static inline uint16_t avrcp_subevent_now_playing_info_done_get_avrcp_cid(const uint8_t * event){ 8747 return little_endian_read_16(event, 3); 8748 } 8749 /** 8750 * @brief Get field command_type from event AVRCP_SUBEVENT_NOW_PLAYING_INFO_DONE 8751 * @param event packet 8752 * @return command_type 8753 * @note: btstack_type 1 8754 */ 8755 static inline uint8_t avrcp_subevent_now_playing_info_done_get_command_type(const uint8_t * event){ 8756 return event[5]; 8757 } 8758 /** 8759 * @brief Get field status from event AVRCP_SUBEVENT_NOW_PLAYING_INFO_DONE 8760 * @param event packet 8761 * @return status 8762 * @note: btstack_type 1 8763 */ 8764 static inline uint8_t avrcp_subevent_now_playing_info_done_get_status(const uint8_t * event){ 8765 return event[6]; 8766 } 8767 8768 /** 8769 * @brief Get field avrcp_cid from event AVRCP_SUBEVENT_NOTIFICATION_PLAYBACK_POS_CHANGED 8770 * @param event packet 8771 * @return avrcp_cid 8772 * @note: btstack_type 2 8773 */ 8774 static inline uint16_t avrcp_subevent_notification_playback_pos_changed_get_avrcp_cid(const uint8_t * event){ 8775 return little_endian_read_16(event, 3); 8776 } 8777 /** 8778 * @brief Get field command_type from event AVRCP_SUBEVENT_NOTIFICATION_PLAYBACK_POS_CHANGED 8779 * @param event packet 8780 * @return command_type 8781 * @note: btstack_type 1 8782 */ 8783 static inline uint8_t avrcp_subevent_notification_playback_pos_changed_get_command_type(const uint8_t * event){ 8784 return event[5]; 8785 } 8786 /** 8787 * @brief Get field playback_position_ms from event AVRCP_SUBEVENT_NOTIFICATION_PLAYBACK_POS_CHANGED 8788 * @param event packet 8789 * @return playback_position_ms 8790 * @note: btstack_type 4 8791 */ 8792 static inline uint32_t avrcp_subevent_notification_playback_pos_changed_get_playback_position_ms(const uint8_t * event){ 8793 return little_endian_read_32(event, 6); 8794 } 8795 8796 /** 8797 * @brief Get field avrcp_cid from event AVRCP_SUBEVENT_GET_CAPABILITY_EVENT_ID 8798 * @param event packet 8799 * @return avrcp_cid 8800 * @note: btstack_type 2 8801 */ 8802 static inline uint16_t avrcp_subevent_get_capability_event_id_get_avrcp_cid(const uint8_t * event){ 8803 return little_endian_read_16(event, 3); 8804 } 8805 /** 8806 * @brief Get field command_type from event AVRCP_SUBEVENT_GET_CAPABILITY_EVENT_ID 8807 * @param event packet 8808 * @return command_type 8809 * @note: btstack_type 1 8810 */ 8811 static inline uint8_t avrcp_subevent_get_capability_event_id_get_command_type(const uint8_t * event){ 8812 return event[5]; 8813 } 8814 /** 8815 * @brief Get field status from event AVRCP_SUBEVENT_GET_CAPABILITY_EVENT_ID 8816 * @param event packet 8817 * @return status 8818 * @note: btstack_type 1 8819 */ 8820 static inline uint8_t avrcp_subevent_get_capability_event_id_get_status(const uint8_t * event){ 8821 return event[6]; 8822 } 8823 /** 8824 * @brief Get field event_id from event AVRCP_SUBEVENT_GET_CAPABILITY_EVENT_ID 8825 * @param event packet 8826 * @return event_id 8827 * @note: btstack_type 1 8828 */ 8829 static inline uint8_t avrcp_subevent_get_capability_event_id_get_event_id(const uint8_t * event){ 8830 return event[7]; 8831 } 8832 8833 /** 8834 * @brief Get field avrcp_cid from event AVRCP_SUBEVENT_GET_CAPABILITY_EVENT_ID_DONE 8835 * @param event packet 8836 * @return avrcp_cid 8837 * @note: btstack_type 2 8838 */ 8839 static inline uint16_t avrcp_subevent_get_capability_event_id_done_get_avrcp_cid(const uint8_t * event){ 8840 return little_endian_read_16(event, 3); 8841 } 8842 /** 8843 * @brief Get field command_type from event AVRCP_SUBEVENT_GET_CAPABILITY_EVENT_ID_DONE 8844 * @param event packet 8845 * @return command_type 8846 * @note: btstack_type 1 8847 */ 8848 static inline uint8_t avrcp_subevent_get_capability_event_id_done_get_command_type(const uint8_t * event){ 8849 return event[5]; 8850 } 8851 /** 8852 * @brief Get field status from event AVRCP_SUBEVENT_GET_CAPABILITY_EVENT_ID_DONE 8853 * @param event packet 8854 * @return status 8855 * @note: btstack_type 1 8856 */ 8857 static inline uint8_t avrcp_subevent_get_capability_event_id_done_get_status(const uint8_t * event){ 8858 return event[6]; 8859 } 8860 8861 /** 8862 * @brief Get field avrcp_cid from event AVRCP_SUBEVENT_GET_CAPABILITY_COMPANY_ID 8863 * @param event packet 8864 * @return avrcp_cid 8865 * @note: btstack_type 2 8866 */ 8867 static inline uint16_t avrcp_subevent_get_capability_company_id_get_avrcp_cid(const uint8_t * event){ 8868 return little_endian_read_16(event, 3); 8869 } 8870 /** 8871 * @brief Get field command_type from event AVRCP_SUBEVENT_GET_CAPABILITY_COMPANY_ID 8872 * @param event packet 8873 * @return command_type 8874 * @note: btstack_type 1 8875 */ 8876 static inline uint8_t avrcp_subevent_get_capability_company_id_get_command_type(const uint8_t * event){ 8877 return event[5]; 8878 } 8879 /** 8880 * @brief Get field status from event AVRCP_SUBEVENT_GET_CAPABILITY_COMPANY_ID 8881 * @param event packet 8882 * @return status 8883 * @note: btstack_type 1 8884 */ 8885 static inline uint8_t avrcp_subevent_get_capability_company_id_get_status(const uint8_t * event){ 8886 return event[6]; 8887 } 8888 /** 8889 * @brief Get field company_id from event AVRCP_SUBEVENT_GET_CAPABILITY_COMPANY_ID 8890 * @param event packet 8891 * @return company_id 8892 * @note: btstack_type 3 8893 */ 8894 static inline uint32_t avrcp_subevent_get_capability_company_id_get_company_id(const uint8_t * event){ 8895 return little_endian_read_24(event, 7); 8896 } 8897 8898 /** 8899 * @brief Get field avrcp_cid from event AVRCP_SUBEVENT_GET_CAPABILITY_COMPANY_ID_DONE 8900 * @param event packet 8901 * @return avrcp_cid 8902 * @note: btstack_type 2 8903 */ 8904 static inline uint16_t avrcp_subevent_get_capability_company_id_done_get_avrcp_cid(const uint8_t * event){ 8905 return little_endian_read_16(event, 3); 8906 } 8907 /** 8908 * @brief Get field command_type from event AVRCP_SUBEVENT_GET_CAPABILITY_COMPANY_ID_DONE 8909 * @param event packet 8910 * @return command_type 8911 * @note: btstack_type 1 8912 */ 8913 static inline uint8_t avrcp_subevent_get_capability_company_id_done_get_command_type(const uint8_t * event){ 8914 return event[5]; 8915 } 8916 /** 8917 * @brief Get field status from event AVRCP_SUBEVENT_GET_CAPABILITY_COMPANY_ID_DONE 8918 * @param event packet 8919 * @return status 8920 * @note: btstack_type 1 8921 */ 8922 static inline uint8_t avrcp_subevent_get_capability_company_id_done_get_status(const uint8_t * event){ 8923 return event[6]; 8924 } 8925 8926 /** 8927 * @brief Get field bd_addr from event AVRCP_SUBEVENT_INCOMING_BROWSING_CONNECTION 8928 * @param event packet 8929 * @param Pointer to storage for bd_addr 8930 * @note: btstack_type B 8931 */ 8932 static inline void avrcp_subevent_incoming_browsing_connection_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 8933 reverse_bytes(&event[3], bd_addr, 6); 8934 } 8935 /** 8936 * @brief Get field browsing_cid from event AVRCP_SUBEVENT_INCOMING_BROWSING_CONNECTION 8937 * @param event packet 8938 * @return browsing_cid 8939 * @note: btstack_type 2 8940 */ 8941 static inline uint16_t avrcp_subevent_incoming_browsing_connection_get_browsing_cid(const uint8_t * event){ 8942 return little_endian_read_16(event, 9); 8943 } 8944 8945 /** 8946 * @brief Get field status from event AVRCP_SUBEVENT_BROWSING_CONNECTION_ESTABLISHED 8947 * @param event packet 8948 * @return status 8949 * @note: btstack_type 1 8950 */ 8951 static inline uint8_t avrcp_subevent_browsing_connection_established_get_status(const uint8_t * event){ 8952 return event[3]; 8953 } 8954 /** 8955 * @brief Get field bd_addr from event AVRCP_SUBEVENT_BROWSING_CONNECTION_ESTABLISHED 8956 * @param event packet 8957 * @param Pointer to storage for bd_addr 8958 * @note: btstack_type B 8959 */ 8960 static inline void avrcp_subevent_browsing_connection_established_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 8961 reverse_bytes(&event[4], bd_addr, 6); 8962 } 8963 /** 8964 * @brief Get field browsing_cid from event AVRCP_SUBEVENT_BROWSING_CONNECTION_ESTABLISHED 8965 * @param event packet 8966 * @return browsing_cid 8967 * @note: btstack_type 2 8968 */ 8969 static inline uint16_t avrcp_subevent_browsing_connection_established_get_browsing_cid(const uint8_t * event){ 8970 return little_endian_read_16(event, 10); 8971 } 8972 8973 /** 8974 * @brief Get field browsing_cid from event AVRCP_SUBEVENT_BROWSING_CONNECTION_RELEASED 8975 * @param event packet 8976 * @return browsing_cid 8977 * @note: btstack_type 2 8978 */ 8979 static inline uint16_t avrcp_subevent_browsing_connection_released_get_browsing_cid(const uint8_t * event){ 8980 return little_endian_read_16(event, 3); 8981 } 8982 8983 /** 8984 * @brief Get field browsing_cid from event AVRCP_SUBEVENT_BROWSING_DONE 8985 * @param event packet 8986 * @return browsing_cid 8987 * @note: btstack_type 2 8988 */ 8989 static inline uint16_t avrcp_subevent_browsing_done_get_browsing_cid(const uint8_t * event){ 8990 return little_endian_read_16(event, 3); 8991 } 8992 /** 8993 * @brief Get field uid_counter from event AVRCP_SUBEVENT_BROWSING_DONE 8994 * @param event packet 8995 * @return uid_counter 8996 * @note: btstack_type 2 8997 */ 8998 static inline uint16_t avrcp_subevent_browsing_done_get_uid_counter(const uint8_t * event){ 8999 return little_endian_read_16(event, 5); 9000 } 9001 /** 9002 * @brief Get field browsing_status from event AVRCP_SUBEVENT_BROWSING_DONE 9003 * @param event packet 9004 * @return browsing_status 9005 * @note: btstack_type 1 9006 */ 9007 static inline uint8_t avrcp_subevent_browsing_done_get_browsing_status(const uint8_t * event){ 9008 return event[7]; 9009 } 9010 /** 9011 * @brief Get field bluetooth_status from event AVRCP_SUBEVENT_BROWSING_DONE 9012 * @param event packet 9013 * @return bluetooth_status 9014 * @note: btstack_type 1 9015 */ 9016 static inline uint8_t avrcp_subevent_browsing_done_get_bluetooth_status(const uint8_t * event){ 9017 return event[8]; 9018 } 9019 9020 /** 9021 * @brief Get field browsing_cid from event AVRCP_SUBEVENT_BROWSING_GET_FOLDER_ITEMS 9022 * @param event packet 9023 * @return browsing_cid 9024 * @note: btstack_type 2 9025 */ 9026 static inline uint16_t avrcp_subevent_browsing_get_folder_items_get_browsing_cid(const uint8_t * event){ 9027 return little_endian_read_16(event, 3); 9028 } 9029 /** 9030 * @brief Get field scope from event AVRCP_SUBEVENT_BROWSING_GET_FOLDER_ITEMS 9031 * @param event packet 9032 * @return scope 9033 * @note: btstack_type 1 9034 */ 9035 static inline uint8_t avrcp_subevent_browsing_get_folder_items_get_scope(const uint8_t * event){ 9036 return event[5]; 9037 } 9038 /** 9039 * @brief Get field attr_bitmap from event AVRCP_SUBEVENT_BROWSING_GET_FOLDER_ITEMS 9040 * @param event packet 9041 * @return attr_bitmap 9042 * @note: btstack_type 4 9043 */ 9044 static inline uint32_t avrcp_subevent_browsing_get_folder_items_get_attr_bitmap(const uint8_t * event){ 9045 return little_endian_read_32(event, 6); 9046 } 9047 9048 /** 9049 * @brief Get field browsing_cid from event AVRCP_SUBEVENT_BROWSING_GET_TOTAL_NUM_ITEMS 9050 * @param event packet 9051 * @return browsing_cid 9052 * @note: btstack_type 2 9053 */ 9054 static inline uint16_t avrcp_subevent_browsing_get_total_num_items_get_browsing_cid(const uint8_t * event){ 9055 return little_endian_read_16(event, 3); 9056 } 9057 /** 9058 * @brief Get field scope from event AVRCP_SUBEVENT_BROWSING_GET_TOTAL_NUM_ITEMS 9059 * @param event packet 9060 * @return scope 9061 * @note: btstack_type 1 9062 */ 9063 static inline uint8_t avrcp_subevent_browsing_get_total_num_items_get_scope(const uint8_t * event){ 9064 return event[5]; 9065 } 9066 9067 /** 9068 * @brief Get field browsing_cid from event AVRCP_SUBEVENT_BROWSING_SET_BROWSED_PLAYER 9069 * @param event packet 9070 * @return browsing_cid 9071 * @note: btstack_type 2 9072 */ 9073 static inline uint16_t avrcp_subevent_browsing_set_browsed_player_get_browsing_cid(const uint8_t * event){ 9074 return little_endian_read_16(event, 3); 9075 } 9076 /** 9077 * @brief Get field player_id from event AVRCP_SUBEVENT_BROWSING_SET_BROWSED_PLAYER 9078 * @param event packet 9079 * @return player_id 9080 * @note: btstack_type 2 9081 */ 9082 static inline uint16_t avrcp_subevent_browsing_set_browsed_player_get_player_id(const uint8_t * event){ 9083 return little_endian_read_16(event, 5); 9084 } 9085 9086 /** 9087 * @brief Get field goep_cid from event GOEP_SUBEVENT_CONNECTION_OPENED 9088 * @param event packet 9089 * @return goep_cid 9090 * @note: btstack_type 2 9091 */ 9092 static inline uint16_t goep_subevent_connection_opened_get_goep_cid(const uint8_t * event){ 9093 return little_endian_read_16(event, 3); 9094 } 9095 /** 9096 * @brief Get field status from event GOEP_SUBEVENT_CONNECTION_OPENED 9097 * @param event packet 9098 * @return status 9099 * @note: btstack_type 1 9100 */ 9101 static inline uint8_t goep_subevent_connection_opened_get_status(const uint8_t * event){ 9102 return event[5]; 9103 } 9104 /** 9105 * @brief Get field bd_addr from event GOEP_SUBEVENT_CONNECTION_OPENED 9106 * @param event packet 9107 * @param Pointer to storage for bd_addr 9108 * @note: btstack_type B 9109 */ 9110 static inline void goep_subevent_connection_opened_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 9111 reverse_bytes(&event[6], bd_addr, 6); 9112 } 9113 /** 9114 * @brief Get field con_handle from event GOEP_SUBEVENT_CONNECTION_OPENED 9115 * @param event packet 9116 * @return con_handle 9117 * @note: btstack_type H 9118 */ 9119 static inline hci_con_handle_t goep_subevent_connection_opened_get_con_handle(const uint8_t * event){ 9120 return little_endian_read_16(event, 12); 9121 } 9122 /** 9123 * @brief Get field incoming from event GOEP_SUBEVENT_CONNECTION_OPENED 9124 * @param event packet 9125 * @return incoming 9126 * @note: btstack_type 1 9127 */ 9128 static inline uint8_t goep_subevent_connection_opened_get_incoming(const uint8_t * event){ 9129 return event[14]; 9130 } 9131 9132 /** 9133 * @brief Get field goep_cid from event GOEP_SUBEVENT_CONNECTION_CLOSED 9134 * @param event packet 9135 * @return goep_cid 9136 * @note: btstack_type 2 9137 */ 9138 static inline uint16_t goep_subevent_connection_closed_get_goep_cid(const uint8_t * event){ 9139 return little_endian_read_16(event, 3); 9140 } 9141 9142 /** 9143 * @brief Get field goep_cid from event GOEP_SUBEVENT_CAN_SEND_NOW 9144 * @param event packet 9145 * @return goep_cid 9146 * @note: btstack_type 2 9147 */ 9148 static inline uint16_t goep_subevent_can_send_now_get_goep_cid(const uint8_t * event){ 9149 return little_endian_read_16(event, 3); 9150 } 9151 9152 /** 9153 * @brief Get field pbap_cid from event PBAP_SUBEVENT_CONNECTION_OPENED 9154 * @param event packet 9155 * @return pbap_cid 9156 * @note: btstack_type 2 9157 */ 9158 static inline uint16_t pbap_subevent_connection_opened_get_pbap_cid(const uint8_t * event){ 9159 return little_endian_read_16(event, 3); 9160 } 9161 /** 9162 * @brief Get field status from event PBAP_SUBEVENT_CONNECTION_OPENED 9163 * @param event packet 9164 * @return status 9165 * @note: btstack_type 1 9166 */ 9167 static inline uint8_t pbap_subevent_connection_opened_get_status(const uint8_t * event){ 9168 return event[5]; 9169 } 9170 /** 9171 * @brief Get field bd_addr from event PBAP_SUBEVENT_CONNECTION_OPENED 9172 * @param event packet 9173 * @param Pointer to storage for bd_addr 9174 * @note: btstack_type B 9175 */ 9176 static inline void pbap_subevent_connection_opened_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 9177 reverse_bytes(&event[6], bd_addr, 6); 9178 } 9179 /** 9180 * @brief Get field con_handle from event PBAP_SUBEVENT_CONNECTION_OPENED 9181 * @param event packet 9182 * @return con_handle 9183 * @note: btstack_type H 9184 */ 9185 static inline hci_con_handle_t pbap_subevent_connection_opened_get_con_handle(const uint8_t * event){ 9186 return little_endian_read_16(event, 12); 9187 } 9188 /** 9189 * @brief Get field incoming from event PBAP_SUBEVENT_CONNECTION_OPENED 9190 * @param event packet 9191 * @return incoming 9192 * @note: btstack_type 1 9193 */ 9194 static inline uint8_t pbap_subevent_connection_opened_get_incoming(const uint8_t * event){ 9195 return event[14]; 9196 } 9197 9198 /** 9199 * @brief Get field goep_cid from event PBAP_SUBEVENT_CONNECTION_CLOSED 9200 * @param event packet 9201 * @return goep_cid 9202 * @note: btstack_type 2 9203 */ 9204 static inline uint16_t pbap_subevent_connection_closed_get_goep_cid(const uint8_t * event){ 9205 return little_endian_read_16(event, 3); 9206 } 9207 9208 /** 9209 * @brief Get field goep_cid from event PBAP_SUBEVENT_OPERATION_COMPLETED 9210 * @param event packet 9211 * @return goep_cid 9212 * @note: btstack_type 2 9213 */ 9214 static inline uint16_t pbap_subevent_operation_completed_get_goep_cid(const uint8_t * event){ 9215 return little_endian_read_16(event, 3); 9216 } 9217 /** 9218 * @brief Get field status from event PBAP_SUBEVENT_OPERATION_COMPLETED 9219 * @param event packet 9220 * @return status 9221 * @note: btstack_type 1 9222 */ 9223 static inline uint8_t pbap_subevent_operation_completed_get_status(const uint8_t * event){ 9224 return event[5]; 9225 } 9226 9227 /** 9228 * @brief Get field goep_cid from event PBAP_SUBEVENT_PHONEBOOK_SIZE 9229 * @param event packet 9230 * @return goep_cid 9231 * @note: btstack_type 2 9232 */ 9233 static inline uint16_t pbap_subevent_phonebook_size_get_goep_cid(const uint8_t * event){ 9234 return little_endian_read_16(event, 3); 9235 } 9236 /** 9237 * @brief Get field status from event PBAP_SUBEVENT_PHONEBOOK_SIZE 9238 * @param event packet 9239 * @return status 9240 * @note: btstack_type 1 9241 */ 9242 static inline uint8_t pbap_subevent_phonebook_size_get_status(const uint8_t * event){ 9243 return event[5]; 9244 } 9245 /** 9246 * @brief Get field phonebook_size from event PBAP_SUBEVENT_PHONEBOOK_SIZE 9247 * @param event packet 9248 * @return phonebook_size 9249 * @note: btstack_type 2 9250 */ 9251 static inline uint16_t pbap_subevent_phonebook_size_get_phonebook_size(const uint8_t * event){ 9252 return little_endian_read_16(event, 6); 9253 } 9254 9255 /** 9256 * @brief Get field goep_cid from event PBAP_SUBEVENT_AUTHENTICATION_REQUEST 9257 * @param event packet 9258 * @return goep_cid 9259 * @note: btstack_type 2 9260 */ 9261 static inline uint16_t pbap_subevent_authentication_request_get_goep_cid(const uint8_t * event){ 9262 return little_endian_read_16(event, 3); 9263 } 9264 /** 9265 * @brief Get field user_id_required from event PBAP_SUBEVENT_AUTHENTICATION_REQUEST 9266 * @param event packet 9267 * @return user_id_required 9268 * @note: btstack_type 1 9269 */ 9270 static inline uint8_t pbap_subevent_authentication_request_get_user_id_required(const uint8_t * event){ 9271 return event[5]; 9272 } 9273 /** 9274 * @brief Get field full_access from event PBAP_SUBEVENT_AUTHENTICATION_REQUEST 9275 * @param event packet 9276 * @return full_access 9277 * @note: btstack_type 1 9278 */ 9279 static inline uint8_t pbap_subevent_authentication_request_get_full_access(const uint8_t * event){ 9280 return event[6]; 9281 } 9282 9283 /** 9284 * @brief Get field goep_cid from event PBAP_SUBEVENT_CARD_RESULT 9285 * @param event packet 9286 * @return goep_cid 9287 * @note: btstack_type 2 9288 */ 9289 static inline uint16_t pbap_subevent_card_result_get_goep_cid(const uint8_t * event){ 9290 return little_endian_read_16(event, 3); 9291 } 9292 /** 9293 * @brief Get field name_len from event PBAP_SUBEVENT_CARD_RESULT 9294 * @param event packet 9295 * @return name_len 9296 * @note: btstack_type J 9297 */ 9298 static inline uint8_t pbap_subevent_card_result_get_name_len(const uint8_t * event){ 9299 return event[5]; 9300 } 9301 /** 9302 * @brief Get field name from event PBAP_SUBEVENT_CARD_RESULT 9303 * @param event packet 9304 * @return name 9305 * @note: btstack_type V 9306 */ 9307 static inline const uint8_t * pbap_subevent_card_result_get_name(const uint8_t * event){ 9308 return &event[6]; 9309 } 9310 /** 9311 * @brief Get field handle_len from event PBAP_SUBEVENT_CARD_RESULT 9312 * @param event packet 9313 * @return handle_len 9314 * @note: btstack_type J 9315 */ 9316 static inline uint8_t pbap_subevent_card_result_get_handle_len(const uint8_t * event){ 9317 return event[6u + event[5]]; 9318 } 9319 /** 9320 * @brief Get field handle from event PBAP_SUBEVENT_CARD_RESULT 9321 * @param event packet 9322 * @return handle 9323 * @note: btstack_type V 9324 */ 9325 static inline const uint8_t * pbap_subevent_card_result_get_handle(const uint8_t * event){ 9326 return &event[6u + event[5] + 1u]; 9327 } 9328 9329 /** 9330 * @brief Get field hid_cid from event HID_SUBEVENT_INCOMING_CONNECTION 9331 * @param event packet 9332 * @return hid_cid 9333 * @note: btstack_type 2 9334 */ 9335 static inline uint16_t hid_subevent_incoming_connection_get_hid_cid(const uint8_t * event){ 9336 return little_endian_read_16(event, 3); 9337 } 9338 /** 9339 * @brief Get field address from event HID_SUBEVENT_INCOMING_CONNECTION 9340 * @param event packet 9341 * @param Pointer to storage for address 9342 * @note: btstack_type B 9343 */ 9344 static inline void hid_subevent_incoming_connection_get_address(const uint8_t * event, bd_addr_t address){ 9345 reverse_bytes(&event[5], address, 6); 9346 } 9347 /** 9348 * @brief Get field handle from event HID_SUBEVENT_INCOMING_CONNECTION 9349 * @param event packet 9350 * @return handle 9351 * @note: btstack_type H 9352 */ 9353 static inline hci_con_handle_t hid_subevent_incoming_connection_get_handle(const uint8_t * event){ 9354 return little_endian_read_16(event, 11); 9355 } 9356 9357 /** 9358 * @brief Get field hid_cid from event HID_SUBEVENT_CONNECTION_OPENED 9359 * @param event packet 9360 * @return hid_cid 9361 * @note: btstack_type 2 9362 */ 9363 static inline uint16_t hid_subevent_connection_opened_get_hid_cid(const uint8_t * event){ 9364 return little_endian_read_16(event, 3); 9365 } 9366 /** 9367 * @brief Get field status from event HID_SUBEVENT_CONNECTION_OPENED 9368 * @param event packet 9369 * @return status 9370 * @note: btstack_type 1 9371 */ 9372 static inline uint8_t hid_subevent_connection_opened_get_status(const uint8_t * event){ 9373 return event[5]; 9374 } 9375 /** 9376 * @brief Get field bd_addr from event HID_SUBEVENT_CONNECTION_OPENED 9377 * @param event packet 9378 * @param Pointer to storage for bd_addr 9379 * @note: btstack_type B 9380 */ 9381 static inline void hid_subevent_connection_opened_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 9382 reverse_bytes(&event[6], bd_addr, 6); 9383 } 9384 /** 9385 * @brief Get field con_handle from event HID_SUBEVENT_CONNECTION_OPENED 9386 * @param event packet 9387 * @return con_handle 9388 * @note: btstack_type H 9389 */ 9390 static inline hci_con_handle_t hid_subevent_connection_opened_get_con_handle(const uint8_t * event){ 9391 return little_endian_read_16(event, 12); 9392 } 9393 /** 9394 * @brief Get field incoming from event HID_SUBEVENT_CONNECTION_OPENED 9395 * @param event packet 9396 * @return incoming 9397 * @note: btstack_type 1 9398 */ 9399 static inline uint8_t hid_subevent_connection_opened_get_incoming(const uint8_t * event){ 9400 return event[14]; 9401 } 9402 9403 /** 9404 * @brief Get field hid_cid from event HID_SUBEVENT_CONNECTION_CLOSED 9405 * @param event packet 9406 * @return hid_cid 9407 * @note: btstack_type 2 9408 */ 9409 static inline uint16_t hid_subevent_connection_closed_get_hid_cid(const uint8_t * event){ 9410 return little_endian_read_16(event, 3); 9411 } 9412 9413 /** 9414 * @brief Get field hid_cid from event HID_SUBEVENT_CAN_SEND_NOW 9415 * @param event packet 9416 * @return hid_cid 9417 * @note: btstack_type 2 9418 */ 9419 static inline uint16_t hid_subevent_can_send_now_get_hid_cid(const uint8_t * event){ 9420 return little_endian_read_16(event, 3); 9421 } 9422 9423 /** 9424 * @brief Get field hid_cid from event HID_SUBEVENT_SUSPEND 9425 * @param event packet 9426 * @return hid_cid 9427 * @note: btstack_type 2 9428 */ 9429 static inline uint16_t hid_subevent_suspend_get_hid_cid(const uint8_t * event){ 9430 return little_endian_read_16(event, 3); 9431 } 9432 9433 /** 9434 * @brief Get field hid_cid from event HID_SUBEVENT_EXIT_SUSPEND 9435 * @param event packet 9436 * @return hid_cid 9437 * @note: btstack_type 2 9438 */ 9439 static inline uint16_t hid_subevent_exit_suspend_get_hid_cid(const uint8_t * event){ 9440 return little_endian_read_16(event, 3); 9441 } 9442 9443 /** 9444 * @brief Get field hid_cid from event HID_SUBEVENT_VIRTUAL_CABLE_UNPLUG 9445 * @param event packet 9446 * @return hid_cid 9447 * @note: btstack_type 2 9448 */ 9449 static inline uint16_t hid_subevent_virtual_cable_unplug_get_hid_cid(const uint8_t * event){ 9450 return little_endian_read_16(event, 3); 9451 } 9452 9453 /** 9454 * @brief Get field hid_cid from event HID_SUBEVENT_GET_REPORT_RESPONSE 9455 * @param event packet 9456 * @return hid_cid 9457 * @note: btstack_type 2 9458 */ 9459 static inline uint16_t hid_subevent_get_report_response_get_hid_cid(const uint8_t * event){ 9460 return little_endian_read_16(event, 3); 9461 } 9462 /** 9463 * @brief Get field handshake_status from event HID_SUBEVENT_GET_REPORT_RESPONSE 9464 * @param event packet 9465 * @return handshake_status 9466 * @note: btstack_type 1 9467 */ 9468 static inline uint8_t hid_subevent_get_report_response_get_handshake_status(const uint8_t * event){ 9469 return event[5]; 9470 } 9471 /** 9472 * @brief Get field report_len from event HID_SUBEVENT_GET_REPORT_RESPONSE 9473 * @param event packet 9474 * @return report_len 9475 * @note: btstack_type L 9476 */ 9477 static inline uint16_t hid_subevent_get_report_response_get_report_len(const uint8_t * event){ 9478 return little_endian_read_16(event, 6); 9479 } 9480 /** 9481 * @brief Get field report from event HID_SUBEVENT_GET_REPORT_RESPONSE 9482 * @param event packet 9483 * @return report 9484 * @note: btstack_type V 9485 */ 9486 static inline const uint8_t * hid_subevent_get_report_response_get_report(const uint8_t * event){ 9487 return &event[8]; 9488 } 9489 9490 /** 9491 * @brief Get field hid_cid from event HID_SUBEVENT_SET_REPORT_RESPONSE 9492 * @param event packet 9493 * @return hid_cid 9494 * @note: btstack_type 2 9495 */ 9496 static inline uint16_t hid_subevent_set_report_response_get_hid_cid(const uint8_t * event){ 9497 return little_endian_read_16(event, 3); 9498 } 9499 /** 9500 * @brief Get field handshake_status from event HID_SUBEVENT_SET_REPORT_RESPONSE 9501 * @param event packet 9502 * @return handshake_status 9503 * @note: btstack_type 1 9504 */ 9505 static inline uint8_t hid_subevent_set_report_response_get_handshake_status(const uint8_t * event){ 9506 return event[5]; 9507 } 9508 9509 /** 9510 * @brief Get field hid_cid from event HID_SUBEVENT_GET_PROTOCOL_RESPONSE 9511 * @param event packet 9512 * @return hid_cid 9513 * @note: btstack_type 2 9514 */ 9515 static inline uint16_t hid_subevent_get_protocol_response_get_hid_cid(const uint8_t * event){ 9516 return little_endian_read_16(event, 3); 9517 } 9518 /** 9519 * @brief Get field handshake_status from event HID_SUBEVENT_GET_PROTOCOL_RESPONSE 9520 * @param event packet 9521 * @return handshake_status 9522 * @note: btstack_type 1 9523 */ 9524 static inline uint8_t hid_subevent_get_protocol_response_get_handshake_status(const uint8_t * event){ 9525 return event[5]; 9526 } 9527 /** 9528 * @brief Get field protocol_mode from event HID_SUBEVENT_GET_PROTOCOL_RESPONSE 9529 * @param event packet 9530 * @return protocol_mode 9531 * @note: btstack_type 1 9532 */ 9533 static inline uint8_t hid_subevent_get_protocol_response_get_protocol_mode(const uint8_t * event){ 9534 return event[6]; 9535 } 9536 9537 /** 9538 * @brief Get field hid_cid from event HID_SUBEVENT_SET_PROTOCOL_RESPONSE 9539 * @param event packet 9540 * @return hid_cid 9541 * @note: btstack_type 2 9542 */ 9543 static inline uint16_t hid_subevent_set_protocol_response_get_hid_cid(const uint8_t * event){ 9544 return little_endian_read_16(event, 3); 9545 } 9546 /** 9547 * @brief Get field handshake_status from event HID_SUBEVENT_SET_PROTOCOL_RESPONSE 9548 * @param event packet 9549 * @return handshake_status 9550 * @note: btstack_type 1 9551 */ 9552 static inline uint8_t hid_subevent_set_protocol_response_get_handshake_status(const uint8_t * event){ 9553 return event[5]; 9554 } 9555 /** 9556 * @brief Get field protocol_mode from event HID_SUBEVENT_SET_PROTOCOL_RESPONSE 9557 * @param event packet 9558 * @return protocol_mode 9559 * @note: btstack_type 1 9560 */ 9561 static inline uint8_t hid_subevent_set_protocol_response_get_protocol_mode(const uint8_t * event){ 9562 return event[6]; 9563 } 9564 9565 /** 9566 * @brief Get field hid_cid from event HID_SUBEVENT_REPORT 9567 * @param event packet 9568 * @return hid_cid 9569 * @note: btstack_type 2 9570 */ 9571 static inline uint16_t hid_subevent_report_get_hid_cid(const uint8_t * event){ 9572 return little_endian_read_16(event, 3); 9573 } 9574 /** 9575 * @brief Get field report_len from event HID_SUBEVENT_REPORT 9576 * @param event packet 9577 * @return report_len 9578 * @note: btstack_type L 9579 */ 9580 static inline uint16_t hid_subevent_report_get_report_len(const uint8_t * event){ 9581 return little_endian_read_16(event, 5); 9582 } 9583 /** 9584 * @brief Get field report from event HID_SUBEVENT_REPORT 9585 * @param event packet 9586 * @return report 9587 * @note: btstack_type V 9588 */ 9589 static inline const uint8_t * hid_subevent_report_get_report(const uint8_t * event){ 9590 return &event[7]; 9591 } 9592 9593 /** 9594 * @brief Get field hid_cid from event HID_SUBEVENT_DESCRIPTOR_AVAILABLE 9595 * @param event packet 9596 * @return hid_cid 9597 * @note: btstack_type 2 9598 */ 9599 static inline uint16_t hid_subevent_descriptor_available_get_hid_cid(const uint8_t * event){ 9600 return little_endian_read_16(event, 3); 9601 } 9602 /** 9603 * @brief Get field status from event HID_SUBEVENT_DESCRIPTOR_AVAILABLE 9604 * @param event packet 9605 * @return status 9606 * @note: btstack_type 1 9607 */ 9608 static inline uint8_t hid_subevent_descriptor_available_get_status(const uint8_t * event){ 9609 return event[5]; 9610 } 9611 9612 /** 9613 * @brief Get field hid_cid from event HID_SUBEVENT_SNIFF_SUBRATING_PARAMS 9614 * @param event packet 9615 * @return hid_cid 9616 * @note: btstack_type 2 9617 */ 9618 static inline uint16_t hid_subevent_sniff_subrating_params_get_hid_cid(const uint8_t * event){ 9619 return little_endian_read_16(event, 3); 9620 } 9621 /** 9622 * @brief Get field host_max_latency from event HID_SUBEVENT_SNIFF_SUBRATING_PARAMS 9623 * @param event packet 9624 * @return host_max_latency 9625 * @note: btstack_type 2 9626 */ 9627 static inline uint16_t hid_subevent_sniff_subrating_params_get_host_max_latency(const uint8_t * event){ 9628 return little_endian_read_16(event, 5); 9629 } 9630 /** 9631 * @brief Get field host_min_timeout from event HID_SUBEVENT_SNIFF_SUBRATING_PARAMS 9632 * @param event packet 9633 * @return host_min_timeout 9634 * @note: btstack_type 2 9635 */ 9636 static inline uint16_t hid_subevent_sniff_subrating_params_get_host_min_timeout(const uint8_t * event){ 9637 return little_endian_read_16(event, 7); 9638 } 9639 9640 /** 9641 * @brief Get field con_handle from event HIDS_SUBEVENT_CAN_SEND_NOW 9642 * @param event packet 9643 * @return con_handle 9644 * @note: btstack_type 2 9645 */ 9646 static inline uint16_t hids_subevent_can_send_now_get_con_handle(const uint8_t * event){ 9647 return little_endian_read_16(event, 3); 9648 } 9649 9650 /** 9651 * @brief Get field con_handle from event HIDS_SUBEVENT_PROTOCOL_MODE 9652 * @param event packet 9653 * @return con_handle 9654 * @note: btstack_type 2 9655 */ 9656 static inline uint16_t hids_subevent_protocol_mode_get_con_handle(const uint8_t * event){ 9657 return little_endian_read_16(event, 3); 9658 } 9659 /** 9660 * @brief Get field protocol_mode from event HIDS_SUBEVENT_PROTOCOL_MODE 9661 * @param event packet 9662 * @return protocol_mode 9663 * @note: btstack_type 1 9664 */ 9665 static inline uint8_t hids_subevent_protocol_mode_get_protocol_mode(const uint8_t * event){ 9666 return event[5]; 9667 } 9668 9669 /** 9670 * @brief Get field con_handle from event HIDS_SUBEVENT_BOOT_MOUSE_INPUT_REPORT_ENABLE 9671 * @param event packet 9672 * @return con_handle 9673 * @note: btstack_type 2 9674 */ 9675 static inline uint16_t hids_subevent_boot_mouse_input_report_enable_get_con_handle(const uint8_t * event){ 9676 return little_endian_read_16(event, 3); 9677 } 9678 /** 9679 * @brief Get field enable from event HIDS_SUBEVENT_BOOT_MOUSE_INPUT_REPORT_ENABLE 9680 * @param event packet 9681 * @return enable 9682 * @note: btstack_type 1 9683 */ 9684 static inline uint8_t hids_subevent_boot_mouse_input_report_enable_get_enable(const uint8_t * event){ 9685 return event[5]; 9686 } 9687 9688 /** 9689 * @brief Get field con_handle from event HIDS_SUBEVENT_BOOT_KEYBOARD_INPUT_REPORT_ENABLE 9690 * @param event packet 9691 * @return con_handle 9692 * @note: btstack_type 2 9693 */ 9694 static inline uint16_t hids_subevent_boot_keyboard_input_report_enable_get_con_handle(const uint8_t * event){ 9695 return little_endian_read_16(event, 3); 9696 } 9697 /** 9698 * @brief Get field enable from event HIDS_SUBEVENT_BOOT_KEYBOARD_INPUT_REPORT_ENABLE 9699 * @param event packet 9700 * @return enable 9701 * @note: btstack_type 1 9702 */ 9703 static inline uint8_t hids_subevent_boot_keyboard_input_report_enable_get_enable(const uint8_t * event){ 9704 return event[5]; 9705 } 9706 9707 /** 9708 * @brief Get field con_handle from event HIDS_SUBEVENT_INPUT_REPORT_ENABLE 9709 * @param event packet 9710 * @return con_handle 9711 * @note: btstack_type 2 9712 */ 9713 static inline uint16_t hids_subevent_input_report_enable_get_con_handle(const uint8_t * event){ 9714 return little_endian_read_16(event, 3); 9715 } 9716 /** 9717 * @brief Get field enable from event HIDS_SUBEVENT_INPUT_REPORT_ENABLE 9718 * @param event packet 9719 * @return enable 9720 * @note: btstack_type 1 9721 */ 9722 static inline uint8_t hids_subevent_input_report_enable_get_enable(const uint8_t * event){ 9723 return event[5]; 9724 } 9725 9726 /** 9727 * @brief Get field con_handle from event HIDS_SUBEVENT_OUTPUT_REPORT_ENABLE 9728 * @param event packet 9729 * @return con_handle 9730 * @note: btstack_type 2 9731 */ 9732 static inline uint16_t hids_subevent_output_report_enable_get_con_handle(const uint8_t * event){ 9733 return little_endian_read_16(event, 3); 9734 } 9735 /** 9736 * @brief Get field enable from event HIDS_SUBEVENT_OUTPUT_REPORT_ENABLE 9737 * @param event packet 9738 * @return enable 9739 * @note: btstack_type 1 9740 */ 9741 static inline uint8_t hids_subevent_output_report_enable_get_enable(const uint8_t * event){ 9742 return event[5]; 9743 } 9744 9745 /** 9746 * @brief Get field con_handle from event HIDS_SUBEVENT_FEATURE_REPORT_ENABLE 9747 * @param event packet 9748 * @return con_handle 9749 * @note: btstack_type 2 9750 */ 9751 static inline uint16_t hids_subevent_feature_report_enable_get_con_handle(const uint8_t * event){ 9752 return little_endian_read_16(event, 3); 9753 } 9754 /** 9755 * @brief Get field enable from event HIDS_SUBEVENT_FEATURE_REPORT_ENABLE 9756 * @param event packet 9757 * @return enable 9758 * @note: btstack_type 1 9759 */ 9760 static inline uint8_t hids_subevent_feature_report_enable_get_enable(const uint8_t * event){ 9761 return event[5]; 9762 } 9763 9764 /** 9765 * @brief Get field con_handle from event HIDS_SUBEVENT_SUSPEND 9766 * @param event packet 9767 * @return con_handle 9768 * @note: btstack_type 2 9769 */ 9770 static inline uint16_t hids_subevent_suspend_get_con_handle(const uint8_t * event){ 9771 return little_endian_read_16(event, 3); 9772 } 9773 9774 /** 9775 * @brief Get field con_handle from event HIDS_SUBEVENT_EXIT_SUSPEND 9776 * @param event packet 9777 * @return con_handle 9778 * @note: btstack_type 2 9779 */ 9780 static inline uint16_t hids_subevent_exit_suspend_get_con_handle(const uint8_t * event){ 9781 return little_endian_read_16(event, 3); 9782 } 9783 9784 /** 9785 * @brief Get field con_handle from event GATTSERVICE_SUBEVENT_CYCLING_POWER_START_CALIBRATION 9786 * @param event packet 9787 * @return con_handle 9788 * @note: btstack_type 2 9789 */ 9790 static inline uint16_t gattservice_subevent_cycling_power_start_calibration_get_con_handle(const uint8_t * event){ 9791 return little_endian_read_16(event, 3); 9792 } 9793 /** 9794 * @brief Get field measurement_type from event GATTSERVICE_SUBEVENT_CYCLING_POWER_START_CALIBRATION 9795 * @param event packet 9796 * @return measurement_type 9797 * @note: btstack_type 1 9798 */ 9799 static inline uint8_t gattservice_subevent_cycling_power_start_calibration_get_measurement_type(const uint8_t * event){ 9800 return event[5]; 9801 } 9802 /** 9803 * @brief Get field is_enhanced from event GATTSERVICE_SUBEVENT_CYCLING_POWER_START_CALIBRATION 9804 * @param event packet 9805 * @return is_enhanced 9806 * @note: btstack_type 1 9807 */ 9808 static inline uint8_t gattservice_subevent_cycling_power_start_calibration_get_is_enhanced(const uint8_t * event){ 9809 return event[6]; 9810 } 9811 9812 /** 9813 * @brief Get field con_handle from event GATTSERVICE_SUBEVENT_CYCLING_POWER_BROADCAST_START 9814 * @param event packet 9815 * @return con_handle 9816 * @note: btstack_type 2 9817 */ 9818 static inline uint16_t gattservice_subevent_cycling_power_broadcast_start_get_con_handle(const uint8_t * event){ 9819 return little_endian_read_16(event, 3); 9820 } 9821 9822 /** 9823 * @brief Get field con_handle from event GATTSERVICE_SUBEVENT_CYCLING_POWER_BROADCAST_STOP 9824 * @param event packet 9825 * @return con_handle 9826 * @note: btstack_type 2 9827 */ 9828 static inline uint16_t gattservice_subevent_cycling_power_broadcast_stop_get_con_handle(const uint8_t * event){ 9829 return little_endian_read_16(event, 3); 9830 } 9831 9832 /** 9833 * @brief Get field hids_cid from event GATTSERVICE_SUBEVENT_BATTERY_SERVICE_CONNECTED 9834 * @param event packet 9835 * @return hids_cid 9836 * @note: btstack_type 2 9837 */ 9838 static inline uint16_t gattservice_subevent_battery_service_connected_get_hids_cid(const uint8_t * event){ 9839 return little_endian_read_16(event, 3); 9840 } 9841 /** 9842 * @brief Get field status from event GATTSERVICE_SUBEVENT_BATTERY_SERVICE_CONNECTED 9843 * @param event packet 9844 * @return status 9845 * @note: btstack_type 1 9846 */ 9847 static inline uint8_t gattservice_subevent_battery_service_connected_get_status(const uint8_t * event){ 9848 return event[5]; 9849 } 9850 /** 9851 * @brief Get field num_instances from event GATTSERVICE_SUBEVENT_BATTERY_SERVICE_CONNECTED 9852 * @param event packet 9853 * @return num_instances 9854 * @note: btstack_type 1 9855 */ 9856 static inline uint8_t gattservice_subevent_battery_service_connected_get_num_instances(const uint8_t * event){ 9857 return event[6]; 9858 } 9859 /** 9860 * @brief Get field poll_bitmap from event GATTSERVICE_SUBEVENT_BATTERY_SERVICE_CONNECTED 9861 * @param event packet 9862 * @return poll_bitmap 9863 * @note: btstack_type 1 9864 */ 9865 static inline uint8_t gattservice_subevent_battery_service_connected_get_poll_bitmap(const uint8_t * event){ 9866 return event[7]; 9867 } 9868 9869 /** 9870 * @brief Get field hids_cid from event GATTSERVICE_SUBEVENT_BATTERY_SERVICE_LEVEL 9871 * @param event packet 9872 * @return hids_cid 9873 * @note: btstack_type 2 9874 */ 9875 static inline uint16_t gattservice_subevent_battery_service_level_get_hids_cid(const uint8_t * event){ 9876 return little_endian_read_16(event, 3); 9877 } 9878 /** 9879 * @brief Get field sevice_index from event GATTSERVICE_SUBEVENT_BATTERY_SERVICE_LEVEL 9880 * @param event packet 9881 * @return sevice_index 9882 * @note: btstack_type 1 9883 */ 9884 static inline uint8_t gattservice_subevent_battery_service_level_get_sevice_index(const uint8_t * event){ 9885 return event[5]; 9886 } 9887 /** 9888 * @brief Get field att_status from event GATTSERVICE_SUBEVENT_BATTERY_SERVICE_LEVEL 9889 * @param event packet 9890 * @return att_status 9891 * @note: btstack_type 1 9892 */ 9893 static inline uint8_t gattservice_subevent_battery_service_level_get_att_status(const uint8_t * event){ 9894 return event[6]; 9895 } 9896 /** 9897 * @brief Get field level from event GATTSERVICE_SUBEVENT_BATTERY_SERVICE_LEVEL 9898 * @param event packet 9899 * @return level 9900 * @note: btstack_type 1 9901 */ 9902 static inline uint8_t gattservice_subevent_battery_service_level_get_level(const uint8_t * event){ 9903 return event[7]; 9904 } 9905 9906 /** 9907 * @brief Get field con_handle from event GATTSERVICE_SUBEVENT_DEVICE_INFORMATION_DONE 9908 * @param event packet 9909 * @return con_handle 9910 * @note: btstack_type H 9911 */ 9912 static inline hci_con_handle_t gattservice_subevent_device_information_done_get_con_handle(const uint8_t * event){ 9913 return little_endian_read_16(event, 3); 9914 } 9915 /** 9916 * @brief Get field att_status from event GATTSERVICE_SUBEVENT_DEVICE_INFORMATION_DONE 9917 * @param event packet 9918 * @return att_status 9919 * @note: btstack_type 1 9920 */ 9921 static inline uint8_t gattservice_subevent_device_information_done_get_att_status(const uint8_t * event){ 9922 return event[5]; 9923 } 9924 9925 /** 9926 * @brief Get field con_handle from event GATTSERVICE_SUBEVENT_DEVICE_INFORMATION_MANUFACTURER_NAME 9927 * @param event packet 9928 * @return con_handle 9929 * @note: btstack_type H 9930 */ 9931 static inline hci_con_handle_t gattservice_subevent_device_information_manufacturer_name_get_con_handle(const uint8_t * event){ 9932 return little_endian_read_16(event, 3); 9933 } 9934 /** 9935 * @brief Get field att_status from event GATTSERVICE_SUBEVENT_DEVICE_INFORMATION_MANUFACTURER_NAME 9936 * @param event packet 9937 * @return att_status 9938 * @note: btstack_type 1 9939 */ 9940 static inline uint8_t gattservice_subevent_device_information_manufacturer_name_get_att_status(const uint8_t * event){ 9941 return event[5]; 9942 } 9943 /** 9944 * @brief Get field value from event GATTSERVICE_SUBEVENT_DEVICE_INFORMATION_MANUFACTURER_NAME 9945 * @param event packet 9946 * @return value 9947 * @note: btstack_type T 9948 */ 9949 static inline const char * gattservice_subevent_device_information_manufacturer_name_get_value(const uint8_t * event){ 9950 return (const char *) &event[6]; 9951 } 9952 9953 /** 9954 * @brief Get field con_handle from event GATTSERVICE_SUBEVENT_DEVICE_INFORMATION_MODEL_NUMBER 9955 * @param event packet 9956 * @return con_handle 9957 * @note: btstack_type H 9958 */ 9959 static inline hci_con_handle_t gattservice_subevent_device_information_model_number_get_con_handle(const uint8_t * event){ 9960 return little_endian_read_16(event, 3); 9961 } 9962 /** 9963 * @brief Get field att_status from event GATTSERVICE_SUBEVENT_DEVICE_INFORMATION_MODEL_NUMBER 9964 * @param event packet 9965 * @return att_status 9966 * @note: btstack_type 1 9967 */ 9968 static inline uint8_t gattservice_subevent_device_information_model_number_get_att_status(const uint8_t * event){ 9969 return event[5]; 9970 } 9971 /** 9972 * @brief Get field value from event GATTSERVICE_SUBEVENT_DEVICE_INFORMATION_MODEL_NUMBER 9973 * @param event packet 9974 * @return value 9975 * @note: btstack_type T 9976 */ 9977 static inline const char * gattservice_subevent_device_information_model_number_get_value(const uint8_t * event){ 9978 return (const char *) &event[6]; 9979 } 9980 9981 /** 9982 * @brief Get field con_handle from event GATTSERVICE_SUBEVENT_DEVICE_INFORMATION_SERIAL_NUMBER 9983 * @param event packet 9984 * @return con_handle 9985 * @note: btstack_type H 9986 */ 9987 static inline hci_con_handle_t gattservice_subevent_device_information_serial_number_get_con_handle(const uint8_t * event){ 9988 return little_endian_read_16(event, 3); 9989 } 9990 /** 9991 * @brief Get field att_status from event GATTSERVICE_SUBEVENT_DEVICE_INFORMATION_SERIAL_NUMBER 9992 * @param event packet 9993 * @return att_status 9994 * @note: btstack_type 1 9995 */ 9996 static inline uint8_t gattservice_subevent_device_information_serial_number_get_att_status(const uint8_t * event){ 9997 return event[5]; 9998 } 9999 /** 10000 * @brief Get field value from event GATTSERVICE_SUBEVENT_DEVICE_INFORMATION_SERIAL_NUMBER 10001 * @param event packet 10002 * @return value 10003 * @note: btstack_type T 10004 */ 10005 static inline const char * gattservice_subevent_device_information_serial_number_get_value(const uint8_t * event){ 10006 return (const char *) &event[6]; 10007 } 10008 10009 /** 10010 * @brief Get field con_handle from event GATTSERVICE_SUBEVENT_DEVICE_INFORMATION_HARDWARE_REVISION 10011 * @param event packet 10012 * @return con_handle 10013 * @note: btstack_type H 10014 */ 10015 static inline hci_con_handle_t gattservice_subevent_device_information_hardware_revision_get_con_handle(const uint8_t * event){ 10016 return little_endian_read_16(event, 3); 10017 } 10018 /** 10019 * @brief Get field att_status from event GATTSERVICE_SUBEVENT_DEVICE_INFORMATION_HARDWARE_REVISION 10020 * @param event packet 10021 * @return att_status 10022 * @note: btstack_type 1 10023 */ 10024 static inline uint8_t gattservice_subevent_device_information_hardware_revision_get_att_status(const uint8_t * event){ 10025 return event[5]; 10026 } 10027 /** 10028 * @brief Get field value from event GATTSERVICE_SUBEVENT_DEVICE_INFORMATION_HARDWARE_REVISION 10029 * @param event packet 10030 * @return value 10031 * @note: btstack_type T 10032 */ 10033 static inline const char * gattservice_subevent_device_information_hardware_revision_get_value(const uint8_t * event){ 10034 return (const char *) &event[6]; 10035 } 10036 10037 /** 10038 * @brief Get field con_handle from event GATTSERVICE_SUBEVENT_DEVICE_INFORMATION_FIRMWARE_REVISION 10039 * @param event packet 10040 * @return con_handle 10041 * @note: btstack_type H 10042 */ 10043 static inline hci_con_handle_t gattservice_subevent_device_information_firmware_revision_get_con_handle(const uint8_t * event){ 10044 return little_endian_read_16(event, 3); 10045 } 10046 /** 10047 * @brief Get field att_status from event GATTSERVICE_SUBEVENT_DEVICE_INFORMATION_FIRMWARE_REVISION 10048 * @param event packet 10049 * @return att_status 10050 * @note: btstack_type 1 10051 */ 10052 static inline uint8_t gattservice_subevent_device_information_firmware_revision_get_att_status(const uint8_t * event){ 10053 return event[5]; 10054 } 10055 /** 10056 * @brief Get field value from event GATTSERVICE_SUBEVENT_DEVICE_INFORMATION_FIRMWARE_REVISION 10057 * @param event packet 10058 * @return value 10059 * @note: btstack_type T 10060 */ 10061 static inline const char * gattservice_subevent_device_information_firmware_revision_get_value(const uint8_t * event){ 10062 return (const char *) &event[6]; 10063 } 10064 10065 /** 10066 * @brief Get field con_handle from event GATTSERVICE_SUBEVENT_DEVICE_INFORMATION_SOFTWARE_REVISION 10067 * @param event packet 10068 * @return con_handle 10069 * @note: btstack_type H 10070 */ 10071 static inline hci_con_handle_t gattservice_subevent_device_information_software_revision_get_con_handle(const uint8_t * event){ 10072 return little_endian_read_16(event, 3); 10073 } 10074 /** 10075 * @brief Get field att_status from event GATTSERVICE_SUBEVENT_DEVICE_INFORMATION_SOFTWARE_REVISION 10076 * @param event packet 10077 * @return att_status 10078 * @note: btstack_type 1 10079 */ 10080 static inline uint8_t gattservice_subevent_device_information_software_revision_get_att_status(const uint8_t * event){ 10081 return event[5]; 10082 } 10083 /** 10084 * @brief Get field value from event GATTSERVICE_SUBEVENT_DEVICE_INFORMATION_SOFTWARE_REVISION 10085 * @param event packet 10086 * @return value 10087 * @note: btstack_type T 10088 */ 10089 static inline const char * gattservice_subevent_device_information_software_revision_get_value(const uint8_t * event){ 10090 return (const char *) &event[6]; 10091 } 10092 10093 /** 10094 * @brief Get field con_handle from event GATTSERVICE_SUBEVENT_DEVICE_INFORMATION_SYSTEM_ID 10095 * @param event packet 10096 * @return con_handle 10097 * @note: btstack_type H 10098 */ 10099 static inline hci_con_handle_t gattservice_subevent_device_information_system_id_get_con_handle(const uint8_t * event){ 10100 return little_endian_read_16(event, 3); 10101 } 10102 /** 10103 * @brief Get field att_status from event GATTSERVICE_SUBEVENT_DEVICE_INFORMATION_SYSTEM_ID 10104 * @param event packet 10105 * @return att_status 10106 * @note: btstack_type 1 10107 */ 10108 static inline uint8_t gattservice_subevent_device_information_system_id_get_att_status(const uint8_t * event){ 10109 return event[5]; 10110 } 10111 /** 10112 * @brief Get field manufacturer_id_low from event GATTSERVICE_SUBEVENT_DEVICE_INFORMATION_SYSTEM_ID 10113 * @param event packet 10114 * @return manufacturer_id_low 10115 * @note: btstack_type 4 10116 */ 10117 static inline uint32_t gattservice_subevent_device_information_system_id_get_manufacturer_id_low(const uint8_t * event){ 10118 return little_endian_read_32(event, 6); 10119 } 10120 /** 10121 * @brief Get field manufacturer_id_high from event GATTSERVICE_SUBEVENT_DEVICE_INFORMATION_SYSTEM_ID 10122 * @param event packet 10123 * @return manufacturer_id_high 10124 * @note: btstack_type 1 10125 */ 10126 static inline uint8_t gattservice_subevent_device_information_system_id_get_manufacturer_id_high(const uint8_t * event){ 10127 return event[10]; 10128 } 10129 /** 10130 * @brief Get field organizationally_unique_id from event GATTSERVICE_SUBEVENT_DEVICE_INFORMATION_SYSTEM_ID 10131 * @param event packet 10132 * @return organizationally_unique_id 10133 * @note: btstack_type 3 10134 */ 10135 static inline uint32_t gattservice_subevent_device_information_system_id_get_organizationally_unique_id(const uint8_t * event){ 10136 return little_endian_read_24(event, 11); 10137 } 10138 10139 /** 10140 * @brief Get field con_handle from event GATTSERVICE_SUBEVENT_DEVICE_INFORMATION_IEEE_REGULATORY_CERTIFICATION 10141 * @param event packet 10142 * @return con_handle 10143 * @note: btstack_type H 10144 */ 10145 static inline hci_con_handle_t gattservice_subevent_device_information_ieee_regulatory_certification_get_con_handle(const uint8_t * event){ 10146 return little_endian_read_16(event, 3); 10147 } 10148 /** 10149 * @brief Get field att_status from event GATTSERVICE_SUBEVENT_DEVICE_INFORMATION_IEEE_REGULATORY_CERTIFICATION 10150 * @param event packet 10151 * @return att_status 10152 * @note: btstack_type 1 10153 */ 10154 static inline uint8_t gattservice_subevent_device_information_ieee_regulatory_certification_get_att_status(const uint8_t * event){ 10155 return event[5]; 10156 } 10157 /** 10158 * @brief Get field value_a from event GATTSERVICE_SUBEVENT_DEVICE_INFORMATION_IEEE_REGULATORY_CERTIFICATION 10159 * @param event packet 10160 * @return value_a 10161 * @note: btstack_type 2 10162 */ 10163 static inline uint16_t gattservice_subevent_device_information_ieee_regulatory_certification_get_value_a(const uint8_t * event){ 10164 return little_endian_read_16(event, 6); 10165 } 10166 /** 10167 * @brief Get field value_b from event GATTSERVICE_SUBEVENT_DEVICE_INFORMATION_IEEE_REGULATORY_CERTIFICATION 10168 * @param event packet 10169 * @return value_b 10170 * @note: btstack_type 2 10171 */ 10172 static inline uint16_t gattservice_subevent_device_information_ieee_regulatory_certification_get_value_b(const uint8_t * event){ 10173 return little_endian_read_16(event, 8); 10174 } 10175 10176 /** 10177 * @brief Get field con_handle from event GATTSERVICE_SUBEVENT_DEVICE_INFORMATION_PNP_ID 10178 * @param event packet 10179 * @return con_handle 10180 * @note: btstack_type H 10181 */ 10182 static inline hci_con_handle_t gattservice_subevent_device_information_pnp_id_get_con_handle(const uint8_t * event){ 10183 return little_endian_read_16(event, 3); 10184 } 10185 /** 10186 * @brief Get field att_status from event GATTSERVICE_SUBEVENT_DEVICE_INFORMATION_PNP_ID 10187 * @param event packet 10188 * @return att_status 10189 * @note: btstack_type 1 10190 */ 10191 static inline uint8_t gattservice_subevent_device_information_pnp_id_get_att_status(const uint8_t * event){ 10192 return event[5]; 10193 } 10194 /** 10195 * @brief Get field vendor_source_id from event GATTSERVICE_SUBEVENT_DEVICE_INFORMATION_PNP_ID 10196 * @param event packet 10197 * @return vendor_source_id 10198 * @note: btstack_type 1 10199 */ 10200 static inline uint8_t gattservice_subevent_device_information_pnp_id_get_vendor_source_id(const uint8_t * event){ 10201 return event[6]; 10202 } 10203 /** 10204 * @brief Get field vendor_id from event GATTSERVICE_SUBEVENT_DEVICE_INFORMATION_PNP_ID 10205 * @param event packet 10206 * @return vendor_id 10207 * @note: btstack_type 2 10208 */ 10209 static inline uint16_t gattservice_subevent_device_information_pnp_id_get_vendor_id(const uint8_t * event){ 10210 return little_endian_read_16(event, 7); 10211 } 10212 /** 10213 * @brief Get field product_id from event GATTSERVICE_SUBEVENT_DEVICE_INFORMATION_PNP_ID 10214 * @param event packet 10215 * @return product_id 10216 * @note: btstack_type 2 10217 */ 10218 static inline uint16_t gattservice_subevent_device_information_pnp_id_get_product_id(const uint8_t * event){ 10219 return little_endian_read_16(event, 9); 10220 } 10221 /** 10222 * @brief Get field product_version from event GATTSERVICE_SUBEVENT_DEVICE_INFORMATION_PNP_ID 10223 * @param event packet 10224 * @return product_version 10225 * @note: btstack_type 2 10226 */ 10227 static inline uint16_t gattservice_subevent_device_information_pnp_id_get_product_version(const uint8_t * event){ 10228 return little_endian_read_16(event, 11); 10229 } 10230 10231 /** 10232 * @brief Get field con_handle from event GATTSERVICE_SUBEVENT_SCAN_PARAMETERS_SERVICE_CONNECTED 10233 * @param event packet 10234 * @return con_handle 10235 * @note: btstack_type H 10236 */ 10237 static inline hci_con_handle_t gattservice_subevent_scan_parameters_service_connected_get_con_handle(const uint8_t * event){ 10238 return little_endian_read_16(event, 3); 10239 } 10240 /** 10241 * @brief Get field att_status from event GATTSERVICE_SUBEVENT_SCAN_PARAMETERS_SERVICE_CONNECTED 10242 * @param event packet 10243 * @return att_status 10244 * @note: btstack_type 1 10245 */ 10246 static inline uint8_t gattservice_subevent_scan_parameters_service_connected_get_att_status(const uint8_t * event){ 10247 return event[5]; 10248 } 10249 10250 /** 10251 * @brief Get field con_handle from event GATTSERVICE_SUBEVENT_SPP_SERVICE_CONNECTED 10252 * @param event packet 10253 * @return con_handle 10254 * @note: btstack_type H 10255 */ 10256 static inline hci_con_handle_t gattservice_subevent_spp_service_connected_get_con_handle(const uint8_t * event){ 10257 return little_endian_read_16(event, 3); 10258 } 10259 10260 /** 10261 * @brief Get field con_handle from event GATTSERVICE_SUBEVENT_SPP_SERVICE_DISCONNECTED 10262 * @param event packet 10263 * @return con_handle 10264 * @note: btstack_type H 10265 */ 10266 static inline hci_con_handle_t gattservice_subevent_spp_service_disconnected_get_con_handle(const uint8_t * event){ 10267 return little_endian_read_16(event, 3); 10268 } 10269 10270 /** 10271 * @brief Get field hids_cid from event GATTSERVICE_SUBEVENT_HID_SERVICE_CONNECTED 10272 * @param event packet 10273 * @return hids_cid 10274 * @note: btstack_type 2 10275 */ 10276 static inline uint16_t gattservice_subevent_hid_service_connected_get_hids_cid(const uint8_t * event){ 10277 return little_endian_read_16(event, 3); 10278 } 10279 /** 10280 * @brief Get field status from event GATTSERVICE_SUBEVENT_HID_SERVICE_CONNECTED 10281 * @param event packet 10282 * @return status 10283 * @note: btstack_type 1 10284 */ 10285 static inline uint8_t gattservice_subevent_hid_service_connected_get_status(const uint8_t * event){ 10286 return event[5]; 10287 } 10288 /** 10289 * @brief Get field protocol_mode from event GATTSERVICE_SUBEVENT_HID_SERVICE_CONNECTED 10290 * @param event packet 10291 * @return protocol_mode 10292 * @note: btstack_type 1 10293 */ 10294 static inline uint8_t gattservice_subevent_hid_service_connected_get_protocol_mode(const uint8_t * event){ 10295 return event[6]; 10296 } 10297 /** 10298 * @brief Get field num_instances from event GATTSERVICE_SUBEVENT_HID_SERVICE_CONNECTED 10299 * @param event packet 10300 * @return num_instances 10301 * @note: btstack_type 1 10302 */ 10303 static inline uint8_t gattservice_subevent_hid_service_connected_get_num_instances(const uint8_t * event){ 10304 return event[7]; 10305 } 10306 10307 /** 10308 * @brief Get field hids_cid from event GATTSERVICE_SUBEVENT_HID_REPORT 10309 * @param event packet 10310 * @return hids_cid 10311 * @note: btstack_type 2 10312 */ 10313 static inline uint16_t gattservice_subevent_hid_report_get_hids_cid(const uint8_t * event){ 10314 return little_endian_read_16(event, 3); 10315 } 10316 /** 10317 * @brief Get field service_index from event GATTSERVICE_SUBEVENT_HID_REPORT 10318 * @param event packet 10319 * @return service_index 10320 * @note: btstack_type 1 10321 */ 10322 static inline uint8_t gattservice_subevent_hid_report_get_service_index(const uint8_t * event){ 10323 return event[5]; 10324 } 10325 /** 10326 * @brief Get field report_id from event GATTSERVICE_SUBEVENT_HID_REPORT 10327 * @param event packet 10328 * @return report_id 10329 * @note: btstack_type 1 10330 */ 10331 static inline uint8_t gattservice_subevent_hid_report_get_report_id(const uint8_t * event){ 10332 return event[6]; 10333 } 10334 /** 10335 * @brief Get field report_len from event GATTSERVICE_SUBEVENT_HID_REPORT 10336 * @param event packet 10337 * @return report_len 10338 * @note: btstack_type L 10339 */ 10340 static inline uint16_t gattservice_subevent_hid_report_get_report_len(const uint8_t * event){ 10341 return little_endian_read_16(event, 7); 10342 } 10343 /** 10344 * @brief Get field report from event GATTSERVICE_SUBEVENT_HID_REPORT 10345 * @param event packet 10346 * @return report 10347 * @note: btstack_type V 10348 */ 10349 static inline const uint8_t * gattservice_subevent_hid_report_get_report(const uint8_t * event){ 10350 return &event[9]; 10351 } 10352 10353 /** 10354 * @brief Get field hids_cid from event GATTSERVICE_SUBEVENT_HID_INFORMATION 10355 * @param event packet 10356 * @return hids_cid 10357 * @note: btstack_type 2 10358 */ 10359 static inline uint16_t gattservice_subevent_hid_information_get_hids_cid(const uint8_t * event){ 10360 return little_endian_read_16(event, 3); 10361 } 10362 /** 10363 * @brief Get field service_index from event GATTSERVICE_SUBEVENT_HID_INFORMATION 10364 * @param event packet 10365 * @return service_index 10366 * @note: btstack_type 1 10367 */ 10368 static inline uint8_t gattservice_subevent_hid_information_get_service_index(const uint8_t * event){ 10369 return event[5]; 10370 } 10371 /** 10372 * @brief Get field base_usb_hid_version from event GATTSERVICE_SUBEVENT_HID_INFORMATION 10373 * @param event packet 10374 * @return base_usb_hid_version 10375 * @note: btstack_type 2 10376 */ 10377 static inline uint16_t gattservice_subevent_hid_information_get_base_usb_hid_version(const uint8_t * event){ 10378 return little_endian_read_16(event, 6); 10379 } 10380 /** 10381 * @brief Get field country_code from event GATTSERVICE_SUBEVENT_HID_INFORMATION 10382 * @param event packet 10383 * @return country_code 10384 * @note: btstack_type 1 10385 */ 10386 static inline uint8_t gattservice_subevent_hid_information_get_country_code(const uint8_t * event){ 10387 return event[8]; 10388 } 10389 /** 10390 * @brief Get field remote_wake from event GATTSERVICE_SUBEVENT_HID_INFORMATION 10391 * @param event packet 10392 * @return remote_wake 10393 * @note: btstack_type 1 10394 */ 10395 static inline uint8_t gattservice_subevent_hid_information_get_remote_wake(const uint8_t * event){ 10396 return event[9]; 10397 } 10398 /** 10399 * @brief Get field normally_connectable from event GATTSERVICE_SUBEVENT_HID_INFORMATION 10400 * @param event packet 10401 * @return normally_connectable 10402 * @note: btstack_type 1 10403 */ 10404 static inline uint8_t gattservice_subevent_hid_information_get_normally_connectable(const uint8_t * event){ 10405 return event[10]; 10406 } 10407 10408 /** 10409 * @brief Get field hids_cid from event GATTSERVICE_SUBEVENT_HID_PROTOCOL_MODE 10410 * @param event packet 10411 * @return hids_cid 10412 * @note: btstack_type 2 10413 */ 10414 static inline uint16_t gattservice_subevent_hid_protocol_mode_get_hids_cid(const uint8_t * event){ 10415 return little_endian_read_16(event, 3); 10416 } 10417 /** 10418 * @brief Get field service_index from event GATTSERVICE_SUBEVENT_HID_PROTOCOL_MODE 10419 * @param event packet 10420 * @return service_index 10421 * @note: btstack_type 1 10422 */ 10423 static inline uint8_t gattservice_subevent_hid_protocol_mode_get_service_index(const uint8_t * event){ 10424 return event[5]; 10425 } 10426 /** 10427 * @brief Get field protocol_mode from event GATTSERVICE_SUBEVENT_HID_PROTOCOL_MODE 10428 * @param event packet 10429 * @return protocol_mode 10430 * @note: btstack_type 1 10431 */ 10432 static inline uint8_t gattservice_subevent_hid_protocol_mode_get_protocol_mode(const uint8_t * event){ 10433 return event[6]; 10434 } 10435 10436 /** 10437 * @brief Get field hids_cid from event GATTSERVICE_SUBEVENT_HID_SERVICE_REPORTS_NOTIFICATION 10438 * @param event packet 10439 * @return hids_cid 10440 * @note: btstack_type 2 10441 */ 10442 static inline uint16_t gattservice_subevent_hid_service_reports_notification_get_hids_cid(const uint8_t * event){ 10443 return little_endian_read_16(event, 3); 10444 } 10445 /** 10446 * @brief Get field configuration from event GATTSERVICE_SUBEVENT_HID_SERVICE_REPORTS_NOTIFICATION 10447 * @param event packet 10448 * @return configuration 10449 * @note: btstack_type 1 10450 */ 10451 static inline uint8_t gattservice_subevent_hid_service_reports_notification_get_configuration(const uint8_t * event){ 10452 return event[5]; 10453 } 10454 10455 /** 10456 * @brief Get field con_handle from event GATTSERVICE_SUBEVENT_SCAN_PARAMETERS_SERVICE_SCAN_INTERVAL_UPDATE 10457 * @param event packet 10458 * @return con_handle 10459 * @note: btstack_type H 10460 */ 10461 static inline hci_con_handle_t gattservice_subevent_scan_parameters_service_scan_interval_update_get_con_handle(const uint8_t * event){ 10462 return little_endian_read_16(event, 3); 10463 } 10464 /** 10465 * @brief Get field max_scan_interval from event GATTSERVICE_SUBEVENT_SCAN_PARAMETERS_SERVICE_SCAN_INTERVAL_UPDATE 10466 * @param event packet 10467 * @return max_scan_interval 10468 * @note: btstack_type 2 10469 */ 10470 static inline uint16_t gattservice_subevent_scan_parameters_service_scan_interval_update_get_max_scan_interval(const uint8_t * event){ 10471 return little_endian_read_16(event, 5); 10472 } 10473 /** 10474 * @brief Get field min_scan_window from event GATTSERVICE_SUBEVENT_SCAN_PARAMETERS_SERVICE_SCAN_INTERVAL_UPDATE 10475 * @param event packet 10476 * @return min_scan_window 10477 * @note: btstack_type 2 10478 */ 10479 static inline uint16_t gattservice_subevent_scan_parameters_service_scan_interval_update_get_min_scan_window(const uint8_t * event){ 10480 return little_endian_read_16(event, 7); 10481 } 10482 10483 /** 10484 * @brief Get field hids_cid from event GATTSERVICE_SUBEVENT_MICROPHONE_CONTROL_SERVICE_CONNECTED 10485 * @param event packet 10486 * @return hids_cid 10487 * @note: btstack_type 2 10488 */ 10489 static inline uint16_t gattservice_subevent_microphone_control_service_connected_get_hids_cid(const uint8_t * event){ 10490 return little_endian_read_16(event, 3); 10491 } 10492 /** 10493 * @brief Get field status from event GATTSERVICE_SUBEVENT_MICROPHONE_CONTROL_SERVICE_CONNECTED 10494 * @param event packet 10495 * @return status 10496 * @note: btstack_type 1 10497 */ 10498 static inline uint8_t gattservice_subevent_microphone_control_service_connected_get_status(const uint8_t * event){ 10499 return event[5]; 10500 } 10501 10502 /** 10503 * @brief Get field mics_cid from event GATTSERVICE_SUBEVENT_MICROPHONE_CONTROL_SERVICE_MUTE 10504 * @param event packet 10505 * @return mics_cid 10506 * @note: btstack_type 2 10507 */ 10508 static inline uint16_t gattservice_subevent_microphone_control_service_mute_get_mics_cid(const uint8_t * event){ 10509 return little_endian_read_16(event, 3); 10510 } 10511 /** 10512 * @brief Get field status from event GATTSERVICE_SUBEVENT_MICROPHONE_CONTROL_SERVICE_MUTE 10513 * @param event packet 10514 * @return status 10515 * @note: btstack_type 1 10516 */ 10517 static inline uint8_t gattservice_subevent_microphone_control_service_mute_get_status(const uint8_t * event){ 10518 return event[5]; 10519 } 10520 /** 10521 * @brief Get field mute_value from event GATTSERVICE_SUBEVENT_MICROPHONE_CONTROL_SERVICE_MUTE 10522 * @param event packet 10523 * @return mute_value 10524 * @note: btstack_type 1 10525 */ 10526 static inline uint8_t gattservice_subevent_microphone_control_service_mute_get_mute_value(const uint8_t * event){ 10527 return event[6]; 10528 } 10529 10530 /** 10531 * @brief Get field map_cid from event MAP_SUBEVENT_CONNECTION_OPENED 10532 * @param event packet 10533 * @return map_cid 10534 * @note: btstack_type 2 10535 */ 10536 static inline uint16_t map_subevent_connection_opened_get_map_cid(const uint8_t * event){ 10537 return little_endian_read_16(event, 3); 10538 } 10539 /** 10540 * @brief Get field status from event MAP_SUBEVENT_CONNECTION_OPENED 10541 * @param event packet 10542 * @return status 10543 * @note: btstack_type 1 10544 */ 10545 static inline uint8_t map_subevent_connection_opened_get_status(const uint8_t * event){ 10546 return event[5]; 10547 } 10548 /** 10549 * @brief Get field bd_addr from event MAP_SUBEVENT_CONNECTION_OPENED 10550 * @param event packet 10551 * @param Pointer to storage for bd_addr 10552 * @note: btstack_type B 10553 */ 10554 static inline void map_subevent_connection_opened_get_bd_addr(const uint8_t * event, bd_addr_t bd_addr){ 10555 reverse_bytes(&event[6], bd_addr, 6); 10556 } 10557 /** 10558 * @brief Get field con_handle from event MAP_SUBEVENT_CONNECTION_OPENED 10559 * @param event packet 10560 * @return con_handle 10561 * @note: btstack_type H 10562 */ 10563 static inline hci_con_handle_t map_subevent_connection_opened_get_con_handle(const uint8_t * event){ 10564 return little_endian_read_16(event, 12); 10565 } 10566 /** 10567 * @brief Get field incoming from event MAP_SUBEVENT_CONNECTION_OPENED 10568 * @param event packet 10569 * @return incoming 10570 * @note: btstack_type 1 10571 */ 10572 static inline uint8_t map_subevent_connection_opened_get_incoming(const uint8_t * event){ 10573 return event[14]; 10574 } 10575 10576 /** 10577 * @brief Get field map_cid from event MAP_SUBEVENT_CONNECTION_CLOSED 10578 * @param event packet 10579 * @return map_cid 10580 * @note: btstack_type 2 10581 */ 10582 static inline uint16_t map_subevent_connection_closed_get_map_cid(const uint8_t * event){ 10583 return little_endian_read_16(event, 3); 10584 } 10585 10586 /** 10587 * @brief Get field map_cid from event MAP_SUBEVENT_OPERATION_COMPLETED 10588 * @param event packet 10589 * @return map_cid 10590 * @note: btstack_type 2 10591 */ 10592 static inline uint16_t map_subevent_operation_completed_get_map_cid(const uint8_t * event){ 10593 return little_endian_read_16(event, 3); 10594 } 10595 /** 10596 * @brief Get field status from event MAP_SUBEVENT_OPERATION_COMPLETED 10597 * @param event packet 10598 * @return status 10599 * @note: btstack_type 1 10600 */ 10601 static inline uint8_t map_subevent_operation_completed_get_status(const uint8_t * event){ 10602 return event[5]; 10603 } 10604 10605 /** 10606 * @brief Get field map_cid from event MAP_SUBEVENT_FOLDER_LISTING_ITEM 10607 * @param event packet 10608 * @return map_cid 10609 * @note: btstack_type 2 10610 */ 10611 static inline uint16_t map_subevent_folder_listing_item_get_map_cid(const uint8_t * event){ 10612 return little_endian_read_16(event, 3); 10613 } 10614 /** 10615 * @brief Get field name_len from event MAP_SUBEVENT_FOLDER_LISTING_ITEM 10616 * @param event packet 10617 * @return name_len 10618 * @note: btstack_type L 10619 */ 10620 static inline uint16_t map_subevent_folder_listing_item_get_name_len(const uint8_t * event){ 10621 return little_endian_read_16(event, 5); 10622 } 10623 /** 10624 * @brief Get field name from event MAP_SUBEVENT_FOLDER_LISTING_ITEM 10625 * @param event packet 10626 * @return name 10627 * @note: btstack_type V 10628 */ 10629 static inline const uint8_t * map_subevent_folder_listing_item_get_name(const uint8_t * event){ 10630 return &event[7]; 10631 } 10632 10633 /** 10634 * @brief Get field map_cid from event MAP_SUBEVENT_MESSAGE_LISTING_ITEM 10635 * @param event packet 10636 * @return map_cid 10637 * @note: btstack_type 2 10638 */ 10639 static inline uint16_t map_subevent_message_listing_item_get_map_cid(const uint8_t * event){ 10640 return little_endian_read_16(event, 3); 10641 } 10642 /** 10643 * @brief Get field handle from event MAP_SUBEVENT_MESSAGE_LISTING_ITEM 10644 * @param event packet 10645 * @return handle 10646 * @note: btstack_type D 10647 */ 10648 static inline const uint8_t * map_subevent_message_listing_item_get_handle(const uint8_t * event){ 10649 return (const uint8_t *) &event[5]; 10650 } 10651 10652 /** 10653 * @brief Get field map_cid from event MAP_SUBEVENT_PARSING_DONE 10654 * @param event packet 10655 * @return map_cid 10656 * @note: btstack_type 2 10657 */ 10658 static inline uint16_t map_subevent_parsing_done_get_map_cid(const uint8_t * event){ 10659 return little_endian_read_16(event, 3); 10660 } 10661 10662 10663 /** 10664 * @brief Get field status from event MESH_SUBEVENT_PB_TRANSPORT_PDU_SENT 10665 * @param event packet 10666 * @return status 10667 * @note: btstack_type 1 10668 */ 10669 static inline uint8_t mesh_subevent_pb_transport_pdu_sent_get_status(const uint8_t * event){ 10670 return event[3]; 10671 } 10672 10673 /** 10674 * @brief Get field status from event MESH_SUBEVENT_PB_TRANSPORT_LINK_OPEN 10675 * @param event packet 10676 * @return status 10677 * @note: btstack_type 1 10678 */ 10679 static inline uint8_t mesh_subevent_pb_transport_link_open_get_status(const uint8_t * event){ 10680 return event[3]; 10681 } 10682 /** 10683 * @brief Get field pb_transport_cid from event MESH_SUBEVENT_PB_TRANSPORT_LINK_OPEN 10684 * @param event packet 10685 * @return pb_transport_cid 10686 * @note: btstack_type 2 10687 */ 10688 static inline uint16_t mesh_subevent_pb_transport_link_open_get_pb_transport_cid(const uint8_t * event){ 10689 return little_endian_read_16(event, 4); 10690 } 10691 /** 10692 * @brief Get field pb_type from event MESH_SUBEVENT_PB_TRANSPORT_LINK_OPEN 10693 * @param event packet 10694 * @return pb_type 10695 * @note: btstack_type 1 10696 */ 10697 static inline uint8_t mesh_subevent_pb_transport_link_open_get_pb_type(const uint8_t * event){ 10698 return event[6]; 10699 } 10700 10701 /** 10702 * @brief Get field pb_transport_cid from event MESH_SUBEVENT_PB_TRANSPORT_LINK_CLOSED 10703 * @param event packet 10704 * @return pb_transport_cid 10705 * @note: btstack_type 1 10706 */ 10707 static inline uint8_t mesh_subevent_pb_transport_link_closed_get_pb_transport_cid(const uint8_t * event){ 10708 return event[3]; 10709 } 10710 /** 10711 * @brief Get field reason from event MESH_SUBEVENT_PB_TRANSPORT_LINK_CLOSED 10712 * @param event packet 10713 * @return reason 10714 * @note: btstack_type 2 10715 */ 10716 static inline uint16_t mesh_subevent_pb_transport_link_closed_get_reason(const uint8_t * event){ 10717 return little_endian_read_16(event, 4); 10718 } 10719 10720 /** 10721 * @brief Get field pb_transport_cid from event MESH_SUBEVENT_PB_PROV_ATTENTION_TIMER 10722 * @param event packet 10723 * @return pb_transport_cid 10724 * @note: btstack_type 2 10725 */ 10726 static inline uint16_t mesh_subevent_pb_prov_attention_timer_get_pb_transport_cid(const uint8_t * event){ 10727 return little_endian_read_16(event, 3); 10728 } 10729 /** 10730 * @brief Get field attention_time from event MESH_SUBEVENT_PB_PROV_ATTENTION_TIMER 10731 * @param event packet 10732 * @return attention_time 10733 * @note: btstack_type 1 10734 */ 10735 static inline uint8_t mesh_subevent_pb_prov_attention_timer_get_attention_time(const uint8_t * event){ 10736 return event[5]; 10737 } 10738 10739 /** 10740 * @brief Get field pb_transport_cid from event MESH_SUBEVENT_PB_PROV_START_EMIT_PUBLIC_KEY_OOB 10741 * @param event packet 10742 * @return pb_transport_cid 10743 * @note: btstack_type 2 10744 */ 10745 static inline uint16_t mesh_subevent_pb_prov_start_emit_public_key_oob_get_pb_transport_cid(const uint8_t * event){ 10746 return little_endian_read_16(event, 3); 10747 } 10748 10749 /** 10750 * @brief Get field pb_transport_cid from event MESH_SUBEVENT_PB_PROV_STOP_EMIT_PUBLIC_KEY_OOB 10751 * @param event packet 10752 * @return pb_transport_cid 10753 * @note: btstack_type 2 10754 */ 10755 static inline uint16_t mesh_subevent_pb_prov_stop_emit_public_key_oob_get_pb_transport_cid(const uint8_t * event){ 10756 return little_endian_read_16(event, 3); 10757 } 10758 10759 /** 10760 * @brief Get field pb_transport_cid from event MESH_SUBEVENT_PB_PROV_INPUT_OOB_REQUEST 10761 * @param event packet 10762 * @return pb_transport_cid 10763 * @note: btstack_type 2 10764 */ 10765 static inline uint16_t mesh_subevent_pb_prov_input_oob_request_get_pb_transport_cid(const uint8_t * event){ 10766 return little_endian_read_16(event, 3); 10767 } 10768 10769 /** 10770 * @brief Get field pb_transport_cid from event MESH_SUBEVENT_PB_PROV_START_EMIT_OUTPUT_OOB 10771 * @param event packet 10772 * @return pb_transport_cid 10773 * @note: btstack_type 2 10774 */ 10775 static inline uint16_t mesh_subevent_pb_prov_start_emit_output_oob_get_pb_transport_cid(const uint8_t * event){ 10776 return little_endian_read_16(event, 3); 10777 } 10778 /** 10779 * @brief Get field output_oob from event MESH_SUBEVENT_PB_PROV_START_EMIT_OUTPUT_OOB 10780 * @param event packet 10781 * @return output_oob 10782 * @note: btstack_type 4 10783 */ 10784 static inline uint32_t mesh_subevent_pb_prov_start_emit_output_oob_get_output_oob(const uint8_t * event){ 10785 return little_endian_read_32(event, 5); 10786 } 10787 10788 /** 10789 * @brief Get field pb_transport_cid from event MESH_SUBEVENT_PB_PROV_STOP_EMIT_OUTPUT_OOB 10790 * @param event packet 10791 * @return pb_transport_cid 10792 * @note: btstack_type 2 10793 */ 10794 static inline uint16_t mesh_subevent_pb_prov_stop_emit_output_oob_get_pb_transport_cid(const uint8_t * event){ 10795 return little_endian_read_16(event, 3); 10796 } 10797 10798 /** 10799 * @brief Get field pb_transport_cid from event MESH_SUBEVENT_PB_PROV_START_RECEIVE_PUBLIC_KEY_OOB 10800 * @param event packet 10801 * @return pb_transport_cid 10802 * @note: btstack_type 2 10803 */ 10804 static inline uint16_t mesh_subevent_pb_prov_start_receive_public_key_oob_get_pb_transport_cid(const uint8_t * event){ 10805 return little_endian_read_16(event, 3); 10806 } 10807 10808 /** 10809 * @brief Get field pb_transport_cid from event MESH_SUBEVENT_PB_PROV_STOP_RECEIVE_PUBLIC_KEY_OOB 10810 * @param event packet 10811 * @return pb_transport_cid 10812 * @note: btstack_type 2 10813 */ 10814 static inline uint16_t mesh_subevent_pb_prov_stop_receive_public_key_oob_get_pb_transport_cid(const uint8_t * event){ 10815 return little_endian_read_16(event, 3); 10816 } 10817 10818 /** 10819 * @brief Get field pb_transport_cid from event MESH_SUBEVENT_PB_PROV_OUTPUT_OOB_REQUEST 10820 * @param event packet 10821 * @return pb_transport_cid 10822 * @note: btstack_type 2 10823 */ 10824 static inline uint16_t mesh_subevent_pb_prov_output_oob_request_get_pb_transport_cid(const uint8_t * event){ 10825 return little_endian_read_16(event, 3); 10826 } 10827 10828 /** 10829 * @brief Get field pb_transport_cid from event MESH_SUBEVENT_PB_PROV_START_EMIT_INPUT_OOB 10830 * @param event packet 10831 * @return pb_transport_cid 10832 * @note: btstack_type 2 10833 */ 10834 static inline uint16_t mesh_subevent_pb_prov_start_emit_input_oob_get_pb_transport_cid(const uint8_t * event){ 10835 return little_endian_read_16(event, 3); 10836 } 10837 /** 10838 * @brief Get field output_oob from event MESH_SUBEVENT_PB_PROV_START_EMIT_INPUT_OOB 10839 * @param event packet 10840 * @return output_oob 10841 * @note: btstack_type 4 10842 */ 10843 static inline uint32_t mesh_subevent_pb_prov_start_emit_input_oob_get_output_oob(const uint8_t * event){ 10844 return little_endian_read_32(event, 5); 10845 } 10846 10847 /** 10848 * @brief Get field pb_transport_cid from event MESH_SUBEVENT_PB_PROV_STOP_EMIT_INPUT_OOB 10849 * @param event packet 10850 * @return pb_transport_cid 10851 * @note: btstack_type 2 10852 */ 10853 static inline uint16_t mesh_subevent_pb_prov_stop_emit_input_oob_get_pb_transport_cid(const uint8_t * event){ 10854 return little_endian_read_16(event, 3); 10855 } 10856 10857 /** 10858 * @brief Get field pb_transport_cid from event MESH_SUBEVENT_PB_PROV_CAPABILITIES 10859 * @param event packet 10860 * @return pb_transport_cid 10861 * @note: btstack_type 2 10862 */ 10863 static inline uint16_t mesh_subevent_pb_prov_capabilities_get_pb_transport_cid(const uint8_t * event){ 10864 return little_endian_read_16(event, 3); 10865 } 10866 /** 10867 * @brief Get field num_elements from event MESH_SUBEVENT_PB_PROV_CAPABILITIES 10868 * @param event packet 10869 * @return num_elements 10870 * @note: btstack_type 1 10871 */ 10872 static inline uint8_t mesh_subevent_pb_prov_capabilities_get_num_elements(const uint8_t * event){ 10873 return event[5]; 10874 } 10875 /** 10876 * @brief Get field algorithms from event MESH_SUBEVENT_PB_PROV_CAPABILITIES 10877 * @param event packet 10878 * @return algorithms 10879 * @note: btstack_type 2 10880 */ 10881 static inline uint16_t mesh_subevent_pb_prov_capabilities_get_algorithms(const uint8_t * event){ 10882 return little_endian_read_16(event, 6); 10883 } 10884 /** 10885 * @brief Get field public_key from event MESH_SUBEVENT_PB_PROV_CAPABILITIES 10886 * @param event packet 10887 * @return public_key 10888 * @note: btstack_type 1 10889 */ 10890 static inline uint8_t mesh_subevent_pb_prov_capabilities_get_public_key(const uint8_t * event){ 10891 return event[8]; 10892 } 10893 /** 10894 * @brief Get field static_oob_type from event MESH_SUBEVENT_PB_PROV_CAPABILITIES 10895 * @param event packet 10896 * @return static_oob_type 10897 * @note: btstack_type 1 10898 */ 10899 static inline uint8_t mesh_subevent_pb_prov_capabilities_get_static_oob_type(const uint8_t * event){ 10900 return event[9]; 10901 } 10902 /** 10903 * @brief Get field output_oob_size from event MESH_SUBEVENT_PB_PROV_CAPABILITIES 10904 * @param event packet 10905 * @return output_oob_size 10906 * @note: btstack_type 1 10907 */ 10908 static inline uint8_t mesh_subevent_pb_prov_capabilities_get_output_oob_size(const uint8_t * event){ 10909 return event[10]; 10910 } 10911 /** 10912 * @brief Get field output_oob_action from event MESH_SUBEVENT_PB_PROV_CAPABILITIES 10913 * @param event packet 10914 * @return output_oob_action 10915 * @note: btstack_type 2 10916 */ 10917 static inline uint16_t mesh_subevent_pb_prov_capabilities_get_output_oob_action(const uint8_t * event){ 10918 return little_endian_read_16(event, 11); 10919 } 10920 /** 10921 * @brief Get field input_oob_size from event MESH_SUBEVENT_PB_PROV_CAPABILITIES 10922 * @param event packet 10923 * @return input_oob_size 10924 * @note: btstack_type 1 10925 */ 10926 static inline uint8_t mesh_subevent_pb_prov_capabilities_get_input_oob_size(const uint8_t * event){ 10927 return event[13]; 10928 } 10929 /** 10930 * @brief Get field input_oob_action from event MESH_SUBEVENT_PB_PROV_CAPABILITIES 10931 * @param event packet 10932 * @return input_oob_action 10933 * @note: btstack_type 2 10934 */ 10935 static inline uint16_t mesh_subevent_pb_prov_capabilities_get_input_oob_action(const uint8_t * event){ 10936 return little_endian_read_16(event, 14); 10937 } 10938 10939 /** 10940 * @brief Get field pb_transport_cid from event MESH_SUBEVENT_PB_PROV_COMPLETE 10941 * @param event packet 10942 * @return pb_transport_cid 10943 * @note: btstack_type 2 10944 */ 10945 static inline uint16_t mesh_subevent_pb_prov_complete_get_pb_transport_cid(const uint8_t * event){ 10946 return little_endian_read_16(event, 3); 10947 } 10948 10949 /** 10950 * @brief Get field attention_time from event MESH_SUBEVENT_ATTENTION_TIMER 10951 * @param event packet 10952 * @return attention_time 10953 * @note: btstack_type 1 10954 */ 10955 static inline uint8_t mesh_subevent_attention_timer_get_attention_time(const uint8_t * event){ 10956 return event[3]; 10957 } 10958 10959 /** 10960 * @brief Get field con_handle from event MESH_SUBEVENT_PROXY_CONNECTED 10961 * @param event packet 10962 * @return con_handle 10963 * @note: btstack_type H 10964 */ 10965 static inline hci_con_handle_t mesh_subevent_proxy_connected_get_con_handle(const uint8_t * event){ 10966 return little_endian_read_16(event, 3); 10967 } 10968 10969 /** 10970 * @brief Get field con_handle from event MESH_SUBEVENT_PROXY_PDU_SENT 10971 * @param event packet 10972 * @return con_handle 10973 * @note: btstack_type H 10974 */ 10975 static inline hci_con_handle_t mesh_subevent_proxy_pdu_sent_get_con_handle(const uint8_t * event){ 10976 return little_endian_read_16(event, 3); 10977 } 10978 10979 /** 10980 * @brief Get field con_handle from event MESH_SUBEVENT_PROXY_DISCONNECTED 10981 * @param event packet 10982 * @return con_handle 10983 * @note: btstack_type H 10984 */ 10985 static inline hci_con_handle_t mesh_subevent_proxy_disconnected_get_con_handle(const uint8_t * event){ 10986 return little_endian_read_16(event, 3); 10987 } 10988 10989 /** 10990 * @brief Get field con_handle from event MESH_SUBEVENT_MESSAGE_SENT 10991 * @param event packet 10992 * @return con_handle 10993 * @note: btstack_type H 10994 */ 10995 static inline hci_con_handle_t mesh_subevent_message_sent_get_con_handle(const uint8_t * event){ 10996 return little_endian_read_16(event, 3); 10997 } 10998 10999 /** 11000 * @brief Get field element_index from event MESH_SUBEVENT_STATE_UPDATE_BOOL 11001 * @param event packet 11002 * @return element_index 11003 * @note: btstack_type 1 11004 */ 11005 static inline uint8_t mesh_subevent_state_update_bool_get_element_index(const uint8_t * event){ 11006 return event[3]; 11007 } 11008 /** 11009 * @brief Get field model_identifier from event MESH_SUBEVENT_STATE_UPDATE_BOOL 11010 * @param event packet 11011 * @return model_identifier 11012 * @note: btstack_type 4 11013 */ 11014 static inline uint32_t mesh_subevent_state_update_bool_get_model_identifier(const uint8_t * event){ 11015 return little_endian_read_32(event, 4); 11016 } 11017 /** 11018 * @brief Get field state_identifier from event MESH_SUBEVENT_STATE_UPDATE_BOOL 11019 * @param event packet 11020 * @return state_identifier 11021 * @note: btstack_type 4 11022 */ 11023 static inline uint32_t mesh_subevent_state_update_bool_get_state_identifier(const uint8_t * event){ 11024 return little_endian_read_32(event, 8); 11025 } 11026 /** 11027 * @brief Get field reason from event MESH_SUBEVENT_STATE_UPDATE_BOOL 11028 * @param event packet 11029 * @return reason 11030 * @note: btstack_type 1 11031 */ 11032 static inline uint8_t mesh_subevent_state_update_bool_get_reason(const uint8_t * event){ 11033 return event[12]; 11034 } 11035 /** 11036 * @brief Get field value from event MESH_SUBEVENT_STATE_UPDATE_BOOL 11037 * @param event packet 11038 * @return value 11039 * @note: btstack_type 1 11040 */ 11041 static inline uint8_t mesh_subevent_state_update_bool_get_value(const uint8_t * event){ 11042 return event[13]; 11043 } 11044 11045 /** 11046 * @brief Get field element_index from event MESH_SUBEVENT_STATE_UPDATE_INT16 11047 * @param event packet 11048 * @return element_index 11049 * @note: btstack_type 1 11050 */ 11051 static inline uint8_t mesh_subevent_state_update_int16_get_element_index(const uint8_t * event){ 11052 return event[3]; 11053 } 11054 /** 11055 * @brief Get field model_identifier from event MESH_SUBEVENT_STATE_UPDATE_INT16 11056 * @param event packet 11057 * @return model_identifier 11058 * @note: btstack_type 4 11059 */ 11060 static inline uint32_t mesh_subevent_state_update_int16_get_model_identifier(const uint8_t * event){ 11061 return little_endian_read_32(event, 4); 11062 } 11063 /** 11064 * @brief Get field state_identifier from event MESH_SUBEVENT_STATE_UPDATE_INT16 11065 * @param event packet 11066 * @return state_identifier 11067 * @note: btstack_type 4 11068 */ 11069 static inline uint32_t mesh_subevent_state_update_int16_get_state_identifier(const uint8_t * event){ 11070 return little_endian_read_32(event, 8); 11071 } 11072 /** 11073 * @brief Get field reason from event MESH_SUBEVENT_STATE_UPDATE_INT16 11074 * @param event packet 11075 * @return reason 11076 * @note: btstack_type 1 11077 */ 11078 static inline uint8_t mesh_subevent_state_update_int16_get_reason(const uint8_t * event){ 11079 return event[12]; 11080 } 11081 /** 11082 * @brief Get field value from event MESH_SUBEVENT_STATE_UPDATE_INT16 11083 * @param event packet 11084 * @return value 11085 * @note: btstack_type 2 11086 */ 11087 static inline uint16_t mesh_subevent_state_update_int16_get_value(const uint8_t * event){ 11088 return little_endian_read_16(event, 13); 11089 } 11090 11091 /** 11092 * @brief Get field element_index from event MESH_SUBEVENT_MESSAGE_NOT_ACKNOWLEDGED 11093 * @param event packet 11094 * @return element_index 11095 * @note: btstack_type 1 11096 */ 11097 static inline uint8_t mesh_subevent_message_not_acknowledged_get_element_index(const uint8_t * event){ 11098 return event[3]; 11099 } 11100 /** 11101 * @brief Get field model_identifier from event MESH_SUBEVENT_MESSAGE_NOT_ACKNOWLEDGED 11102 * @param event packet 11103 * @return model_identifier 11104 * @note: btstack_type 4 11105 */ 11106 static inline uint32_t mesh_subevent_message_not_acknowledged_get_model_identifier(const uint8_t * event){ 11107 return little_endian_read_32(event, 4); 11108 } 11109 /** 11110 * @brief Get field opcode from event MESH_SUBEVENT_MESSAGE_NOT_ACKNOWLEDGED 11111 * @param event packet 11112 * @return opcode 11113 * @note: btstack_type 4 11114 */ 11115 static inline uint32_t mesh_subevent_message_not_acknowledged_get_opcode(const uint8_t * event){ 11116 return little_endian_read_32(event, 8); 11117 } 11118 /** 11119 * @brief Get field dest from event MESH_SUBEVENT_MESSAGE_NOT_ACKNOWLEDGED 11120 * @param event packet 11121 * @return dest 11122 * @note: btstack_type 2 11123 */ 11124 static inline uint16_t mesh_subevent_message_not_acknowledged_get_dest(const uint8_t * event){ 11125 return little_endian_read_16(event, 12); 11126 } 11127 11128 /** 11129 * @brief Get field dest from event MESH_SUBEVENT_GENERIC_ON_OFF 11130 * @param event packet 11131 * @return dest 11132 * @note: btstack_type 2 11133 */ 11134 static inline uint16_t mesh_subevent_generic_on_off_get_dest(const uint8_t * event){ 11135 return little_endian_read_16(event, 3); 11136 } 11137 /** 11138 * @brief Get field status from event MESH_SUBEVENT_GENERIC_ON_OFF 11139 * @param event packet 11140 * @return status 11141 * @note: btstack_type 1 11142 */ 11143 static inline uint8_t mesh_subevent_generic_on_off_get_status(const uint8_t * event){ 11144 return event[5]; 11145 } 11146 /** 11147 * @brief Get field present_value from event MESH_SUBEVENT_GENERIC_ON_OFF 11148 * @param event packet 11149 * @return present_value 11150 * @note: btstack_type 1 11151 */ 11152 static inline uint8_t mesh_subevent_generic_on_off_get_present_value(const uint8_t * event){ 11153 return event[6]; 11154 } 11155 /** 11156 * @brief Get field target_value from event MESH_SUBEVENT_GENERIC_ON_OFF 11157 * @param event packet 11158 * @return target_value 11159 * @note: btstack_type 1 11160 */ 11161 static inline uint8_t mesh_subevent_generic_on_off_get_target_value(const uint8_t * event){ 11162 return event[7]; 11163 } 11164 /** 11165 * @brief Get field remaining_time_ms from event MESH_SUBEVENT_GENERIC_ON_OFF 11166 * @param event packet 11167 * @return remaining_time_ms 11168 * @note: btstack_type 4 11169 */ 11170 static inline uint32_t mesh_subevent_generic_on_off_get_remaining_time_ms(const uint8_t * event){ 11171 return little_endian_read_32(event, 8); 11172 } 11173 11174 /** 11175 * @brief Get field dest from event MESH_SUBEVENT_GENERIC_LEVEL 11176 * @param event packet 11177 * @return dest 11178 * @note: btstack_type 2 11179 */ 11180 static inline uint16_t mesh_subevent_generic_level_get_dest(const uint8_t * event){ 11181 return little_endian_read_16(event, 3); 11182 } 11183 /** 11184 * @brief Get field status from event MESH_SUBEVENT_GENERIC_LEVEL 11185 * @param event packet 11186 * @return status 11187 * @note: btstack_type 1 11188 */ 11189 static inline uint8_t mesh_subevent_generic_level_get_status(const uint8_t * event){ 11190 return event[5]; 11191 } 11192 /** 11193 * @brief Get field present_value from event MESH_SUBEVENT_GENERIC_LEVEL 11194 * @param event packet 11195 * @return present_value 11196 * @note: btstack_type 2 11197 */ 11198 static inline uint16_t mesh_subevent_generic_level_get_present_value(const uint8_t * event){ 11199 return little_endian_read_16(event, 6); 11200 } 11201 /** 11202 * @brief Get field target_value from event MESH_SUBEVENT_GENERIC_LEVEL 11203 * @param event packet 11204 * @return target_value 11205 * @note: btstack_type 2 11206 */ 11207 static inline uint16_t mesh_subevent_generic_level_get_target_value(const uint8_t * event){ 11208 return little_endian_read_16(event, 8); 11209 } 11210 /** 11211 * @brief Get field remaining_time_ms from event MESH_SUBEVENT_GENERIC_LEVEL 11212 * @param event packet 11213 * @return remaining_time_ms 11214 * @note: btstack_type 4 11215 */ 11216 static inline uint32_t mesh_subevent_generic_level_get_remaining_time_ms(const uint8_t * event){ 11217 return little_endian_read_32(event, 10); 11218 } 11219 11220 /** 11221 * @brief Get field dest from event MESH_SUBEVENT_HEALTH_PERFORM_TEST 11222 * @param event packet 11223 * @return dest 11224 * @note: btstack_type 2 11225 */ 11226 static inline uint16_t mesh_subevent_health_perform_test_get_dest(const uint8_t * event){ 11227 return little_endian_read_16(event, 3); 11228 } 11229 /** 11230 * @brief Get field netkey_index from event MESH_SUBEVENT_HEALTH_PERFORM_TEST 11231 * @param event packet 11232 * @return netkey_index 11233 * @note: btstack_type 2 11234 */ 11235 static inline uint16_t mesh_subevent_health_perform_test_get_netkey_index(const uint8_t * event){ 11236 return little_endian_read_16(event, 5); 11237 } 11238 /** 11239 * @brief Get field appkey_index from event MESH_SUBEVENT_HEALTH_PERFORM_TEST 11240 * @param event packet 11241 * @return appkey_index 11242 * @note: btstack_type 2 11243 */ 11244 static inline uint16_t mesh_subevent_health_perform_test_get_appkey_index(const uint8_t * event){ 11245 return little_endian_read_16(event, 7); 11246 } 11247 /** 11248 * @brief Get field company_id from event MESH_SUBEVENT_HEALTH_PERFORM_TEST 11249 * @param event packet 11250 * @return company_id 11251 * @note: btstack_type 2 11252 */ 11253 static inline uint16_t mesh_subevent_health_perform_test_get_company_id(const uint8_t * event){ 11254 return little_endian_read_16(event, 9); 11255 } 11256 /** 11257 * @brief Get field test_id from event MESH_SUBEVENT_HEALTH_PERFORM_TEST 11258 * @param event packet 11259 * @return test_id 11260 * @note: btstack_type 1 11261 */ 11262 static inline uint8_t mesh_subevent_health_perform_test_get_test_id(const uint8_t * event){ 11263 return event[11]; 11264 } 11265 /** 11266 * @brief Get field acknowledged from event MESH_SUBEVENT_HEALTH_PERFORM_TEST 11267 * @param event packet 11268 * @return acknowledged 11269 * @note: btstack_type 1 11270 */ 11271 static inline uint8_t mesh_subevent_health_perform_test_get_acknowledged(const uint8_t * event){ 11272 return event[12]; 11273 } 11274 11275 /** 11276 * @brief Get field element_index from event MESH_SUBEVENT_HEALTH_ATTENTION_TIMER_CHANGED 11277 * @param event packet 11278 * @return element_index 11279 * @note: btstack_type 1 11280 */ 11281 static inline uint8_t mesh_subevent_health_attention_timer_changed_get_element_index(const uint8_t * event){ 11282 return event[3]; 11283 } 11284 11285 /** 11286 * @brief Get field dest from event MESH_SUBEVENT_GENERIC_DEFAULT_TRANSITION_TIME 11287 * @param event packet 11288 * @return dest 11289 * @note: btstack_type 2 11290 */ 11291 static inline uint16_t mesh_subevent_generic_default_transition_time_get_dest(const uint8_t * event){ 11292 return little_endian_read_16(event, 3); 11293 } 11294 /** 11295 * @brief Get field status from event MESH_SUBEVENT_GENERIC_DEFAULT_TRANSITION_TIME 11296 * @param event packet 11297 * @return status 11298 * @note: btstack_type 1 11299 */ 11300 static inline uint8_t mesh_subevent_generic_default_transition_time_get_status(const uint8_t * event){ 11301 return event[5]; 11302 } 11303 /** 11304 * @brief Get field transition_time_gdtt from event MESH_SUBEVENT_GENERIC_DEFAULT_TRANSITION_TIME 11305 * @param event packet 11306 * @return transition_time_gdtt 11307 * @note: btstack_type 1 11308 */ 11309 static inline uint8_t mesh_subevent_generic_default_transition_time_get_transition_time_gdtt(const uint8_t * event){ 11310 return event[6]; 11311 } 11312 11313 /** 11314 * @brief Get field dest from event MESH_SUBEVENT_CONFIGURATION_BEACON 11315 * @param event packet 11316 * @return dest 11317 * @note: btstack_type 2 11318 */ 11319 static inline uint16_t mesh_subevent_configuration_beacon_get_dest(const uint8_t * event){ 11320 return little_endian_read_16(event, 3); 11321 } 11322 /** 11323 * @brief Get field foundation_status from event MESH_SUBEVENT_CONFIGURATION_BEACON 11324 * @param event packet 11325 * @return foundation_status 11326 * @note: btstack_type 1 11327 */ 11328 static inline uint8_t mesh_subevent_configuration_beacon_get_foundation_status(const uint8_t * event){ 11329 return event[5]; 11330 } 11331 /** 11332 * @brief Get field secure_network_beacon_state from event MESH_SUBEVENT_CONFIGURATION_BEACON 11333 * @param event packet 11334 * @return secure_network_beacon_state 11335 * @note: btstack_type 1 11336 */ 11337 static inline uint8_t mesh_subevent_configuration_beacon_get_secure_network_beacon_state(const uint8_t * event){ 11338 return event[6]; 11339 } 11340 11341 /** 11342 * @brief Get field dest from event MESH_SUBEVENT_CONFIGURATION_DEFAULT_TTL 11343 * @param event packet 11344 * @return dest 11345 * @note: btstack_type 2 11346 */ 11347 static inline uint16_t mesh_subevent_configuration_default_ttl_get_dest(const uint8_t * event){ 11348 return little_endian_read_16(event, 3); 11349 } 11350 /** 11351 * @brief Get field foundation_status from event MESH_SUBEVENT_CONFIGURATION_DEFAULT_TTL 11352 * @param event packet 11353 * @return foundation_status 11354 * @note: btstack_type 1 11355 */ 11356 static inline uint8_t mesh_subevent_configuration_default_ttl_get_foundation_status(const uint8_t * event){ 11357 return event[5]; 11358 } 11359 /** 11360 * @brief Get field default_ttl from event MESH_SUBEVENT_CONFIGURATION_DEFAULT_TTL 11361 * @param event packet 11362 * @return default_ttl 11363 * @note: btstack_type 1 11364 */ 11365 static inline uint8_t mesh_subevent_configuration_default_ttl_get_default_ttl(const uint8_t * event){ 11366 return event[6]; 11367 } 11368 11369 /** 11370 * @brief Get field dest from event MESH_SUBEVENT_CONFIGURATION_GATT_PROXY 11371 * @param event packet 11372 * @return dest 11373 * @note: btstack_type 2 11374 */ 11375 static inline uint16_t mesh_subevent_configuration_gatt_proxy_get_dest(const uint8_t * event){ 11376 return little_endian_read_16(event, 3); 11377 } 11378 /** 11379 * @brief Get field foundation_status from event MESH_SUBEVENT_CONFIGURATION_GATT_PROXY 11380 * @param event packet 11381 * @return foundation_status 11382 * @note: btstack_type 1 11383 */ 11384 static inline uint8_t mesh_subevent_configuration_gatt_proxy_get_foundation_status(const uint8_t * event){ 11385 return event[5]; 11386 } 11387 /** 11388 * @brief Get field gatt_proxy_state from event MESH_SUBEVENT_CONFIGURATION_GATT_PROXY 11389 * @param event packet 11390 * @return gatt_proxy_state 11391 * @note: btstack_type 1 11392 */ 11393 static inline uint8_t mesh_subevent_configuration_gatt_proxy_get_gatt_proxy_state(const uint8_t * event){ 11394 return event[6]; 11395 } 11396 11397 /** 11398 * @brief Get field dest from event MESH_SUBEVENT_CONFIGURATION_RELAY 11399 * @param event packet 11400 * @return dest 11401 * @note: btstack_type 2 11402 */ 11403 static inline uint16_t mesh_subevent_configuration_relay_get_dest(const uint8_t * event){ 11404 return little_endian_read_16(event, 3); 11405 } 11406 /** 11407 * @brief Get field foundation_status from event MESH_SUBEVENT_CONFIGURATION_RELAY 11408 * @param event packet 11409 * @return foundation_status 11410 * @note: btstack_type 1 11411 */ 11412 static inline uint8_t mesh_subevent_configuration_relay_get_foundation_status(const uint8_t * event){ 11413 return event[5]; 11414 } 11415 /** 11416 * @brief Get field relay from event MESH_SUBEVENT_CONFIGURATION_RELAY 11417 * @param event packet 11418 * @return relay 11419 * @note: btstack_type 1 11420 */ 11421 static inline uint8_t mesh_subevent_configuration_relay_get_relay(const uint8_t * event){ 11422 return event[6]; 11423 } 11424 /** 11425 * @brief Get field retransmit_count from event MESH_SUBEVENT_CONFIGURATION_RELAY 11426 * @param event packet 11427 * @return retransmit_count 11428 * @note: btstack_type 1 11429 */ 11430 static inline uint8_t mesh_subevent_configuration_relay_get_retransmit_count(const uint8_t * event){ 11431 return event[7]; 11432 } 11433 /** 11434 * @brief Get field retransmit_interval_ms from event MESH_SUBEVENT_CONFIGURATION_RELAY 11435 * @param event packet 11436 * @return retransmit_interval_ms 11437 * @note: btstack_type 1 11438 */ 11439 static inline uint8_t mesh_subevent_configuration_relay_get_retransmit_interval_ms(const uint8_t * event){ 11440 return event[8]; 11441 } 11442 11443 /** 11444 * @brief Get field dest from event MESH_SUBEVENT_CONFIGURATION_MODEL_PUBLICATION 11445 * @param event packet 11446 * @return dest 11447 * @note: btstack_type 2 11448 */ 11449 static inline uint16_t mesh_subevent_configuration_model_publication_get_dest(const uint8_t * event){ 11450 return little_endian_read_16(event, 3); 11451 } 11452 /** 11453 * @brief Get field foundation_status from event MESH_SUBEVENT_CONFIGURATION_MODEL_PUBLICATION 11454 * @param event packet 11455 * @return foundation_status 11456 * @note: btstack_type 1 11457 */ 11458 static inline uint8_t mesh_subevent_configuration_model_publication_get_foundation_status(const uint8_t * event){ 11459 return event[5]; 11460 } 11461 /** 11462 * @brief Get field publish_address from event MESH_SUBEVENT_CONFIGURATION_MODEL_PUBLICATION 11463 * @param event packet 11464 * @return publish_address 11465 * @note: btstack_type 2 11466 */ 11467 static inline uint16_t mesh_subevent_configuration_model_publication_get_publish_address(const uint8_t * event){ 11468 return little_endian_read_16(event, 6); 11469 } 11470 /** 11471 * @brief Get field appkey_index from event MESH_SUBEVENT_CONFIGURATION_MODEL_PUBLICATION 11472 * @param event packet 11473 * @return appkey_index 11474 * @note: btstack_type 2 11475 */ 11476 static inline uint16_t mesh_subevent_configuration_model_publication_get_appkey_index(const uint8_t * event){ 11477 return little_endian_read_16(event, 8); 11478 } 11479 /** 11480 * @brief Get field credential_flag from event MESH_SUBEVENT_CONFIGURATION_MODEL_PUBLICATION 11481 * @param event packet 11482 * @return credential_flag 11483 * @note: btstack_type 1 11484 */ 11485 static inline uint8_t mesh_subevent_configuration_model_publication_get_credential_flag(const uint8_t * event){ 11486 return event[10]; 11487 } 11488 /** 11489 * @brief Get field publish_ttl from event MESH_SUBEVENT_CONFIGURATION_MODEL_PUBLICATION 11490 * @param event packet 11491 * @return publish_ttl 11492 * @note: btstack_type 1 11493 */ 11494 static inline uint8_t mesh_subevent_configuration_model_publication_get_publish_ttl(const uint8_t * event){ 11495 return event[11]; 11496 } 11497 /** 11498 * @brief Get field publish_period from event MESH_SUBEVENT_CONFIGURATION_MODEL_PUBLICATION 11499 * @param event packet 11500 * @return publish_period 11501 * @note: btstack_type 1 11502 */ 11503 static inline uint8_t mesh_subevent_configuration_model_publication_get_publish_period(const uint8_t * event){ 11504 return event[12]; 11505 } 11506 /** 11507 * @brief Get field publish_retransmit_count from event MESH_SUBEVENT_CONFIGURATION_MODEL_PUBLICATION 11508 * @param event packet 11509 * @return publish_retransmit_count 11510 * @note: btstack_type 1 11511 */ 11512 static inline uint8_t mesh_subevent_configuration_model_publication_get_publish_retransmit_count(const uint8_t * event){ 11513 return event[13]; 11514 } 11515 /** 11516 * @brief Get field publish_retransmit_interval_steps from event MESH_SUBEVENT_CONFIGURATION_MODEL_PUBLICATION 11517 * @param event packet 11518 * @return publish_retransmit_interval_steps 11519 * @note: btstack_type 1 11520 */ 11521 static inline uint8_t mesh_subevent_configuration_model_publication_get_publish_retransmit_interval_steps(const uint8_t * event){ 11522 return event[14]; 11523 } 11524 /** 11525 * @brief Get field model_identifier from event MESH_SUBEVENT_CONFIGURATION_MODEL_PUBLICATION 11526 * @param event packet 11527 * @return model_identifier 11528 * @note: btstack_type 4 11529 */ 11530 static inline uint32_t mesh_subevent_configuration_model_publication_get_model_identifier(const uint8_t * event){ 11531 return little_endian_read_32(event, 15); 11532 } 11533 11534 /** 11535 * @brief Get field dest from event MESH_SUBEVENT_CONFIGURATION_MODEL_SUBSCRIPTION 11536 * @param event packet 11537 * @return dest 11538 * @note: btstack_type 2 11539 */ 11540 static inline uint16_t mesh_subevent_configuration_model_subscription_get_dest(const uint8_t * event){ 11541 return little_endian_read_16(event, 3); 11542 } 11543 /** 11544 * @brief Get field foundation_status from event MESH_SUBEVENT_CONFIGURATION_MODEL_SUBSCRIPTION 11545 * @param event packet 11546 * @return foundation_status 11547 * @note: btstack_type 1 11548 */ 11549 static inline uint8_t mesh_subevent_configuration_model_subscription_get_foundation_status(const uint8_t * event){ 11550 return event[5]; 11551 } 11552 /** 11553 * @brief Get field address from event MESH_SUBEVENT_CONFIGURATION_MODEL_SUBSCRIPTION 11554 * @param event packet 11555 * @return address 11556 * @note: btstack_type 2 11557 */ 11558 static inline uint16_t mesh_subevent_configuration_model_subscription_get_address(const uint8_t * event){ 11559 return little_endian_read_16(event, 6); 11560 } 11561 /** 11562 * @brief Get field model_identifier from event MESH_SUBEVENT_CONFIGURATION_MODEL_SUBSCRIPTION 11563 * @param event packet 11564 * @return model_identifier 11565 * @note: btstack_type 4 11566 */ 11567 static inline uint32_t mesh_subevent_configuration_model_subscription_get_model_identifier(const uint8_t * event){ 11568 return little_endian_read_32(event, 8); 11569 } 11570 11571 /** 11572 * @brief Get field dest from event MESH_SUBEVENT_CONFIGURATION_MODEL_SUBSCRIPTION_LIST_ITEM 11573 * @param event packet 11574 * @return dest 11575 * @note: btstack_type 2 11576 */ 11577 static inline uint16_t mesh_subevent_configuration_model_subscription_list_item_get_dest(const uint8_t * event){ 11578 return little_endian_read_16(event, 3); 11579 } 11580 /** 11581 * @brief Get field foundation_status from event MESH_SUBEVENT_CONFIGURATION_MODEL_SUBSCRIPTION_LIST_ITEM 11582 * @param event packet 11583 * @return foundation_status 11584 * @note: btstack_type 1 11585 */ 11586 static inline uint8_t mesh_subevent_configuration_model_subscription_list_item_get_foundation_status(const uint8_t * event){ 11587 return event[5]; 11588 } 11589 /** 11590 * @brief Get field model_identifier from event MESH_SUBEVENT_CONFIGURATION_MODEL_SUBSCRIPTION_LIST_ITEM 11591 * @param event packet 11592 * @return model_identifier 11593 * @note: btstack_type 4 11594 */ 11595 static inline uint32_t mesh_subevent_configuration_model_subscription_list_item_get_model_identifier(const uint8_t * event){ 11596 return little_endian_read_32(event, 6); 11597 } 11598 /** 11599 * @brief Get field num_subscription_addresses from event MESH_SUBEVENT_CONFIGURATION_MODEL_SUBSCRIPTION_LIST_ITEM 11600 * @param event packet 11601 * @return num_subscription_addresses 11602 * @note: btstack_type 1 11603 */ 11604 static inline uint8_t mesh_subevent_configuration_model_subscription_list_item_get_num_subscription_addresses(const uint8_t * event){ 11605 return event[10]; 11606 } 11607 /** 11608 * @brief Get field subscription_address_pos from event MESH_SUBEVENT_CONFIGURATION_MODEL_SUBSCRIPTION_LIST_ITEM 11609 * @param event packet 11610 * @return subscription_address_pos 11611 * @note: btstack_type 1 11612 */ 11613 static inline uint8_t mesh_subevent_configuration_model_subscription_list_item_get_subscription_address_pos(const uint8_t * event){ 11614 return event[11]; 11615 } 11616 /** 11617 * @brief Get field subscription_address_item from event MESH_SUBEVENT_CONFIGURATION_MODEL_SUBSCRIPTION_LIST_ITEM 11618 * @param event packet 11619 * @return subscription_address_item 11620 * @note: btstack_type 2 11621 */ 11622 static inline uint16_t mesh_subevent_configuration_model_subscription_list_item_get_subscription_address_item(const uint8_t * event){ 11623 return little_endian_read_16(event, 12); 11624 } 11625 11626 /** 11627 * @brief Get field dest from event MESH_SUBEVENT_CONFIGURATION_NETKEY_INDEX 11628 * @param event packet 11629 * @return dest 11630 * @note: btstack_type 2 11631 */ 11632 static inline uint16_t mesh_subevent_configuration_netkey_index_get_dest(const uint8_t * event){ 11633 return little_endian_read_16(event, 3); 11634 } 11635 /** 11636 * @brief Get field foundation_status from event MESH_SUBEVENT_CONFIGURATION_NETKEY_INDEX 11637 * @param event packet 11638 * @return foundation_status 11639 * @note: btstack_type 1 11640 */ 11641 static inline uint8_t mesh_subevent_configuration_netkey_index_get_foundation_status(const uint8_t * event){ 11642 return event[5]; 11643 } 11644 11645 /** 11646 * @brief Get field dest from event MESH_SUBEVENT_CONFIGURATION_NETKEY_INDEX_LIST_ITEM 11647 * @param event packet 11648 * @return dest 11649 * @note: btstack_type 2 11650 */ 11651 static inline uint16_t mesh_subevent_configuration_netkey_index_list_item_get_dest(const uint8_t * event){ 11652 return little_endian_read_16(event, 3); 11653 } 11654 /** 11655 * @brief Get field foundation_status from event MESH_SUBEVENT_CONFIGURATION_NETKEY_INDEX_LIST_ITEM 11656 * @param event packet 11657 * @return foundation_status 11658 * @note: btstack_type 1 11659 */ 11660 static inline uint8_t mesh_subevent_configuration_netkey_index_list_item_get_foundation_status(const uint8_t * event){ 11661 return event[5]; 11662 } 11663 /** 11664 * @brief Get field num_netkey_indexes from event MESH_SUBEVENT_CONFIGURATION_NETKEY_INDEX_LIST_ITEM 11665 * @param event packet 11666 * @return num_netkey_indexes 11667 * @note: btstack_type 1 11668 */ 11669 static inline uint8_t mesh_subevent_configuration_netkey_index_list_item_get_num_netkey_indexes(const uint8_t * event){ 11670 return event[6]; 11671 } 11672 /** 11673 * @brief Get field netkey_index_pos from event MESH_SUBEVENT_CONFIGURATION_NETKEY_INDEX_LIST_ITEM 11674 * @param event packet 11675 * @return netkey_index_pos 11676 * @note: btstack_type 1 11677 */ 11678 static inline uint8_t mesh_subevent_configuration_netkey_index_list_item_get_netkey_index_pos(const uint8_t * event){ 11679 return event[7]; 11680 } 11681 /** 11682 * @brief Get field netkey_index_item from event MESH_SUBEVENT_CONFIGURATION_NETKEY_INDEX_LIST_ITEM 11683 * @param event packet 11684 * @return netkey_index_item 11685 * @note: btstack_type 2 11686 */ 11687 static inline uint16_t mesh_subevent_configuration_netkey_index_list_item_get_netkey_index_item(const uint8_t * event){ 11688 return little_endian_read_16(event, 8); 11689 } 11690 11691 /** 11692 * @brief Get field dest from event MESH_SUBEVENT_CONFIGURATION_APPKEY_INDEX 11693 * @param event packet 11694 * @return dest 11695 * @note: btstack_type 2 11696 */ 11697 static inline uint16_t mesh_subevent_configuration_appkey_index_get_dest(const uint8_t * event){ 11698 return little_endian_read_16(event, 3); 11699 } 11700 /** 11701 * @brief Get field foundation_status from event MESH_SUBEVENT_CONFIGURATION_APPKEY_INDEX 11702 * @param event packet 11703 * @return foundation_status 11704 * @note: btstack_type 1 11705 */ 11706 static inline uint8_t mesh_subevent_configuration_appkey_index_get_foundation_status(const uint8_t * event){ 11707 return event[5]; 11708 } 11709 /** 11710 * @brief Get field netkey_index_item from event MESH_SUBEVENT_CONFIGURATION_APPKEY_INDEX 11711 * @param event packet 11712 * @return netkey_index_item 11713 * @note: btstack_type 2 11714 */ 11715 static inline uint16_t mesh_subevent_configuration_appkey_index_get_netkey_index_item(const uint8_t * event){ 11716 return little_endian_read_16(event, 6); 11717 } 11718 /** 11719 * @brief Get field appkey_index_item from event MESH_SUBEVENT_CONFIGURATION_APPKEY_INDEX 11720 * @param event packet 11721 * @return appkey_index_item 11722 * @note: btstack_type 2 11723 */ 11724 static inline uint16_t mesh_subevent_configuration_appkey_index_get_appkey_index_item(const uint8_t * event){ 11725 return little_endian_read_16(event, 8); 11726 } 11727 11728 /** 11729 * @brief Get field dest from event MESH_SUBEVENT_CONFIGURATION_APPKEY_INDEX_LIST_ITEM 11730 * @param event packet 11731 * @return dest 11732 * @note: btstack_type 2 11733 */ 11734 static inline uint16_t mesh_subevent_configuration_appkey_index_list_item_get_dest(const uint8_t * event){ 11735 return little_endian_read_16(event, 3); 11736 } 11737 /** 11738 * @brief Get field foundation_status from event MESH_SUBEVENT_CONFIGURATION_APPKEY_INDEX_LIST_ITEM 11739 * @param event packet 11740 * @return foundation_status 11741 * @note: btstack_type 1 11742 */ 11743 static inline uint8_t mesh_subevent_configuration_appkey_index_list_item_get_foundation_status(const uint8_t * event){ 11744 return event[5]; 11745 } 11746 /** 11747 * @brief Get field netkey_index from event MESH_SUBEVENT_CONFIGURATION_APPKEY_INDEX_LIST_ITEM 11748 * @param event packet 11749 * @return netkey_index 11750 * @note: btstack_type 2 11751 */ 11752 static inline uint16_t mesh_subevent_configuration_appkey_index_list_item_get_netkey_index(const uint8_t * event){ 11753 return little_endian_read_16(event, 6); 11754 } 11755 /** 11756 * @brief Get field num_appkey_indexes from event MESH_SUBEVENT_CONFIGURATION_APPKEY_INDEX_LIST_ITEM 11757 * @param event packet 11758 * @return num_appkey_indexes 11759 * @note: btstack_type 1 11760 */ 11761 static inline uint8_t mesh_subevent_configuration_appkey_index_list_item_get_num_appkey_indexes(const uint8_t * event){ 11762 return event[8]; 11763 } 11764 /** 11765 * @brief Get field appkey_index_pos from event MESH_SUBEVENT_CONFIGURATION_APPKEY_INDEX_LIST_ITEM 11766 * @param event packet 11767 * @return appkey_index_pos 11768 * @note: btstack_type 1 11769 */ 11770 static inline uint8_t mesh_subevent_configuration_appkey_index_list_item_get_appkey_index_pos(const uint8_t * event){ 11771 return event[9]; 11772 } 11773 /** 11774 * @brief Get field netkey_index_item from event MESH_SUBEVENT_CONFIGURATION_APPKEY_INDEX_LIST_ITEM 11775 * @param event packet 11776 * @return netkey_index_item 11777 * @note: btstack_type 2 11778 */ 11779 static inline uint16_t mesh_subevent_configuration_appkey_index_list_item_get_netkey_index_item(const uint8_t * event){ 11780 return little_endian_read_16(event, 10); 11781 } 11782 /** 11783 * @brief Get field appkey_index_item from event MESH_SUBEVENT_CONFIGURATION_APPKEY_INDEX_LIST_ITEM 11784 * @param event packet 11785 * @return appkey_index_item 11786 * @note: btstack_type 2 11787 */ 11788 static inline uint16_t mesh_subevent_configuration_appkey_index_list_item_get_appkey_index_item(const uint8_t * event){ 11789 return little_endian_read_16(event, 12); 11790 } 11791 11792 /** 11793 * @brief Get field dest from event MESH_SUBEVENT_CONFIGURATION_NODE_IDENTITY 11794 * @param event packet 11795 * @return dest 11796 * @note: btstack_type 2 11797 */ 11798 static inline uint16_t mesh_subevent_configuration_node_identity_get_dest(const uint8_t * event){ 11799 return little_endian_read_16(event, 3); 11800 } 11801 /** 11802 * @brief Get field foundation_status from event MESH_SUBEVENT_CONFIGURATION_NODE_IDENTITY 11803 * @param event packet 11804 * @return foundation_status 11805 * @note: btstack_type 1 11806 */ 11807 static inline uint8_t mesh_subevent_configuration_node_identity_get_foundation_status(const uint8_t * event){ 11808 return event[5]; 11809 } 11810 /** 11811 * @brief Get field netkey_index_item from event MESH_SUBEVENT_CONFIGURATION_NODE_IDENTITY 11812 * @param event packet 11813 * @return netkey_index_item 11814 * @note: btstack_type 2 11815 */ 11816 static inline uint16_t mesh_subevent_configuration_node_identity_get_netkey_index_item(const uint8_t * event){ 11817 return little_endian_read_16(event, 6); 11818 } 11819 /** 11820 * @brief Get field identity_status from event MESH_SUBEVENT_CONFIGURATION_NODE_IDENTITY 11821 * @param event packet 11822 * @return identity_status 11823 * @note: btstack_type 1 11824 */ 11825 static inline uint8_t mesh_subevent_configuration_node_identity_get_identity_status(const uint8_t * event){ 11826 return event[8]; 11827 } 11828 11829 /** 11830 * @brief Get field dest from event MESH_SUBEVENT_CONFIGURATION_MODEL_APP 11831 * @param event packet 11832 * @return dest 11833 * @note: btstack_type 2 11834 */ 11835 static inline uint16_t mesh_subevent_configuration_model_app_get_dest(const uint8_t * event){ 11836 return little_endian_read_16(event, 3); 11837 } 11838 /** 11839 * @brief Get field foundation_status from event MESH_SUBEVENT_CONFIGURATION_MODEL_APP 11840 * @param event packet 11841 * @return foundation_status 11842 * @note: btstack_type 1 11843 */ 11844 static inline uint8_t mesh_subevent_configuration_model_app_get_foundation_status(const uint8_t * event){ 11845 return event[5]; 11846 } 11847 /** 11848 * @brief Get field appkey_index from event MESH_SUBEVENT_CONFIGURATION_MODEL_APP 11849 * @param event packet 11850 * @return appkey_index 11851 * @note: btstack_type 2 11852 */ 11853 static inline uint16_t mesh_subevent_configuration_model_app_get_appkey_index(const uint8_t * event){ 11854 return little_endian_read_16(event, 6); 11855 } 11856 /** 11857 * @brief Get field model_identifier from event MESH_SUBEVENT_CONFIGURATION_MODEL_APP 11858 * @param event packet 11859 * @return model_identifier 11860 * @note: btstack_type 4 11861 */ 11862 static inline uint32_t mesh_subevent_configuration_model_app_get_model_identifier(const uint8_t * event){ 11863 return little_endian_read_32(event, 8); 11864 } 11865 11866 /** 11867 * @brief Get field dest from event MESH_SUBEVENT_CONFIGURATION_MODEL_APP_LIST_ITEM 11868 * @param event packet 11869 * @return dest 11870 * @note: btstack_type 2 11871 */ 11872 static inline uint16_t mesh_subevent_configuration_model_app_list_item_get_dest(const uint8_t * event){ 11873 return little_endian_read_16(event, 3); 11874 } 11875 /** 11876 * @brief Get field foundation_status from event MESH_SUBEVENT_CONFIGURATION_MODEL_APP_LIST_ITEM 11877 * @param event packet 11878 * @return foundation_status 11879 * @note: btstack_type 1 11880 */ 11881 static inline uint8_t mesh_subevent_configuration_model_app_list_item_get_foundation_status(const uint8_t * event){ 11882 return event[5]; 11883 } 11884 /** 11885 * @brief Get field model_id from event MESH_SUBEVENT_CONFIGURATION_MODEL_APP_LIST_ITEM 11886 * @param event packet 11887 * @return model_id 11888 * @note: btstack_type 4 11889 */ 11890 static inline uint32_t mesh_subevent_configuration_model_app_list_item_get_model_id(const uint8_t * event){ 11891 return little_endian_read_32(event, 6); 11892 } 11893 /** 11894 * @brief Get field num_appkey_indexes from event MESH_SUBEVENT_CONFIGURATION_MODEL_APP_LIST_ITEM 11895 * @param event packet 11896 * @return num_appkey_indexes 11897 * @note: btstack_type 1 11898 */ 11899 static inline uint8_t mesh_subevent_configuration_model_app_list_item_get_num_appkey_indexes(const uint8_t * event){ 11900 return event[10]; 11901 } 11902 /** 11903 * @brief Get field appkey_index_pos from event MESH_SUBEVENT_CONFIGURATION_MODEL_APP_LIST_ITEM 11904 * @param event packet 11905 * @return appkey_index_pos 11906 * @note: btstack_type 1 11907 */ 11908 static inline uint8_t mesh_subevent_configuration_model_app_list_item_get_appkey_index_pos(const uint8_t * event){ 11909 return event[11]; 11910 } 11911 /** 11912 * @brief Get field appkey_index_item from event MESH_SUBEVENT_CONFIGURATION_MODEL_APP_LIST_ITEM 11913 * @param event packet 11914 * @return appkey_index_item 11915 * @note: btstack_type 2 11916 */ 11917 static inline uint16_t mesh_subevent_configuration_model_app_list_item_get_appkey_index_item(const uint8_t * event){ 11918 return little_endian_read_16(event, 12); 11919 } 11920 11921 /** 11922 * @brief Get field dest from event MESH_SUBEVENT_CONFIGURATION_NODE_RESET 11923 * @param event packet 11924 * @return dest 11925 * @note: btstack_type 2 11926 */ 11927 static inline uint16_t mesh_subevent_configuration_node_reset_get_dest(const uint8_t * event){ 11928 return little_endian_read_16(event, 3); 11929 } 11930 /** 11931 * @brief Get field foundation_status from event MESH_SUBEVENT_CONFIGURATION_NODE_RESET 11932 * @param event packet 11933 * @return foundation_status 11934 * @note: btstack_type 1 11935 */ 11936 static inline uint8_t mesh_subevent_configuration_node_reset_get_foundation_status(const uint8_t * event){ 11937 return event[5]; 11938 } 11939 11940 /** 11941 * @brief Get field dest from event MESH_SUBEVENT_CONFIGURATION_FRIEND 11942 * @param event packet 11943 * @return dest 11944 * @note: btstack_type 2 11945 */ 11946 static inline uint16_t mesh_subevent_configuration_friend_get_dest(const uint8_t * event){ 11947 return little_endian_read_16(event, 3); 11948 } 11949 /** 11950 * @brief Get field foundation_status from event MESH_SUBEVENT_CONFIGURATION_FRIEND 11951 * @param event packet 11952 * @return foundation_status 11953 * @note: btstack_type 1 11954 */ 11955 static inline uint8_t mesh_subevent_configuration_friend_get_foundation_status(const uint8_t * event){ 11956 return event[5]; 11957 } 11958 /** 11959 * @brief Get field friend_state from event MESH_SUBEVENT_CONFIGURATION_FRIEND 11960 * @param event packet 11961 * @return friend_state 11962 * @note: btstack_type 1 11963 */ 11964 static inline uint8_t mesh_subevent_configuration_friend_get_friend_state(const uint8_t * event){ 11965 return event[6]; 11966 } 11967 11968 /** 11969 * @brief Get field dest from event MESH_SUBEVENT_CONFIGURATION_KEY_REFRESH_PHASE 11970 * @param event packet 11971 * @return dest 11972 * @note: btstack_type 2 11973 */ 11974 static inline uint16_t mesh_subevent_configuration_key_refresh_phase_get_dest(const uint8_t * event){ 11975 return little_endian_read_16(event, 3); 11976 } 11977 /** 11978 * @brief Get field foundation_status from event MESH_SUBEVENT_CONFIGURATION_KEY_REFRESH_PHASE 11979 * @param event packet 11980 * @return foundation_status 11981 * @note: btstack_type 1 11982 */ 11983 static inline uint8_t mesh_subevent_configuration_key_refresh_phase_get_foundation_status(const uint8_t * event){ 11984 return event[5]; 11985 } 11986 /** 11987 * @brief Get field netkey_index from event MESH_SUBEVENT_CONFIGURATION_KEY_REFRESH_PHASE 11988 * @param event packet 11989 * @return netkey_index 11990 * @note: btstack_type 2 11991 */ 11992 static inline uint16_t mesh_subevent_configuration_key_refresh_phase_get_netkey_index(const uint8_t * event){ 11993 return little_endian_read_16(event, 6); 11994 } 11995 /** 11996 * @brief Get field phase from event MESH_SUBEVENT_CONFIGURATION_KEY_REFRESH_PHASE 11997 * @param event packet 11998 * @return phase 11999 * @note: btstack_type 1 12000 */ 12001 static inline uint8_t mesh_subevent_configuration_key_refresh_phase_get_phase(const uint8_t * event){ 12002 return event[8]; 12003 } 12004 12005 /** 12006 * @brief Get field dest from event MESH_SUBEVENT_CONFIGURATION_HEARTBEAT_PUBLICATION 12007 * @param event packet 12008 * @return dest 12009 * @note: btstack_type 2 12010 */ 12011 static inline uint16_t mesh_subevent_configuration_heartbeat_publication_get_dest(const uint8_t * event){ 12012 return little_endian_read_16(event, 3); 12013 } 12014 /** 12015 * @brief Get field foundation_status from event MESH_SUBEVENT_CONFIGURATION_HEARTBEAT_PUBLICATION 12016 * @param event packet 12017 * @return foundation_status 12018 * @note: btstack_type 1 12019 */ 12020 static inline uint8_t mesh_subevent_configuration_heartbeat_publication_get_foundation_status(const uint8_t * event){ 12021 return event[5]; 12022 } 12023 /** 12024 * @brief Get field heartbeat_destination from event MESH_SUBEVENT_CONFIGURATION_HEARTBEAT_PUBLICATION 12025 * @param event packet 12026 * @return heartbeat_destination 12027 * @note: btstack_type 2 12028 */ 12029 static inline uint16_t mesh_subevent_configuration_heartbeat_publication_get_heartbeat_destination(const uint8_t * event){ 12030 return little_endian_read_16(event, 6); 12031 } 12032 /** 12033 * @brief Get field count_S from event MESH_SUBEVENT_CONFIGURATION_HEARTBEAT_PUBLICATION 12034 * @param event packet 12035 * @return count_S 12036 * @note: btstack_type 2 12037 */ 12038 static inline uint16_t mesh_subevent_configuration_heartbeat_publication_get_count_S(const uint8_t * event){ 12039 return little_endian_read_16(event, 8); 12040 } 12041 /** 12042 * @brief Get field period_S from event MESH_SUBEVENT_CONFIGURATION_HEARTBEAT_PUBLICATION 12043 * @param event packet 12044 * @return period_S 12045 * @note: btstack_type 2 12046 */ 12047 static inline uint16_t mesh_subevent_configuration_heartbeat_publication_get_period_S(const uint8_t * event){ 12048 return little_endian_read_16(event, 10); 12049 } 12050 /** 12051 * @brief Get field ttl from event MESH_SUBEVENT_CONFIGURATION_HEARTBEAT_PUBLICATION 12052 * @param event packet 12053 * @return ttl 12054 * @note: btstack_type 1 12055 */ 12056 static inline uint8_t mesh_subevent_configuration_heartbeat_publication_get_ttl(const uint8_t * event){ 12057 return event[12]; 12058 } 12059 /** 12060 * @brief Get field features from event MESH_SUBEVENT_CONFIGURATION_HEARTBEAT_PUBLICATION 12061 * @param event packet 12062 * @return features 12063 * @note: btstack_type 2 12064 */ 12065 static inline uint16_t mesh_subevent_configuration_heartbeat_publication_get_features(const uint8_t * event){ 12066 return little_endian_read_16(event, 13); 12067 } 12068 /** 12069 * @brief Get field netkey_index from event MESH_SUBEVENT_CONFIGURATION_HEARTBEAT_PUBLICATION 12070 * @param event packet 12071 * @return netkey_index 12072 * @note: btstack_type 2 12073 */ 12074 static inline uint16_t mesh_subevent_configuration_heartbeat_publication_get_netkey_index(const uint8_t * event){ 12075 return little_endian_read_16(event, 15); 12076 } 12077 12078 /** 12079 * @brief Get field dest from event MESH_SUBEVENT_CONFIGURATION_HEARTBEAT_SUBSCRIPTION 12080 * @param event packet 12081 * @return dest 12082 * @note: btstack_type 2 12083 */ 12084 static inline uint16_t mesh_subevent_configuration_heartbeat_subscription_get_dest(const uint8_t * event){ 12085 return little_endian_read_16(event, 3); 12086 } 12087 /** 12088 * @brief Get field foundation_status from event MESH_SUBEVENT_CONFIGURATION_HEARTBEAT_SUBSCRIPTION 12089 * @param event packet 12090 * @return foundation_status 12091 * @note: btstack_type 1 12092 */ 12093 static inline uint8_t mesh_subevent_configuration_heartbeat_subscription_get_foundation_status(const uint8_t * event){ 12094 return event[5]; 12095 } 12096 /** 12097 * @brief Get field heartbeat_destination from event MESH_SUBEVENT_CONFIGURATION_HEARTBEAT_SUBSCRIPTION 12098 * @param event packet 12099 * @return heartbeat_destination 12100 * @note: btstack_type 2 12101 */ 12102 static inline uint16_t mesh_subevent_configuration_heartbeat_subscription_get_heartbeat_destination(const uint8_t * event){ 12103 return little_endian_read_16(event, 6); 12104 } 12105 /** 12106 * @brief Get field heartbeat_source from event MESH_SUBEVENT_CONFIGURATION_HEARTBEAT_SUBSCRIPTION 12107 * @param event packet 12108 * @return heartbeat_source 12109 * @note: btstack_type 2 12110 */ 12111 static inline uint16_t mesh_subevent_configuration_heartbeat_subscription_get_heartbeat_source(const uint8_t * event){ 12112 return little_endian_read_16(event, 8); 12113 } 12114 /** 12115 * @brief Get field count_S from event MESH_SUBEVENT_CONFIGURATION_HEARTBEAT_SUBSCRIPTION 12116 * @param event packet 12117 * @return count_S 12118 * @note: btstack_type 2 12119 */ 12120 static inline uint16_t mesh_subevent_configuration_heartbeat_subscription_get_count_S(const uint8_t * event){ 12121 return little_endian_read_16(event, 10); 12122 } 12123 /** 12124 * @brief Get field period_S from event MESH_SUBEVENT_CONFIGURATION_HEARTBEAT_SUBSCRIPTION 12125 * @param event packet 12126 * @return period_S 12127 * @note: btstack_type 2 12128 */ 12129 static inline uint16_t mesh_subevent_configuration_heartbeat_subscription_get_period_S(const uint8_t * event){ 12130 return little_endian_read_16(event, 12); 12131 } 12132 /** 12133 * @brief Get field min_hops from event MESH_SUBEVENT_CONFIGURATION_HEARTBEAT_SUBSCRIPTION 12134 * @param event packet 12135 * @return min_hops 12136 * @note: btstack_type 1 12137 */ 12138 static inline uint8_t mesh_subevent_configuration_heartbeat_subscription_get_min_hops(const uint8_t * event){ 12139 return event[14]; 12140 } 12141 /** 12142 * @brief Get field max_hops from event MESH_SUBEVENT_CONFIGURATION_HEARTBEAT_SUBSCRIPTION 12143 * @param event packet 12144 * @return max_hops 12145 * @note: btstack_type 1 12146 */ 12147 static inline uint8_t mesh_subevent_configuration_heartbeat_subscription_get_max_hops(const uint8_t * event){ 12148 return event[15]; 12149 } 12150 12151 /** 12152 * @brief Get field dest from event MESH_SUBEVENT_CONFIGURATION_LOW_POWER_NODE_POLL_TIMEOUT 12153 * @param event packet 12154 * @return dest 12155 * @note: btstack_type 2 12156 */ 12157 static inline uint16_t mesh_subevent_configuration_low_power_node_poll_timeout_get_dest(const uint8_t * event){ 12158 return little_endian_read_16(event, 3); 12159 } 12160 /** 12161 * @brief Get field foundation_status from event MESH_SUBEVENT_CONFIGURATION_LOW_POWER_NODE_POLL_TIMEOUT 12162 * @param event packet 12163 * @return foundation_status 12164 * @note: btstack_type 1 12165 */ 12166 static inline uint8_t mesh_subevent_configuration_low_power_node_poll_timeout_get_foundation_status(const uint8_t * event){ 12167 return event[5]; 12168 } 12169 /** 12170 * @brief Get field lpn_address from event MESH_SUBEVENT_CONFIGURATION_LOW_POWER_NODE_POLL_TIMEOUT 12171 * @param event packet 12172 * @return lpn_address 12173 * @note: btstack_type 2 12174 */ 12175 static inline uint16_t mesh_subevent_configuration_low_power_node_poll_timeout_get_lpn_address(const uint8_t * event){ 12176 return little_endian_read_16(event, 6); 12177 } 12178 /** 12179 * @brief Get field poll_timeout from event MESH_SUBEVENT_CONFIGURATION_LOW_POWER_NODE_POLL_TIMEOUT 12180 * @param event packet 12181 * @return poll_timeout 12182 * @note: btstack_type 3 12183 */ 12184 static inline uint32_t mesh_subevent_configuration_low_power_node_poll_timeout_get_poll_timeout(const uint8_t * event){ 12185 return little_endian_read_24(event, 8); 12186 } 12187 12188 /** 12189 * @brief Get field dest from event MESH_SUBEVENT_CONFIGURATION_NETWORK_TRANSMIT 12190 * @param event packet 12191 * @return dest 12192 * @note: btstack_type 2 12193 */ 12194 static inline uint16_t mesh_subevent_configuration_network_transmit_get_dest(const uint8_t * event){ 12195 return little_endian_read_16(event, 3); 12196 } 12197 /** 12198 * @brief Get field foundation_status from event MESH_SUBEVENT_CONFIGURATION_NETWORK_TRANSMIT 12199 * @param event packet 12200 * @return foundation_status 12201 * @note: btstack_type 1 12202 */ 12203 static inline uint8_t mesh_subevent_configuration_network_transmit_get_foundation_status(const uint8_t * event){ 12204 return event[5]; 12205 } 12206 /** 12207 * @brief Get field transmit_count from event MESH_SUBEVENT_CONFIGURATION_NETWORK_TRANSMIT 12208 * @param event packet 12209 * @return transmit_count 12210 * @note: btstack_type 1 12211 */ 12212 static inline uint8_t mesh_subevent_configuration_network_transmit_get_transmit_count(const uint8_t * event){ 12213 return event[6]; 12214 } 12215 /** 12216 * @brief Get field transmit_interval_steps_ms from event MESH_SUBEVENT_CONFIGURATION_NETWORK_TRANSMIT 12217 * @param event packet 12218 * @return transmit_interval_steps_ms 12219 * @note: btstack_type 2 12220 */ 12221 static inline uint16_t mesh_subevent_configuration_network_transmit_get_transmit_interval_steps_ms(const uint8_t * event){ 12222 return little_endian_read_16(event, 7); 12223 } 12224 12225 12226 12227 /* API_END */ 12228 12229 #if defined __cplusplus 12230 } 12231 #endif 12232 12233 #endif // BTSTACK_EVENT_H 12234