Creality Ender 3 v2 (#17719)
This commit is contained in:
@ -51,10 +51,16 @@ extern uint8_t marlin_debug_flags;
|
||||
extern int8_t serial_port_index;
|
||||
#define _PORT_REDIRECT(n,p) REMEMBER(n,serial_port_index,p)
|
||||
#define _PORT_RESTORE(n) RESTORE(n)
|
||||
#define SERIAL_OUT(WHAT, V...) do{ \
|
||||
if (!serial_port_index || serial_port_index == SERIAL_BOTH) (void)MYSERIAL0.WHAT(V); \
|
||||
if ( serial_port_index) (void)MYSERIAL1.WHAT(V); \
|
||||
}while(0)
|
||||
|
||||
#ifdef SERIAL_CATCHALL
|
||||
#define SERIAL_OUT(WHAT, V...) (void)CAT(MYSERIAL,SERIAL_CATCHALL).WHAT(V)
|
||||
#else
|
||||
#define SERIAL_OUT(WHAT, V...) do{ \
|
||||
if (!serial_port_index || serial_port_index == SERIAL_BOTH) (void)MYSERIAL0.WHAT(V); \
|
||||
if ( serial_port_index) (void)MYSERIAL1.WHAT(V); \
|
||||
}while(0)
|
||||
#endif
|
||||
|
||||
#define SERIAL_ASSERT(P) if(serial_port_index!=(P)){ debugger(); }
|
||||
#else
|
||||
#define _PORT_REDIRECT(n,p) NOOP
|
||||
|
Reference in New Issue
Block a user