From 65c6543bf17f7800614974f61d487ef00f84819d Mon Sep 17 00:00:00 2001 From: xdrm-brackets Date: Wed, 31 Jan 2018 07:28:41 +0100 Subject: [PATCH] updated sub-view's to use 'com/read' --- sub-view/gpio | 4 ++-- sub-view/systemd | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/sub-view/gpio b/sub-view/gpio index 8c67884..2c497e5 100755 --- a/sub-view/gpio +++ b/sub-view/gpio @@ -21,7 +21,7 @@ LED="0"; Rx=(0 0 0); # led; relays while sleep 1; clear; do # (3) Get last value from lines beginning by 'GSTA' # - STATE="`cat $BUF_IN | grep -Po "^GPIO(.+)$" | sed 's/^GPIO\(....\)$/\1/g' | tail -n1`"; + STATE="`$ROOT/com/read gpio | grep -Po "^GPIO(.+)$" | sed 's/^GPIO\(....\)$/\1/g' | tail -n1`"; echo "state: $STATE"; @@ -43,4 +43,4 @@ while sleep 1; clear; do echo -n "R2: "; $ROOT/src/disp-relay ${Rx[2]}; echo -n "R3: "; $ROOT/src/disp-relay ${Rx[3]}; -done; \ No newline at end of file +done; diff --git a/sub-view/systemd b/sub-view/systemd index 5e8c997..e0b53db 100755 --- a/sub-view/systemd +++ b/sub-view/systemd @@ -21,7 +21,7 @@ declare -A SERV; while sleep 1; clear; do # (4) Get last value from lines beginning by 'GSTA' # - SERV_LIST="`cat $BUF_IN | grep -Po "^SYSD(.+)$" | sed 's/^SYSD\(.\+\)$/\1/g' | tail -n20`"; + SERV_LIST="`$ROOT/com/read systemd | grep -Po "^SYSD(.+)$" | sed 's/^SYSD\(.\+\)$/\1/g' | tail -n20`"; # (5) Store each service # while IFS= read -r line; do