On 2012/04/25 12:20 PM, Simon Pickering wrote:
> I've just written a Comedi driver for a PCI high voltage DAC card and
> wanted to ask a driver-related question and also make a comment or two
> about the website (as someone who has just come to Comedi and used the
> docs to get going).
Well done!
> First of all is the question of whether I can switch my card's
> analogue outputs on at some point after the kernel module is loaded
> (e.g. via some Comedilib command or ideally when the relevant device
> file is opened)? I currently set the card outputs to 0V when the
> driver is initialised, but as the card in question outputs either 150
> or 500V (depending on the exact model), I'd prefer to have it
> completely off until it's needed.
There are optional 'open' and 'close' hooks in 'struct
comedi_device_struct' that the driver can set. You could use those to
turn the outputs on and off.
> I also have a couple of comments about the website - the first one is
> that the wiki link on this page is broken (
http://comedi.org/
> documentation.html) and emails to
webm...@comedi.org get bounced.
I think the wiki contents got lost during a server rebuild. I don't
know if there's a backup anywhere. I suppose David Schleef is still
technically the webmaster, although he's not directly involved in Comedi
any more. I guess it's better to bounce the messages than tip them into
a bitbucket. Comments on the website can be made on the mailing list.
> Secondly, I see that the HTML docs on the site are out of date -
> certainly the driver writing section doesn't seem to have current
> information on some of the structures. I also noted that the parameter
> list for e.g. comedi_to_phys() is different in the "3.2. Converting
> samples to voltages" section (
http://comedi.org/doc/x403.html) vs. the
> stand alone page describing the function (
http://comedi.org/doc/
> r5619.html).
The HTML docs will be updated when we release an official version of
comedilib. That's "real soon now" (probably about a week to tie up any
loose ends in the packaging and documentation).
> I wonder if a warning that the HTML docs are out of date would be
> worth adding to the site (though other than the above points I'm not
> sure how out of date, so perhaps it's just a case of correcting some
> minor things as it's certainly nice to have the well written and
> explained documentation available)? Certainly a pointer to the
> Hardware_Driver.HOWTO in the git repo would be useful for driver
> writers IMO.
Adding some version information to the online docs and comedilib manual
would be a good start! We can add some comment about the age of the
comedilib manual, but I'll leave that until after upcoming release of
comedilib.
I think there might have been some info in the wiki about driver
writing, but that got lost.
We can add a link to the Hardware_Driver.HOWTO (such as it is, it's a
bit basic!) to the Documentation page.
--
-=( Ian Abbott @ MEV Ltd. E-mail: <
abb...@mev.co.uk> )=-
-=( Tel:
+44 (0)161 477 1898 FAX:
+44 (0)161 718 3587 )=-