From 35993bf722e3b5912692dbd32982ea82d4811743 Mon Sep 17 00:00:00 2001 From: Cameron Thompson <50184035+iamromulan@users.noreply.github.com> Date: Tue, 19 Mar 2024 20:05:56 -0700 Subject: [PATCH 1/4] Fixed ttyd not starting at boot --- RMxxx_rgmii_toolkit.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/RMxxx_rgmii_toolkit.sh b/RMxxx_rgmii_toolkit.sh index 3a50c56..08e8820 100644 --- a/RMxxx_rgmii_toolkit.sh +++ b/RMxxx_rgmii_toolkit.sh @@ -834,7 +834,7 @@ install_ttyd() { wget -O scripts/ttyd.bash "https://raw.githubusercontent.com/$GITUSER/quectel-rgmii-toolkit/$GITTREE/ttyd/scripts/ttyd.bash" && chmod +x scripts/ttyd.bash wget -O systemd/ttyd.service "https://raw.githubusercontent.com/$GITUSER/quectel-rgmii-toolkit/$GITTREE/ttyd/systemd/ttyd.service" cp systemd/ttyd.service /lib/systemd/system/ - ln -sf /lib/systemd/system/ttyd.service /etc/systemd/system/multi-user.target.wants/ + ln -sf /lib/systemd/system/ttyd.service /lib/systemd/system/multi-user.target.wants/ # Enabling and starting ttyd service systemctl daemon-reload From e19dc87405f3db285e726b869e29c0b37104e704 Mon Sep 17 00:00:00 2001 From: Cameron Thompson <50184035+iamromulan@users.noreply.github.com> Date: Thu, 21 Mar 2024 22:33:21 -0400 Subject: [PATCH 2/4] Re-add sed; Fixes stats page --- simpleadmin/scripts/modemstatus_parse.sh | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/simpleadmin/scripts/modemstatus_parse.sh b/simpleadmin/scripts/modemstatus_parse.sh index 5d3b6cc..234d88f 100644 --- a/simpleadmin/scripts/modemstatus_parse.sh +++ b/simpleadmin/scripts/modemstatus_parse.sh @@ -307,8 +307,7 @@ case $RAT in PCI=$(echo $QENG5 | cut -d, -f8) get_secondary_bands # Apply | sed '1d' to NR_BAND - # Temporarily removed the sed command for testing - NR_BAND=$(echo $NR_BAND) + NR_BAND=$(echo $NR_BAND | sed '1d') CHANNEL=$(echo $QENG5 | cut -d, -f10) LBAND=$(echo $QENG5 | cut -d, -f11) PC_BAND="NR5G BAND "$LBAND From a3b4e400275a3d4c7ff6f325619b5c5d57dccb77 Mon Sep 17 00:00:00 2001 From: Cameron Thompson <50184035+iamromulan@users.noreply.github.com> Date: Thu, 21 Mar 2024 23:29:16 -0400 Subject: [PATCH 3/4] Sync changes with simpleadmintest --- simpleadmin/www/index.html | 44 +++++++++++++++++++------------------- 1 file changed, 22 insertions(+), 22 deletions(-) diff --git a/simpleadmin/www/index.html b/simpleadmin/www/index.html index 1b340b9..d392ef1 100644 --- a/simpleadmin/www/index.html +++ b/simpleadmin/www/index.html @@ -256,28 +256,28 @@ }, }; } - // function getSignalData() { - // return { - // csqData: {}, - // lastUpdate: new Date().toLocaleString(), - // getcsq() { - // fetch("/cgi-bin/get_csq") - // .then((res) => res.json()) - // .then((data) => { - // this.csqData = data; - // this.lastUpdate = new Date( - // data.LASTUPDATE * 1000 - // ).toLocaleString(); - // }); - // }, - // init() { - // this.getcsq(); - // setInterval(() => { - // this.getcsq(); - // }, 30000); - // }, - // }; - // } + function getSignalData() { + return { + csqData: {}, + lastUpdate: new Date().toLocaleString(), + getcsq() { + fetch("/cgi-bin/get_csq") + .then((res) => res.json()) + .then((data) => { + this.csqData = data; + this.lastUpdate = new Date( + data.LASTUPDATE * 1000 + ).toLocaleString(); + }); + }, + init() { + this.getcsq(); + setInterval(() => { + this.getcsq(); + }, 30000); + }, + }; + } From 4b92fdbaf0c5dc3604e0d2ee4a974764cf0caa62 Mon Sep 17 00:00:00 2001 From: Cameron Thompson <50184035+iamromulan@users.noreply.github.com> Date: Sat, 23 Mar 2024 16:36:03 -0400 Subject: [PATCH 4/4] Re-add sed https://github.com/iamromulan/quectel-rgmii-toolkit/commit/dea33f9ad9eca34abf0de964c90511a513ba61e0#r140145133 --- simpleadmin/scripts/modemstatus_parse.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/simpleadmin/scripts/modemstatus_parse.sh b/simpleadmin/scripts/modemstatus_parse.sh index 234d88f..df5cfaf 100644 --- a/simpleadmin/scripts/modemstatus_parse.sh +++ b/simpleadmin/scripts/modemstatus_parse.sh @@ -44,7 +44,7 @@ get_secondary_bands() { SCC_BANDS=$(echo "$OX" | grep '+QCAINFO: "SCC"' | grep -o '"LTE BAND [0-9]\+"' | tr -d '"' | sed '1d') # Extract NR5G BANDs from SCC lines - NR_BAND=$(echo "$OX" | grep '+QCAINFO: "SCC"' | grep -o '"NR5G BAND [0-9]\+"' | tr -d '"') + NR_BAND=$(echo "$OX" | grep '+QCAINFO: "SCC"' | grep -o '"NR5G BAND [0-9]\+"' | tr -d '"'| sed '1d') # Check if both SCC and NR bands are non-empty if [ -n "$SCC_BANDS" ] && [ -n "$NR_BAND" ]; then @@ -519,4 +519,4 @@ MODEZ=$(echo $MODE | tr -d '"') } > /tmp/signal.txt # Pregenerate JSON File -/usrdata/simpleadmin/scripts/tojson.sh /tmp/signal.txt > /tmp/modemstatus.json \ No newline at end of file +/usrdata/simpleadmin/scripts/tojson.sh /tmp/signal.txt > /tmp/modemstatus.json