install & automount

This commit is contained in:
2025-09-25 15:08:51 +02:00
parent 97547f4f80
commit cfd1b0bc43
4 changed files with 251 additions and 16 deletions

12
99-usb-automount.rules Normal file
View File

@@ -0,0 +1,12 @@
# USB Auto-Mount udev rules for Raspberry Pi Video Player
# These rules automatically mount USB devices when they are inserted
# Mount USB storage devices when added
SUBSYSTEM=="block", KERNEL=="sd*[0-9]", ACTION=="add", RUN+="/opt/video_player/usb_automount.sh add %k"
# Unmount USB storage devices when removed
SUBSYSTEM=="block", KERNEL=="sd*[0-9]", ACTION=="remove", RUN+="/opt/video_player/usb_automount.sh remove %k"
# Alternative rules for different USB device naming patterns
SUBSYSTEM=="block", KERNEL=="mmcblk*[0-9]", ACTION=="add", RUN+="/opt/video_player/usb_automount.sh add %k"
SUBSYSTEM=="block", KERNEL=="mmcblk*[0-9]", ACTION=="remove", RUN+="/opt/video_player/usb_automount.sh remove %k"