Merge branch 'bugfix/expose_baud_rate_in_menu_v5.1' into 'release/v5.1'

fix(nimble): Exposed the baud rate for hci uart in menuconfig (v5.1)

See merge request espressif/esp-idf!29489
This commit is contained in:
Rahul Tank 2024-03-11 20:09:45 +08:00
commit e78e9a9558
2 changed files with 31 additions and 2 deletions

View File

@ -783,9 +783,35 @@ menu "Host-controller Transport"
help
Uart port
choice BT_NIMBLE_HCI_USE_UART_BAUDRATE
prompt "Uart Hci Baud Rate"
default UART_BAUDRATE_921600
depends on BT_CONTROLLER_DISABLED && BT_NIMBLE_TRANSPORT_UART
help
Uart Baud Rate
config UART_BAUDRATE_115200
bool "115200"
config UART_BAUDRATE_230400
bool "230400"
config UART_BAUDRATE_460800
bool "460800"
config UART_BAUDRATE_921600
bool "921600"
endchoice
config BT_NIMBLE_HCI_UART_BAUDRATE
depends on BT_CONTROLLER_DISABLED && BT_NIMBLE_TRANSPORT_UART
int
default 115200 if UART_BAUDRATE_115200
default 230400 if UART_BAUDRATE_230400
default 460800 if UART_BAUDRATE_460800
default 921600 if UART_BAUDRATE_921600
choice BT_NIMBLE_USE_HCI_UART_PARITY
prompt "Uart PARITY"
default UART_PARITY_NONE
depends on BT_CONTROLLER_DISABLED && BT_NIMBLE_TRANSPORT_UART
help
Uart Parity
@ -801,16 +827,19 @@ menu "Host-controller Transport"
int
default 0 if !UART_PARITY_NONE
default 1 if UART_PARITY_NONE
depends on BT_CONTROLLER_DISABLED && BT_NIMBLE_TRANSPORT_UART
config BT_NIMBLE_TRANSPORT_UART_PARITY_ODD
int
default 0 if !UART_PARITY_ODD
default 1 if UART_PARITY_ODD
depends on BT_CONTROLLER_DISABLED && BT_NIMBLE_TRANSPORT_UART
config BT_NIMBLE_TRANSPORT_UART_PARITY_EVEN
int
default 0 if !UART_PARITY_EVEN
default 1 if UART_PARITY_EVEN
depends on BT_CONTROLLER_DISABLED && BT_NIMBLE_TRANSPORT_UART
config BT_NIMBLE_UART_RX_PIN
int "UART Rx pin"

View File

@ -1777,7 +1777,7 @@
#endif
#endif
#if CONFIG_BT_CONTROLLER_DISABLED
#if CONFIG_BT_CONTROLLER_DISABLED && CONFIG_BT_NIMBLE_TRANSPORT_UART
#ifndef MYNEWT_VAL_BLE_TRANSPORT_UART_PORT
#define MYNEWT_VAL_BLE_TRANSPORT_UART_PORT CONFIG_BT_NIMBLE_TRANSPORT_UART_PORT
#endif
@ -1799,7 +1799,7 @@
#endif
#ifndef MYNEWT_VAL_BLE_TRANSPORT_UART_BAUDRATE
#define MYNEWT_VAL_BLE_TRANSPORT_UART_BAUDRATE (921600)
#define MYNEWT_VAL_BLE_TRANSPORT_UART_BAUDRATE CONFIG_BT_NIMBLE_HCI_UART_BAUDRATE
#endif
#ifndef MYNEWT_VAL_BLE_TRANSPORT_UART_DATA_BITS