Skip to content

Commit

Permalink
Correct line wrap
Browse files Browse the repository at this point in the history
  • Loading branch information
Isysxp committed Dec 1, 2024
1 parent 2c3563e commit 4249e99
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 13 deletions.
19 changes: 8 additions & 11 deletions ESP_Terminal.ino
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
void ParseTelnet(WiFiClient TCPclient);
#define GFX_DEV_DEVICE WAVESHARE_ESP32_S3_TFT_4_3
#define GFX_BL 2
const char* ssid = "MySSID"; // CHANGE TO YOUR WIFI SSID
const char* password = "MyPassword"; // CHANGE TO YOUR WIFI PASSWORD
const char* ssid = "BT-Q6CTR8"; // CHANGE TO YOUR WIFI SSID
const char* password = "c531a3d358"; // CHANGE TO YOUR WIFI PASSWORD
const int serverPort = 23;
IPAddress raspberryIp (192, 168, 1, 110); // Change to the address of a Raspberry Pi

Expand Down Expand Up @@ -113,10 +113,6 @@ void Display_Char(char ch) {
case ('\r'):
gfx->setCursor(0, (lnum)*20);
break;
case (' '):
cx = gfx->getCursorX();
gfx->setCursor(cx + 10, (lnum)*20);
break;
case (7): // ^g (BEL)
break;
case ('\b'):
Expand All @@ -132,12 +128,13 @@ void Display_Char(char ch) {
break;
default:
cx = gfx->getCursorX();
gfx->print(ch);
gfx->setCursor(cx + 10, (lnum)*20);
if (cx >= 790) {
gfx->setCursor(cx=0, (lnum)*20);
Display_Char('\n');
if (cx >= 800) {
gfx->setCursor(cx=0, (lnum) * 20);
Display_Char('\n');
}
if (ch != ' ')
gfx->print(ch);
gfx->setCursor(cx + 10, (lnum)*20);
break;
}
}
Expand Down
2 changes: 1 addition & 1 deletion __vm/Compile.vmps.xml

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion __vm/Upload.vmps.xml

Large diffs are not rendered by default.

0 comments on commit 4249e99

Please sign in to comment.