hci.c (ac0f6b8367cae2c6ab4ee53a79dbd707960e8e13) | hci.c (c45ca112d38f4f658b727060f48145122a1f2d05) |
---|---|
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 --- 4131 unchanged lines hidden (view full) --- 4140 hci_emit_big_created(big, status); 4141 } else { 4142 hci_emit_big_terminated(big); 4143 } 4144 } 4145 } 4146 break; 4147 case HCI_SUBEVENT_LE_TERMINATE_BIG_COMPLETE: | 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 --- 4131 unchanged lines hidden (view full) --- 4140 hci_emit_big_created(big, status); 4141 } else { 4142 hci_emit_big_terminated(big); 4143 } 4144 } 4145 } 4146 break; 4147 case HCI_SUBEVENT_LE_TERMINATE_BIG_COMPLETE: |
4148 hci_stack->iso_active_operation_type = HCI_ISO_TYPE_INVALID; |
|
4148 big = hci_big_for_handle(hci_subevent_le_terminate_big_complete_get_big_handle(packet)); 4149 if (big != NULL){ 4150 // finalize associated ISO streams 4151 btstack_linked_list_iterator_t it; 4152 btstack_linked_list_iterator_init(&it, &hci_stack->iso_streams); 4153 while (btstack_linked_list_iterator_has_next(&it)){ 4154 hci_iso_stream_t * iso_stream = (hci_iso_stream_t *) btstack_linked_list_iterator_next(&it); 4155 if (iso_stream->group_id == big->big_handle){ --- 9 unchanged lines hidden (view full) --- 4165 break; 4166 default: 4167 hci_emit_big_terminated(big); 4168 break; 4169 } 4170 } 4171 break; 4172 case HCI_SUBEVENT_LE_BIG_SYNC_ESTABLISHED: | 4149 big = hci_big_for_handle(hci_subevent_le_terminate_big_complete_get_big_handle(packet)); 4150 if (big != NULL){ 4151 // finalize associated ISO streams 4152 btstack_linked_list_iterator_t it; 4153 btstack_linked_list_iterator_init(&it, &hci_stack->iso_streams); 4154 while (btstack_linked_list_iterator_has_next(&it)){ 4155 hci_iso_stream_t * iso_stream = (hci_iso_stream_t *) btstack_linked_list_iterator_next(&it); 4156 if (iso_stream->group_id == big->big_handle){ --- 9 unchanged lines hidden (view full) --- 4166 break; 4167 default: 4168 hci_emit_big_terminated(big); 4169 break; 4170 } 4171 } 4172 break; 4173 case HCI_SUBEVENT_LE_BIG_SYNC_ESTABLISHED: |
4174 hci_stack->iso_active_operation_type = HCI_ISO_TYPE_INVALID; |
|
4173 big_sync = hci_big_sync_for_handle(packet[4]); 4174 if (big_sync != NULL){ 4175 uint8_t status = packet[3]; 4176 uint8_t big_handle = packet[4]; 4177 if (status == ERROR_CODE_SUCCESS){ 4178 // store bis_con_handles and trigger iso path setup 4179 uint8_t num_bis = btstack_min(MAX_NR_BIS, packet[16]); 4180 uint8_t i; --- 12 unchanged lines hidden (view full) --- 4193 hci_emit_big_sync_created(big_sync, status); 4194 } else { 4195 hci_emit_big_sync_stopped(big_handle); 4196 } 4197 } 4198 } 4199 break; 4200 case HCI_SUBEVENT_LE_BIG_SYNC_LOST: | 4175 big_sync = hci_big_sync_for_handle(packet[4]); 4176 if (big_sync != NULL){ 4177 uint8_t status = packet[3]; 4178 uint8_t big_handle = packet[4]; 4179 if (status == ERROR_CODE_SUCCESS){ 4180 // store bis_con_handles and trigger iso path setup 4181 uint8_t num_bis = btstack_min(MAX_NR_BIS, packet[16]); 4182 uint8_t i; --- 12 unchanged lines hidden (view full) --- 4195 hci_emit_big_sync_created(big_sync, status); 4196 } else { 4197 hci_emit_big_sync_stopped(big_handle); 4198 } 4199 } 4200 } 4201 break; 4202 case HCI_SUBEVENT_LE_BIG_SYNC_LOST: |
4203 hci_stack->iso_active_operation_type = HCI_ISO_TYPE_INVALID; |
|
4201 big_sync = hci_big_sync_for_handle(packet[4]); 4202 if (big_sync != NULL){ 4203 uint8_t big_handle = packet[4]; 4204 btstack_linked_list_remove(&hci_stack->le_audio_big_syncs, (btstack_linked_item_t *) big_sync); 4205 hci_emit_big_sync_stopped(big_handle); 4206 } 4207 break; 4208#endif --- 5735 unchanged lines hidden --- | 4204 big_sync = hci_big_sync_for_handle(packet[4]); 4205 if (big_sync != NULL){ 4206 uint8_t big_handle = packet[4]; 4207 btstack_linked_list_remove(&hci_stack->le_audio_big_syncs, (btstack_linked_item_t *) big_sync); 4208 hci_emit_big_sync_stopped(big_handle); 4209 } 4210 break; 4211#endif --- 5735 unchanged lines hidden --- |