Re: [PATCH] Trivial, add AO subdevice to comedi_test

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Thursday 15 May 2003 10:05 am, Calin A. Culianu wrote:
> Hi guys,
>
> I found it useful when devloping/testing comedi applications to
> sometimes have an AO subdevice available in the comedi_test driver. 
> It's pretty useless, as all it does is loop back AO to the AI channels,
> and doesn't even support AO commands or anything, but it at least lets
> one use the comedi_test driver with applications that require analog
> input _and_ analog output.
>
> Let me know if this patch is useful.  It isn't very invasive and
> hopefully it can make it into comedi cvs...
>

It's useful, a couple things should be changed though.  You should insert 
the ao readback into the fake_waveform function, adding a new ai channel 
for each ao channel readback.  That way, it will work with ai commands 
also.  Then make the ai insn get its data by calling fake_waveform with 
the current time (this is a fix that isn't really related to your changes, 
but it should be done).  Your waveform_ai_insn_read should be made the ao 
read insn.  If you don't want to do this stuff yourself, tell me and I'll 
try and get around to it in a few days.

- -- 
Frank

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.6 (GNU/Linux)
Comment: For info see http://www.gnupg.org

iD8DBQE+w9PK5vihyNWuA4URAmKEAKCeslny9uVIcnTYZqUBKkbkdFNZOACfaZ8f
Gp4CDsqi4tkhytVMWIV/nLY=
=jwhc
-----END PGP SIGNATURE-----

Received on 2003-05-15Z16:52:10