summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJan-Peter Nilsson <peppe@pappkartong.se>2013-03-16 23:54:13 +0100
committerJan-Peter Nilsson <peppe@pappkartong.se>2013-03-16 23:54:13 +0100
commit1d5da8d5d70859c71f7369aca45d22cfe5bab94d (patch)
tree3b97fe2827a60ecdd7b9214c9470edea823df222
parent3247f27fed09e4dbc3792cc5dcd4ae1681340f19 (diff)
Add udev rule to avoid mixing up the ttyUSBx devicesHEADmaster
-rw-r--r--etc/52-tv.rules1
-rwxr-xr-xtv2
2 files changed, 2 insertions, 1 deletions
diff --git a/etc/52-tv.rules b/etc/52-tv.rules
new file mode 100644
index 0000000..c3104e6
--- /dev/null
+++ b/etc/52-tv.rules
@@ -0,0 +1 @@
+SUBSYSTEMS=="usb", ATTRS{idVendor}=="067b", ATTRS{idProduct}=="2303", KERNEL=="ttyUSB*", SYMLINK+="tv"
diff --git a/tv b/tv
index 912a64b..bdf5871 100755
--- a/tv
+++ b/tv
@@ -4,7 +4,7 @@ import sys
import LgTV
-tv = LgTV.LgTV("/dev/ttyUSB0")
+tv = LgTV.LgTV("/dev/tv")
#tv.setValue(01, "xb", 0x00)
#print tv.getValue(01, "xb")
#tv.setValue(01, "xb", 0x80)