mirror of
https://git.intern.spaceteamaachen.de/ALPAKA/sta-core.git
synced 2025-12-17 00:58:02 +00:00
Separate print methods from UART interface
This commit is contained in:
@@ -30,22 +30,20 @@
|
||||
|
||||
#ifdef STA_DEBUG_SERIAL_ENABLE
|
||||
|
||||
#include <sta/intf/uart.hpp>
|
||||
#include <sta/printable_uart.hpp>
|
||||
|
||||
|
||||
namespace sta
|
||||
{
|
||||
extern UART * const DebugSerial;
|
||||
extern PrintableUART DebugSerial;
|
||||
} // namespace sta
|
||||
|
||||
|
||||
# define STA_DEBUG_PRINT(...) sta::DebugSerial->print(__VA_ARGS__)
|
||||
# define STA_DEBUG_PRINTLN(...) sta::DebugSerial->println(__VA_ARGS__)
|
||||
# define STA_DEBUG_WRITE(b, s) sta::DebugSerial->write(b, s)
|
||||
# define STA_DEBUG_PRINT(...) sta::DebugSerial.print(__VA_ARGS__)
|
||||
# define STA_DEBUG_PRINTLN(...) sta::DebugSerial.println(__VA_ARGS__)
|
||||
#else // !STA_DEBUG_SERIAL_ENABLE
|
||||
# define STA_DEBUG_PRINT(...) ((void)0)
|
||||
# define STA_DEBUG_PRINTLN(...) ((void)0)
|
||||
# define STA_DEBUG_WRITE(b, s) ((void)0)
|
||||
#endif // !STA_DEBUG_SERIAL_ENABLE
|
||||
|
||||
#endif // STA_DEBUG_SERIAL_HPP
|
||||
|
||||
Reference in New Issue
Block a user