From a3be5a335e0d9c62bea782bdd5a08d99acb74292 Mon Sep 17 00:00:00 2001 From: Matthias Ringwald Date: Wed, 23 Dec 2015 16:03:19 +0100 Subject: [PATCH] h4 wiced: check CTS before sending with manual control --- port/wiced/hci_transport_h4_wiced.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/port/wiced/hci_transport_h4_wiced.c b/port/wiced/hci_transport_h4_wiced.c index 4f0e27b3c..d955fc31f 100644 --- a/port/wiced/hci_transport_h4_wiced.c +++ b/port/wiced/hci_transport_h4_wiced.c @@ -165,6 +165,13 @@ static wiced_result_t h4_rx_worker_receive_packet(void * arg){ // executed on tx worker thread static wiced_result_t h4_tx_worker_send_packet(void * arg){ +#ifdef WICED_BT_UART_MANUAL_CTS_RTS + while (platform_gpio_input_get(wiced_bt_uart_pins[WICED_BT_PIN_UART_CTS]) == WICED_TRUE){ + printf("."); + wiced_rtos_delay_milliseconds(10); + } + printf("\n"); +#endif // blocking send platform_uart_transmit_bytes(wiced_bt_uart_driver, tx_worker_data_buffer, tx_worker_data_size); // let stack know