From 6d94d9e766ced73135154a681114ad8d49cff308 Mon Sep 17 00:00:00 2001 From: Theo Arends <11044339+arendst@users.noreply.github.com> Date: Thu, 28 Dec 2023 17:53:21 +0100 Subject: [PATCH] Cleanup --- tasmota/tasmota_xdrv_driver/xdrv_08_serial_bridge.ino | 4 ++-- tasmota/tasmota_xdrv_driver/xdrv_14_mp3.ino | 4 +--- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/tasmota/tasmota_xdrv_driver/xdrv_08_serial_bridge.ino b/tasmota/tasmota_xdrv_driver/xdrv_08_serial_bridge.ino index c3d432808..fdce70e4a 100644 --- a/tasmota/tasmota_xdrv_driver/xdrv_08_serial_bridge.ino +++ b/tasmota/tasmota_xdrv_driver/xdrv_08_serial_bridge.ino @@ -198,11 +198,11 @@ void SerialBridgeInit(void) { } else { serial_bridge_buffer = (char*)(malloc(SERIAL_BRIDGE_BUFSIZE)); } - SerialBridgeSerial->flush(); - SerialBridgePrintf("\r\n"); #ifdef ESP32 AddLog(LOG_LEVEL_DEBUG, PSTR("SBR: Serial UART%d"), SerialBridgeSerial->getUart()); #endif + SerialBridgeSerial->flush(); + SerialBridgePrintf("\r\n"); } } } diff --git a/tasmota/tasmota_xdrv_driver/xdrv_14_mp3.ino b/tasmota/tasmota_xdrv_driver/xdrv_14_mp3.ino index e4855ee2e..58daa63ed 100644 --- a/tasmota/tasmota_xdrv_driver/xdrv_14_mp3.ino +++ b/tasmota/tasmota_xdrv_driver/xdrv_14_mp3.ino @@ -183,10 +183,8 @@ void MP3PlayerInit(void) // start serial communication fixed to 9600 baud if (MP3Player->begin(9600)) { + if (MP3Player->hardwareSerial()) { ClaimSerial(); } #ifdef ESP32 - if (MP3Player->hardwareSerial()) { - ClaimSerial(); // Disable console using uart0 - } AddLog(LOG_LEVEL_DEBUG, PSTR("MP3: Serial UART%d"), MP3Player->getUart()); #endif // ESP32 MP3Player->flush();