From 3f9ad44a14304a9aeb30948a9770a20cd9d48de7 Mon Sep 17 00:00:00 2001 From: mycprotein <51121231+mycprotein@users.noreply.github.com> Date: Wed, 11 Dec 2024 23:21:19 +0800 Subject: [PATCH] Update ZgatewaySERIAL.ino Fix tx issues The serial gateway can only receive serial data and publish via mqtt, but can not convert mqtt into serial data. It is because the receiverReady is not handled correctly for the tx part. A quick work around is to set receiverReady to true. (it seems not used) --- main/ZgatewaySERIAL.ino | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/main/ZgatewaySERIAL.ino b/main/ZgatewaySERIAL.ino index 422e21dfd0..fec15511eb 100644 --- a/main/ZgatewaySERIAL.ino +++ b/main/ZgatewaySERIAL.ino @@ -53,7 +53,7 @@ const TickType_t semaphoreTimeout = pdMS_TO_TICKS(1000); // 1 second timeout Stream* SERIALStream = NULL; //unsigned long msgCount = 0; -bool receiverReady = false; +bool receiverReady = true; unsigned long lastHeartbeatReceived = 0; unsigned long lastHeartbeatAckReceived = 0; unsigned long lastHeartbeatSent = 0; @@ -372,4 +372,4 @@ void handleHeartbeat() { sendHeartbeatAck(); } } -#endif \ No newline at end of file +#endif