User’s Manual
31
PART 1 AD268
6. Parameters
6.3 Sample program for setting the parameters
A sample program to set the parameters is shown below.
This is an example to set the input type as 0 to 10V range (type = 1) for each channel.
In this sample program, it is assumed that he AD268 is allocated to XW000 to XW007.
For details of READ and WRITE instructions, refer to the T-series Instruction Set manual.
(Main program)
In this sample program, the rung 1 is activated at the beginning of RUN mode (at the second
scan) automatically. The input type is set to 0 to 10V for all 8 channels.
When the parameter setting process is completed, the flags R1000 to R1002 are returned to
OFF.
For reading the parameters from the AD268, there is no special procedure. Simply read the
data from the AD268’s buffer memory by using READ instruction.
Step (1):
Writes 0 into the
command
register (H8020).
Step (2):
Writes parameters.
•
Gain = 32000
•
Offset = 0
•
Average = 1
•
Type = 1 (0-10V)
Total 32 words
starting with
Step (3):
Writes 1 into the
command
register (H8020).
Step (4):
Waits until the
response
register (H8021)
comes 1.
Step (5):
Writes 0 into the
command
register (H8020)
to return to initial
state.
(H8020)
(H8000)
(H8020)
(H8021)
(H8020)
CTi Automation - Phone: 800.894.0412 - Fax: 208.368.0415 - Web: www.ctiautomation.net - Email: [email protected]