Compare commits
7 Commits
Author | SHA1 | Date |
---|---|---|
pyup.io bot | 32f4af941e | |
pyup.io bot | d8badd32bd | |
Sebastian | 858fc0a331 | |
pyup.io bot | f7441a7ff4 | |
pyup.io bot | 4087405690 | |
Felipe Martin Garcia | 4b0bc271bc | |
pyup-bot | 74e5054ca4 |
|
@ -88,3 +88,4 @@ ENV/
|
|||
|
||||
# Rope project settings
|
||||
.ropeproject
|
||||
.built/
|
||||
|
|
|
@ -0,0 +1,34 @@
|
|||
all: test
|
||||
|
||||
venv: .built/venv
|
||||
|
||||
.built/venv: .built/
|
||||
( \
|
||||
python3 -m venv venv ;\
|
||||
source venv/bin/activate ;\
|
||||
pip install --upgrade pip ;\
|
||||
pip install --upgrade -r requirements.txt ;\
|
||||
touch $@ ;\
|
||||
)
|
||||
|
||||
test: venv
|
||||
( \
|
||||
. venv/bin/activate ;\
|
||||
python3 setup.py install ;\
|
||||
luxa off ;\
|
||||
sleep 1 ;\
|
||||
luxa set --led=all ff0000 ;\
|
||||
sleep 1 ;\
|
||||
luxa set --led=all 00ff00 ;\
|
||||
sleep 1 ;\
|
||||
luxa set --led=all 0000ff ;\
|
||||
sleep 1 ;\
|
||||
luxa off ;\
|
||||
)
|
||||
|
||||
.built/:
|
||||
@mkdir -p $@
|
||||
|
||||
clean:
|
||||
rm -rf venv/
|
||||
rm -rf .built/
|
16
README.md
16
README.md
|
@ -10,6 +10,22 @@ cd pyluxafor
|
|||
python3 setup.py install
|
||||
```
|
||||
|
||||
## Ensure that USB device gets proper permissions
|
||||
|
||||
Create UDEV rule in /etc/udev/rules.d/60-luxafor.rules with the following content
|
||||
```
|
||||
# add Luxafor LED flag
|
||||
SUBSYSTEMS=="usb", ATTR{idVendor}=="04d8", ATTR{idProduct}=="f372", MODE:="0666"
|
||||
```
|
||||
|
||||
Reload udev configuration files
|
||||
|
||||
```shell
|
||||
sudo udevadm control --reload && sudo udevadm trigger
|
||||
```
|
||||
|
||||
Reinsert the Luxafor LED light.
|
||||
|
||||
## Using the CLI
|
||||
|
||||
Pyluxafor provides the `luxa` command to interact with the USB led in the same way as the library
|
||||
|
|
|
@ -1 +1 @@
|
|||
click>=6.7.0,<=6.7.99
|
||||
click==8.0.4
|
||||
|
|
Loading…
Reference in New Issue