a2dp_sink.c (e91a86a9662daf64817ff278c078ebc108b31365) | a2dp_sink.c (ff8fd80fee45f40d915031451a42d12c30dff8bd) |
---|---|
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 --- 207 unchanged lines hidden (view full) --- 216 pos += 2; 217 event[pos++] = local_seid; 218 (*callback)(HCI_EVENT_PACKET, 0, event, sizeof(event)); 219} 220 221static inline void a2dp_emit_cmd_accepted(btstack_packet_handler_t callback, uint8_t * packet, uint16_t size){ 222 if (!callback) return; 223 UNUSED(size); | 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 --- 207 unchanged lines hidden (view full) --- 216 pos += 2; 217 event[pos++] = local_seid; 218 (*callback)(HCI_EVENT_PACKET, 0, event, sizeof(event)); 219} 220 221static inline void a2dp_emit_cmd_accepted(btstack_packet_handler_t callback, uint8_t * packet, uint16_t size){ 222 if (!callback) return; 223 UNUSED(size); |
224 packet[0] = HCI_EVENT_A2DP_META; |
|
224 packet[2] = A2DP_SUBEVENT_COMMAND_ACCEPTED; 225 (*callback)(HCI_EVENT_PACKET, 0, packet, size); 226} 227 228static inline void a2dp_emit_cmd_rejected(btstack_packet_handler_t callback, uint8_t * packet, uint16_t size){ 229 if (!callback) return; 230 UNUSED(size); | 225 packet[2] = A2DP_SUBEVENT_COMMAND_ACCEPTED; 226 (*callback)(HCI_EVENT_PACKET, 0, packet, size); 227} 228 229static inline void a2dp_emit_cmd_rejected(btstack_packet_handler_t callback, uint8_t * packet, uint16_t size){ 230 if (!callback) return; 231 UNUSED(size); |
232 packet[0] = HCI_EVENT_A2DP_META; |
|
231 packet[2] = A2DP_SUBEVENT_COMMAND_REJECTED; 232 (*callback)(HCI_EVENT_PACKET, 0, packet, size); 233} 234 235static void packet_handler(uint8_t packet_type, uint16_t channel, uint8_t *packet, uint16_t size){ 236 UNUSED(channel); 237 UNUSED(size); 238 bd_addr_t address; --- 94 unchanged lines hidden --- | 233 packet[2] = A2DP_SUBEVENT_COMMAND_REJECTED; 234 (*callback)(HCI_EVENT_PACKET, 0, packet, size); 235} 236 237static void packet_handler(uint8_t packet_type, uint16_t channel, uint8_t *packet, uint16_t size){ 238 UNUSED(channel); 239 UNUSED(size); 240 bd_addr_t address; --- 94 unchanged lines hidden --- |