You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[TRACE] basic.ino L.30 setup : this is trace: log level 5
98
98
```
99
99
100
+
### Log Destination Control
101
+
102
+
You can output the log to another `Serial` easily:
103
+
104
+
```cpp
105
+
LOG_ATTACH_SERIAL(Serial2);
106
+
```
107
+
108
+
Also this library supports the log output to any `Stream` based instances. For example, you can change the log output destination to `Ethernet/WiFiClient`, `Ethernet/WiFiUDP` instead of default `Serial` as follows:
109
+
110
+
```cpp
111
+
LOG_ATTACH_STREAM(your_udp_client);
112
+
// or
113
+
LOG_ATTACH_STREAM(your_tcp_client);
114
+
// or
115
+
LOG_ATTACH_STREAM(any_other_stream);
116
+
```
117
+
100
118
### Log Preamble Control
101
119
102
120
The `LOG_PREAMBLE` macro is called every `LOG_XXXX`. It defines a string that will be printed between the `[LEVEL]` and your custom message. To override the default definition, you must define the macro **before** you `#include <DebugLog.h>`
@@ -509,6 +527,7 @@ If you use `LOG_ATTACH_FS_MANUAL`, these macros are used to flush files manually
0 commit comments