From 1543af8777067061dfc23cfb17ca71178d604a11 Mon Sep 17 00:00:00 2001 From: ollo Date: Thu, 18 Apr 2019 16:41:04 +0200 Subject: [PATCH] Activated remote flashing --- tools/remoteFlash.sh | 5 ++--- tools/tcpFlash.py | 4 ++++ 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/tools/remoteFlash.sh b/tools/remoteFlash.sh index 5cd5834..8b93b92 100755 --- a/tools/remoteFlash.sh +++ b/tools/remoteFlash.sh @@ -25,7 +25,6 @@ if [ $? -ne 0 ]; then exit 2 fi echo "Upgrading $IP" -exit 3 FILES="displayword.lua main.lua timecore.lua webpage.html webserver.lua wordclock.lua init.lua" @@ -44,7 +43,7 @@ for f in $FILES; do fi done -echo "Reboot the ESP" -echo "node.restart()" | nc $IP 80 +echo "TODO: Reboot the ESP" +#echo "node.restart()" | nc $IP 80 exit 0 diff --git a/tools/tcpFlash.py b/tools/tcpFlash.py index a0c92c7..5a82873 100755 --- a/tools/tcpFlash.py +++ b/tools/tcpFlash.py @@ -87,6 +87,10 @@ def main(nodeip, luafile, volatile=None): print "\rSending " + str(i) + "/" + str(len(contents)) + " ...", sys.stdout.flush() l = line.rstrip() + if ( l.endswith("]") ): + l = l + " " + print "add a space at the end" + if (volatile is None): if (not sendCmd(s, "w([[" + l + "]]);")): print "Cannot write line " + str(i)