Advantech PCM-3730 isolated - 8 in/8 out ttl - 16 in/16 out
Advantech PCL-725 isolated - 8 in/8 out
Advantech PCL-733 isolated - 32 in
+ Advantech PCL-734 isolated - 32 out
To compile this driver as a module, choose M here: the module will be
called pcl730.
tristate "Generic driver for very simple devices"
---help---
Enable generic support for very simple / POC (Piece of Crap) boards,
- Keithley Metrabyte DAC-02 (dac02) and Advantech PCL-734 (pcl734).
+ Keithley Metrabyte DAC-02 (dac02).
To compile this driver as a module, choose M here: the module will be
called poc.
* (Advantech) PCM-3730 [pcm3730]
* (Advantech) PCL-725 [pcl725]
* (Advantech) PCL-733 [pcl733]
+ * (Advantech) PCL-734 [pcl734]
* Author: José Luis Sánchez (jsanchezv@teleline.es)
* Status: untested
*
* The pcm3730 PC/104 board does not have the PCL730_IDIO_HI register.
* The pcl725 ISA board uses separate registers for isolated digital I/O.
* The pcl733 ISA board uses all four registers for isolated digital inputs.
+ * The pcl734 ISA board uses all four registers for isolated digital outputs.
*/
#define PCL730_IDIO_LO 0 /* Isolated Digital I/O low byte (ID0-ID7) */
#define PCL730_IDIO_HI 1 /* Isolated Digital I/O high byte (ID8-ID15) */
.io_range = 0x04,
.n_subdevs = 1,
.n_iso_in_chan = 32,
+ }, {
+ .name = "pcl734",
+ .io_range = 0x04,
+ .n_subdevs = 1,
+ .n_iso_out_chan = 32,
},
};
outb(s->state & 0xff, dev->iobase + reg);
if ((mask & 0xff00) && (s->n_chan > 8))
outb((s->state >> 8) & 0xff, dev->iobase + reg + 1);
+ if ((mask & 0xff0000) && (s->n_chan > 16))
+ outb((s->state >> 16) & 0xff, dev->iobase + reg + 2);
+ if ((mask & 0xff000000) && (s->n_chan > 24))
+ outb((s->state >> 24) & 0xff, dev->iobase + reg + 3);
}
data[1] = s->state;
Description: Generic driver for very simple devices
Author: ds
Devices: [Keithley Metrabyte] DAC-02 (dac02)
- PCL-734 (pcl734)
Updated: Sat, 16 Mar 2002 17:34:48 -0800
Status: unknown
This driver is indended to support very simple ISA-based devices,
including:
dac02 - Keithley DAC-02 analog output board
- pcl734 - Advantech PCL-734
Configuration options:
[0] - I/O port base
return 1;
}
-static int pcl734_insn_bits(struct comedi_device *dev,
- struct comedi_subdevice *s,
- struct comedi_insn *insn, unsigned int *data)
-{
- if (data[0]) {
- s->state &= ~data[0];
- s->state |= (data[0] & data[1]);
- if ((data[0] >> 0) & 0xff)
- outb((s->state >> 0) & 0xff, dev->iobase + 0);
- if ((data[0] >> 8) & 0xff)
- outb((s->state >> 8) & 0xff, dev->iobase + 1);
- if ((data[0] >> 16) & 0xff)
- outb((s->state >> 16) & 0xff, dev->iobase + 2);
- if ((data[0] >> 24) & 0xff)
- outb((s->state >> 24) & 0xff, dev->iobase + 3);
- }
- data[1] = s->state;
-
- return insn->n;
-}
-
static int poc_attach(struct comedi_device *dev, struct comedi_devconfig *it)
{
const struct boarddef_struct *board = comedi_board(dev);
.winsn = dac02_ao_winsn,
.rinsn = readback_insn,
.range = &range_unknown,
- }, {
- .name = "pcl734",
- .iosize = 4,
- .type = COMEDI_SUBD_DO,
- .n_chan = 32,
- .n_bits = 1,
- .insnbits = pcl734_insn_bits,
- .range = &range_digital,
},
};