From 30c261028e27dab0e30aec19b9c21c37cc74e92b Mon Sep 17 00:00:00 2001 From: Avamander Date: Fri, 2 Oct 2020 21:45:51 +0300 Subject: Renamed Logging/ to logging/ --- src/Logging/NrfLogger.cpp | 32 -------------------------------- 1 file changed, 32 deletions(-) delete mode 100644 src/Logging/NrfLogger.cpp (limited to 'src/Logging/NrfLogger.cpp') diff --git a/src/Logging/NrfLogger.cpp b/src/Logging/NrfLogger.cpp deleted file mode 100644 index 7ccacc82..00000000 --- a/src/Logging/NrfLogger.cpp +++ /dev/null @@ -1,32 +0,0 @@ -#include -#include -#include -#include -#include -#include "NrfLogger.h" - -using namespace Pinetime::Logging; - -void NrfLogger::Init() { - auto result = NRF_LOG_INIT(nullptr); - APP_ERROR_CHECK(result); - - NRF_LOG_DEFAULT_BACKENDS_INIT(); - - if (pdPASS != xTaskCreate(NrfLogger::Process, "LOGGER", 200, this, 0, &m_logger_thread)) - APP_ERROR_HANDLER(NRF_ERROR_NO_MEM); -} - -void NrfLogger::Process(void*) { - NRF_LOG_INFO("Logger task started!"); - while (1) { - NRF_LOG_FLUSH(); - vTaskDelay(100); // Not good for power consumption, it will wake up every 100ms... - } -} - -void NrfLogger::Resume() { - vTaskResume(m_logger_thread); -} - - -- cgit v1.2.3-70-g09d2