From da4470233c096a77a7c69fbae901a04e1daca795 Mon Sep 17 00:00:00 2001 From: Fabian Date: Wed, 21 Apr 2021 16:03:47 -0500 Subject: [PATCH] fix paste into serial console --- src/browser/serial.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/browser/serial.js b/src/browser/serial.js index 5e41679d..2590674e 100644 --- a/src/browser/serial.js +++ b/src/browser/serial.js @@ -228,7 +228,10 @@ function SerialAdapterXtermJS(element, bus) term.write("This is the serial console. Whatever you type or paste here will be sent to COM1"); term["onData"](function(data) { - bus.send("serial0-input", data.charCodeAt(0)); + for(let i = 0; i < data.length; i++) + { + bus.send("serial0-input", data.charCodeAt(i)); + } }); bus.register("serial0-output-char", function(chr)