updated the logger for static use without a static interface
added the RGB sensor isl29125 added WIFI
This commit is contained in:
@@ -53,7 +53,7 @@
|
||||
|
||||
#if defined(ENABLE_SERIAL_LOGGING)
|
||||
#define LOGGER_LOG(severity,...) \
|
||||
debugLogger.log(__FILE__, __func__, __LINE__, severity, ##__VA_ARGS__)
|
||||
logger::log(__FILE__, __func__, __LINE__, severity, ##__VA_ARGS__)
|
||||
#else
|
||||
#define LOGGER_LOG(severity, message)
|
||||
#endif
|
||||
@@ -98,9 +98,8 @@
|
||||
// Type definitions.
|
||||
// --------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
|
||||
class logger;
|
||||
extern logger debugLogger;
|
||||
//class logger;
|
||||
//extern logger debugLogger;
|
||||
|
||||
// --------------------------------------------------------------------------------------------------------------------
|
||||
// Function declarations
|
||||
@@ -126,7 +125,7 @@ class logger
|
||||
// Class Constructor
|
||||
logger(uint32_t queuesize, ISerialBus<uint8_t>& serialPort);
|
||||
|
||||
FunctionStatus log(const char* fileName, const char* functionName, int lineNumber, LogType logType, const char* format, ...);
|
||||
static FunctionStatus log(const char* fileName, const char* functionName, int lineNumber, LogType logType, const char* format, ...);
|
||||
|
||||
// The Logger task - should be called by the system scheduler regularly
|
||||
void task();
|
||||
@@ -160,18 +159,20 @@ class logger
|
||||
|
||||
void composeTypeParameterList(void);
|
||||
|
||||
void composeLogQueueItem(struct LogQueueItem* logQueueItem, std::string fileName, std::string functionName,
|
||||
int lineNumber, LogType logType, std::string context);
|
||||
static void composeLogQueueItem(struct LogQueueItem* logQueueItem, const std::string& fileName, const std::string& functionName,
|
||||
int lineNumber, LogType logType, const std::string& context);
|
||||
|
||||
std::list<struct typeParameters> typeParameterList;
|
||||
|
||||
std::list<struct LogQueueItem> queue;
|
||||
static std::list<struct LogQueueItem> queue;
|
||||
ISerialBus<uint8_t>& port;
|
||||
uint32_t queuesize;
|
||||
uint32_t numberOfLostMessages;
|
||||
static uint32_t queuesize;
|
||||
static uint32_t numberOfLostMessages;
|
||||
static bool overflowRecovery;
|
||||
|
||||
};
|
||||
|
||||
|
||||
/** @} */
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user