Commit Graph

4 Commits

Author SHA1 Message Date
thorpej 99cf5fb567 Add an example devpubd hook that looks for Minipro-compatible EEPROM
programmers and sets the access permissions to 0660.
2024-03-30 16:47:55 +00:00
thorpej 4e13543e2b Add an example devpubd hook that detects the generic USB interface
portion of a Tigard debug board and changes the permissions of the
appropriate /dev/ugenN.* nodes to allow access without superuser
permissions, suitable for using e.g. openocd with the device.

This example can be easily modified to support other generic USB devices
that have user-space drivers where running as the superuser is not desired.
2024-03-30 06:42:10 +00:00
thorpej 2142cffc5c Descend into share/examples/devpubd/hooks 2024-03-30 06:29:33 +00:00
thorpej 70f7362772 Add an example devpubd hook that makes stable path names, using symlinks,
for USB serial interfaces, regardless of where the interface is connected
or the order of enumeration.  This requires the USB device to have a
"serialnumber" to function.  Examples:

- uftdi serial adapter with two ports:

	/dev/tty-uftdi-FT64S4YP-1 -> /dev/ttyU0
	/dev/tty-uftdi-FT64S4YP-2 -> /dev/ttyU1

- uslsa serial adapter:

	/dev/tty-uslsa-01E7ABCC -> /dev/ttyU4

This allows something like the following in /etc/remote:

sun3:dv=/dev/tty-uftdi-FT64S4YP-1:br#9600:pa=none:dc:

That path will always be stable regardless of which /dev/ttyU* node is
actually assigned when the serial adapter is plugged in.
2024-03-30 06:29:01 +00:00