mirror of
https://github.com/bluekitchen/btstack.git
synced 2025-04-15 23:42:52 +00:00
esp32: fix warning for changes in esp-idf 5.3
This commit is contained in:
parent
4b86d035e6
commit
4839cdf83e
@ -62,9 +62,15 @@
|
|||||||
|
|
||||||
#include "driver/uart.h"
|
#include "driver/uart.h"
|
||||||
|
|
||||||
#include "esp_vfs_dev.h"
|
#include "esp_idf_version.h"
|
||||||
#include "esp_log.h"
|
#include "esp_log.h"
|
||||||
|
|
||||||
|
#if ESP_IDF_VERSION >= ESP_IDF_VERSION_VAL(5, 3, 0)
|
||||||
|
#include "driver/uart_vfs.h"
|
||||||
|
#else
|
||||||
|
#include "esp_vfs_dev.h"
|
||||||
|
#endif
|
||||||
|
|
||||||
static const char *TAG = "btstack_stdio";
|
static const char *TAG = "btstack_stdio";
|
||||||
|
|
||||||
// handle esp-idf change from CONFIG_CONSOLE_UART_NUM to CONFIG_ESP_CONSOLE_UART_NUM
|
// handle esp-idf change from CONFIG_CONSOLE_UART_NUM to CONFIG_ESP_CONSOLE_UART_NUM
|
||||||
@ -192,7 +198,11 @@ void btstack_stdio_init(void) {
|
|||||||
0));
|
0));
|
||||||
|
|
||||||
/* Tell VFS to use UART driver */
|
/* Tell VFS to use UART driver */
|
||||||
|
#if ESP_IDF_VERSION >= ESP_IDF_VERSION_VAL(5, 3, 0)
|
||||||
|
uart_vfs_dev_use_driver(CONFIG_ESP_CONSOLE_UART_NUM);
|
||||||
|
#else
|
||||||
esp_vfs_dev_uart_use_driver(CONFIG_ESP_CONSOLE_UART_NUM);
|
esp_vfs_dev_uart_use_driver(CONFIG_ESP_CONSOLE_UART_NUM);
|
||||||
|
#endif
|
||||||
|
|
||||||
//Create a task to block on UART RX
|
//Create a task to block on UART RX
|
||||||
xTaskCreate(btstack_stdio_task, "btstack_stdio", 2048, NULL, 12, NULL);
|
xTaskCreate(btstack_stdio_task, "btstack_stdio", 2048, NULL, 12, NULL);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user