From 4fd8b7d749db20847fe8f12abb9b0c42b05d4960 Mon Sep 17 00:00:00 2001 From: Eggert Jung Date: Fri, 25 Apr 2025 17:53:15 +0200 Subject: [PATCH] rename serial output to sout --- device/serialstream.cc | 18 +++++++++--------- device/serialstream.h | 2 +- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/device/serialstream.cc b/device/serialstream.cc index 80179a0..7313626 100644 --- a/device/serialstream.cc +++ b/device/serialstream.cc @@ -5,17 +5,17 @@ SerialStream::SerialStream(ComPort port, BaudRate baud_rate, DataBits data_bits, StopBits stop_bits, Parity parity) :Serial(port, baud_rate, data_bits, stop_bits, parity) {} -SerialStream kout = SerialStream(); +SerialStream sout = SerialStream(); void SerialStream::flush() { - print(kout.buffer, kout.pos); - kout.pos = 0; + print(sout.buffer, sout.pos); + sout.pos = 0; } void SerialStream::setForeground(Color c) { write(0x1b); write('['); - kout << 30+c; + sout << 30+c; flush(); write('m'); } @@ -44,11 +44,11 @@ void SerialStream::setPos(int x, int y) { //char out[] = {0x1b, '[', 0, 0, ';', 0, 0, 'H', 0}; //*this << 0x1b; write(0x1b); - kout << '['; - kout << dec << x; - kout << ';'; - kout << dec << y; - kout << 'H'; + sout << '['; + sout << dec << x; + sout << ';'; + sout << dec << y; + sout << 'H'; flush(); //itoa(x, &out[2], 10); //itoa(y, &out[5], 10); diff --git a/device/serialstream.h b/device/serialstream.h index 5e1122b..d1708ff 100644 --- a/device/serialstream.h +++ b/device/serialstream.h @@ -142,5 +142,5 @@ class SerialStream : public OutputStream, public Serial { void print(char* str, int length); }; -extern SerialStream kout; +extern SerialStream sout;