-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathLogging_Task_M.hpp
More file actions
62 lines (51 loc) · 1.65 KB
/
Logging_Task_M.hpp
File metadata and controls
62 lines (51 loc) · 1.65 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
/**
********************************************************************************
* @file Logging_Task_M.hpp
* @author jaddina
* @date Sep 6, 2025
* @brief
********************************************************************************
*/
#ifndef CORE_INC_LOGGING_TASK_M_HPP_
#define CORE_INC_LOGGING_TASK_M_HPP_
/************************************
* INCLUDES
************************************/
//#include "SensorDataTypes.hpp"
#include "Task.hpp"
#include "SystemDefines.hpp"
/************************************
* MACROS AND DEFINES
************************************/
constexpr uint16_t LOGGING_RX_BUFFER_SZ_BYTES = 16;
/************************************
* TYPEDEFS
************************************/
/************************************
* CLASS DEFINITIONS
************************************/
/************************************
* FUNCTION DECLARATIONS
************************************/
class LoggingTask : public Task
{
public:
static LoggingTask& Inst() {
static LoggingTask inst;
return inst;
}
void InitTask();
protected:
bool RecieveData();
static void RunTask(void* pvParams) { LoggingTask::Inst().Run(pvParams); } // Static Task Interface, passes control to the instance Run();
void Run(void * pvParams); // Main run code
void HandleCommand(Command& cm);
void WriteData();//put argue
bool HandleDataBrokerCommand(Command& cm);
private:
// Private Functions
LoggingTask(); // Private constructor
LoggingTask(const LoggingTask&); // Prevent copy-construction
LoggingTask& operator=(const LoggingTask&); // Prevent assignment
};
#endif /* CORE_INC_LOGGING_TASK_M_HPP_ */