DAS20 BOARD DRIVER:


INTRODUCTION:

The Keithley Metrabyte DAS-20 is a "legacy" classic. While no longer encouraged for new system designs (since other boards are substantially less expensive), it remains a top performer with many advanced features:
  • 12-bit ADC samples at 100 kHz.
  • 16 single-ended (8 differential) ADC inputs.
  • Individually programmable gain on each input.
  • DMA allows full throughput even on 4.77 MHz system.
  • Dual 12-bit DACs, bipolar or unipolar formats.
  • 8 bits digital input.
  • 8 bits digital output.
  • Undoubtedly the world's most complex timer chip (AM9513).
Although the manufacturer refers to this board as the DAS-20 (with a hyphen), the Daqarta driver is simply DAS20.ADC.


DAS20 CONFIGURATION PARAMETERS:


PARAMETER OVERVIEW:

This driver allows you to specify certain parameters on the DAS20.ADC line, which must be the second line of the DQA.CFG file. Each parameter is given as a letter and colon, followed immediately by a value or text string. Use a space between parameters. For example:
 DAS20.ADC      A:h300  I:7
The order of the parameters is not important for this driver, with the exception of the D: DMA and I: IRQ entries.

The parameter letters are case-insensitive, as are the entries that follow the colons.

Daqarta does not use any SET lines in your AUTOEXEC.BAT file, nor does it use any non-Daqarta drivers or libraries that may have been supplied by the board manufacturer.

You can check to see which parameters have been set, either via the configuration line or by default, by checking the board information summary available via the ALT-H Plug-In Help system. This also shows a summary of the default values for all parameters. There is no need to enter any parameter that is the same as the default value assumed by the driver.


A: ADDRESS:

Use this to tell Daqarta the base I/O address for your board. This should match the value selected by the DIP switches on the board, which usually comes from the manufacturer with a default setting of 300h (hexadecimal). To tell the Daqarta parameter parser that the value is in hexadecimal, precede it with an 'h', as in:
 DAS20.ADC      A:h330
The default address assumed by the driver is h300.

The value you enter is not validated against any standard list. Daqarta looks for the board at the address given, and if it does not find a valid DAS-20 board there it exits with:

 'DAS-20 board not found.'
The only exception is if you set A:0 to allow viewing of this board Help system without having a board installed or properly configured.


C: CHANNEL PRESET:

