Bluetooth channels rate fix (it was 60ms instead of 20ms)
This commit is contained in:
@@ -341,6 +341,13 @@ void bluetoothWakeup(void)
|
|||||||
#else // PCBX9E
|
#else // PCBX9E
|
||||||
void bluetoothWakeup()
|
void bluetoothWakeup()
|
||||||
{
|
{
|
||||||
|
if (bluetoothState != BLUETOOTH_STATE_OFF) {
|
||||||
|
bluetoothWriteWakeup();
|
||||||
|
if (bluetoothIsWriting()) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
tmr10ms_t now = get_tmr10ms();
|
tmr10ms_t now = get_tmr10ms();
|
||||||
|
|
||||||
if (now < bluetoothWakeupTime)
|
if (now < bluetoothWakeupTime)
|
||||||
@@ -360,13 +367,6 @@ void bluetoothWakeup()
|
|||||||
bluetoothState = BLUETOOTH_STATE_FACTORY_BAUDRATE_INIT;
|
bluetoothState = BLUETOOTH_STATE_FACTORY_BAUDRATE_INIT;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (bluetoothState != BLUETOOTH_STATE_OFF) {
|
|
||||||
bluetoothWriteWakeup();
|
|
||||||
if (bluetoothIsWriting()) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (bluetoothState == BLUETOOTH_STATE_FACTORY_BAUDRATE_INIT) {
|
if (bluetoothState == BLUETOOTH_STATE_FACTORY_BAUDRATE_INIT) {
|
||||||
bluetoothWriteString("AT+BAUD4\r\n");
|
bluetoothWriteString("AT+BAUD4\r\n");
|
||||||
bluetoothState = BLUETOOTH_STATE_BAUDRATE_SENT;
|
bluetoothState = BLUETOOTH_STATE_BAUDRATE_SENT;
|
||||||
|
|||||||
Reference in New Issue
Block a user