diff --git a/platformio.ini b/platformio.ini index 3242ed20..9e24bbb4 100644 --- a/platformio.ini +++ b/platformio.ini @@ -94,6 +94,7 @@ build_flags = -D PIOENV=${PIOENV} -D HTTP_UPLOAD_BUFLEN=1024 ; lower http upload buffer -D MQTT_MAX_PACKET_SIZE=2048 ; longer PubSubClient messages + -D HASP_CONSOLE_BUFFER=220 ; maximum length of a console/telnet command -D NO_GLOBAL_HTTPUPDATE ; dont instantiate httpUpdate ; -- lvgl build options ----------------------------- -D LV_MEM_SIZE=61440U ; 60kB lvgl memory @@ -137,6 +138,7 @@ hspi = build_flags= -D HTTP_UPLOAD_BUFLEN=640 ; lower http upload buffer -D MQTT_MAX_PACKET_SIZE=1024 ; longer PubSubClient messages + -D HASP_CONSOLE_BUFFER=220 ; maximum length of a console/telnet command -D ATOMIC_FS_UPDATE ; enabled compressed ota updates -D NO_GLOBAL_HTTPUPDATE ; dont instantiate httpUpdate ; -- lwIP Variant ----------------------------------- @@ -164,6 +166,7 @@ lib_deps = build_flags= -I include/stm32f4 -D MQTT_MAX_PACKET_SIZE=2048 ; longer PubSubClient messages + -D HASP_CONSOLE_BUFFER=220 ; maximum length of a console/telnet command -D IRAM_ATTR= ; No IRAM_ATTR available on STM32 -D ICACHE_RAM_ATTR= -D STM32 diff --git a/src/hasp_debug.cpp b/src/hasp_debug.cpp index 14e45f10..ae61f1a4 100644 --- a/src/hasp_debug.cpp +++ b/src/hasp_debug.cpp @@ -89,7 +89,7 @@ uint16_t debugSerialBaud = SERIAL_SPEED / 10; // Multiplied by 10 bool debugSerialStarted = false; bool debugAnsiCodes = true; -ConsoleInput debugConsole(&Serial, 220); +ConsoleInput debugConsole(&Serial, HASP_CONSOLE_BUFFER); //#define TERM_COLOR_Black "\u001b[30m" #define TERM_COLOR_GRAY "\e[37m" diff --git a/src/svc/hasp_telnet.cpp b/src/svc/hasp_telnet.cpp index 6d821950..c64fa336 100644 --- a/src/svc/hasp_telnet.cpp +++ b/src/svc/hasp_telnet.cpp @@ -244,7 +244,7 @@ void telnetSetup() telnetServer->setNoDelay(true); telnetServer->begin(); - telnetConsole = new ConsoleInput(&telnetClient, 220); + telnetConsole = new ConsoleInput(&telnetClient, HASP_CONSOLE_BUFFER); if(telnetConsole != NULL) { telnetConsole->setLineCallback(telnetProcessLine); Log.trace(TAG_TELN, F("Remote console started"));