tcp port send stdio
This commit is contained in:
@@ -22,8 +22,13 @@
|
||||
// Holds last echoed line for display
|
||||
static char g_last_echo[128] = "";
|
||||
|
||||
// Global DisplayManager pointer
|
||||
static DisplayManager* g_display_manager = nullptr;
|
||||
#include "command_processor.h"
|
||||
#include "epaper_manager.h"
|
||||
#include "wifi_manager.h"
|
||||
#include "tcp_debug.h"
|
||||
|
||||
// Global display manager instance
|
||||
DisplayManager* g_display_manager = nullptr;
|
||||
|
||||
// Keyboard buffer
|
||||
#define MAX_INPUT_LEN 64
|
||||
@@ -75,6 +80,7 @@ static bool execute_command(CommandAction action, const char* input) {
|
||||
epaper_send_update(err_msg, true);
|
||||
} else {
|
||||
epaper_send_update("Connected!", true);
|
||||
tcp_debug_init();
|
||||
}
|
||||
} else {
|
||||
if (g_display_manager) g_display_manager->refresh("Connection Failed", nullptr);
|
||||
@@ -148,7 +154,7 @@ static void process_kbd_report(hid_keyboard_report_t const *report) {
|
||||
g_buffer_index = 0;
|
||||
g_input_buffer[0] = '\0';
|
||||
} else if (event.is_printable) {
|
||||
printf("%c", event.ascii);
|
||||
// printf("%c", event.ascii);
|
||||
if (g_buffer_index < MAX_INPUT_LEN - 1) {
|
||||
g_input_buffer[g_buffer_index++] = event.ascii;
|
||||
g_input_buffer[g_buffer_index] = '\0';
|
||||
|
||||
Reference in New Issue
Block a user