From 47881d11a6369e3a8f9de1c523e63115942b43de Mon Sep 17 00:00:00 2001 From: m1nl Date: Fri, 6 Jun 2025 21:20:20 +0200 Subject: [PATCH] prevent zero-byte read from serial causing too frequent wakeups --- src/mesh/StreamAPI.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/mesh/StreamAPI.cpp b/src/mesh/StreamAPI.cpp index 6f309cc50..ba949818a 100644 --- a/src/mesh/StreamAPI.cpp +++ b/src/mesh/StreamAPI.cpp @@ -66,12 +66,12 @@ int32_t StreamAPI::readStream() // If we didn't just fail the packet and we now have the right # of bytes, parse it handleToRadio(rxBuf + HEADER_LEN, len); + // we had bytes available this time, so assume we might have them next time also + lastRxMsec = millis(); } } } - // we had bytes available this time, so assume we might have them next time also - lastRxMsec = millis(); return 0; } }