WLED/wled00/net_debug.h
cschwinne 1d8c9ac020 Net debug optimizations
Fix ESP8266 (unaligned progmem flash string reads)
Do not send an extra package for \n in println
Only resolve IP/hostname once
2022-11-06 16:50:12 +01:00

25 lines
622 B
C++

#ifndef WLED_NET_DEBUG_H
#define WLED_NET_DEBUG_H
#include <WString.h>
#include <WiFiUdp.h>
class NetworkDebugPrinter {
private:
IPAddress debugPrintHostIP;
public:
void print(const char *s, bool newline = false);
void print(const __FlashStringHelper* s, bool newline = false);
void print(String s);
void print(unsigned int n, bool newline = false);
void println();
void println(const char *s);
void println(const __FlashStringHelper* s);
void println(String s);
void println(unsigned int n);
void printf(const char *fmt, ...);
};
extern NetworkDebugPrinter NetDebug;
#endif