From 8838c9457b5fc1bd97026ee5c513e740d649d044 Mon Sep 17 00:00:00 2001 From: Matthias Ringwald Date: Mon, 15 May 2017 18:06:55 +0200 Subject: [PATCH] esp32: avoid compile error in freertos support as xEventGroupSetBitsFromISR is not defined, but not needed on esp32 --- platform/freertos/btstack_uart_block_freertos.c | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/platform/freertos/btstack_uart_block_freertos.c b/platform/freertos/btstack_uart_block_freertos.c index 3d9e1c428..d671e3af4 100644 --- a/platform/freertos/btstack_uart_block_freertos.c +++ b/platform/freertos/btstack_uart_block_freertos.c @@ -50,9 +50,12 @@ #include "btstack_run_loop_freertos.h" #include "hal_uart_dma.h" +// hack to avoid error for ESP32 +#ifndef ESP_PLATFORM + #if (INCLUDE_xEventGroupSetBitFromISR != 1) -#error "The BTstack HAL UART Run Loop integration (btstack_uart_block_freertos) needs to trigger Run Loop iterations from ISR context, -but 'INCLUDE_xEventGroupSetBitFromISR' is not enabled in your FreeRTOS configuration. Please enable INCLUDE_xEventGroupSetBitFromISR." +#error "The BTstack HAL UART Run Loop integration (btstack_uart_block_freertos) needs to trigger Run Loop iterations from ISR context," \ +"but 'INCLUDE_xEventGroupSetBitFromISR' is not enabled in your FreeRTOS configuration. Please enable INCLUDE_xEventGroupSetBitFromISR." #endif // uart config @@ -156,4 +159,7 @@ static const btstack_uart_block_t btstack_uart_block_freertos = { const btstack_uart_block_t * btstack_uart_block_freertos_instance(void){ return &btstack_uart_block_freertos; -} \ No newline at end of file +} + +// end of hack to avoid error for ESP32 +#endif // ESP_PLATFORM