Skip to content

Commit faea8b5

Browse files
committed
Add logic to print pipe if second control chracter is read
This allows the user to print a pipe control character to the display by escaping the control character as a double pipe
1 parent 1ba8535 commit faea8b5

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

firmware/OpenLCD/OpenLCD.ino

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -267,7 +267,14 @@ void updateDisplay()
267267
{
268268
SerLCD.write(byte(incoming - 35)); //You write location zero to display customer char 0
269269
}
270+
//If we get a second special setting character, then write it to the display
271+
//This allows us to print a pipe by escaping it as a double
272+
else if (incoming == SPECIAL_SETTING) {
273+
SerLCD.write(incoming);
270274

275+
currentFrame[characterCount++] = incoming; //Record this character to the display buffer
276+
if (characterCount == settingLCDwidth * settingLCDlines) characterCount = 0; //Wrap condition
277+
}
271278
modeSetting = false;
272279
}
273280
else if (modeTWI == true)

0 commit comments

Comments
 (0)