Operator`s manual

SECTION 12. PROGRAM CONTROL INSTRUCTIONS
12-6
the start of the instructions to execute if the test
condition is false (Figure 3.8-1). The Else
Instruction is optional; when it is omitted, a false
comparison will result in execution branching
directly to the End Instruction. Instruction 94
has no parameters.
*** 95 END ***
FUNCTION
Instruction 95 is used to indicate the end/return
of a subroutine (Instruction 85), the end of a
loop (Instruction 87), the end of an If Then/Else
sequence, or the end of the Case statement
(Instructions 88-93 when used with command
30). The End Instruction has no parameters.
*** 96 ACTIVATE SERIAL DATA OUTPUT ***
FUNCTION
Instruction 96 is used instead to activate the
tape, Storage Module, or serial port output. By
using Program Control Instructions to allow
execution of Instruction 96 only at certain times,
the user can control when the output is active.
When used to send data to the SM192 or
SM716 Storage Module, the 21X can determine
whether or not the Storage Module is
connected. If the Storage Module is not
connected, the data will not be sent until it is
connected. Instruction 96 also allows for faster
data output via the serial port with the Binary
Option, which outputs FINAL STORAGE
FORMAT (2 bytes per low resolution data point)
instead of ASCII (10 bytes per data point,
Section 4.5). Appendix C describes FINAL
STORAGE FORMAT. Section 4.3 describes
Tape output.
A single parameter is used to select whether the
instruction is to control the tape, Storage
Module, or the printer output, and if the printer is
selected, the format and baud rate. Instruction
96 must be entered separately for each output
device used.
Instruction 96 uses the same Tape and Printer
pointers as the *8 and *9 modes which can be
used to get a residual or partial dump of Final
Storage (Section 4). Note that the Tape output
will not activate until at least 512 Final Storage
Locations have been stored.
Do not use *4 to activate a device that is
activated by Instruction 96.
PAR. DATA
NO. TYPE DESCRIPTION
01: 2 The left digit specifies the Option
and the right specifies the baud
rate for the printer. The code for
tape must be 00, and for
Storage Module it is 30.
Option X = Baud Rate
00 -- TAPE 0 -- 300
1X -- PRINTER, ASCII 1 -- 1200
2X -- PRINTER, Binary 2 -- 9600
30 -- SM192 or SM716 3 -- 76,800
31 -- Send filemark to SM192/716
*** 97 INITIATE ***
TELECOMMUNICATIONS
Instruction 97 is used to have the 21X initiate
telecommunications in response to certain
conditions. When the instruction is executed
with the interrupt disable flag set low, the 21X
will make a call and send the ID number
specified in Parameter 8 (in ASCII at the
specified baud rate). The ID number will be sent
every 4 seconds until the 21X receives a
response or the time specified in Parameter 3
expires. The expected response is to have the
ID sent back to the 21X, at which time the 21X
will go into telecommunications and the normal
telecommunications time limit will take effect
(Section 5.1). The 21X will not send any data
without first receiving a command to do so. The
TELCOM program in Campbell Scientific's
PC208 datalogger support software enables IBM
PC/XT/AT/PS2 and compatible computers to
automatically answer calls and retrieve data.
When the 21X receives a correct digit for the ID,
it restarts the 4 second timer. There are then 4
seconds in which the next digit must be received
before the 21X again sends the ID. When the
21X sends the ID, it expects the response to
start from the beginning. If an incorrect
character is detected, the 21X will immediately
send the correct ID. If a correct response is not
received within the time allotted in Parameter 3,
the 21X will hang up.