Firmware SDK
|
Logging facility (output on TXD2, format 115200 / 8N1) More...
Macros | |
#define | TWR_LOG_UART TWR_UART_UART2 |
#define | TWR_LOG_BUFFER_SIZE 256 |
#define | TWR_LOG_DUMP_WIDTH 8 |
Enumerations | |
enum | twr_log_level_t { TWR_LOG_LEVEL_DUMP = 0 , TWR_LOG_LEVEL_DEBUG = 1 , TWR_LOG_LEVEL_INFO = 2 , TWR_LOG_LEVEL_WARNING = 3 , TWR_LOG_LEVEL_ERROR = 4 , TWR_LOG_LEVEL_OFF = 5 } |
Log level. More... | |
enum | twr_log_timestamp_t { TWR_LOG_TIMESTAMP_OFF = -1 , TWR_LOG_TIMESTAMP_ABS = 0 , TWR_LOG_TIMESTAMP_REL = 1 } |
Log timestamp. More... | |
Functions | |
void | twr_log_init (twr_log_level_t level, twr_log_timestamp_t timestamp) |
Initialize logging facility. More... | |
void | twr_log_dump (const void *buffer, size_t length, const char *format,...) __attribute__((format(printf |
Log DUMP message (annotated in log as <X>) More... | |
void void | twr_log_debug (const char *format,...) __attribute__((format(printf |
Log DEBUG message (annotated in log as <D>) More... | |
void void void | twr_log_info (const char *format,...) __attribute__((format(printf |
Log INFO message (annotated in log as ) More... | |
void void void void | twr_log_warning (const char *format,...) __attribute__((format(printf |
Log WARNING message (annotated in log as <W>) More... | |
void void void void void | twr_log_error (const char *format,...) __attribute__((format(printf |
Log ERROR message (annotated in log as <E>) More... | |
Logging facility (output on TXD2, format 115200 / 8N1)
enum twr_log_level_t |
enum twr_log_timestamp_t |
void void twr_log_debug | ( | const char * | format, |
... | |||
) |
Log DEBUG message (annotated in log as <D>)
[in] | format | Format string (printf style) |
[in] | ... | Optional format arguments |
void twr_log_dump | ( | const void * | buffer, |
size_t | length, | ||
const char * | format, | ||
... | |||
) |
Log DUMP message (annotated in log as <X>)
[in] | buffer | Pointer to source buffer |
[in] | length | Number of bytes to be printed |
[in] | format | Format string (printf style) |
[in] | ... | Optional format arguments |
void void void void void twr_log_error | ( | const char * | format, |
... | |||
) |
Log ERROR message (annotated in log as <E>)
[in] | format | Format string (printf style) |
[in] | ... | Optional format arguments |
Referenced by twr_ds2484_enable(), and twr_module_x1_init().
void void void twr_log_info | ( | const char * | format, |
... | |||
) |
Log INFO message (annotated in log as )
[in] | format | Format string (printf style) |
[in] | ... | Optional format arguments |
void twr_log_init | ( | twr_log_level_t | level, |
twr_log_timestamp_t | timestamp | ||
) |
void void void void twr_log_warning | ( | const char * | format, |
... | |||
) |
Log WARNING message (annotated in log as <W>)
[in] | format | Format string (printf style) |
[in] | ... | Optional format arguments |