Tektronix User's Guide for CTM-PER (2Meg) Users Guide

CTM-PER
Continuous-Period
Counter
Keithley
MetraByte
Corporation
Manual Part Number: 24826
Printed: March 1990
Rev.
1.0
Copyright @ 1990
KEITHLEY METRABYTE/ASYST/DAC
440
Myles Standish Boulevard
Taunton, Massachusetts 02780
Telephone 5081880-3000
FAX
508/880-0179
Eeithley MetraByte assumes
this
product.
This
product
reliability suitable for
Information furnished
by
Keithley MetraE3yte Keithley MetraByte Corporation any infringements
is
granted
by
of
patents or other
implication or otherwise under
Eeithley MetraByte/Asyst/DAC
BasicTM
lBM@
PC,
Microsoft*
Turbo
is a trademark
is
a
registered trademark
XT,
and
AT@
is
C*
is
a
of
Dartmouth College.
are trademarks of International
a
registered trademark of Microsoft Corporation.
registered trademark of Borland International.
WARNING
no
liability for damages consequent
is
not designed
use
in
life support or critical applications.
is
believed to be accurate and reliable. However, the
assumes
of
no responsibility for the
rights
is
of
third parties
any
patent
also
referred to here-in
International Business Machines Corporation.
with
components
that
rights
Business
use
of such information nor for
may result from
of
Keithley MetraByte Corporation.
as
Keith@
Machines Corporation.
to
the use
of
a level
its
MefmByte.
of
use.
of
No
license
...
-111
*
WARRANTY
All
products manufactured
worksmanship for a period of one year from the date
product that MetraI3yte. be repaired or replaced. improper
is
found to be defective
use.
by
Keithley MetraByte are warranted against defective materials and
within
This
INFORMATION
the
warranty
warranty
of
delivery to the
period
does not apply to products damaged
will,
original
at the
purchaser.
option
of Keithley
Any
by
-
iv
-
CONTENTS
CHAPTER
1.1
1.2
1.3
1.3.1
1.3.2
1.3.3
1.3.4
CHAPTER
2.1
2.2
2.2.1
2.2.2
2.3
2.4
2.5
2.6
2.7
CHAPTER
1
2
3
INTRODUCTION
.....
.....
1-1
.....
.....
2-4
.....
.....
1-2
.....
2-1
1-1
1-3
.....
2-4
.....
.....
2-3
.....
.....
1-2
1-1
1-2
&
SETUP
2-2
.....
General
Functional Detail
Specifications
SIGNAL & GATE Inputs Crystal Clock & Counter Programmed Control
Environmental
HARDWARE INSTALLATION
Introduction
Copying The Distribution Diskettes
Procedure For Dual-Floppy Disk Computers
Procedure For Hard-Disk Computers Unpacking and Inspecting Selecting & Setting The Base Address
Hardware Installation
Cabling
Register Maps
PROGRAMMING
2-1
.....
.....
2-1
2-2
.....
2-1
3.1
3.2
3.3
3.4
3.5
3.6
3.6.1
3.6.2
3.6.3
3.6.4
3.6.5
3.6.6
3.6.7
3.6.8
3.6.9
3.6.1
3.6.1
CHAPTER
CHAPTER
APPENDIX
4
5
A
Introduction Loading The CTMPERBIN Driver Routine CALL Statement Format Use
Of
CALL Sequence Mode CALL Descriptions
Mode Mode Mode Mode
Mode Mode Mode Mode Mode
0
1
Mode Mode
CALIBRATION & TEST
FACTORY RETURN INFORMATION
SUMMARY
.....
3-1
.....
3-2
The CALL Routine
.....
.....
3-3
_....
0
-
Initialize
1
-
StartlStop Clock
2
-
Setup GATE, Edges, Scaling
3
-
Data Collection, Single
4
-
Data Colection, Multiple
5
-
Data Collection, Multiple Delta
6
-
Data Collection Via Interrupt
7
-
Delta Collection Via Interrupt
8
-
Data Collection
9
-
Transfer From Memory To Array
10
-
Monitor Status
OF
.....
ERROR
3-4
CODES
3-2
3-4
..._.
Via
.....
3-4
.....
DMA
3-1
1
.....
.....
.....
.....
3-6
3-7
.....
.....
3-9
.....
3-8
3-1
3-5
3-8
3-9
.....
3-10
APPENDIX
B
CTM-PER: PASCAL, C, FORTRAN DRIVERS
-v-
FOR
CTM-PER
CTM-PER
CHAPTER
1
-
INTRODUCTION
Chapter
1
INTRODUCTION
1.1
GENERAL
The
CTM-PER
signal. review, analysis, etc. For example, the results can consecutive measurements.
TIl depends on frequency limits of the computer. In some computers, the upper frequency limit no more
An
to set up the board, to determine data formats for the array. The distributed software also contains use with BASIC, QUICKBASIC, examples and utility setup programs
The
signal frequencies may range from
important part of the
CTM-PER
(V4.0-5.1),
(V3.0-5.0),
higher), and GW, COMPAQ, and
is a PC-computer accessory board for monitoring timing changes in an on-going
board measures consecutive
than
20
KHz.)
CTM-PER
specify
start/stop parameters for board operation, to control data
PASCAL,
software supports all common memory models for the following languages: Microsoft
Microsoft
Microsoft
Quick-C
FORTRAN
(V1.0-2.0),
W4.0-5.0),
IBM
periods
0
(DC)
package is the distributed software. The software enables the user
with
Turbo C (V1.0-2.0), Microsoft Pascal
BASIC (V2.0 & higher).
of a
lTL
be
presented to the PC monitor in
to
80
KHz.
C,
and
FORTRAN.
sources.
Lahey Personal
signal and makes the results available for
The
80KHz
In addition, there are commented
upper frequency limit actually
CALL
subroutines for
(V3.0-4.0),
Fortran
(V1.0-2.0),
QuickBASIC
an
array of
flow,
Turbo Pascal
(V4.0
lTL
will
and to
be
C
&
Typical of a rotating sensor. BNC connectors labeled SIGNAL and GATE are available at the board's rear plate. GATE can
can measure the timing of positive, negative, or both edges.
1.2
CTM-PER
applications include monitoring a Doppler signal and measuring output intervals
be
programmed
FUNCTIONAL DETAIL
10
Mnz
CRYSTAL
DIP SWITCH
with
selective polarity and used to enable measurements. SIGNAL
I
I
4
PC'BUS INTERFACE1
OPTOCOUPLER
I
11
SIGNAL
GATE
Figure
1-1.
Block
diagram
of
the
CTM-PER
Board.
Introduction
-
1
-
1
CHAPTER
The register, as shown in Figure signal edge, it loads the value of the 2Sbit counter and the state of the GATE and
(First
values to load into While
backup. the four-value limit causes an overrun error.
Load hold no more than four counter values); it is a function detects level changes and is limited to
Unload DMA (Direct Memory Access) technique yields a
period
about 26.8 seconds. Information about
counter values. Because the clock
1
-
INTRODUCTION
CTM-PER
In,
FIFO
speed
speed
being
relies on an internal, crystalcontrolled,
1-1.
It detects a signal edge by sensing a change in level.
First Out) memory as four bytes (32 bits). Succeeding level changes cause successive counter
FTFO
memory.
memory loads and unloads continuously, a slowing of the unload rate can cause a
FIFO
memory can hold a backup of up to four counter values. Any attempt to load beyond
is a factor only while
depends on the technique for unloading
speed
range
timed
can
be
considered as the roll-over time for the 10
a
measured period or interval
FIFO
memory is holding less than four counter values (F'IFO can
1.0
MHz.
is
the fastest technique and is the one used by the
of
20KHz to
is
IOMHz,
80KHz,
the resolution of the period is
lOMHz
of
FIFO
depending on the computer. The lower limit
oscillator clock and a 28-bit up-counter
the rate at which the on-board state machine
and storing data in computer memory.
MHz
is
taken from the difference between
CTM-PER
On
detecting a
SIGNAL
CTM-PER.
clock and the 28 bit counter:
0.1
microsecond.
into
two
consecutive
FIFO
This
of
a
Total data accumulation is limited only by total computer memory (or disk capacity if a product like MetraByte's by two factors: the speeds at which
1.3
SPECIFICATIONS
1.3.1
1.3.2
SIGNAL
CoMectOrs: SIGNAL/GATE High-Level Input Low-Level Input High-Level Input Current Low-Level Input Current Absolute Maximum Input Protection: Transient Immunity:
Isolation Voltage:
Crystal
STREAMER
and
Common Mode)
Clock
is used to stream data onto disk). The upper limit of frequency
FIFO
memory loads and is unloaded.
GATE Inputs
Type:
BNC
(2)
Load:
Inpur
1
LSTTL
2.0
VDC
0.8
VDC
40
pi4
-0.4
7
VDC
100
5000
500
mA
ohms
VDC
UNIT
LOAD
(minimum)
(maximum)
(maximum)
(maximum)
in
series with
V/us
(min)
(Input
to
computer)
input
and
and Counter
6.8
V
Zener
is
controlled
Frequency: Frequency Stability:
Measurement Resolution: Measurement Rollover: Measurement
1-2
-
Introduction
Bits:
1o.Ooo
MHZ
+/-0.01%
0.1
microsecond
26.8
seconds
28
(+/-lo0
ppm)
CTM-PER
ChXPTER
1
-
INTRODUCTION
1.3.3
1.3.4
Programmed
GATE:
Minimum
Signal Maximum Signal Frequency:
Data
Interrupt Levels:
DMA
GATE
Edges:
Acquisition
Levels:
Environmental
Operating Temperature:
Bus:
Power Requirements:
Control
Trigger
Modes:
Positive, negative,
100
nsec.
Positive, negative, or
1
.O
MHz
(burst
(Computer dependent)
Programmed,
2,3,4,5,6,7,
1,3,
or none
0
to
50
Degree
IBM
K/XT
+5
VDC
@
or
of
4),
interrupt,
or
none
Celcius
Compatible
600
mA (typical)
none
both
20
to
or
80
KHz
DMA
(continuous
DMA)
Introduction
-
1
-
3
CTM-PER
CHAPTER
2
-
INSTALLATION
&
SETUP
Chapter
INSTALLATION
2.1
CTM-PER
available on a use, not for resale.
Installation of your CIU-PER Software will require the following procedures:
2.2
Make working copies in a safe place.
suits
disk
2
&
SETUP
INTRODUCTION
distribution software is on a
3.5"
diskette.
Making a working copy of your CTM-PER Distribution diskette(s). Unpacking and inspecting the board. Selecting a Base Address for your CTM-PER driver board. Installation.
COPYING
your particular computer configuration. The first procedure is for a computer with dual floppy-
drives, the second is for a computer
THE
DISTRIBUTION DISKETTES
To
copy the Distribution diskette(s1,
This
of
your CTM-PER Distribution Software diskettek) and store your original copy
5.25",
360K
floppy diskette
software is licensed to permit multiple copies for non-commeraal
use
a procedure (from the
with
both a floppy- and a hard-disk drive.
(DOS
2.10
format); it is
two
that follow) that
also
2.2.1
2.2.2
Procedure
With your your computer on and booted, place your
1.
the A Drive.
Log
2.
3.
4.
6.
7.
8.
to the A Drive by typing
At
the
Insert the sourcediskette (the CTM-PER Distribution diskette) into the A Drive. The system will prompt you through the disk copying process, asking the
B
When you have completed copying, the computer will ask
If
you are copying two diskettes, respond by typing
Y
<Enter> and follow the prompts to copy the second diskette. Otherwise,
Put the original CTM-PER diskettds) in a safe place for storage. Then label your back-up disk(s) as your CTM-PER working copies.
Procedure
With your computer
1.
files. (In most The following instructions create
2.
you prefer a name other than
(immediately following). to that directory, and
DOS
Drive.
for
Dual Floppy-Disk Computers
A:
<Enter>
A>
prompt,
for
Hard-Disk Computers
cases,
type
&DISKCOPY
on
and booted, log to the drive to
this will
go
be
the C Drive.)
a
directory named
W,
substitute your preference in place
If
you intend to use an existing directory,
to Step
3.
A:
B:
<Enter,
DOS
disk containing
you
COPY
be
used for your
CTlM
for the
to insert the
ANOTHER
CTM-PER
CTM-PER
of
skip
these instructions, log
DISKCOPY.EXE
target
(Y/N)?
type
N
Distribution files. If
CTMin
in
diskette into
<Enten.
Distribution
Step a.
a.
Make a
b.
Change to the
CTM
subdirectory by typing
CTh4
directory by typing
MD
CTM
CD
<Enter>
CTM
<Enter>
Installation
&
Setup
-
2
-
1
CHAPTER
2
-
INSTALLATION
&
SETUP
CTM-PER
Place the
3.
Type
3.
If copying
5.
With the safe storage area.
2.3
UNPACKING AND INSPECTING
After you remove the wrapped board from its outer shipping carton, proceed as follows:
1.
2.
3.
4.
You
factory.
CTM-PER
Place one hand firmly on a metal portion of the computer chassis (the computer must Off and grounded). package and your body, thereby preventing damage to board components.
Allow
wrapping material.
Inspect
factory. Check the contents of your mM-PER package against its packing list to
complete. Report any missing items to MetraByte immediately.
may find it advisable to retain the packing material in case the board must
CTU-PER
the copy-all-files command, as
two
Distribution files copied to your hard drive, put the original Utility Diskette(s) in a
a
moment for
the board for signs of damage. If any damage is apparent, return the board to the
Distribution Disk into a floppy Drive
COPY
diskettes, repeat Steps 3 and 4 for the second diskette.
You
place your hand on the chassis to drain off static electricity from the
static
electricity discharge; carefully unwrap the board from its anti-static
&*.*
<Enter>
A.
be
be
be
turned
sure the order is
returned to the
2.4
SELECTING AND SETTING
The
CTM-PER
locations are already occupied by internal I/O and other peripheral cards, you have the option of resetting the Base Address switch is located as shown in Figure Referring to Figure shown).
requires four consecutive address locations in 1/0 space. Since some 1/0 address
CTM-PER
I/O
base address by means of an on-board Base Address
2-2,
you set the base address on a four-byte boundary to
THE
BASE ADDRESS
2-1,
DIP
DIP
and it appears as shown in Figure
3FC
Hex
7
SWITCH
switch. The
(300
I
2-2.
Hex is
SIGNAL
GATE
2
-
Q
2
-
Figure
Installation
2-1.
CTM-PER
&
Setup
board
outline,
showing
Base
Address
switch
I
location.
CTM-PER
CHAPTER 2 -
INSTALLATION
&
SETUP
Figure
The board is preset for a base address of address is not satisfactory, your distribution software contains a program called called base address and shows a picture of Use
this
program by logging to its location (to the floppy drive containing the distribution diskette or to the harddrive directory containing your distribution files) and typing
When the computer responds with format and press
2.5
HARDWARE INSTALLATION
To
install the CTM-PER in a PC, proceed as follows.
WAR"G:
Turn
1.
2.
Off
Remove the cover of the PC as follows: First remove the cover-mounting
of
panel Finally, tilt the cover upwards and remove.
the computer. Then, slide the cover of the computer about
2-2.
Base
Address
DIPSW.EXE
the
DIPSW
Desired
<Enfer>.
ANY
ATTEMPT
COMPUTER POWER ON COULD DAMAGE
power to the
TO
PC
and all attached equipment.
switch.
300
HEX.
that asks for
DIP
switch
base
address?,
INSERT
OR REMOVE
If this
setting.
type
your choice in decimal or
ANY
ADAPTER BOARD
YOUR
COMPUTER!
screws
3/4
of
the way forward.
IBM
WITH
from the rear
&H-
THE
Choose an available option slot. Loosen and remove the screw at the top of the blank adapter
3.
plate. Then slide the plate up and out to remove.
4.
Hold the CI'M-PER chassis (but not on any components). This will safely discharge any static electricity from your body.
Make sure the board switches have been properly
5.
Align the board connector with the desired accessory slot and with the corresponding rear-
5.
panel slot. Gently press the board downward into inserting the rear-panel adapter-plate screw.
Replace the computer's cover. Tilt the cover up and slide it onto the system's base,
7.
of
the front
screws.
Plug
8.
MetraByte recommends that you retain the static-shield packaging for possible future removal and handling
2.6
CABLING
Connect
labelled SIGNAL.
software, this connector can
of
the cable carrying the
the
in all cords and cables.
the
CTM-PER
BNC
board
in one hand placing your other hand on any metallic part of the PC
set
(refer
to
the preceding section).
the
socket. Secure the board in place by
making
cover is under the rail along the front of the frame. Replace the mounting
Turn
the power to the computer back on.
board.
TTL
Connector
be
left open.
signal to
J2
(GATE) is an optional
be
monitored to BNC Connector
?TL
input. If GATE is not enabled in
J1
(Figure
2-1),
sure
which is
Installation
h
Setup
-
2
-
3
CHAPTER
2.7
Board Address + 0:
READ:
READ:
2
-
INSTALLATION
REGISTER
MAPS
I
C3
I
C11
I
I I I I
C2
1
I
C10 C9
&
SETUP
C1
CO
I
C8
GTI 'SGl
I
I
C7 C6
'0
I
C5
I
CTM-PER
I
0
I
C4
READ:
READ:
WRITE:
Board Address
I
Cl9 ICl8 IC17 ICl6
I
1
C27
C26
FIFO
DATA
1st
=
LS
2nd
=
3rd Byte Count (2A1 1
3rd
=
2nd Byte Count (2"19
4th
=
MSB
SG/
=
l/O
of
1
->
Falliig Edge Trigger (negative signal trigger),
0
->
Rising Edge Trigger (positive signal trigger).
GT/
=
O/l
of
I
I
+
1
:
(Not
Used).
'CIS
'C14
IC13
I
1
1
I
C25
@ata
C24
stored
C23
as
4
Bytes).
C22
I
C21
Nibble Count + GATE + SIGNAL.
to
2q).
to
2A12).
Count
(2A27
u)
2"20).
signal after Trigger,
GATE after Trigger.
I
I
I I
1
'C12
I
C20
I
I
1
I
Board Address
READ:
WRITE:
2 - 4
-
Installation & Setup
+
2:
I
I
CLR
r
CLR
OVR
I
-
CLR = CLEAR;
1
->
Co~nter~ Count
OW
=
OverRun
GPL = GATE Polarity;
=
GTE GAT SIG
TEN
TST
S1=
SO
GATE Enable;
=
GATE,
=
SIGNAL; 1/0
=
0
=
Stop
Single or
=
Positive or Negative
I
GPL
I
GPL
1/0
->
GATE used
signal,
Dual
I
I
Error,
I
I
TEN
Count
->
FIFO
->
GATE
GATE
Trigger,
data
I I
SIG
I I
TST
to
0,
+FIFO
overrun
used,
collection,
GTE GAT
GTE
0
->
(Normal)
1
1/0
1
->
->
GATE Level at Trigger.
->
SIGNAL Level at Trigger.
as
0
->
Stop
Edge Signal Trigger;
Signal
Trigger,
FIFO
l/O
1
->
I
1
SO
SO
1
'
S1
S1
cleared and
Nom~al.
occurred
to
count, 0/1 to hold.
0
->
GATE
0
->
0
->
since
GATE ignored.
used
as
1
->
Collect. Single, Positive,
OVR
CLEAR.
gate.
1
->
Dual.
1
->
Negative.
to
0.
CTM-PER
CHAPTER
2
-
INSTALLATION
&
SETUP
Board
READ:
WRITE:
Address
+
3:
I
I
DOR
IT/
1
I
DOR
=
lT/
=
INTERRm,
DME = DMA
LEV
=
INE = INTERRUPT
INTERRUPT
IL2,
ILl,
OOO
001
010
011
I
I
0
->
0
I
Interrupt
1
->
DME LEV INE
I
DME 'LEV IINE
DATA-OUT-READY;
ENABLE;
DMA
LEVEL;
ENABLE
ENABLE
M3
=
INTERRUPT
->
->
->
->
None NOW
IRQ2 IRQ3
100 101 110
111
1
IL2
'112
1
->
Data
pending.
->
Enable
Level 1,l
on
data
on
TC
(if
LEVEL;
->
IRQ4
->
IRQS
->
IRQ6
->
IRQ7
I
IL1
I
IL1
In
FIFO.
DMA,
0
->
Level
(if
not
DMA); 1
I
ILO
I
ILO
->
Disable.
3.
DMA);
->
Enable,
I
I
0
->
Disable.
Installation
&
Setup
-
2
-
5
CTM-PER
CHeER
3 - PROGRAMMING
Chapter
3
PROGRAMMING
3.1
INTRODUCTION
The
CTM-PER
these are the have equivalent instructions.
To
simplify program generation, the distribution software contains the I/O driver routine
CTMPERBIN.
covers the majority of common operating modes. The benefits of using CT"ER.BIN are largely in significant reduction of programming time.
driver
also
or
DMA
available only by using the CALL routines.
3.2
LOADING THE CTMPER.BIN DRIVER ROUTINE (BASIC)
To
use
the CTMPER.BIN driver, load it into memory. Avoid loading it over any part
by another program.
is programmable at the lowest level using input and output instructions.
INPW
supports data collection on interrupt or DMA. Note, however, that BASIC
processing functions, and so-called
and
OUT
X,Y
functions. Assembly language and most other high level languages
This
routine is accessible from BASIC using a single-line CALL statement, and
background
An
example of loading this routine using IBM BASIC is as follows:
data collection using these methods is
In
BASIC
it
The
has
no interrupt
of
memory used
100
CLEAR, 48'1 024
110
DEF SEG=O
SG=256'PEEK(&H511)+PEEK(&H510)
120
SG=SG+48'1024/16
130
DEF SEG=SG
140
BLOAD "CTMPER.BIN",O
150
CTM
160 170 180
A
second option applies when you have memory outside the BASIC workspace; it should
non-IBM BASIC (when the
21 0 DEF SEG=&H7000 220 BLOAD "CTMPER.BIN",O
230
240 DIM D%(15) 250 FIAG%=O
Before you enough for the CTMPER.BIN file) at the location in line
SEG=&H7000
with another program's use of the memory results in a failure to exit and return from the routine. The computer
Try
a different memory location until the program works.
PER=O
DIM D%(15) 'DECLARE ARRAY FLAGY-0 'DECLARE VARIABLE
CTMPER=O
try
loading outside the workspace,
and experiment with loading the CALL routine at other locations. Usually any clash
hangs
up, and the only cure is to switch
PEEKS
of line
120
above will not work).
be
'CONTRACT WORKSPACE 'BASIC WORKSPACE SEGMENT
'LOAD
'LOAD IN ASSEMBLY DRIVER 'DECLARE ARRAY
'DECLARE VARIABLE
sure
you
OFF,
IN
ASSEMBLY DRIVER
really do have unused memory (large
210.
You
can change the line
wait a few seconds, and
TO
48K
210
turn
on the power.
be
DEF
used for
Programming
-
3
-
1
CHAPTER
3.3
CALL STATEMENT FORMAT (BASIC)
3
-
PROGRAMMING
CTM-PER
Prior to entering the subroutine is located. The
xxxxx
CALL
CTMPER(MD%,
C"ER
statement. In of the
The three variables within brackets are Mode, as described
(pointers) are passed pointers from the stack and exchanged. Four important format requirements must
1.
2.
3.
is the address offset from the current segment of memory,
CALL
routine.
The
CALL
variables, just their locations from the order always
(mode, data, errors)
The
CALL
the variables on this basis.
You
cannot
statement. For example, the following is an
CALL,
all
the examples, the current segment is defined to correspond with the starting address
in
parameters are positional. The subroutine knows nothing of the names
be
written in the correct order:
routine expects its parameters to
perform
the DEF SEG=SG statement sets the segment address at which the
CALL
This
offset
the following sections.
in
the sequence written to
statement for
D%(O),
FLAG%)
is
therefore zero and
known
the
C"ER.BIN driver must use the form:
as the
On
executing the
BASICS
uses
them
to locate the variables in
of
be
any arithmetic functions within the parameter list brackets of the
illegal
CALL
as
defined in the last DEF SEG
CTMPER=O
CALL
parameters; their meaning depends on the
stack. The
be
met:
their pointers on the stack. The parameters must
integer-type Variables and will write and read to
(see
CALL,
CALL
BASIC's
line
160).
the addresses of the variables
routine unloads these
data space
so
data can
be
of
the
CALL
statement:
CTMPER(MD%+2,D%(0)+8,FLAG%)
CALL
4.
You
cannot
following is
CALL
Apart from these restrictions,
examples are just convenient conventions. Strictly,
CALL.
the
3.4
USE
OF
The following Modes. Note that scaled by a power of two and stored as
MD%
parameter in the
MODE
(MDI)
0
1
use
constants for any of the parameters in the
an
illegal
CTMPER(7,2,FLAG%)
statement:
you
can name the integer variables what you want; the names
THE CALL ROUTINE
subsections
delta
contain details and examples of using the
is
defined
CALL
Initialize, store Start the counter or to stop
interrupts and/or
as
the difference between the current and last data value; the
as follows:
16
bits (an unsigned integer). The Modes are selected by the
FUNCTION
CTM-PER
DMA.
CALL
statement. For example, the
you
should declare the variables before executing
CALL
routine in all ten
base
address, interrupt level, and
the
counter and stop data collection.
(continued on next page)
DMA
in
the
CTM-PER
deZta
level.
shuts
down
is
3
-
2
-
Programming
~ ~ ~~ ~
CTM-PER
CHAPl'ER
3
-
PROGRAMMING
MODE
Note that the mode used for data collection depends on what else the computer is computer's user computer and application program in order to establish full performance details.
@ID%)
2
3
4
5
6
7
8
9
10
speed,
vary
the signal frequency, monitor the overrun error, and check the data for his/her particular
and the
Setup gate, edge, and scaling parameters. Start data collection and return next data. Start data collection and return array of data. Start data collection and return array of deltas. Start data collection of data into memory via interrupt. Start data collection of deltas into memory via interrupt. Start data collection of data into memory via DMA. Transfer data/delta from memory into array. Check status of data collection.
speed
of the signal being measured. In all cases,
FUNCTION
it
is recommended that the
doing,
the
MODE MODE SPEED
3,43
67
8
3.5
CALL
Mode 0 must always terminate interrupt or
2
must be called at least once before starting data collection. The normal minimum sequences
are
SEQUENCE
as
follows:
slow (several hundred Hertz) medium (several thousand Hertz) high (up to
be
called initially. Mode
DMA
operation when an operation
PROGRAMMED COLLECTION
MODE
0
20
to
80
KHz)
1
is
optional to start
the
sequence and should be used to
is
aborted before normal completion. Mode
OF
DATmELTA
I
MODE MODE
I
2
3,4,
or
5
of
calls
Programming
-
3-3
Loading...
+ 34 hidden pages