统一os_log

This commit is contained in:
zogodo
2020-02-17 21:10:13 +08:00
parent 1a7d4d5a47
commit 051a9504ee
12 changed files with 67 additions and 79 deletions

View File

@@ -4,6 +4,15 @@
#include "mico.h"
#include "micokit_ext.h"
#define app_log(M, ...) do { custom_log("APP", M, ##__VA_ARGS__); web_log(M, ##__VA_ARGS__) } while(0)
#define key_log(M, ...) do { custom_log("KEY", M, ##__VA_ARGS__); web_log(M, ##__VA_ARGS__) } while(0)
#define ota_log(M, ...) do { custom_log("OTA", M, ##__VA_ARGS__); web_log(M, ##__VA_ARGS__) } while(0)
#define rtc_log(M, ...) do { custom_log("RTC", M, ##__VA_ARGS__); web_log(M, ##__VA_ARGS__) } while(0)
#define tc1_log(M, ...) do { custom_log("TC1", M, ##__VA_ARGS__); web_log(M, ##__VA_ARGS__) } while(0)
#define http_log(M, ...) do { custom_log("HTTP", M, ##__VA_ARGS__); web_log(M, ##__VA_ARGS__) } while(0)
#define mqtt_log(M, ...) do { custom_log("MQTT", M, ##__VA_ARGS__); web_log(M, ##__VA_ARGS__) } while(0)
#define wifi_log(M, ...) do { custom_log("WIFI", M, ##__VA_ARGS__); web_log(M, ##__VA_ARGS__) } while(0)
#define VERSION "v1.0.15"
#define TYPE 1