# udev rules file for brltty
#

ACTION!="add", GOTO="brltty_rules_end"

SUBSYSTEM=="usb_device", GOTO="brltty_usb_begin"
SUBSYSTEM=="usb", KERNEL!="*:*", GOTO="brltty_usb_begin"
GOTO="brltty_rules_end"

LABEL="brltty_usb_begin"

# XXX: Check in Programs/config.c's usbDrivers about device drivers probing
# which is not enabled by upstream due to conflicting protocols.

# Generic identifiers
# We disable the at, ce, and mm drivers: these devices are very rare, and detection
# conflicts with ht or sk devices.
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="6001", RUN+="/lib/udev/brltty.sh -b hm,ht -d usb:"
ATTRS{idVendor}=="10c4", ATTRS{idProduct}=="ea60", RUN+="/lib/udev/brltty.sh -b sk -d usb:"
ATTRS{idVendor}=="10c4", ATTRS{idProduct}=="ea80", RUN+="/lib/udev/brltty.sh -b sk -d usb:"


# Alva
ATTRS{idVendor}=="06b0", ATTRS{idProduct}=="0001", RUN+="/lib/udev/brltty.sh -b al -d usb:"
ATTRS{idVendor}=="0798", ATTRS{idProduct}=="0624", RUN+="/lib/udev/brltty.sh -b al -d usb:"
ATTRS{idVendor}=="0798", ATTRS{idProduct}=="0640", RUN+="/lib/udev/brltty.sh -b al -d usb:"
ATTRS{idVendor}=="0798", ATTRS{idProduct}=="0680", RUN+="/lib/udev/brltty.sh -b al -d usb:"

# Baum
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="fe70", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="fe71", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="fe72", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="fe73", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="fe74", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="fe75", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="fe76", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="fe77", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0904", ATTRS{idProduct}=="2000", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0904", ATTRS{idProduct}=="2001", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0904", ATTRS{idProduct}=="2002", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0904", ATTRS{idProduct}=="2007", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0904", ATTRS{idProduct}=="2008", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0904", ATTRS{idProduct}=="2009", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0904", ATTRS{idProduct}=="2010", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0904", ATTRS{idProduct}=="2011", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0904", ATTRS{idProduct}=="2014", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0904", ATTRS{idProduct}=="2015", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0904", ATTRS{idProduct}=="2016", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0904", ATTRS{idProduct}=="3000", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0904", ATTRS{idProduct}=="3001", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0904", ATTRS{idProduct}=="4004", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0904", ATTRS{idProduct}=="4005", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0904", ATTRS{idProduct}=="4007", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0904", ATTRS{idProduct}=="4008", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0904", ATTRS{idProduct}=="6001", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0904", ATTRS{idProduct}=="6002", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0904", ATTRS{idProduct}=="6003", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0904", ATTRS{idProduct}=="6004", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0904", ATTRS{idProduct}=="6005", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0904", ATTRS{idProduct}=="6006", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0904", ATTRS{idProduct}=="6007", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0904", ATTRS{idProduct}=="6008", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0904", ATTRS{idProduct}=="6009", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0904", ATTRS{idProduct}=="600a", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0904", ATTRS{idProduct}=="6011", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0904", ATTRS{idProduct}=="6012", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0904", ATTRS{idProduct}=="6013", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0904", ATTRS{idProduct}=="6101", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0904", ATTRS{idProduct}=="6102", RUN+="/lib/udev/brltty.sh -b bm -d usb:"
ATTRS{idVendor}=="0904", ATTRS{idProduct}=="6103", RUN+="/lib/udev/brltty.sh -b bm -d usb:"

# BrailleNote
ATTRS{idVendor}=="1c71", ATTRS{idProduct}=="c004", RUN+="/lib/udev/brltty.sh -b bn -d usb:"

# EuroBraille
ATTRS{idVendor}=="c251", ATTRS{idProduct}=="1122", RUN+="/lib/udev/brltty.sh -b eu -d usb:"
ATTRS{idVendor}=="c251", ATTRS{idProduct}=="1123", RUN+="/lib/udev/brltty.sh -b eu -d usb:"
ATTRS{idVendor}=="c251", ATTRS{idProduct}=="1124", RUN+="/lib/udev/brltty.sh -b eu -d usb:"
ATTRS{idVendor}=="c251", ATTRS{idProduct}=="1125", RUN+="/lib/udev/brltty.sh -b eu -d usb:"
ATTRS{idVendor}=="c251", ATTRS{idProduct}=="1126", RUN+="/lib/udev/brltty.sh -b eu -d usb:"
ATTRS{idVendor}=="c251", ATTRS{idProduct}=="1127", RUN+="/lib/udev/brltty.sh -b eu -d usb:"
ATTRS{idVendor}=="c251", ATTRS{idProduct}=="1128", RUN+="/lib/udev/brltty.sh -b eu -d usb:"
ATTRS{idVendor}=="c251", ATTRS{idProduct}=="1129", RUN+="/lib/udev/brltty.sh -b eu -d usb:"
ATTRS{idVendor}=="c251", ATTRS{idProduct}=="112a", RUN+="/lib/udev/brltty.sh -b eu -d usb:"
ATTRS{idVendor}=="c251", ATTRS{idProduct}=="112b", RUN+="/lib/udev/brltty.sh -b eu -d usb:"
ATTRS{idVendor}=="c251", ATTRS{idProduct}=="112c", RUN+="/lib/udev/brltty.sh -b eu -d usb:"
ATTRS{idVendor}=="c251", ATTRS{idProduct}=="112d", RUN+="/lib/udev/brltty.sh -b eu -d usb:"
ATTRS{idVendor}=="c251", ATTRS{idProduct}=="112e", RUN+="/lib/udev/brltty.sh -b eu -d usb:"
ATTRS{idVendor}=="c251", ATTRS{idProduct}=="112f", RUN+="/lib/udev/brltty.sh -b eu -d usb:"
ATTRS{idVendor}=="c251", ATTRS{idProduct}=="1130", RUN+="/lib/udev/brltty.sh -b eu -d usb:"
ATTRS{idVendor}=="c251", ATTRS{idProduct}=="1131", RUN+="/lib/udev/brltty.sh -b eu -d usb:"
ATTRS{idVendor}=="c251", ATTRS{idProduct}=="1132", RUN+="/lib/udev/brltty.sh -b eu -d usb:"

# FreedomScientific
ATTRS{idVendor}=="0f4e", ATTRS{idProduct}=="0100", RUN+="/lib/udev/brltty.sh -b fs -d usb:"
ATTRS{idVendor}=="0f4e", ATTRS{idProduct}=="0111", RUN+="/lib/udev/brltty.sh -b fs -d usb:"
ATTRS{idVendor}=="0f4e", ATTRS{idProduct}=="0112", RUN+="/lib/udev/brltty.sh -b fs -d usb:"
ATTRS{idVendor}=="0f4e", ATTRS{idProduct}=="0114", RUN+="/lib/udev/brltty.sh -b fs -d usb:"

# Hedo
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="de58", RUN+="/lib/udev/brltty.sh -b hd -d usb:"
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="de59", RUN+="/lib/udev/brltty.sh -b hd -d usb:"

# HandyTech
ATTRS{idVendor}=="0921", ATTRS{idProduct}=="1200", RUN+="/lib/udev/brltty.sh -b ht -d usb:"
ATTRS{idVendor}=="1fe4", ATTRS{idProduct}=="0003", RUN+="/lib/udev/brltty.sh -b ht -d usb:"
ATTRS{idVendor}=="1fe4", ATTRS{idProduct}=="0044", RUN+="/lib/udev/brltty.sh -b ht -d usb:"
ATTRS{idVendor}=="1fe4", ATTRS{idProduct}=="0054", RUN+="/lib/udev/brltty.sh -b ht -d usb:"
ATTRS{idVendor}=="1fe4", ATTRS{idProduct}=="0055", RUN+="/lib/udev/brltty.sh -b ht -d usb:"
ATTRS{idVendor}=="1fe4", ATTRS{idProduct}=="0064", RUN+="/lib/udev/brltty.sh -b ht -d usb:"
ATTRS{idVendor}=="1fe4", ATTRS{idProduct}=="0074", RUN+="/lib/udev/brltty.sh -b ht -d usb:"
ATTRS{idVendor}=="1fe4", ATTRS{idProduct}=="0081", RUN+="/lib/udev/brltty.sh -b ht -d usb:"
ATTRS{idVendor}=="1fe4", ATTRS{idProduct}=="0082", RUN+="/lib/udev/brltty.sh -b ht -d usb:"
ATTRS{idVendor}=="1fe4", ATTRS{idProduct}=="0083", RUN+="/lib/udev/brltty.sh -b ht -d usb:"
ATTRS{idVendor}=="1fe4", ATTRS{idProduct}=="0084", RUN+="/lib/udev/brltty.sh -b ht -d usb:"
ATTRS{idVendor}=="1fe4", ATTRS{idProduct}=="0086", RUN+="/lib/udev/brltty.sh -b ht -d usb:"
ATTRS{idVendor}=="1fe4", ATTRS{idProduct}=="0087", RUN+="/lib/udev/brltty.sh -b ht -d usb:"
ATTRS{idVendor}=="1fe4", ATTRS{idProduct}=="008a", RUN+="/lib/udev/brltty.sh -b ht -d usb:"
ATTRS{idVendor}=="1fe4", ATTRS{idProduct}=="008b", RUN+="/lib/udev/brltty.sh -b ht -d usb:"

# HIMS
ATTRS{idVendor}=="045e", ATTRS{idProduct}=="930a", RUN+="/lib/udev/brltty.sh -b hm -d usb:"
ATTRS{idVendor}=="045e", ATTRS{idProduct}=="930b", RUN+="/lib/udev/brltty.sh -b hm -d usb:"

# HumanWare
ATTRS{idVendor}=="1c71", ATTRS{idProduct}=="c005", RUN+="/lib/udev/brltty.sh -b hw -d usb:"

# BrailleMemo
ATTRS{idVendor}=="1148", ATTRS{idProduct}=="0301", RUN+="/lib/udev/brltty.sh -b mm -d usb:"

# Metec
ATTRS{idVendor}=="0452", ATTRS{idProduct}=="0100", RUN+="/lib/udev/brltty.sh -b mt -d usb:"

# Papenmeier
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="f208", RUN+="/lib/udev/brltty.sh -b pm -d usb:"

# Pegasus
ATTRS{idVendor}=="4242", ATTRS{idProduct}=="0001", RUN+="/lib/udev/brltty.sh -b pg -d usb:"

# Voyager
ATTRS{idVendor}=="0798", ATTRS{idProduct}=="0001", RUN+="/lib/udev/brltty.sh -b vo -d usb:"
ATTRS{idVendor}=="0798", ATTRS{idProduct}=="0600", RUN+="/lib/udev/brltty.sh -b vo -d usb:"

LABEL="brltty_rules_end"
