Example session
First we need to compile the daq core module:
The next step is to tell the core module which driver you want to attach to a specific card. In our example we wan't to attach the skeleton driver to the card represents through '/dev/daq0'.
BTW, take a look at the 'daq_skeleton.c' driver to get an overview about the driver development. There is also a demo directory with a few examples which make use of the 'DAQ userland interface'.
# cd daq-0.23 # make all installNow we need to compile the daq skeleton driver:
# cd daq-0.23/drivers # make all installAfter that, we're able to load both modules, the core and the skeleton module:
# kldload daq # kldload daq_skeletonLet us see what dmesg says:
# dmesg | tail ... ... ... daq_core: version 0.23 -- Manuel Gebele <forensixs@gmx.de> daq_skeleton: registering daq driverEverything seems to be ok, the skeleton driver is registered to the core.
The next step is to tell the core module which driver you want to attach to a specific card. In our example we wan't to attach the skeleton driver to the card represents through '/dev/daq0'.
# cd daq-0.23/daq_cardconf # gcc -Wall -o daq_cardconf daq_cardconf.c # ./daq_cardconf /dev/daq0 daq_skeleton # dmesg | tail ... ... ... daq_core0: daq_skeleton: attachedFinally we try to get some useful information about the card attributes (defined by the skeleton driver).
# cd daq-0.23/demo # gcc -Wall -o daq_cardinfo daq_cardinfo.c # ./daq_cardinfo /dev/daq0 driver name: daq_skeleton card name: skel_card1 read kit: 0 write kit: 0 vers_code: 65536 # of kits: 3Unfortunately there is no more documentation, please be patient...
BTW, take a look at the 'daq_skeleton.c' driver to get an overview about the driver development. There is also a demo directory with a few examples which make use of the 'DAQ userland interface'.