mirror of https://github.com/ARMmbed/mbed-os.git
Removing 500ms delay inCyH4TransportDriver init; fixing warning about order of BT POWER in declarations
parent
0e6ede86de
commit
4d70877b35
|
|
@ -127,8 +127,7 @@ void CyH4TransportDriver::initialize()
|
|||
bt_power = 0;
|
||||
rtos::ThisThread::sleep_for(1ms);
|
||||
|
||||
cy_rslt_t rslt = cyhal_uart_init(&uart, tx, rx, NULL, NULL);
|
||||
// MBED_WARNING
|
||||
cyhal_uart_init(&uart, tx, rx, NULL, NULL);
|
||||
|
||||
const cyhal_uart_cfg_t uart_cfg = { .data_bits = 8, .stop_bits = 1, .parity = CYHAL_UART_PARITY_NONE, .rx_buffer = NULL, .rx_buffer_size = 0 };
|
||||
cyhal_uart_configure(&uart, &uart_cfg);
|
||||
|
|
@ -155,7 +154,6 @@ void CyH4TransportDriver::initialize()
|
|||
bt_device_wake = WAKE_EVENT_ACTIVE_HIGH;
|
||||
}
|
||||
sleep_manager_unlock_deep_sleep();
|
||||
// rtos::ThisThread::sleep_for(500ms);
|
||||
}
|
||||
|
||||
void CyH4TransportDriver::terminate()
|
||||
|
|
@ -170,10 +168,6 @@ void CyH4TransportDriver::terminate()
|
|||
CYHAL_ISR_PRIORITY_DEFAULT,
|
||||
false
|
||||
);
|
||||
cyhal_uart_register_callback(&uart,
|
||||
NULL,
|
||||
NULL
|
||||
);
|
||||
|
||||
// DigitalInOut does not appear to have Destructor nor does it have a
|
||||
// free() func (though the protected gpio_t does) so must call directly
|
||||
|
|
|
|||
|
|
@ -100,7 +100,6 @@ private:
|
|||
|
||||
mbed::DigitalInOut bt_host_wake;
|
||||
mbed::DigitalInOut bt_device_wake;
|
||||
mbed::DigitalInOut bt_power;
|
||||
bool bt_host_wake_active;
|
||||
|
||||
#if (defined(MBED_TICKLESS) && DEVICE_SLEEP && DEVICE_LPTICKER)
|
||||
|
|
@ -112,6 +111,7 @@ private:
|
|||
uint8_t dev_wake_irq_event;
|
||||
|
||||
bool holding_deep_sleep_lock;
|
||||
mbed::DigitalInOut bt_power;
|
||||
|
||||
};
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue