hci.h (d6b06661159f27ddc0293fa2a7eaba2d8924e39f) hci.h (fb37a842ea98c26e62c79cddf7c8d9662590cf7e)
1/*
2 * Copyright (C) 2014 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

--- 559 unchanged lines hidden (view full) ---

568 // uint16_t lmp_version;
569 uint16_t manufacturer;
570 // uint16_t lmp_subversion;
571
572 // usable packet types given acl_data_packet_length and HCI_ACL_BUFFER_SIZE
573 uint16_t packet_types;
574
575 /* callback to L2CAP layer */
1/*
2 * Copyright (C) 2014 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

--- 559 unchanged lines hidden (view full) ---

568 // uint16_t lmp_version;
569 uint16_t manufacturer;
570 // uint16_t lmp_subversion;
571
572 // usable packet types given acl_data_packet_length and HCI_ACL_BUFFER_SIZE
573 uint16_t packet_types;
574
575 /* callback to L2CAP layer */
576 void (*packet_handler)(uint8_t packet_type, uint8_t *packet, uint16_t size);
576 void (*acl_packet_handler)(uint8_t packet_type, uint8_t *packet, uint16_t size);
577
578 /* callback for SCO data */
579 void (*sco_packet_handler)(uint8_t packet_type, uint8_t *packet, uint16_t size);
580
581 /* callbacks for events */
582 btstack_linked_list_t event_handlers;
583
584 /* hci state machine */

--- 201 unchanged lines hidden (view full) ---

786void hci_set_bd_addr(bd_addr_t addr);
787
788/**
789 * @brief Add event packet handler.
790 */
791void hci_add_event_handler(btstack_packet_callback_registration_t * callback_handler);
792
793/**
577
578 /* callback for SCO data */
579 void (*sco_packet_handler)(uint8_t packet_type, uint8_t *packet, uint16_t size);
580
581 /* callbacks for events */
582 btstack_linked_list_t event_handlers;
583
584 /* hci state machine */

--- 201 unchanged lines hidden (view full) ---

786void hci_set_bd_addr(bd_addr_t addr);
787
788/**
789 * @brief Add event packet handler.
790 */
791void hci_add_event_handler(btstack_packet_callback_registration_t * callback_handler);
792
793/**
794 * @brief Registers a packet handler. Used if L2CAP is not used (rarely).
794 * @brief Registers a packet handler for ACL data. Used by L2CAP
795 */
795 */
796void hci_register_packet_handler(void (*handler)(uint8_t packet_type, uint8_t *packet, uint16_t size));
796void hci_register_acl_packet_handler(void (*handler)(uint8_t packet_type, uint8_t *packet, uint16_t size));
797
798/**
799 * @brief Registers a packet handler for SCO data. Used for HSP and HFP profiles.
800 */
801void hci_register_sco_packet_handler(void (*handler)(uint8_t packet_type, uint8_t *packet, uint16_t size));
802
803/**
804 * @brief Requests the change of BTstack power mode.

--- 93 unchanged lines hidden ---
797
798/**
799 * @brief Registers a packet handler for SCO data. Used for HSP and HFP profiles.
800 */
801void hci_register_sco_packet_handler(void (*handler)(uint8_t packet_type, uint8_t *packet, uint16_t size));
802
803/**
804 * @brief Requests the change of BTstack power mode.

--- 93 unchanged lines hidden ---