feat(deploy): add stable USB serial symlinks for BATM3
USB-serial adapters enumerate in unpredictable order on reboot, causing ttyUSB0/1/2 to swap between the F56 dispenser, MEI validator, and NFC module. Add udev rules that create stable symlinks by adapter serial number: - /dev/ttyF56 → Prolific DDDLb103Y23 (F56 dispenser) - /dev/ttyMEI → FTDI A9YW78OC (MEI cash recycler) - /dev/ttyNFC → FTDI A9ZF8ELY (NFC module) Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
7dfc5ffc98
commit
6cf372055f
1 changed files with 4 additions and 0 deletions
|
|
@ -68,9 +68,13 @@
|
|||
};
|
||||
|
||||
# Serial port access for bill validator/dispenser (USB-serial adapters)
|
||||
# Stable symlinks by adapter serial number (prevents ttyUSB reordering on reboot)
|
||||
services.udev.extraRules = lib.mkAfter ''
|
||||
KERNEL=="ttyS[0-9]*", MODE="0666"
|
||||
KERNEL=="ttyUSB[0-9]*", MODE="0666"
|
||||
KERNEL=="ttyACM[0-9]*", MODE="0666"
|
||||
SUBSYSTEM=="tty", ATTRS{serial}=="DDDLb103Y23", SYMLINK+="ttyF56", MODE="0666"
|
||||
SUBSYSTEM=="tty", ATTRS{serial}=="A9YW78OC", SYMLINK+="ttyMEI", MODE="0666"
|
||||
SUBSYSTEM=="tty", ATTRS{serial}=="A9ZF8ELY", SYMLINK+="ttyNFC", MODE="0666"
|
||||
'';
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue