diff --git a/src/SparkFun_Alphanumeric_Display.cpp b/src/SparkFun_Alphanumeric_Display.cpp index a4df114..58fae7d 100644 --- a/src/SparkFun_Alphanumeric_Display.cpp +++ b/src/SparkFun_Alphanumeric_Display.cpp @@ -331,6 +331,12 @@ bool HT16K33::clear() // Clear the displayRAM array for (uint8_t i = 0; i < 16 * numberOfDisplays; i++) displayRAM[i] = 0; + + // Clear the displayContent array + for (uint8_t i = 0; i < 16; i++) + { + displayContent[i] = ""; + } digitPosition = 0; @@ -681,6 +687,9 @@ void HT16K33::printChar(uint8_t displayChar, uint8_t digit) uint16_t segmentsToTurnOn = getSegmentsToTurnOn(characterPosition); illuminateChar(segmentsToTurnOn, digit); + + // Add char to local RAM to enable shiftRight() and shiftLeft() + displayContent[digit] = displayChar; } // Update the list to define a new segments display for a particular character