From c3e1a8a83bc4ec6e346ac651d5d816458da457c8 Mon Sep 17 00:00:00 2001 From: Thorsten von Eicken Date: Sun, 15 Nov 2015 22:08:43 -0800 Subject: [PATCH] improve home page --- html/console.js | 9 +++++++++ html/home.html | 13 +++++++------ 2 files changed, 16 insertions(+), 6 deletions(-) diff --git a/html/console.js b/html/console.js index f29469ca..e85d6d7d 100644 --- a/html/console.js +++ b/html/console.js @@ -22,12 +22,21 @@ function updateText(resp) { var delay = 3000; if (resp != null && resp.len > 0) { console.log("updateText got", resp.len, "chars at", resp.start); + var isScrolledToBottom = el.scrollHeight - el.clientHeight <= el.scrollTop + 1; + //console.log("isScrolledToBottom="+isScrolledToBottom, "scrollHeight="+el.scrollHeight, + // "clientHeight="+el.clientHeight, "scrollTop="+el.scrollTop, + // "" + (el.scrollHeight - el.clientHeight) + "<=" + (el.scrollTop + 1)); + + // append the text if (resp.start > el.textEnd) { el.innerHTML = el.innerHTML.concat("\r\nSystem overview
- @@ -36,11 +36,12 @@

Info

program microcontrollers over the serial port, in particular Arduinos, AVRs, and NXP's LPC800 and other ARM processors. Typical avrdude command line to program an Arduino:

-
/home/arduino/hardware/tools/avrdude \
+
+ /home/arduino/hardware/tools/avrdude \
  -DV -patmega328p \
  -Pnet:esp-link.local:23 \
-   -carduino -b115200 -U \
-   -C /home/arduino/hardware/tools/avrdude.conf \
+   -carduino -b115200 -U -C \
+   /home/arduino/hardware/tools/avrdude.conf \
  flash:w:my_sketch.hex:i

where -Pnet:esp-link.local:23 tells avrdude to connect to port 23 of esp-link. @@ -125,8 +126,8 @@

System details

Description:
- -