DJI Onboard SDK  4.0
osdk_logger.h
Go to the documentation of this file.
1 
29 /* Define to prevent recursive inclusion -------------------------------------*/
30 #ifndef OSDK_LOGGER_H
31 #define OSDK_LOGGER_H
32 
33 /* Includes ------------------------------------------------------------------*/
34 #include "osdk_typedef.h"
35 
36 #ifdef __cplusplus
37 extern "C" {
38 #endif
39 
40 /* Exported types ------------------------------------------------------------*/
41 typedef E_OsdkStat (*OsdkLogger_ConsoleFunc)(const uint8_t *data,
42  uint16_t dataLen);
43 
44 typedef enum {
45  OSDK_LOGGER_CONSOLE_LOG_LEVEL_ERROR = 1,
46  OSDK_LOGGER_CONSOLE_LOG_LEVEL_WARNING = 2,
47  OSDK_LOGGER_CONSOLE_LOG_LEVEL_INFO = 3,
48  OSDK_LOGGER_CONSOLE_LOG_LEVEL_DEBUG = 4,
49 } E_OsdkLoggerConsoleLogLevel;
50 
51 typedef struct {
52  uint8_t consoleLevel;
53  OsdkLogger_ConsoleFunc func;
54 } T_OsdkLoggerConsole;
55 
56 /* Exported functions --------------------------------------------------------*/
57 E_OsdkStat OsdkLogger_AddConsole(T_OsdkLoggerConsole *console);
58 
59 #ifdef __cplusplus
60 }
61 #endif
62 
63 #endif // OSDK_LOGGER_H
64 /************************ (C) COPYRIGHT DJI Innovations *******END OF FILE******/