This parameter allows you to change the default channel that will be used when you first activate this driver via the Board option. A switch near the upper right corner of the board (called 'MUX CNFG' in the manufacturer's documentation) controls whether it is configured as 16 single-ended channels or 8 differential channels:
    16-channel             8-channel
   Single-Ended           Differential
     .------.               .------.
     | --[] |               | []-- |
     `------'               `------'
Valid channel numbers are 0 through 15 single-ended, or 0 through 7 differential. For example:
 DAS20.ADC      C:3
would set channel 3. You may change the channel from the board's control menu during operation. If you don't give a C: parameter, the default is channel 0.

Although the 8/16 channel switch can't be controlled by software, it can be read. If Daqarta finds the switch set to 8 channels and you use the C: parameter to try to set a channel number above 7, it will automatically be reduced by 8 to bring it into compatibility. For example, if you had entered 15, it will become 7.

You can check the status of the 8/16 channel switch by means of the information summary available through the ALT-H Plug-In Help system.


D: DMA (Direct Memory Access) Level:

The DAS-20 can use either DMA or interrupt-driven (one interrupt per sample) RTime processing. The D: parameter selects DMA operation and specifies DMA level 1 or 3, which is controlled entirely by software... there are no switches or jumpers on the DAS-20 board for this.

DMA operation uses one interrupt per 32768 samples, so you must also specify an IRQ level if you don't want to accept the default IRQ 7. You must give the I: parameter (if any) BEFORE the D: parameter to select DMA for RTime. For example:

 DAS20.ADC      I:5  D:1
would specify DMA level 1 operation for RTime mode, using IRQ 5. Alternately,
 DAS20.ADC      D:3
would specify DMA level 3 operation using the IRQ 7 default. The D: parameter will be ignored if it is given before the I: parameter. If you don't use a D: parameter, RTime mode will default to interrupt-driven operation.

Although the DAS-20 board allows DMA output to the DACs as well as DMA input from the ADC, it does not allow both at once. If you use the STIM3 Stimulus Generator to generate signals in RTime mode, Daqarta will automatically revert to interrupt-driven operation in order to perform simultaneous acquisition and output.

DMA is never used when RTime is inactive (Sequential mode).


F: HELP FILE OMIT:

This driver normally attempts to load this associated Help file on start-up, and exits with an error message if it can't find it. Setting F:0 on the ADC configuration line tells the driver not to look for the file. You would probably only want to use this option if you are really short of DOS memory, since loading the Help file only increases memory use by a few hundred bytes for its separate link stack and directory. (The file itself shares the text buffer of the Main Help file.)

Note that ALL Help files, including main, can be omitted via an F:0 parameter on the INIT line (first line) of the DQA.CFG file. If this is present, no individual module Help will be loaded.


I: IRQ (Interrupt Request):

The DAS-20 board allows RTime processing by means of one interrupt for each sample, or via DMA which uses an interrupt only once every 32768 samples. The Interrupt Request level in either case is controlled entirely by software... there are no jumpers or switches on the board for this. IRQ values from 2 through 7 may be selected here. For example:
 DAS20.ADC      I:5
would indicate that Daqarta should use IRQ 5 instead of the default IRQ 7.

If you want to specify DMA mode for RTime, make sure that any I: parameter comes before the D: parameter.

No board interrupt is used in Sequential mode, only when RTime is active.

You may want to avoid setting IRQ 2 on most machines, since it is redirected through IRQ 9 on the second interrupt controller and thus requires an extra End Of Interrupt (EOI) command to acknowledge each interrupt. This takes a little more time and could reduce the maximum sample rate possible in RTime mode. It will have no effect on Sequential mode. For PC or XT systems with an 8088 CPU there is only one interrupt controller, so the extra EOI command is not used and performance is not affected.

If you use interrupt-driven RTime, you may need to use the special DDISK13 BIOS-replacement driver for DDisk recording. This will only work with drives of 528 Meg or less. For larger drives, you will need to conduct your own tests to see if you can get suitable glitch-free recordings at your chosen sample rate, etc.


P: PORT I/O PRESET:

The DAS-20 has separate 8-bit digital input and output ports that may be used by Daqarta for External Trigger, DDisk Remote control, Averager Remote control, or stimulus Pulse Output.

Although individual bit usage can be set under menu control, you will typically hard-wire these items once your system is set up. The P: parameter allows you to specify bit usage if the default assignments must be changed.

Use a letter after the P: to specify usage, followed by a digit (n) from 0 to 7 to specify the bit for that use. (Letters are not case-sensitive.)

  Parameter     ---- Usage ----         Default
    P:En        External Trigger        Dig In 0
    P:Dn        DDisk Remote            Dig In 1
    P:An        Averager Remote         Dig In 2
    P:Pn        Pulse Output            Dig Out 0
Make sure that inputs don't use the same bit. Pulse Output can use any bit, since it is the only output here. (However, note that it will be superceded when STIM3 Stimulus Generator DigOut is active.)


R: INPUT RANGE PRESET:

Use this parameter to specify the initial input Range control setting. This will become the initial range for all channels.

Ranges are designated with the same numbering system used by the manufacturer, but this driver only accepts bipolar ranges (odd values) since there is no particular use for unipolar ranges with Daqarta:

 R:1  =  +/- 10 V
 R:3  =  +/- 5.0 V
 R:5  =  +/- 0.5 V
 R:7  =  +/- 50mV

A typical use of the R: parameter in your configuration line would be:

 DAS20.ADC      R:5
This would specify the +/- 0.5 Volt range. If you enter any value other than 1, 3, 5, or 7, Daqarta will exit with
 'Error in R: parameter value.'

DAC OUTPUT RANGE:

The DAS-20 allows the DAC output range to be selected by means of switches on the board. Each DAC has a pair of switches that may be set to one of the following configurations:
 +/- 10 V     +/- 5 V     0 to +10 V    ILLEGAL
 .------.     .------.     .------.     .------.
 | []-- |     | []-- |     | --[] |     | --[] |
 | []-- |     | --[] |     | --[] |     | []-- |
 `------'     `------'     `------'     `------'

Note that the individual DACs may be set to different ranges. Although there is no software control over these switch settings, they are read by Daqarta and reported in the information summary available through the ALT-H Plug-In Help system.

The STIM3 Stimulus Generator uses only a single data format (unipolar or bipolar), however, which is determined by DAC0. The STIM3 output levels are set as a percent of full-scale, so it doesn't matter whether you set +/- 10 on one DAC and +/- 5 on the other (as long as you can keep them straight), but you should not mix unipolar and bipolar ranges or the DAC1 output will be grossly distorted.

That's because the unipolar range uses a simple binary format with values running from 0 to 4095, and the bipolar ranges use two's complement with values running from -2048 to +2047. So if STIM3 produced, for example, a -1 (111111111111 binary) value for a slightly negative output from a bipolar range, that same value would give a full-scale positive output (4095) from the unipolar range.


STIMULUS OVERSAMPLING:

When used with the STIM3 Stimulus Generator, DAS-20 boards can use stimulus oversampling (STIM3 Factor greater than 1). This means that the sample rate for each DAC and/or digital stimulus output is higher than the ADC acquisition sample rate by the Factor. The maximum rate (Factor times acquisition sample rate) is constrained to the limits of the ADC chip itself (100 kHz), since the board must actually acquire input data on every sample and then discard it for output-only samples.


GO:

Questions? Comments? Contact us!

We respond to ALL inquiries, typically within 24 hrs.
INTERSTELLAR RESEARCH: Over 20 Years of Innovative Instrumentation
© Copyright 1998 - 2001 by Interstellar Research - tech@daqarta.com