From 0c7785ecf87044492a6102e87d7801d6a128138a Mon Sep 17 00:00:00 2001 From: sh123 Date: Sat, 3 Dec 2022 15:56:22 +0200 Subject: [PATCH] Minor refactoring --- kiss_processor.cpp | 2 +- loraprs_service.cpp | 2 +- loraprs_service.h | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/kiss_processor.cpp b/kiss_processor.cpp index 3e32c49..92b1f0c 100644 --- a/kiss_processor.cpp +++ b/kiss_processor.cpp @@ -160,7 +160,7 @@ bool Processor::processSerialToRig() serialToRigQueue_.push(rxByte); } } - yield(); + vTaskDelay(1); } return allProcessed; } diff --git a/loraprs_service.cpp b/loraprs_service.cpp index b41b464..3f01e27 100644 --- a/loraprs_service.cpp +++ b/loraprs_service.cpp @@ -4,7 +4,7 @@ namespace LoraPrs { TaskHandle_t Service::rigTaskHandle_; volatile bool Service::rigIsRxActive_ = false; -bool Service::rigIsRxIsrEnabled_ = true; +volatile bool Service::rigIsRxIsrEnabled_ = true; Service::Service() : Kiss::Processor() diff --git a/loraprs_service.h b/loraprs_service.h index 2ab72bf..e0d65cf 100644 --- a/loraprs_service.h +++ b/loraprs_service.h @@ -151,7 +151,7 @@ private: // peripherals, radio static TaskHandle_t rigTaskHandle_; static volatile bool rigIsRxActive_; - static bool rigIsRxIsrEnabled_; + static volatile bool rigIsRxIsrEnabled_; bool rigIsImplicitMode_; int rigCurrentTxPacketSize_; CircularBuffer rigTxQueue_;