loader: add script to de-register ftdi_sio

This commit is contained in:
Paul Mathieu 2025-03-12 13:43:56 -07:00
parent e955ad7b91
commit ca2ba3ddda
2 changed files with 20 additions and 1 deletions

View File

@ -1,8 +1,16 @@
export DOCKER_BUILDKIT=1
.PHONY: loader
loader: ## build the loader in docker (linux)
docker build -o . .
.PHONY: ftdi-unbind
ftdi-unbind: ## unbind the ftdi-sio devices on linux (uses sudo)
sh -c "cd /sys/bus/usb/drivers/ftdi_sio && \
for dev in *:*; do \
echo \$$dev | sudo tee unbind ; \
done"
.PHONY: clean
clean:
rm -rf loader $(objects)

View File

@ -28,6 +28,17 @@ Test it out
`./alchitry_loader`
## Linux and macOS and libftd2xx
On Linux (and macOS?) the default kernel drivers prevent libftd2xx from working properly.
On Linux, you can use this to de-register all ftdi-sio devices (until plugged again):
```
make ftdi-unbind
```
## Usage
```