123456789101112131415161718192021222324252627282930313233343536373839 |
- #pragma once
- #ifndef UNITTEST
- #include "Marlin.h"
- static constexpr char mmu2Magic[] PROGMEM = "MMU2:";
- namespace MMU2 {
- void LogErrorEvent_P(const char *msg);
- void LogEchoEvent_P(const char *msg);
- }
- #define SERIAL_MMU2() { serialprintPGM(mmu2Magic); }
- #define MMU2_ECHO_MSG(S) do{ SERIAL_ECHO_START; SERIAL_MMU2(); SERIAL_ECHO(S); }while(0)
- #define MMU2_ERROR_MSG(S) do{ SERIAL_ERROR_START; SERIAL_MMU2(); SERIAL_ECHO(S); }while(0)
- #define MMU2_ECHO_MSGRPGM(S) do{ SERIAL_ECHO_START; SERIAL_MMU2(); SERIAL_ECHORPGM(S); }while(0)
- #define MMU2_ERROR_MSGRPGM(S) do{ SERIAL_ERROR_START; SERIAL_MMU2(); SERIAL_ECHORPGM(S); }while(0)
- #else
- #define MMU2_ECHO_MSG(S)
- #define MMU2_ERROR_MSG(S)
- #define SERIAL_ECHO(S)
- #define SERIAL_ECHOLN(S)
- #define MMU2_ECHO_MSGRPGM(S)
- #define MMU2_ERROR_MSGRPGM(S)
- #endif
|