From 29cee10ff54708a347574080055de46d3f23ac01 Mon Sep 17 00:00:00 2001 From: john30 Date: Tue, 29 Aug 2017 23:19:48 +0200 Subject: [PATCH] added helper script --- contrib/scripts/readallvaillantregisters.sh | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100755 contrib/scripts/readallvaillantregisters.sh diff --git a/contrib/scripts/readallvaillantregisters.sh b/contrib/scripts/readallvaillantregisters.sh new file mode 100755 index 00000000..cdd6dc47 --- /dev/null +++ b/contrib/scripts/readallvaillantregisters.sh @@ -0,0 +1,18 @@ +#!/bin/bash +port=8888 +if [ "x$1" = "x-p" ]; then + shift + port=$1 + shift +fi +addr=08 +if [ "x$1" = "x-a" ]; then + shift + addr=$1 + shift +fi +for (( i=0; i<512; i++ )) ; do + h=`printf "%4.4X" $i` + ret=`echo "hex ${addr}b509030d${h##??}${h%%??}"|nc localhost $port|head -n 1` + echo $i "=" $ret +done