From 3773f2a7b2e905279c607e3d5dbe197c57b8755f Mon Sep 17 00:00:00 2001 From: Anthony Wang Date: Thu, 16 Dec 2021 11:24:40 -0600 Subject: Create debugging script https://gist.github.com/ocerman/6566b00072c8af96a109f65075f2d8b7 --- zp_read_debug.sh | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100755 zp_read_debug.sh diff --git a/zp_read_debug.sh b/zp_read_debug.sh new file mode 100755 index 0000000..7fece5b --- /dev/null +++ b/zp_read_debug.sh @@ -0,0 +1,20 @@ +#!/bin/bash + +hwmon="/sys/class/hwmon" +mdevs=`ls $hwmon` +zenmon="" +ok=0 + +for dev in $mdevs; do + path="$hwmon/$dev" + devname=`cat $path/name` + if [ "$devname" == "zenpower" ]; then + cat $path/debug_data + ok=1 + fi +done + +if [ $ok -ne 1 ]; then + echo "Zenpower not found" + exit +fi \ No newline at end of file -- cgit v1.2.3-70-g09d2