mirror of
https://github.com/femtofox/femtofox.git
synced 2026-11-29 03:17:04 -05:00
Continued sysinfo
This commit is contained in:
parent
634ce2307f
commit
4e61869b4a
2 changed files with 5 additions and 3 deletions
|
|
@ -249,12 +249,13 @@ $(lsusb | grep -v 'root hub' | awk 'NR>0{printf "USB: "; for(i=7;i<
|
|||
i2c devices: $i2c_addresses\n\
|
||||
\n\
|
||||
Kernel:
|
||||
Version: $(uname -r)
|
||||
Modules active: $(lsmod | awk 'NR>1 {print $1}' | tr '\n' ' ' && echo)\n\
|
||||
Boot modules: $boot_modules\n\
|
||||
\n\
|
||||
Meshtasticd:\n\
|
||||
Service status: $(femto-meshtasticd-config.sh -S)\n\
|
||||
$(femto-meshtasticd-config.sh -i)\
|
||||
Service status: $(replace_colors "$(femto-meshtasticd-config.sh -S)")\n\
|
||||
$(replace_colors "$(femto-meshtasticd-config.sh -i)")\
|
||||
"
|
||||
echo -e "$info"
|
||||
}
|
||||
|
|
|
|||
|
|
@ -80,7 +80,8 @@ while getopts ":higkl:q:va:cpo:sStruxm" opt; do
|
|||
echo -e "\
|
||||
Version: $(echo "$output" | grep -oP '"firmwareVersion":\s*"\K[^"]+' | head -n 1)\n\
|
||||
Node name: $(echo "$output" | grep -oP 'Owner:\s*\K.*' | head -n 1)\n\
|
||||
NodeID: $(printf "%X\n" $(echo "$output" | grep -oP '"myNodeNum":\s*\K\d+' | head -n 1) | tr '[:upper:]' '[:lower:]') ($(echo "$output" | grep -oP '"myNodeNum":\s*\K\d+' | head -n 1))\n\
|
||||
NodeID: $(printf "%08x\n" $(echo "$output" | grep -oP '"myNodeNum":\s*\K\d+' | head -n 1)) ($(echo "$output" | grep -oP '"myNodeNum":\s*\K\d+' | head -n 1))\n\
|
||||
TX enabled? $(txEnabled=$(echo "$output" | grep -oP '"txEnabled":\s*\K\w+'); [[ "$txEnabled" == "true" ]] && echo "\033[0;34menabled\033[0m" || echo "\033[0;31mdisabled\033[0m")\n\
|
||||
Role: $(echo "$output" | grep -oP '"role":\s*"\K[^"]+' | head -n 1)\n\
|
||||
Preset: $(echo "$output" | grep -oP '"modemPreset":\s*"\K[^"]+')\n\
|
||||
Region: $(echo "$output" | grep -oP '"region":\s*"\K[^"]+')\n\
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue