Updated usbdux firmware files. The udev hotplug mechanism
[comedilib.git] / etc / hotplug / usb / usbduxsigma / usbduxsigma
1 #!/bin/sh
2 #
3 # hotplug script for USBDUXsigma. Mon Apr 23 13:38:43 GMT 2012
4 # Bernd.Porr@gla.ac.uk
5 #
6 #
7 #
8 #look for comedi config
9 COMEDI_CONFIG=
10 #
11 if [ -e /usr/local/sbin/comedi_config ]; then
12         COMEDI_CONFIG=/usr/local/sbin/comedi_config
13 fi
14 if [ -e /usr/sbin/comedi_config ]; then 
15         COMEDI_CONFIG=/usr/sbin/comedi_config
16 fi
17 if [ -e /sbin/comedi_config ]; then 
18         COMEDI_CONFIG=/sbin/comedi_config
19 fi
20 #
21 #
22 #look for the firmware
23 USBDUX_FIRMWARE=
24 if [ -e /usr/share/usb/usbduxsigma_firmware.hex ]; then 
25         USBDUX_FIRMWARE=/usr/share/usb/usbduxsigma_firmware.hex
26 fi
27 if [ -e /usr/local/share/usb/usbduxsigma_firmware.hex ]; then
28         USBDUX_FIRMWARE=/usr/local/share/usb/usbduxsigma_firmware.hex
29 fi
30 #
31 #
32 # If you have more than one device please add/uncomment
33
34 # just to make sure we remove the comedi device
35 $COMEDI_CONFIG -r /dev/comedi0
36 # $COMEDI_CONFIG -r /dev/comedi1
37 #
38 # connecting the comedi device comedi0 with the module usbdux
39 $COMEDI_CONFIG -i $USBDUX_FIRMWARE /dev/comedi0 usbduxsigma
40 # $COMEDI_CONFIG -i $USBDUX_FIRMWARE /dev/comedi1 usbduxsigma
41 #
42 #