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