diff --git a/examples/Features/EEPROM/EEPROM-Settings/EEPROM-Settings.ino b/examples/Features/EEPROM/EEPROM-Settings/EEPROM-Settings.ino index 93d3eccd..81e3f3f6 100644 --- a/examples/Features/EEPROM/EEPROM-Settings/EEPROM-Settings.ino +++ b/examples/Features/EEPROM/EEPROM-Settings/EEPROM-Settings.ino @@ -42,16 +42,18 @@ KEYMAPS( KALEIDOSCOPE_INIT_PLUGINS(EEPROMSettings); void setup() { - Kaleidoscope.serialPort().begin(9600); + auto &serial_port = Kaleidoscope.serialPort(); + + serial_port.begin(9600); Kaleidoscope.setup(); - while (!Kaleidoscope.serialPort()) { + while (!serial_port) { } - Kaleidoscope.serialPort().println(EEPROMSettings.isValid() ? F("valid EEPROM settings") : F("invalid EEPROM settings")); - Kaleidoscope.serialPort().println(EEPROMSettings.crc(), HEX); - Kaleidoscope.serialPort().println(EEPROMSettings.version()); + serial_port.println(EEPROMSettings.isValid() ? F("valid EEPROM settings") : F("invalid EEPROM settings")); + serial_port.println(EEPROMSettings.crc(), HEX); + serial_port.println(EEPROMSettings.version()); } void loop() { diff --git a/examples/Features/HostOS/HostOS.ino b/examples/Features/HostOS/HostOS.ino index 575b2c6b..8803f9d7 100644 --- a/examples/Features/HostOS/HostOS.ino +++ b/examples/Features/HostOS/HostOS.ino @@ -43,12 +43,14 @@ KEYMAPS( KALEIDOSCOPE_INIT_PLUGINS(EEPROMSettings, HostOS); void setup() { - Kaleidoscope.serialPort().begin(9600); + auto &serial_port = Kaleidoscope.serialPort(); + + serial_port.begin(9600); Kaleidoscope.setup(); - Kaleidoscope.serialPort().print("Host OS id is: "); - Kaleidoscope.serialPort().println(HostOS.os(), DEC); + serial_port.print("Host OS id is: "); + serial_port.println(HostOS.os(), DEC); } void loop() { diff --git a/examples/Keystrokes/Leader/Leader.ino b/examples/Keystrokes/Leader/Leader.ino index 90d4b72a..fc6f65c2 100644 --- a/examples/Keystrokes/Leader/Leader.ino +++ b/examples/Keystrokes/Leader/Leader.ino @@ -39,12 +39,14 @@ KEYMAPS( ) // *INDENT-ON* +auto &serial_port = Kaleidoscope.serialPort(); + static void leaderTestA(uint8_t seq_index) { - Kaleidoscope.serialPort().println(F("leaderTestA")); + serial_port.println(F("leaderTestA")); } static void leaderTestAA(uint8_t seq_index) { - Kaleidoscope.serialPort().println(F("leaderTestAA")); + serial_port.println(F("leaderTestAA")); } static const kaleidoscope::plugin::Leader::dictionary_t leader_dictionary[] PROGMEM =