Skip to content

Commit

Permalink
wlanpi-model command executed on M4+ now shows USB mode (host/OTG)
Browse files Browse the repository at this point in the history
  • Loading branch information
jiribrejcha authored Aug 2, 2024
1 parent 7e022b9 commit bb1c7ec
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 1 deletion.
6 changes: 6 additions & 0 deletions debian/changelog
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
wlanpi-common (1.1.22) unstable; urgency=medium

* wlanpi-model command executed on M4+ now shows USB mode (host/OTG)

-- Jiri Brejcha <[email protected]> Fri, 02 Aug 2024 8:40:00 +0100

wlanpi-common (1.1.21-2) unstable; urgency=medium

* Adds automatic USB mode switching between host and OTG mode on M4+ based on physical switch position
Expand Down
7 changes: 6 additions & 1 deletion opt/wlanpi-common/wlanpi-model.sh
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,11 @@ elif grep -q "Raspberry Pi Compute Module 4" /proc/cpuinfo; then
else
echo "Model: WLAN Pi M4+"
echo "Main board: Mcuzone M4+"
if grep -q -E "^\s*otg_mode=1" /boot/config.txt; then
echo "USB mode: Host - Bluetooth and USB-A ports enabled"
else
echo "USB mode: OTG - Bluetooth and USB-A ports disabled"
fi
fi
debugger "End script now. Platform is M4+."

Expand Down Expand Up @@ -186,4 +191,4 @@ if [ "$BRIEF_OUTPUT" -eq 0 ]; then
echo "No Bluetooth adapter"
fi
fi
fi
fi

0 comments on commit bb1c7ec

Please sign in to comment.