From cf4c814b59f5e42b1bc65aeb19e876e69ee8c522 Mon Sep 17 00:00:00 2001 From: Jm Date: Sat, 16 Jul 2022 08:08:10 -0700 Subject: [PATCH] Allow range test module to loop back messages --- src/modules/esp32/RangeTestModule.h | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/modules/esp32/RangeTestModule.h b/src/modules/esp32/RangeTestModule.h index 76735d37..db49a586 100644 --- a/src/modules/esp32/RangeTestModule.h +++ b/src/modules/esp32/RangeTestModule.h @@ -28,7 +28,10 @@ class RangeTestModuleRadio : public SinglePortModule uint32_t lastRxID = 0; public: - RangeTestModuleRadio() : SinglePortModule("RangeTestModuleRadio", PortNum_TEXT_MESSAGE_APP) {} + RangeTestModuleRadio() : SinglePortModule("RangeTestModuleRadio", PortNum_TEXT_MESSAGE_APP) + { + loopbackOk = true; // Allow locally generated messages to loop back to the client + } /** * Send our payload into the mesh @@ -50,7 +53,8 @@ class RangeTestModuleRadio : public SinglePortModule /** Called to handle a particular incoming message - @return ProcessMessage::STOP if you've guaranteed you've handled this message and no other handlers should be considered for it + @return ProcessMessage::STOP if you've guaranteed you've handled this message and no other handlers should be considered for + it */ virtual ProcessMessage handleReceived(const MeshPacket &mp) override; };