SERIES PMC341 PCI MEZZANINE CARD SIMULTANEOUS ANALOG INPUT MODULE
___________________________________________________________________________________________
- 12 -
MODES OF CONVERSION
The PMC341 provides two methods of analog input operation
for maximum flexibility with different applications. The following
sections describe the features of each method and how to best
use them.
Single Conversion Mode
In the Single Conversion mode, conversions are initiated by a
software or external trigger. Upon the trigger, channels 0 to 7 will
be simultaneously converted. Then, after the time programmed
into the High Bank Timer has been reached, channels 8 to 15 will
be converted. All channels enabled in the Channel Enable
Control register will be tagged with their channel number and
stored to the memory buffer. No additional conversions will be
initiated unless a new software or external trigger is generated.
To select this mode of operation bits 1 and 0 of the Channel
Control register must be set to digital code “01”. Then, issuing a
software start convert or external trigger will initiate conversions.
The Low Bank Timer is not used in this mode of operation. Also,
the High Bank Timer is not needed if channels 8 to 15 are
disabled.
This mode of operation can be used to initiate conversions
based on external triggers. This can be used to synchronize
multiple modules to a single module running in a continuous
conversion mode. The external trigger of a PMC341 “master”
must be programmed as an output. The external trigger signal of
that module must then be connected to the external trigger signal
of all other modules that are to be synchronized. These other
modules must be programmed for Single Conversion mode and
external trigger input. Also, the High Bank Timer must be
programmed with the same value on all synchronized modules.
Note that the external trigger only initiates the conversion of the
Low Bank. The conversion of the High Bank is controlled by use
of the High Bank Timer.
Data conversion can be initiated via the Start Convert bit of
the master module configured for continuous conversion mode.
Continuous Conversion Mode
In the Continuous Conversion mode, the hardware controls
the continuous conversions of all enabled channels. All channels
0 to 15 are converted at the rate specified by the Low Bank
Timer. Channels, 8 to 15, are converted after channels 0 to 7.
The time programmed into the High Bank Timer specifies how
long after channels 0 to 7 are converted before channels 8 to 15
are converted.
To initiate this mode bits 1 and 0 of the Channel Control
register must be set to digital code “10”. Then, issuing a software
start convert or external trigger will initiate the continuous
conversions of all enabled channels.
The interrupt capability of the module can be employed as a
means to indicate to the system that up to 512 samples
(depending on the threshold selected via the Threshold register)
are available to be read.
Alternatively, a polling method could be used. The Transition
Status bit (bit-8 of the Control Register) can be polled to insure
the memory buffer data is valid. The Transition Status bit will be
set when valid data is available in the memory buffer. The
Transition Status bit is cleared upon the first read of the memory
buffer and will not be set again until the memory buffers switch
again based upon the Threshold register value.
PROGRAMMING CONSIDERATIONS
The PMC341 provides different methods of analog input
acquisition to give the user maximum flexibility for their
application. Examples are presented in the following sections to
illustrate programming the different modes of operation.
Single Conversion Mode Example
This example will enable channels 0, 3, and 8 through 15 for
the single conversion mode of operation. Conversions can be
initiated via software or external trigger. Channels 8 to 15 will be
simultaneously converted 16
seconds after channels 0 and 3.
1. Execute Write of 0011H to the Control Register at Base
A 04H.
a) Single Conversion is enabled.
b) External and Software generated triggers are enabled.
2. Execute Write of FF09H to the Channel Enable Control
register at Base A 08H. This will enable channels 0,
3, and 8 through 15 for conversion.
3. Execute Write of 007FH to the High Bank Timer at Base
A 10H. Channels 8 to 15 will be converted 16
seconds after channels 0, and 3.
4. Execute Write of 0001H to the Start Convert Bit at Base
A 18H. This starts the simultaneous conversion of
channels 3 and 0. Then, 16
seconds later, channels 8 to 15
are simultaneously converted.
Continuous Conversion Mode with Interrupt Example
This example will enable channels 0 through 13 for the
continuous conversion mode of operation. Interrupts are enabled
and an interrupt threshold of 430 samples is programmed. The
Low Bank Timer will be set for an 80
second interval. The High
Bank Timer is set to activate the simultaneous conversion of
channels 8 through 13 at 23
seconds after channels 0 to 7.
Conversions can be initiated via software or external trigger.
1. Enable interrupts for the PMC module by
writing a “1” to bit 1
of the Interrupt Register at Base A 00H.
2. Execute Write of 0012H to the Control Register at Base
A 04H.
a) Continuous Conversion mode is selected.
b) External and Software generated triggers are enabled.
3. Execute Write of 3FFFH to the Channel Enable Control
register at Base A 08H. This will enable channels 0
through 13 for conversion.
4. Execute Write of 027FH to the Low Bank Timer Register at
Base A 0CH.
a) This sets the Conversion Timer to 639 decimal as
needed for an 80
second interval.