Copyright: ® 1995-2000 Campbell Scientific, Inc.


Programming with Edlog (CR10X)
Programming with Edlog (CR500)

You can use Edlog to create, document, and edit custom datalogger programs.  The topics are selected by clicking the mouse's left button or by pressing the Tab key and then the Enter key:

Getting Started

Step #1 -- click on File|New and select your type of datalogger

Step #2 -- enter an Execution Interval (seconds) for Table 1

Step #3 -- place the cursor on the blank line below the Execution Interval and click on Edit|Insert Instruction

Step #4 -- enter your required instructions in a logical sequence

HELP Navigational Aids

•	Menu Notation

•	Option Selection

•	Enable Options

Edlog Navigational Aids

•	Editor Keystrokes

•	General Input Location Information  (here is some required reading)

•	General Repetition Information

•	Instruction List -- Input/Output  (typically entered in the beginning of the program)

•	Instruction List -- Processing  (typically entered after the Input/Output Instructions)

•	Instruction List -- Output Processing  (typically entered toward the end of the program)

•	Instruction List -- Program Control (enter these where they do the most good)

•	Entering Comments

•	Entering Expressions

•	Errors And Warnings

•	Trace and Final Storage Label Files

•	Indexing Parameters

•	Creating a Library File

•	Selecting a Library File


Duplicate Location Name Error

Your program contains input locations that have the same label but different input location numbers.

For your program to run as expected, you MUST edit your input location labels so that they have unique labels.  The easiest method to catch the duplicate names is to use Edit | Input Labels.

If you loaded a program that was created using an earlier version of Edlog, this error might be the result of a version conflict.  Some earlier versions of Edlog allowed the character '#' to be used in the Input Location Label.  This version does not allow that character and automatically changes labels with that character to have a '_' instead.


Maximum Number of Input Locations is 9999

You have tried to create too may input locations.  You should edit your program to include a smaller number of input locations.


Version Conflict

You have just loaded a program that was created using an earlier version of Edlog.

Your earlier version of Edlog allowed the character '#' to be used in the Input Location Labels.  This version does not allow that character and has automatically changed labels that included that character to have a '_' instead.


Editor Keystrokes

 Keystroke	Description

 PgUp	Page up

 PgDn	Page down

 Enter	Move to next field or create new line

 <shift> Ins	Select an instruction from a dialog box

 <shift> Del	Delete the instruction or line under the cursor

 Up Arrow	Move up one line

 Down Arrow	Move down one line

 Right Arrow	Move one character right

 Left Arrow	Move one character left

<Esc>	Close dialog box

 <ctrl> n	Comment out a line or instruction (see Comments)

 <shift> <ctrl> n	Uncomment a line or instruction (see Comments)

 <end>	Add a comment to the right of the text (see Comments)

<ctrl> Home	Move cursor to beginning of file

 <ctrl> End	Move cursor to end of file

 <ctrl> PgUp	Move cursor to top of screen

 <ctrl> PgDn	Move cursor to bottom of screen

<ctrl> Right Arrow	Indent  instruction one tab right (cursor on parameter)

<ctrl> Left Arrow	Move instruction one tab left (cursor on parameter) or move from input location label to input location number

@	Marks the parameter for *4 mode


Indexing Parameters

Some parameters can be indexed.  The function of indexing varies according to the parameter.  See help for individual instructions to determine what parameters can be indexed.

To index a parameter, press the F4 function key while in the numeric or label field of the parameter, or the C key while in the numeric field of the parameter.  Two dashes will be displayed after the entry indicating the parameter has been indexed.

Pressing the respective key when a parameter is already indexed will toggle the index off.


Entering Comments

Comments are text that is ignored by the compiler.

Typically comments are added to make the program easier to read.  The compiler considers any line of text that has a semicolon as the first character to be a comment.

If you press <ctrl> n or select Edit|Comment while the cursor is on an instruction, the entire instruction will become a comment and will be ignored by the compiler.  By pressing <shift><ctrl> n or selecting Edit|Uncomment, the instruction will no longer be a comment.

Comments can also be added to the right of an instruction or an instruction's parameter.  This is accomplished by pressing the <end> key while the cursor is on the instruction or the instruction's parameter.


Expressions

Definition

Expressions are used to process numbers and input data.  When a datalogger program that contains an expression is compiled, the appropriate instructions are automatically incorporated into the .DLD file.  A variable number of input locations will automatically be assigned as "scratch pads" to store intermediate expression results.

Expressions can be entered anywhere in the table after the execution interval.

Entering Expressions

The following are the rules for entering expressions.  For more information, please see expression examples.

•	Expressions must be set equal to the label of the input location that will store the result.  The label must be to the left of the expression (e.g., label = expression).

•	Expressions can have both fixed numbers and input location labels.  Input locations can ONLY be referenced by their label; each number is always assumed to be a constant.

•	Fixed numbers are limited to five digits not including negative signs and decimal points.

•	Negative numbers should be enclosed in parentheses.

•	Fixed numbers can be entered in Scientific Notation (e.g., 25e3 = 25000, 6e(-1) = 0.6).  Like fixed numbers, the mantissa is limited to five digits.  The largest and smallest numbers that can be entered and processed are 9e18 and 1e(-19), respectively.

•	The operator(s) and/or function(s) used in the expression must be on the operator or function list.

•	Numbers and labels that are immediately after a function must be enclosed in parentheses.

•	Several operators and/or functions can be used in one expression.  Operations and functions that are enclosed in parentheses are calculated first; the inner most parentheses are evaluated first.

•	To continue an expression to the next line, type an _ at the end of the first line.

•	Expressions can have up to 255 characters

•	Expressions cannot be indexed.

Note:  The largest and smallest numbers that can actually be stored in an input location are 9e18 and 1e(-19), respectively.  However, PC208W's numeric monitor can only display five digit numbers (six with a leading zero).  If a location contains a number greater than 99998 or less than -99998, a 99999 or -99999 will be displayed, respectively.  If a location contains a number with more than five digits, the number displayed will be truncated from the right (e.g., 1234.56 will be displayed as 1234.5).


Operator & Function Lists

Operators  (see also expression examples)

*	multiply

/	divide

+ 	add

- 	subtract

^ 	raise to the power of

@ 	modulo divide

Functions  (see also expression examples)

COS	cosine (angle in degrees)

SIN 	sine (angle in degrees)

TAN 	tangent (angle in degrees)

COTAN 	cotangent (angle in degrees)

ARCTAN 	arctangent (angle in degrees)

ARCSIN 	arcsine (angle in degrees)

ARCCOS 	arccosine (angle in degrees)

ARCCOT 	arccotangent (angle in degrees)

SQRT 	square root

LN 	natural logarithm

EXP 	exponent of e (EXP(2) = e^2).  Exponents are limited to two characters and cannot include a decimal.

RCP 	reciprocal (RCP(4) = 1/4 = 0.25)

ABS 	absolute value

FRAC 	takes the fraction portion (FRAC(2.78)=.78)

INT 	takes the integer portion (INT(2.78)=2)


Expression Examples

Below are examples of valid expressions:

Zee = Vee+Ex

Root = SQRT(ABS(data))

avg = (data1+data2+data3+data4+data5)/5

length = SQRT((adj^2)+(opp^2))

TempF = (TempC*1.8)+32

Program Example

Below is a section of a datalogger program that uses an expression to convert Temperature from Celsius to Fahrenheit:

 Execution Interval = 10 sec

  1: Temperature (107)  (P11)

   01:   1    REPS

   02:   2    Channel

   03:   1    Excitation Channel

   04:   2    Loc [TempC]

   05:   1    Mult

   06:   0    Offset

 TempF = (TempC*1.8)+32

When this program is compiled, the .DLD file contains the following instructions.  The last 5 instructions calculate the expression.

 1:P11 (Temperature, 107)

  1:1

  2:2

  3:1

  4:2

  5:1.0

  6:0.0

 2:P31 (Z=X)

  1:2

  2:5

 3:P30 (Z=F)

  1:1.8

  2:0

  3:3

 4:P36 (Z=X*Y)

  1:3

  2:5

  3:5

 5:P30 (Z=F)

  1:32

  2:0

  3:3

 6:P33 (Z=X+Y)

  1:3

  2:5

  3:6


Modulo Divide and Expressions

Divides one number into another and stores the remainder.

Modulo divide expressions require a constant (floating point number) after the operator.

Examples:

When the expression is:    data=13@10,

the input location 'data' stores a 3.

When the expression is:    Value = 5@2,

the input location 'Value' stores a 1.

When the expression is:    amount=10@2,

the input location 'amount' stores a 0.


Errors and Warnings

Errors and warnings occur after a file has been compiled in Edlog, and Edlog detects situations that might cause problems when the compiled program is downloaded to the datalogger.  However, a program may compile successfully in Edlog, and produce a compiler error when downloaded to the datalogger.  If this occurs, you'll receive the message "Failed DLD Transfer" along with an "E" number.

Errors

•	CR500 was reset by watch dog timer

•	Decimal not allowed in an exponent

•	Duplicate *4 ID (see Using Mode 4)

•	Duplicate Subroutine

•	ELSE in SUBROUTINE without IF

•	ELSE without IF

•	Empty program

•	END without IF, LOOP, or SUBROUTINE

•	Equal sign expected

•	EXIT LOOP without LOOP

•	Exponents limited to 2 digits

•	Expression has more than 255 characters (see Entering Expressions)

•	Floating Point Numbers limited to 5 digits

•	Function expected

•	IF CASE without BEGIN CASE

•	IFs and/or LOOPs nested too deep

•	Improper nesting of IFs and/or LOOPs

•	Inadequate Input Storage

•	Instruction 3 and interrupt subroutine use same port

•	Insufficient Input Storage

•	Intermediate Storage full

•	Missing END

•	Missing left parenthesis (see Entering Expressions)

•	Missing parameter

•	Missing right parenthesis (see Entering Expressions)

•	New line expected

•	No ELSE on error check stack

•	Nonexistent SUBROUTINE (see Command Codes)

•	Number expected

•	Right side of MOD operator allows constants only

•	Subroutine encountered before necessary END

•	Subroutine found in main program

•	Subroutines Nested too deep

•	Unable to decode execution interval (see Execution Interval Error)

•	Unknown Compiler Error

•	Unknown instruction

•	Unrecognized table

•	Unrecognized text

•	Variable name expected

•	Variable name longer than nine characters (see the Label requirement section under Input Location)

Warnings

Warnings announce situations where the program compiles but there might be unexpected results.

•	Array ID > 511; changed to 511 in DLD file

•	Array ID already used

•	Execution Interval for Table 1 is 0.0

•	Improper Use of Instruction 80

•	Inaccessible Instruction in Table 3

•	Invalid parameter value

•	Multiplier is set to zero

•	Output Flag Not Set

•	Output instruction, line 9. Output Flag Not Set

•	RF Link ID Must Be < 256

•	Unused Subroutine


Variable name expected

This message occurs when the expression is not set equal to an input location label.

The label must be to the left of the expression, not enclosed in parentheses, and follow the input location label rules.

Example

'Variable name expected' is displayed when a program contains any of these expressions:   5=el*(Vee+en), 10-(zee/2)=bee, (lambda) = COS(theta), 8label=10*data.

These are correct ways of entering the above expressions:   five=el*(Vee+en), bee=10-(zee/2), lambda = COS(theta), label8=10*data.


Equal sign expected

In expressions, an equal sign MUST immediately follow the label of the input location that stores the results (e.g., label = expression).

Example

'Equal sign expected' is displayed when a program contains any of these expressions:   zee/2=bee, data+number=volt1+volt2.

These are correct ways of entering the above expressions:   bee=zee/2, data=volt1+volt2-number.


Floating point numbers limited to 5 digits

All fixed numbers are limited to five digits not including negative signs and decimal points.


Number expected

Indicates one of the following situations:

(1)	An expression with a /, *, or ^ operator is missing a number or label before and/or after the operator.

(2)	An expression with a + or - operator does not have a number or label after the operator.

(3)	An expression with an @ operator does not have a number after the @; only a fixed number is allowed immediately after the @ operator.

(4)	An expression with an @ operator does not have either a number or label before the @.

(5)	An expression has a pair of parentheses with nothing between them (e.g., the expression contains this "()").

(6)	An expression has a number that is immediately followed by a label or function without an operator (e.g., an expression containing '8label' gets this error message).

(7)	An expression has a negative number that occurs immediately after an operator and the negative number is not enclosed in parentheses (e.g., result = data + -5 will get this error; the expression should be entered as: result = data + (-5)).

Note:  You might have gotten this message for a valid parameter entry of zero if you kept the four default zeros (0000) created by Edlog instead of typing in a 0.


New line expected

Indicates one of the following situations:

(1)	An expression contains more than one equal sign.

(2)	An expression has no operator between two sets of parentheses.

Example:   This error message is displayed when a program contains any of these expressions:   zee=(label1)(label2), ex=(5)(ARCTAN(data)), eee=(em)(see^2).

These are correct ways of entering the above expressions:    zee=(label1)*(label2), ex=(5)*(ARCTAN(data)), eee=(em)*(see^2).

(3)	An expression has no operator between a set of parentheses and a number.

Example:   This error message is displayed when a program contains any of these expressions:    tee=5(2), mu=(nu)103, bee=10.52(ef/2), sigma=-17(RCP(alpha)).

These are correct ways of entering the above expressions:   tee=5*(2), mu=(nu)*103, bee=10.52*(ef/2), sigma=-17*(RCP(alpha)).

(4)	An expression has no operator between a set of parentheses and a label or function.

Example:   This error message is displayed when a program contains any of these expressions:   result=(ex^2)data, gamma=(10-omega)SIN(psi), dee=(17)number.

These are correct ways of entering the above expressions:   result=(ex^2)*data, gamma=(10-omega)*SIN(psi), dee=(17)*number.


Function expected

In expressions, letters that are immediately followed by parentheses are assumed to be a function.

If the letters are not on the function list, this error message occurs.


Intermediate Storage

Some processing and most output processing instructions store intermediate results in the Intermediate Storage.

Intermediate Storage is automatically accessed by the instructions and cannot be accessed by the user.

By default, 64 Intermediate Storage locations are available.  Edlog will compute the necessary memory allocations and include the information with the program sent to the logger.  You can change the amount of Intermediate Storage locations by using the *A mode in the keyboard/display.  If more Intermediate Storage is required than the amount allocated, an error occurs.

Caution:   Data stored in Final Storage are erased when the Intermediate Storage memory is increased or decreased.

Memory is taken from Final Storage when the Input and/or Intermediate memory is increased.  Final Storage must have at least 1 data storage location.


Execution Interval for Table 1 is 0.0

When an Execution Interval is 0.0, measurements aren't made.

Sometimes, when debugging a program, the execution interval is intentionally zero.  This allows the user to check for errors by compiling the program without making measurements.


Unrecognized Text

Most likely, this error was the result of erroneously entering one of the following:

•	Comments -- the first character on the left must be a semi-colon.  For more information, see Comments.

•	Expressions -- must start with an input location label followed by an equal sign then a +, -, label, number, or function.  For more detailed information, see Entering Expressions.


Output Flag Not Set

This warning occurs when the output flag has not been set anywhere in the program.  The output flag must be set to store the measurements in Final Storage, and the measurements must be stored in Final Storage to transfer them to a storage module (SM716, SM192, or CSM1), or printer or to retrieve the data via a telecommunication link.


Output Instruction, Line 9. Output Flag Not Set

This warning occurs when an output instruction is found in the program, but the output flag is not set.  The instruction that sets the output flag may be omitted altogether, or the output processing instruction may appear before the output flag in the program.  In either case, measurements that you expect to be stored in Final Storage will not be stored there.  Measurements must be stored in Final Storage to transfer them to a storage module (SM716, SM192, or CSM1), or printer or to retrieve the data via a telecommunication link.


Inaccessible Instruction in Table 3

This warning occurs when Edlog finds an instruction in Table 3 that is not within a subroutine.  For more information, see Instruction 85.


Improper Use of Instruction 80

This warning occurs if Instruction 80 does not immediately follow the command which sets the output flag high.


Unused Subroutine

This warning is displayed when there is a subroutine in table 3 but the subroutine is never called.

This warning is often a result of a typo for the command code of a program control instruction.


Watch Dog Timer

Checks the processor state, software timers, and program related counters.

If the processor has bombed or is neglecting standard system updates, or if the counters are outside the limits, the watch dog timer resets the processor and program execution.  Voltage surges and transients can cause the watch dog timer to reset the processor and program execution.

When the watch dog timer resets the processor and program execution, an error occurs.  Frequent repetitions of this error indicate a hardware or software problem which should be reported to Campbell Scientific.


Input Storage

The Input Storage stores the results of measurements or calculations (see input/output and processing instructions).

Input Storage defaults to 28 locations.  Edlog will compute the necessary memory allocations and include the information with the program sent to the logger.  You can change the amount of Input Storage locations by using the *A mode in the keyboard/display.  If more Input Storage is required than the amount allocated, an error occurs.

Caution:   Data stored in Final Storage are erased when the Input Storage memory is increased or decreased.

Memory is taken from Final Storage when the Input and/or Intermediate memory has been increased.  Final Storage must have at least 1 data storage location.


Execution Interval Errors

Invalid multiple of 1/8 second

Execution Intervals that are between 1/8 and 32 seconds must be multiples of 1/8 (1/8, 1/4, 3/8, 1/2, ... , 63/2, 253/8, 127/4, 255/8).

Value must be <= 8191

All Execution Intervals must be less than or equal to 8191 seconds.

Note:   An execution interval of 0.0 for table 1 yields a warning.


Input/Output Instructions

Measure sensors, control and communicate with external devices, and control some internal functions such as controlling the CR500's timer.

The Input/Output instructions do not store measurements in Final Storage.  The data must be in Final Storage to transfer the data to a storage module (SM716, SM192, or CSM1), or printer or to retrieve the data via a telecommunication link.  Output Processing instruction are required to store the measurements in Final Storage.


Input/Output Instruction List (CR10X)
Input/Output Instruction List (CR500)

For a definition of input/output instructions, see Input/Output Instructions.

Instruction 1, VOLT (SE)

Instruction 2, VOLT (DIFF)

Instruction 3, PULSE

Instruction 4, EX-DEL-SE

Instruction 5, AC HALF BR

Instruction 6, FULL BR

Instruction 7, 3W HALF BR

Instruction 8, EX-DEL-DIFF

Instruction 9, FULL BR w/M EX

Instruction 10, BATT VOLT

Instruction 11, TEMP (107)

Instruction 12, R.H. (207)

Instruction 16, RTD TEMP

Instruction 17, INTERNAL TEMP

Instruction 18, TIME

Instruction 19, SIGNATURE

Instruction 20, SET PORT

Instruction 21, PORT w/DURATION

Instruction 22, EXCITATION w/DELAY

Instruction 24, CALIBRATION

Instruction 25, READ PORTS

Instruction 26, TIMER

Instruction 27, PERIOD AVG (SE)

Instruction 28, VIB WIRE (SE)

Instruction 29, PS9104E

Instruction 105, SDI-12 RECORDER

Instruction 106, SDI-12 SENSOR

Instruction 114, SET TIME

Instruction 117, DATALOGGER ID


Processing Instructions

Allow data reduction, entry of simple algorithms, and conversion of raw data into engineering units.

As a short cut, data can be processed by entering an expression.  When an expression is entered, Edlog automatically incorporates the processing instructions into the .DLD file.

Some processing instructions store intermediate results in the intermediate memory.  Sufficient memory must be allocated to the Intermediate Storage or an error occurs.


Processing Instruction List (CR10X)
Processing Instruction List (CR500)

For a definition of processing instructions, see Processing Instructions.

Instruction 30, Z=F

Instruction 31, Z=X

Instruction 32, Z=Z+1

Instruction 33, Z=X+Y

Instruction 34, Z=X+F

Instruction 35, Z=X-Y

Instruction 36, Z=X*Y

Instruction 37, Z=X*F

Instruction 38, Z=X/Y

Instruction 39, Z=SQRT(X)

Instruction 40, Z=LN(X)

Instruction 41, Z=EXP(X)

Instruction 42, Z=1/X

Instruction 43, Z=ABS(X)

Instruction 44, Z=FRAC(X)

Instruction 45, Z=INT(X)

Instruction 46, Z=X MOD F

Instruction 47, Z=X^Y

Instruction 48, Z=SIN(X)

Instruction 49, SPA. MAX

Instruction 50, SPA. MIN

Instruction 51, SPA. AVG

Instruction 52, RUNNING AVERAGE

Instruction 53, A*X+B

Instruction 54, BLOCK MOVE

Instruction 55, POLYNOMIAL

Instruction 56, SAT.VP

Instruction 57, WB/DBT to VP

Instruction 58, LP FILTER

Instruction 59, Rf(X/(1-X))

Instruction 61, INDIR MOVE

Instruction 63, EXTENDED PARAMETERS

Instruction 65, BULK LOAD

Instruction 66, Z=ARCTAN(X/Y)

Instruction 68, EXTENDED PARAMETERS 4-DIGIT


Output Processing Instructions

Process measured values collected over time and place the results in Final Storage.

Most output processing instructions also use the Intermediate Storage for holding on-going calculations.  If there is not sufficient memory allocated to the Intermediate Storage, an error occurs.


Output Processing Instruction List (CR10X)
Output Processing Instruction List (CR500)

For a definition of output processing instructions, see Output Processing Instructions.

Instruction 70, SAMPLE

Instruction 71, AVERAGE

Instruction 72, TOTALIZE

Instruction 73, MAXIMUM

Instruction 74, MINIMUM

Instruction 77, REAL TIME

Instruction 78, RESOLUTION

Instruction 79, SMPL ON MAX/MIN

Instruction 80, SET ACTIVE STORAGE AREA

Instruction 82, STD DEV


Program Control Instructions

Allow logic based on time or data and control serial data output and CR500-initiated telecommunications.


Program Control Instruction List (CR10X)
Program Control Instruction List (CR500)

For a definition of program control instructions, see Program Control Instructions.

Instruction 83, IF CASE LOCATION < F

Instruction 85, BEGINNING OF SUBROUTINE

Instruction 86, DO

Instruction 87, BEGINNING OF LOOP

Instruction 88, IF X<=>Y

Instruction 89, IF X<=>F

Instruction 90, STEP LOOP INDEX

Instruction 91, IF FLAG/PORT

Instruction 92, IF TIME IS

Instruction 93, CASE

Instruction 94, ELSE

Instruction 95, END

Instruction 96, SERIAL OUT

Instruction 97, INITIATE TELE

Instruction 111, RUN FLASH

Instruction 120, DATA TRANSFER TO TGT

Instruction 121, DATA TRANSFER TO ARGOS ST-13


Menu Notation

Throughout Help, menus and their options will be denoted as the following:   XXX|YYY|ZZZ

Where

XXX  --  the original menu

YYY  --  the menu's option

ZZZ  --  the option's option

Example:   FILE|OPEN denotes the open option under the file menu.


Option Selection

Choosing the Option with a Mouse

1.   Move your mouse to the desired option.

2.   Press the mouse's left button.

3.   Move your mouse to OK.

4.   Press the mouse's left button.

Choosing the Option without a Mouse

1.   Use the arrow keys to move the cursor to the desired option.

2.   Press the <tab> key.  This moves the cursor to OK.

3.   Press <enter>.


Enabling & Disabling Options

Options are enabled or disabled by using the <tab> key to place the cursor on the brackets and pressing the <space> bar or by selecting the brackets with the computer's mouse and pressing the left button.

An 'X' between the brackets indicates this option has been enabled and a space between the brackets indicates this option has been disabled.


Datalogger Choices

Instructions as well as other programming characteristics are datalogger specific, therefore you must choose your datalogger type before developing your Edlog program.

If you're unclear about your datalogger type, see the descriptions below:

CR10X	A small rectangular datalogger.  The wiring panel, power supply, and keyboard/display are all detachable.  The canister should have a red sticker that clearly labels the datalogger as a CR10X.  The wiring panel is most likely black.

CR10X-TD	Same as the CR10X except it uses table based data storage.

CR10  	Except for the sticker, the appearance is the same as the CR10X.  The wiring panel is either silver or black.

21X 	Choose this for programming both the 21X and 21XL.  These are compact dataloggers with built-in keyboard/displays and power supplies.

CR23X  	Incorporates features from both the CR10X and 21X, but is packaged similar to the 21X.  Like the 21X, it has a built-in keyboard/display and power supply.

CR23X-TD	Same as the CR23X except it uses table based data storage.

CR7 	A large modular datalogger that consists of a control module (700X) and I/O module (720 or 720XL).

CR10T 	This datalogger is used exclusively for RTMS applications.

CR510	A small rectangular datalogger.  The power supply and keyboard/display are detachable.  This datalogger has fewer channels than the CR10X.

CR510-TD	Same as the CR510 except it uses table based data storage.

CR500	Except for the silk screening, this datalogger has the same appearance as the CR510.  However, the CR500 has fewer capabilities (e.g., the CR500 only has one final storage area).


File Menu

The file menu is used to load, save, and exit Edlog files.  The options available under the file menu are:

•	New

•	Open

•	Save

•	Save As

•	View File

•	Close

•	Close All

•	Print

•	Print File

•	Print Setup

•	Document DLD File

•	Exit


New

Loads a template to create a new Edlog program.


Open

Loads an existing Edlog program for editing.

Caution -- A file that originally was programmed for one type of datalogger should not be edited to program another type of datalogger (e.g., don't edit a 21X file to program a CR10).


View File

Allows you to view a text file.  The editing functions will be disabled.


Save

Saves the current datalogger program.


Save As

Saves the current datalogger program under a new name.


Close

Closes only the active window.


Close All

Closes all of the windows.


Print

Sends an Edlog program to a printer.


Print to File

Creates a file with a .TXT extension.  These files are Edlog programs that can be printed or used with a text editor.


Print Setup

Selects the printer used when an Edlog program is printed.  The following is also selected under this menu:

•	Paper Orientation -- portrait, landscape.

•	Paper Size -- letter (8 1/2 x 11 in.), legal (8 1/2 x 14 in.), executive (7 1/2 x 10 in.), A4 (210 x 297 mm), Envelope #10 (4 1/8 x 9 1/2 in.), Envelope DL (110 x 220 mm), Envelope Monarch.

•	Paper Source -- upper tray, lower tray, manual feed, envelope feed, auto select.


Document DLD File

Creates a *.CSI file from a downloadable (*.DLD) file (see File Types).  This option is for editing a program that was originally entered using a datalogger's keyboard/display or an older version of Edlog.

Caution:  A .DLD file that originally was programmed for one type of datalogger should not be edited to program another type of datalogger (e.g., don't edit a 21X .DLD file to program a CR10).


File Types

*.CSI

The CSI file is the uncompiled program file created by Edlog.  This is the standard ASCII text file which can be viewed in Edlog, with View, or with any standard text editor.  When a file is retrieved for editing in Edlog, this is the file type which is retrieved.  The CSI extension is automatically assigned by Edlog when a program is saved.

*.DLD

When Edlog compiles a program (*.CSI), a DLD file is created.  This is the file format which is downloaded to the datalogger, and the type of file which is retrieved from the datalogger.  If an existing program file is edited and compiled, the old DLD file will be overwritten by the new file.  A DLD file can be documented (i.e., a CSI file can be created), by choosing File|Document DLD File.

*.DOC

Edlog versions 5.4 and earlier saved program files in a *.DOC file format.  These programs can be formatted for use with newer versions of Edlog by choosing File|Document DLD File.  Since the DLD file does not contain comments, documenting it will not preserve the comments in the original DOC file.  To retrieve the comments, use the separate DOS conversion utility, DOC2CSI.EXE.

*.FSL

FSL files contain a list of the final storage labels used in an Edlog program.  These files are used by PC208W's Report program (Split) to help select the parameters which will be used in parsing data.

*.LBR

Library files (*.LBR) are parts of a program which can be retrieved and used in other Edlog programs.  If a programmer often uses an instruction set in his/her datalogger programs, this partial file can be saved to disk and inserted into a new program quickly.  For information about creating a library file, see Creating a Library File.

Note:  Library files which are created for one type of datalogger should not be used in a different type of datalogger ( e.g., do not use an LBR file created for a CR10X in a 21X program).

*.TXT

Printer output files created by Edlog are saved with a TXT extension.  These files can be sent to a printer or viewed with a text editor.  A TXT file is created by selecting File|Print File.

*.PTI

Program trace information files (*.PTI) are created each time a program is compiled.  If an existing Edlog program is edited and recompiled, the old PTI file is overwritten.  These files provide information for the user on each datalogger program, such as instruction execution times, subroutine execution time, overall program execution times, and final storage information.


Exit

This option exits Edlog.  Whenever the program has not been saved and/or compiled, Edlog will ask whether the program should be saved and/or compiled.


Edit

This menu provides options for editing Edlog programs.  The options available under the Edit menu are:

•	Cut

•	Copy

•	Paste

•	Comment

•	Uncomment

•	Delete

•	Show Clipboard

•	Save Library File

•	Select Library File

•	Insert Instruction

•	Delete Instruction

•	Input Labels

•	View Final Storage Labels

•	View Mode 4 Settings (CR10, CR10X, & CR500 only)


Cut

This option allows sections of a program to be moved to another area of the program or to another program.

For a step-by-step procedure on moving text, see Cut, Copy, and Paste Procedures.

Caution: Instructions from one datalogger type must not be copied to another datalogger type (i.e., do not copy CR10X instructions to a program for a 21X). Some instructions vary among dataloggers. Downloading such a file to a datalogger can cause unpredictable results in datalogger operation, including loss of data.


Copy

This option allows sections of a program to be copied to another area of the program or to another program.

For a step-by-step procedure on moving text, see Cut, Copy, and Paste Procedures.

Caution: Instructions from one datalogger type must not be copied to another datalogger type (i.e., do not copy CR10X instructions to a program for a 21X). Some instructions vary among dataloggers. Downloading such a file to a datalogger can cause unpredictable results in datalogger operation, including loss of data.


Paste

This option is used with EDIT|CUT or EDIT|COPY to allow sections of a program to be moved or copied to another area of the program or to another program.

For a step-by-step procedure on moving text, see Cut, Copy, and Paste Procedures.

Caution: Instructions from one datalogger type must not be copied to another datalogger type (i.e., do not copy CR10X instructions to a program for a 21X). Some instructions vary among dataloggers. Downloading such a file to a datalogger can cause unpredictable results in datalogger operation, including loss of data.


Cut, Copy, and Paste Procedures

EDIT|CUT, EDIT|COPY, and EDIT|PASTE allow sections of the program to be moved or copied to another area of the program or to another program.

Caution: Instructions from one datalogger type must not be copied to another datalogger type (i.e., do not copy CR10X instructions to a program for a 21X). Some instructions vary among dataloggers. Downloading such a file to a datalogger can cause unpredictable results in datalogger operation, including loss of data.

The following steps are required for moving or copying sections of the program:

(1)	Either use the computer's mouse or the <shift> and arrow keys to select all of the text that will be moved or copied.

Note:   You cannot move or copy protected text (Tables, Execution Intervals).  To move or copy an Instruction, the entire instruction, including all of the parameters, must be selected.

(2)	Select EDIT|CUT (or CTRL+X) to move the text or select EDIT|COPY (or CTRL+C) to copy the text.

(3)	Move the cursor to the location where the moved or copied text will reside.

(4)	Select EDIT|PASTE (or CTRL+V) and the text is now moved or copied to the designated location.

Steps 3 and 4 can be repeated allowing text to be copied to many areas of the program.  EDIT|SHOW CLIPBOARD displays the text that is inserted if steps 3 and 4 are repeated.


Comment

Select Edit|Comment to make instructions, expressions, selected text, or the line under the cursor a comment.  Comments are ignored by the compiler.  If you select Edit|Comment while the cursor is on an instruction, the entire instruction will become a comment and will be ignored by the compiler.

Select Edit|Uncomment to make the instruction, expression, selected text, or the line under the cursor no longer be a comment.

For more information, see Entering Comments.


Uncomment

Select Edit|Uncomment to make the instruction, expression, selected text, or the line under the cursor no longer be a comment (comments are ignored by the compiler).  If you select Edit|Uncomment while the cursor is on an instruction, the entire instruction will no longer be a comment.

For more information, see Entering Comments.


Delete

Delete the text that has been selected.


Show Clipboard

Displays the text that has been cut or copied.  This text will be inserted into the program if EDIT|PASTE is used.


Save Library File

Library files are convenient when you need to create several programs that have common Instructions, Expressions, or Comments.

Steps for Creating a Library File:

(1)	Either use the computer's mouse or the <shift> and arrow keys to select all of the text you want to save in a library file.

Note:  The entire instruction, including all of the parameters, must be selected.

(2)	Select Edit|Save Library File

(3)	When a window appears, type in the Library file name and select OK.


Inserting a Library File into a Program

Library files can be inserted into any Edlog program.

Steps for inserting a library file into an Edlog program:

(1)	Move cursor to the location where the text will reside.

(2)	Select Edit|Insert Library File.

(3)	When a window appears, select the desired library file's name.


Insert Instruction

Allows an instruction to be selected from a list.


Insert Instruction

List the available instructions.  From this list, an instruction can be selected.

Selecting the Instruction using a mouse

1.   Move your mouse to the desired instruction.

2.   Press the left button on the mouse.

3.   Move your mouse to OK.

4.   Press the left button on the mouse.

Selecting the Instruction without using a mouse

1.   Use the arrow keys to move the cursor to the desired instruction.

2.   Press the <tab> key.  This moves the cursor to OK.

3.   Press <enter>.


Delete Instruction

Deletes the entire instruction where the cursor is located.


Input Labels

Accesses the input location editor screen.


Input Locations Editor's Screen

This screen allows you to input and edit input locations.  Input location information is provided under these headings:

•	Addr

•	Name

•	Flags

•	# Reads

•	# Writes

•	Blocks

To edit the labels, the cursor is placed on the label and retyped.  The location numbers are edited by using this screen's editing menu.  The following editing commands are available:

•	Insert

•	Delete

•	Move

•	Toggle Manual

•	Optimize

•	Insert Block


Addr

Lists the input location number (address).


Name

Between the brackets, enter the input location label.

The input location label can have up to nine characters.  The first character must be a letter; the other characters can be letters, numbers, or _.  The following labels are reserved for expressions and should not be entered by the user:  CSI_R, CSI_2, CSI_3, . . . CSI_95.


Flags

Automatically displays an R, W, M and/or I, under these conditions:

R 	Indicates the input location has been read.

W	Indicates data are written to this location.

M 	Indicates the input location has been marked with the manual flag (see Manually Toggle).

I	Indicates the input location is part of an implied block.  Input locations are marked as implied when more than 299 input locations are inserted as a block at one time.  If more than 28 input locations exist in the program, only the first and last input locations in the block will appear in the Input Location Editor list.  If less than 28 input locations exist, the locations will be listed up to location number 28, and then all but the last one will be omitted from the list.


# Reads

Automatically displays the number of times the input location is read.


# Writes

Automatically displays the number of times that data are written to this location.


Blocks

Contains the word start when the input location is the initial location for a group of repetitions.

Contains the word member when the input location is part of a group of repetitions but is not the initial nor the last repetition.

Contains the word end when the input location is the last repetition.


Insert

Inserts one or more input locations before another location.  This might change several input location numbers.

Starting address -- enter the input location where the other location(s) will be inserted before.

Number of Inlocs -- enter the number of input locations that will be inserted.

Note:  When you insert more than 299 input locations, Edlog displays only the first and last locations.

For more information, see insert example.


Delete

Deletes one or more input location(s).

Wherever the datalogger program references a deleted location, the input location number will become 0.  When an instruction has been deleted, its input location will still be on the location editor screen until the location has been deleted with this command or the optimize command has been used.

Starting address -- enter the input location number of the first location that will be deleted.

Ending Address -- enter the input location number of the last location that will be deleted.

For more information, see delete example.


Move

Moves one or more input locations to a different number.  This might change several input location numbers.

Starting address -- enter the input location number of the first location that will be moved.

Destination address -- enter the input location number where the locations will be moved.

Number of Inlocs -- enter the number of input locations that will be moved.

For more information, see move example.


Toggle Manual

Toggles the manual flag on and off for one or more input locations.  Input locations where the manual flag is toggled on will not be deleted or moved by the Optimize function.

Starting address -- enter the input location number of the first location that will be marked manual.

Ending Address -- enter the input location number of the last location that will be marked manual.

For more information, see Toggle to Manual example.


Optimize

Deletes input locations that aren't referenced or written to and aren't marked manual.

For more information, see Optimize example.


Insert Block

Creates a block of input locations.  This command also allows a range of locations to be labeled simultaneously and sets the manual flag for a range of locations.

Base Name:   Enter the base name.  For example, a base name of Data will create input locations labeled Data_1, Data_2, ...

Starting Address:   Enter the address of the first input location.

Number of InLocs:  Enter the number of input locations you want to create.

For more information, see Insert Block example.

Notes:

(1)	When you insert more than 299 input locations, Edlog displays only the first and last locations.

(2)	A warning screen appears when the input locations of repetitions are edited incorrectly.


Repetitions and the Input Location Editor

A warning screen will appear when attempting to:

(1)	Insert a location within a repetition block.

(2)	Delete one or more, but not all, of the members in a repetition block.

(3)	Move one or more, but not all, of the members in a repetition block.


Insert Example

Suppose the input location editor's screen is:

 1	[ TempC_____  ]	-W-	0	1 ----- ------ ---

 2	[ WindD______ ]	RW-	1	1 ----- ------ ---

 3	[ WindS______ ]	RW-	1	1 ----- ------ ---

 4	[ ___________  ]	 --- 	0	0 ----- ------ ---

 5	[ ___________  ]	 --- 	0	0 ----- ------ ---

When a line is inserted between 1 and 2, the screen becomes:

 1	[ TempC_____  ]	-W-	0	1 ----- ------ ---

 2	[ ___________  ]	 --- 	0	0 ----- ------ ---

 3	[ WindD______ ]	RW-	1	1 ----- ------ ---

 4	[ WindS______ ]	RW-	1	1 ----- ------ ---

 5	[ ___________  ]	 --- 	0	0 ----- ------ ---

 6	[ ___________  ]	 --- 	0	0 ----- ------ ---

The new input location numbers (3 for WindD, 4 for WindS) are automatically incorporated in the datalogger program, wherever WindD and WindS occur.

Suppose BatteryV is typed between the brackets on the inserted line.

If instruction 10 is added to the datalogger program with BatteryV as the input location label, the location number for instruction 10 will automatically become 2.

The input location editor screen will become:

 1	[ TempC_____  ]	 -W-	0	1 ----- ------ ---

 2	[ BatteryV____  ]	 -W- 	0	1 ----- ------ ---

 3	[ WindD______ ]	RW-	1	1 ----- ------ ---

 4	[ WindS______ ]	RW-	1	1 ----- ------ ---

 5	[ ___________  ]	 --- 	0	0 ----- ------ ---

 6	[ ___________  ]	 --- 	0	0 ----- ------ ---

Caution:   A warning screen appears when the input locations of repetitions are edited incorrectly.


Delete Examples

Example 1

Suppose the input location editor's screen is:

 1	[ TempC_____  ]	-W-	0	1 ----- ------ ---

 2	[ WindD______ ]	RW-	1	1 ----- ------ ---

 3	[ WindS______ ]	RW-	1	1 ----- ------ ---

 4	[ ___________  ]	 --- 	0	0 ----- ------ ---

 5	[ ___________  ]	 --- 	0	0 ----- ------ ---

If location 1 is deleted, the screen becomes:

 1	[ ___________  ]	 --- 	0	0 ----- ------ ---

 2	[ WindD______ ]	RW-	1	1 ----- ------ ---

 3	[ WindS______ ]	RW-	1	1 ----- ------ ---

 4	[ ___________  ]	 --- 	0	0 ----- ------ ---

 5	[ ___________  ]	 --- 	0	0 ----- ------ ---

In the datalogger program wherever TempC originally appeared, the input location number will become 0 and the data will not be stored.

Example 2

Suppose the input location editor's screen is:

 1	[ TempC_____  ]	 --- 	0	0 ----- ------ ---

 2	[ WindD______ ]	RW-	1	1 ----- ------ ---

 3	[ WindS______ ]	RW-	1	1 ----- ------ ---

 4	[ ___________  ]	 --- 	0	0 ----- ------ ---

 5	[ ___________  ]	 --- 	0	0 ----- ------ ---

No R or W on the TempC line indicates this location is not referenced in the datalogger program.  The datalogger program will not be altered if this location is deleted.

Caution:   A warning screen appears when the input locations of repetitions are edited incorrectly.


Move Examples

Example 1

Suppose the input location editor's screen is:

 1	[ WindD______ ]	RW-	1	1 ---------- ------- -----

 2	[ WindS______ ]	RW-	1	1 ---------- ------- -----

 3	[ Data_1_____  ]	 -W- 	0	1 START ------- -----

 4	[ Data_2_____  ]	 -W- 	0	1 ------ MEMBER ---

 5	[ Data_3_____  ]	 -W- 	0	1 -----  ---------- END

 6	[ ___________  ]	 --- 	0	0 ---------- --------- ---

When location 1 is moved to location 6, the screen becomes:

 1	[ ___________  ]	 --- 	0	0 ---------- --------- ---

 2	[ WindS______ ]	RW-	1	1 ---------- ------- -----

 3	[ Data_1_____  ]	 -W- 	0	1 START ------- -----

 4	[ Data_2_____  ]	 -W- 	0	1 ------ MEMBER ---

 5	[ Data_3_____  ]	 -W- 	0	1 -----  ---------- END

 6	[ WindD______ ]	RW-	1	1 ---------- ------- -----

The number 6 will automatically be incorporated in the datalogger program, wherever WindD occurs.

Example 2

Suppose the input location editor's screen is:

 1	[ WindD______ ]	RW-	1	1 ---------- ------- -----

 2	[ WindS______ ]	RW-	1	1 ---------- ------- -----

3	[ Data_1_____  ]	 -W- 	0	1 START ------- -----

 4	[ Data_2_____  ]	 -W- 	0	1 ------ MEMBER ---

 5	[ Data_3_____  ]	 -W- 	0	1 -----  ---------- END

 6	[ ___________  ]	 --- 	0	0 ---------- --------- ---

When locations 3, 4, and 5 are moved to location 1, the screen becomes:

 1	[ Data_1_____  ]	 -W- 	0	1 START ------- -----

 2	[ Data_2_____  ]	 -W- 	0	1 ------ MEMBER ---

 3	[ Data_3_____  ]	 -W- 	0	1 -----  ---------- END

 4	[ WindD______ ]	RW-	1	1 ---------- ------- -----

 5	[ WindS______ ]	RW-	1	1 ---------- ------- -----

 6	[ ___________  ]	 --- 	0	0 ---------- --------- ---

The new input location numbers (1 for Data_1, 2 for Data_2, 3 for Data_3, 4 for WindD, and 5 for WindS) are automatically incorporated in the datalogger program wherever the location labels occur.

Caution:   A warning screen appears when the input locations of repetitions are edited incorrectly.


Toggle Example

Suppose the input location editor's screen is:

 1	[ TempC_____  ]	-W-	0	1 ----- ------ ---

 2	[ ___________  ]	 --- 	0	0 ----- ------ ---

 3	[ ___________  ]	 --- 	0	0 ----- ------ ---

 4	[ ___________  ]	 --- 	0	0 ----- ------ ---

 5	[ WindD______ ]	RW-	1	1 ----- ------ ---

 6	[ WindS______ ]	RW-	1	1 ----- ------ ---

If the toggle manual command is used and location 3 is selected, the input location editor screen becomes:

 1	[ TempC_____  ]	-W-	0	1 ----- ------ ---

 2	[ ___________  ]	 --- 	0	0 ----- ------ ---

 3	[ ___________  ]	 --M	0	0 ----- ------ ---

 4	[ ___________  ]	 --- 	0	0 ----- ------ ---

 5	[ WindD______ ]	RW-	1	1 ----- ------ ---

 6	[ WindS______ ]	RW-	1	1 ----- ------ ---

If the user selects the optimize command, the input editor screen now becomes:

 1	[ TempC_____  ]	-W-	0	1 ----- ------ ---

 2	[ ___________  ]	 --- 	0	0 ----- ------ ---

 3	[ ___________  ]	 --M	0	0 ----- ------ ---

 4	[ WindD______ ]	RW-	1	1 ----- ------ ---

 5	[ WindS______ ]	RW-	1	1 ----- ------ ---

 6	[ ___________  ]	 --- 	0	0 ----- ------ ---

The new input location numbers (4 for WindD, 5 for WindS) are automatically incorporated in the datalogger program, wherever the WindD and WindS locations occur.


Optimize Examples

Example 1

Suppose the input location editor's screen is:

 1	[ TempC_____  ]	-W-	0	1 ----- ------ ---

 2	[ ___________  ]	 --- 	0	0 ----- ------ ---

 3	[ ___________  ]	 --- 	0	0 ----- ------ ---

 4	[ WindD______ ]	RW-	1	1 ----- ------ ---

 5	[ WindS______ ]	RW-	1	1 ----- ------ ---

When the optimize command is used, the screen becomes:

 1	[ TempC_____  ]	-W-	0	1 ----- ------ ---

 2	[ WindD______ ]	RW-	1	1 ----- ------ ---

 3	[ WindS______ ]	RW-	1	1 ----- ------ ---

 4	[ ___________  ]	 --- 	0	0 ----- ------ ---

 5	[ ___________  ]	 --- 	0	0 ----- ------ ---

The new input location numbers (2 for WindD, 3 for WindS) are automatically incorporated in the datalogger program, wherever the WindD and WindS locations occur.

Example 2

Suppose the input location editor's screen is:

 1	[ TempC_____  ]	 ---	0	0 ----- ------ ---

 2	[ WindD______ ]	RW-	1	1 ----- ------ ---

 3	[ WindS______ ]	 ---	0	0 ----- ------ ---

 4	[ ___________  ]	 --- 	0	0 ----- ------ ---

 5	[ ___________  ]	 --- 	0	0 ----- ------ ---

No R or W on the TempC and WindS lines indicate these locations are not referenced in the datalogger program.  When the optimize command is used, these locations are deleted and the input location editor screen becomes:

 1	[ WindD______ ]	RW-	1	1 ----- ------ ---

 2	[ ___________  ]	 --- 	0	0 ----- ------ ---

 3	[ ___________  ]	 --- 	0	0 ----- ------ ---

A 1 is automatically incorporated in the datalogger program wherever WindD occurs.


Insert Block Example

Suppose the input location editor's screen is:

 1	[ TempC_____  ]	-W-	0	1 ----- ------ ---

 2	[ WindD______ ]	RW-	1	1 ----- ------ ---

 3	[ WindS______ ]	RW-	1	1 ----- ------ ---

 4	[ ___________  ]	 --- 	0	0 ----- ------ ---

If the Block command is used with:

Base Name:   Data

Starting Address:   2

Number of InLocs:   3

The input editor's screen becomes:

1	[ TempC_____  ]	-W-	0	1 ----- ------ ---

 2	[ Data_1_____  ]	 --M	0	0 ----- ------ ---

 3	[ Data_2_____  ]	 --M	0	0 ----- ------ ---

 4	[ Data_3_____  ]	 --M	0	0 ----- ------ ---

 5	[ WindD______ ]	RW-	1	1 ----- ------ ---

 6	[ WindS______ ]	RW-	1	1 ----- ------ ---


Final Storage Labels

Lists the final storage labels affected by the highlighted Output Processing Instruction.  If the cursor is not within an output processing instruction, a message will be displayed.


Final Storage Labels

Lists the final storage labels affected by the highlighted Output Processing Instruction.  If the cursor is not within an output processing instruction, a message will be displayed.


View Mode 4 Table

Displays the Mode 4 Table.


Mode 4 Table

Displays a table listing the mode 4 parameters.

Mode 4 allows a general program to be initially entered while the application specific details such as sensor calibration can be overwritten by entering them into the datalogger by using the keyboard/display.  For information on marking a parameter and for an example of Mode 4 use, see the Using Mode 4.


Using Mode 4

The Mode 4 Table is used to enter values into instruction parameters after the program has been compiled and downloaded to a datalogger.  Using Mode 4 allows you to develop a general program with variables for the parameter values; the variables refer to locations in the Mode 4 table.  Once the program has been downloaded to the datalogger, the values in Mode 4 table can be entered manually by the using the keyboard/display or PC208W's terminal mode.  When the program is recompiled, these values are pulled from the Mode 4 Table into the appropriate parameter location.

The procedure for using mode 4 is listed below:

(1)	While the cursor is on the parameter, enter the default parameter entry then type in @ or select the speed key.

(2)	A pop-up window is displayed.  Type in the mode 4 location number in the field provided.

Example:

A use for Mode 4 would be if you have a number of dataloggers that will be programmed identically, except for the calibration of an attached sensor.  The program can be developed incorporating the Mode 4 table, downloaded to each of the dataloggers, and the calibration information manually entered into each datalogger's Mode 4 table.


Search

This menu allows you to search for text.  This menu provides two options: Search and Search Again.


Search

Searches for text in the Edlog Program.  When this option is chosen, a dialog box appears that allows you to enter the text that will be searched.

This dialog box provides two options that by default are disabled:

•	Case Sensitive

•	Whole Words Only


Search Again

Searches for the text that was previously searched.


Compile

This menu is for compiling the program.  After a program has been written, it must be compiled for it to program a datalogger.


Compile

The compiler checks program syntax and attempts to discover programming errors.

The compiler also creates a .DLD file.  The .DLD file excludes all comments and incorporates the instructions required to calculate the expressions.  The .DLD file is what actually programs the datalogger.


Display

This menu controls the way the datalogger program is displayed.  The display menu has the following options:

•	Renumber

•	Rebuild Indention

•	Compress

•	Uncompress


Renumber

Renumbers the instructions so they are numbered sequentially.

Renumber is only required when Option|Editor|Automatic Renumbering is disabled.


Rebuild Indention

Undoes all manual indentions and rebuilds automatic indentions.

When instructions are edited, automatic indentions can get misaligned.


Compress Option

Select the compress option or press the F7 function key to display the first line of each instruction.  This enables the program structure to be easily seen.  Instructions cannot be edited while compressed.

To return to the normal view, select the uncompress option or press the F7 function key.


Uncompress Option

Select the uncompress option or press the F7 function key to return a compressed program to normal view.  A compressed program displays only the first line of each instruction.


Options

The available options under this menu are:

•	Editor

•	Show/Hide Toolbar

•	Font

•	Program Security

•	Final Storage Area 2

•	Datalogger ID

•	Datalogger Power-Up


Editor

The following options are available:

•	Automatic Renumbering

•	Data Entry Warning

•	Automatic Indentions

Number of spaces to indent (for Automatic and/or Manual Indentions)


Editor

The following options are available:

•	Automatic Renumbering

•	Data Entry Warning

•	Automatic Indentions

Number of spaces to indent (for Automatic and/or Manual Indentions)


Automatic Renumbering

When active, the computer automatically renumbers the program instructions whenever instructions are inserted or deleted (see example).

To improve performance on slow computers, the Automatic Renumbering can be disabled.


Automatic Renumbering Example

If a section of a datalogger program is initially the following:

 17:  Minimum (P74)

   01:   1    Rep

   02:   0    Value only

   03:   1    Loc TempC

 18:  Maximum (P73)

   01:   1    Rep

   02:   0    Value only

   03:   1    Loc TempC

 19:  End Table 1

Inserting instruction 71 between instructions 74 and 73, the numbers automatically become:

 17:  Minimum (P74)

   01:   1    Rep

   02:   0    Value only

   03:   1    Loc TempC

 18:  Average (P71)

   01:   1    Rep

   02:   1    Loc TempC

 19:  Maximum (P73)

   01:   1    Rep

   02:   0    Value only

   03:   1    Loc TempC

 20:  End Table 1

If instruction 74 is then deleted, the numbers become:

 17:  Average (P71)

   01:   1    Rep

   02:   1    Loc TempC

 18:  Maximum (P73)

   01:   1    Rep

   02:   0    Value only

   03:   1    Loc TempC

 19:  End Table 1


Data Entry Warning

Displays a warning when an invalid input is entered for a parameter.

The warning lists the valid inputs.  A valid input must be entered before the user can go to another parameter.


Automatic Indentions

Indents all If/Then/Else sequences and Loops.

To use the automatic indention, follow the procedure outlined below:

1.	Select Option|Editor.

2.	Enable the automatic indention option.

3.	In the indention box, type in the amount of spaces that the If/Then/Else sequences and Loops are to be indented and press <enter>.

See also Display|Rebuild Indention.


Manual Indention

To use, follow the procedure outlined below:

1.	Select Option|Editor.

2.	In the indention box, type in the amount of spaces that the instructions are to be indented and press <enter>.

3.	Move the cursor to the instruction that you want indented and press either <ctrl> left arrow or <ctrl> right arrow; the instruction is indented in the direction the arrow is pointing.

See also Display|Rebuild Indention.


Trace and Final Storage Label Files

Whenever you compile the program, a trace file and a final storage label file are created.

Trace File

This file has a .PTI suffix and lists execution time for each instruction, block (e.g., subroutine), and table as well as the number of Final Storage locations used per day (see example).

Note:  These execution times are estimates.  The PTI file does not account for If commands, Else commands, or repetitions of loops.  For some instructions, the execution times are listed as 0.  This occurs when the execution time is difficult to calculate (e.g., Instruction 23).

Final Storage Label File

This file has a .FSL suffix and lists the Final Storage labels.

Loading and Printing the Files

The files can be loaded into Edlog by using FILE|OPEN.  Once in Edlog, the files can be printed by selecting FILE|PRINT TO PRINTER.


Trace File Example

Program Trace Information File for:   C:\CR500PROG.CSI

Date: 6/4/1997

Time: 14:59:14

 T = Program Table Number

 N = Sequential Program Instruction Location Number

 Instruction = Instruction Number and Name

 Inst ExTm = Individual Instruction Execution Time

 Block ExTm = Cumulative Execution Time for program block, i.e., subroutine

 Prog ExTm = Cumulative Total Program Execution Time

  Output Flag High

-------------------------------

Inst	Block	Prog	Inst	Block	Prog

ExTm	ExTm	ExTm	ExTm	ExTm	ExTm

 T|N|Instruction	(msec)	(msec)	(msec)	(msec)	(msec)	(msec)

1|1|2 Volt (Diff)	3.5	3.5	3.5	3.5	3.5	3.5

1|2|92 If time is    	0.4	3.9	3.9	0.4	3.9	3.9

 Output Flag Set @ 12 for Array 102

1|3|70 Sample	0.2	4.1	4.1	0.9	4.8	4.8

 Output Data 1 Values

1|4|92 If time is     	0.4	4.5	4.5	0.4	5.2	5.2

 -------------Subroutine 1---------------

  3|1|85 Beginning of Subroutine    	0.0	0.0	4.5	0.0	0.0	5.2

  3|2|96 Serial Out	0.5	0.5	5.0	0.5	0.5	5.7

  3|3|95 End	0.2	0.7	5.2	0.2	0.7	5.9

------------End Subroutine 1-----------

Program Table 1 Execution Interval   10.000 Seconds

Table 1 Estimated Total Program Execution Time in msec    5.2 w/Output    5.9

Table 1 Estimated Total Final Storage Locations used per day  192.0

 --------------- Table 2 ---------------

2|1|10 Batt Voltage	8.3	8.3	8.3	8.3	8.3	8.3

2|2|92 If time is      	0.4	8.7	8.7	0.4	8.7	8.7

 Output Flag Set @ 22 for Array 202

2|3|70 Sample	0.2	8.9	8.9	0.9	9.6	9.6

 Output Data 1 Values

Program Table 2 Execution Interval   60.000 Seconds

Table 2 Estimated Total Program Execution Time in msec    8.9 w/Output    9.6

Table 2 Estimated Total Final Storage Locations used per day   44.3

Estimated Total Final Storage Locations used per day  236.3


Show/Hide Toolbar

When this option is set to "Show" the speed buttons are displayed.

Using your mouse to select these buttons is a faster method for performing various tasks such as saving a file.


Font

Allows you to customize the appearance of the text in the datalogger program.

The following characteristics can be set:

•	Font Type (Courier, Courier New, Fixedsys, MS LineDraw, Terminal)

•	Font Style (regular, italic, bold, bold italic)

•	Size

•	Effects (strikeout, underline)

•	Color


Program Security

By setting security in the datalogger, you restrict access to certain functions which helps ensure the program or data are not altered.

Entering Passwords

In the Program Security Dialog Box, there is a box for each level of security.  Enter a non-zero number in the appropriate box to enable security at the desired security level.  This number is used as a password to unlock the associated security level when needed.  If you choose to set level 02, level 01 must also be set.  Likewise, if you set level 03, levels 01 and 02 must be set.

Disabling Passwords

Passwords of 0000 disable the program security.  When you disable level 01, you also disable program security for levels 02 and 03.  Similarly, disabling level 02 disables level 03.  All passwords are set to 0000 upon power-up of the datalogger.  When the program is run, security is enabled.

Security Level 01

Blocks access to *1 -- Program Table 1; *2 -- Program Table 2; *3 -- Subroutine Table 3; *A -- Memory Allocation; *D -- Store, Load, and Print Programs.

Security Level 02

Blocks access to *4 -- Parameter Entry Table; *5 -- Datalogger Clock; *6 -- Input Storage Values, Ports and Flags.  When this level is enabled, you can view the settings but cannot change the them.

Security Level 03

Blocks access to *5 -- Datalogger Clock; *6 -- Input Storage Values, Ports and Flags; *7 -- Final Storage Values; *8 -- Manual Data Dump; *9 -- Storage Module Commands; *B -- Datalogger Status; all telecommunication commands except commands A (Datalogger Version, Error Counts, Data Pointer Locations, Backup Battery Status), L (Unlock Security), N (Set Datalogger as Transparent for use in communication links), and E (End Call).


Program Security

By setting security in the datalogger, you restrict access to certain functions which helps ensure the program or data are not altered.

Entering Passwords

In the Program Security Dialog Box, there is a box for each level of security.  Enter a non-zero number in the appropriate box to enable security at the desired security level.  This number is used as a password to unlock the associated security level when needed.  If you choose to set level 02, level 01 must also be set.  Likewise, if you set level 03, levels 01 and 02 must be set.

Disabling Passwords

Passwords of 0000 disable the program security.  When you disable level 01, you also disable program security for levels 02 and 03.  Similarly, disabling level 02 disables level 01.  All passwords are set to 0000 upon power-up of the datalogger.  When the program is run, security is enabled.

Security Level 01

Blocks access to *1 -- Program Table 1; *2 -- Program Table 2; *3 -- Subroutine Table 3; *A -- Memory Allocation; *D -- Store, Load, and Print Programs.

Security Level 02

Blocks access to *4 -- Parameter Entry Table; *5 -- Datalogger Clock; *6 -- Input Storage Values, Ports and Flags.  When this level is enabled, you can view the settings but cannot change the them.

Security Level 03

Blocks access to *5 -- Datalogger Clock; *6 -- Input Storage Values, Ports and Flags; *7 -- Final Storage Values; *8 -- Manual Data Dump; *9 -- Storage Module Commands; *B -- Datalogger Status; all telecommunication commands except commands A (Datalogger Version, Error Counts, Data Pointer Locations, Backup Battery Status), L (Unlock Security), N (Set Datalogger as Transparent for use in communication links), and E (End Call).


Final Storage Area 2

This option is not available for the CR500.


Set Datalogger ID

Allows you to label a datalogger which is especially useful when you're retrieving data from several dataloggers.  By default, the datalogger does not have an ID (the ID is listed as zero).

For more information see, Datalogger ID.


Datalogger ID

Allows you to label a datalogger which is especially useful when you're retrieving data from several dataloggers.

By default, the datalogger does not have an ID (the ID is listed as zero).  Valid IDs are integers from 1 through 12 and 14 through 254.

You may use Instruction 117  to store this ID in an input location.  This allows the ID to be sampled (Instruction 70) and output as part of the data stream.


Select Power-Up Settings

This option is not available for this datalogger.


Window

The Window Menu determines the way multiple windows are displayed and which window is active.  The Window Menu cannot be used with help windows.

For other types of windows, the available options are tile and cascade.


Tile

Displays all windows on an equal portion of the computer screen.


Cascade

The active window covers all but the title bars of the other windows.


Active Window

The active window is the window where the cursor is located.  Only the program in the active window can be edited.

Initially the window that is active is the last window to be entered.  To change the window that is active, the computer's mouse is used to select the other window.  The window menu can also be used to change the window that is active.


Help

Three options are available under the help menu:

•	Contents

•	How to Use Help

•	About Edlog


How to Use Help

Describes using Window's help.


About Edlog

Lists version number and copyright date.


Select Input Location

Lists all the existing input location labels.  From this list, you can select an existing label.


Input Locations

To successfully program your datalogger, you must understand Input Locations.

An Input Location is a place in the datalogger's memory where a measurement is temporarily stored until it is used in intermediate storage, output, or overwritten.  An input location is reserved for each measurement in the datalogger program.  Additional locations can be created by the user.

Each time an individual sensor is scanned, the new measurement overwrites the old.  You use Output Processing instructions to process the measurements and place the results in final storage.  Only data in Final Storage can be transferred to a storage module (SM716, SM192, or CSM1), printer, or tape, or retrieved via a telecommunication link.

Each input location has an input location number and a label that appears whenever the input location is called out in the program.

Entering Labels

When an Input Location is required by a programming instruction, the cursor initially is located between the brackets, which is where the label is keyed-in.  When a new label is entered, the next available input location number is automatically assigned to that label.  A list of existing labels can be accessed by pressing the <F6> function key.  From this list you can select an existing labeled Input Location.

Label Requirements

Labels can have up to nine characters.  The first character must be a letter.  The allowed characters are numbers, letters, and '_'.  The following labels are reserved by Edlog for expressions and should not be entered by the user:  CSI_R, CSI_2, CSI_3, . . . , CSI_95.

Entering Location Numbers

To enter the input location number instead of the label, press <ctrl> left arrow.  This will move the cursor to where the location number is entered; the computer's mouse can also be used to move the cursor.

Reps

When REPS are greater than 1, the input locations are assigned consecutive numbers (e.g., with REPS of 2 and LOC of 5, the input locations are 5 and 6).

The input location's label for each repetition is the original label with an underscore and the next consecutive number appended to the end.

Example:   With 3 REPS and a label of 'data', the labels for each REP are: data_1, data_2, and data_3.

For more information about repetitions, see Repetition Information.

Editing Input Location Numbers and Labels

The input locations are edited by selecting the Input Labels Option in the EDIT menu or by pressing F5, see input location editor screen.

Input Location Anomalies

Edlog allocates only one of the input locations needed for the following instructions.  The additional input locations must be inserted manually using the Input Location's Editor.  For information on manually inserting input locations, refer to Manually Inserting Input Locations Into Edlog.

•	Instruction 49 -- Spatial Maximum

•	Instruction 50 -- Spatial Minimum

•	Instruction 54 -- Block Move

•	Instruction 80 -- Set Active Storage Area

•	Instruction 105 -- SDI-12 Recorder

•	Instruction 106 -- SDI-12 Sensor

•	Instruction 120, Data Transfer To TGT


Manually Inserting Input Locations Into Edlog

For some instructions, Edlog does not automatically create all of the input locations that will be needed.

Example:

For Instruction 87 -- Loop, the instructions contained within the loop will be repeated the number of times specified in Parameter 2 of Instruction 87.  Instruction 87 can be configured to store the data for each output instruction in the same input location with each pass through the loop, or write the data to consecutive input locations with each pass through the loop.  Edlog does not automatically allocate the input locations when the option for consecutive input locations is chosen.  If they are not manually created and reserved for this instruction's use, other input locations could write to this area.  Therefore, the data generated from this scenario could overwrite existing locations or vice versa.

One of the simplest methods to reserve input locations for an instruction's use is to use the Insert Block function:

1.	From the Edlog menu, select Edit | Input Labels to open the Input Location Editor (or press F5 to quickly open the Editor).

2.	From the Input Location Editor's menu, choose Edit | Insert Block (or press F7).

3.	An Insert Block dialog box appears.  Type in a Base Name for the input locations.  Each input location added will have the name of the Base Name with an underscore and a consecutive number (e.g., a Base Name of Temp will create Temp_1, Temp_2, etc.).

4.	In the Starting Address field, type in the number of the first input location where you want to insert the new input location.

5.	In the Number of InLocs field, type in the number of Input Locations to be added, and select OK.

The specified number of input locations will be added at the location defined by the Starting Address field, and the input locations will be marked as Manual.  If an input location exists at the location specified by the Starting Address field, the existing input location (and any input locations that follow) will not be overwritten but will be moved to the next input location after the last of the newly inserted fields.

For more information, see:

•	Toggle Manual

•	Insert Block example


Repetition Information

Many input/output and output processing instructions have a repetition parameter.

Repetitions (REPS) allow one programming instruction to measure several identical sensors or to process data from several input locations.

Wiring Sensors

The sensors must be wired in consecutive channels.  For single-ended measurements, differential channel 1H is single-ended channel 1, 1L is single-ended channel 2, 2H is single-ended channel 3, etc.

Input Location Numbers and Labels

When REPS are greater than 1, the input locations are assigned consecutive numbers (e.g., with REPS of 2 and LOC of 5, the input locations are 5 and 6).

The input location's label for each repetition is the original label with an underscore and the next consecutive number appended to the end.

Example -- With 3 REPS and a label of 'data', the labels for each REP are: data_1, data_2, and data_3.

Only the first location of an output processing instruction is linked to the label.  Reps of input/output instructions and output processing instructions are not linked.

Example:   When the following is a section of an Edlog program, the TempC and BatteryV input locations are sampled.

  10: Temperature (107)  (P11)

   01:   1    REPS

   02:   2    Channel

   03:   1    Excitation Channel

   04:   1    Loc [TempC]

   05:   1    Mult

   06:   0    Offset

  11: Battery, Volt  (P10)

   01:   2    Loc [BatteryV]

  12: If time is  (P92)

   01:   0    minutes into interval

   02:  60    minute interval

   03:  10    Set high Flag 0 (output)

  13: Sample  (P70)

   01:   2   Reps

   02:   1   Loc [TempC]

NOTE:   If an input location is inserted between the TempC and BatteryV location, the inserted location will be sampled instead of BatteryV.


Repetition Increased Warning

If you increase the number of repetitions and at least one of the consecutive locations has been already assigned, this warning will appear.

You will have the following options:

Make Room -- the input location numbers of the other instructions will be revised so that they won't write to the repetition's locations.

Move Reps Block -- the initial input location will be reassigned another number to rectify the situation.

OK -- the situation will not be remedied; the repetitions will write to redundant input locations.

Caution:   If you select the OK button, the datalogger program will compile but the data stored in the affected input locations might be meaningless.

Cancel -- the instruction will be returned to the unedited form.


Program Tables

For the datalogger program to execute correctly, the instructions must be entered in a program table.  There are three program tables:

•	Tables 1 and 2 -- instructions for the main program can be entered in Table 1 and/or Table 2.  Both Table 1 and Table 2 have their own user-designated Execution Interval.  If only one program table is used, it's typically Table 1.

•	Table 3 (Subroutine Table) -- subroutine instructions are entered in this table.  The first instruction entered in Table 3 should always be Instruction 85 which is used to label the first subroutine.  For the subroutines to be run, a Program Control Instruction must be entered in either Table 1 or 2 that calls out the subroutine.


Program Tables

For the datalogger program to execute correctly, the instructions must be entered in a program table.  There are three program tables:

•	Tables 1 and 2 -- instructions for the main program can be entered in Table 1 and/or Table 2.  Both Table 1 and Table 2 have their own user-designated execution interval.

•	Table 3 or Subroutine Table -- subroutine instructions are entered in this table.  The first instruction entered in Table 3 should always be Instruction 85 which is used to label the first subroutine.


Execution Interval

The execution interval is the length of time (in seconds) between program executions.

Example:   When the Execution Interval is 300 sec. (5 min.), the program is executed every 5 min.

Every Edlog program must have a valid execution interval (see below) or an execution interval error occurs.  Table 1's execution interval can be 0.0 but the measurements aren't made and there is a warning.

   Valid entries are

       multiples of:	for Range of:

1/8 or 0.125 sec.	1/8 to 32 sec.

1 sec.  	32 to 8191 sec.


Execution Interval

The execution interval is the length of time (in seconds) between program executions.

   Valid entries are

       multiples of:	for Range of:

1/8 or 0.125 sec.	1/8 to 32 sec.

1 sec.  	32 to 8191 sec.

Example:   When the Execution Interval is 300 sec. (5 min.), the program is executed every 5 min.

Every Edlog program must have a valid execution interval (see below) or an execution interval error occurs.  Table 1's execution interval can be 0.0 but the measurements aren't made and there is a warning.


Empty Line

You may enter:

•	Instructions -- enter the instruction number or access the instruction dialog box by clicking the right mouse button or pressing the <shift> <insert> keys.

•	Comments -- the first character on the left must be a semi-colon.  For more information, see Comments.

•	Expressions -- enter a mathematical expression to process data or numbers.  For the rules on entering expressions, see Entering Expressions.


Unknown Text

Warning:   This text is unknown to Edlog.  If you do not edit this text before you compile the program, you will get the error, 'unrecognized text'.

Most likely, you erroneously entered one of the following:

•	Comments -- the first character on the left must be a semi-colon.  For more information, see Comments.

•	Expressions -- must start with an input location label followed by an equal sign then a +, -, label, number, or function.  For more detailed information, see Entering Expressions.


Instruction 1 - Volt, Single-Ended (SE)

An Input/Output Instruction that measures the input's voltage with respect to ground; output is in millivolts.

A similar instruction is available for differential measurements (see comparison).

Instruction 1 has the following parameters:

•	Parameter 1 -- Repetitions

•	Parameter 2 -- Range

•	Parameter 3 -- Single-Ended Channel

•	Parameter 4 -- Input Location

•	Parameter 5 -- Multiplier

•	Parameter 6 -- Offset


Comparison of Single-ended and Differential Measurements

Differential Measurements

Measure the voltage between two inputs; both inputs must be within the common mode range of +2.5 Volts.  Differential measurements may eliminate errors due to a difference in ground potential between the CR500 and the sensor, such as when external signal conditioning circuitry is powered from the same source as the CR500.  Differential measurements have better noise rejection than single-ended measurements.

Single-ended Measurements

Measure the input's voltage with respect to ground.  Twice as many channels are available for single-ended measurements.


Repetitions

The number of sensors measured with this instruction.

Each measurement uses the same range, multiplier, and offset.  The sensors must be wired in consecutive channels.

For more information, see General Repetition Information.


Repetitions

The number of sensors measured with this instruction.  Each measurement uses the same range, multiplier, and offset.  The sensors must be wired in consecutive channels.


Range

       Integration Methods

-------------------------------------------

60 Hz	50 Hz	|	Full Scale

Slow 	Fast 	  Rej 	  Rej	|	   Range

  01	  11	   21	  31	|	+   2.5 mV

  02	  12	   22	  32	|	+   7.5 mV

  03	  13	   23	  33	|	+  25 mV

  04	  14	   24	  34	|	+ 250 mV

  05	  15	   25	  35	|	+2500 mV

Example -- An entry of 15 selects the fast integration and a full scale range of +2500 mV.

For more information, see Integration Methods.


Integration Methods

Slow Integration (2.72 ms) - provides a more noise-free reading than the fast integration.

Fast Integration (250 microseconds) - minimizes time skew between measurements, has a higher throughput rate, and uses less power than the slow integration.

60 Hz Rejection - eliminates noise from AC power lines in countries that use 60 Hz power.

50 Hz Rejection - eliminates noise from AC power lines in countries that use 50 Hz power.


Single-Ended Channel

The analog channel where the sensor has been wired.  When REPS are greater than 1, this entry is the first sensor's channel.


Location

The input location which will store this instruction's first measurement.

For more information, see Input Location Information.


Multiplier

A factor that the input location value is multiplied by.  A multiplier of 1 has no effect on the input location value.

A multiplier is often used for calibration or to convert the input location value to different units.


Offset

A value that is added to or subtracted from the input location.  An offset of 0 has no effect on the input location value.

An offset is often used for calibration or to convert the data to different units.


Multiplier

A factor that the input location value is multiplied by.  A multiplier of 1 has no effect on the input location value.

A multiplier is often used for calibration or to convert the input location value to different units.


Offset

A value that is added to or subtracted from the input location.  An offset of 0 has no effect on the input location value.

An offset is often used for calibration or to convert the data to different units.


Instruction 2 - Volt, Differential

An Input/Output Instruction that measures the voltage between two inputs; both inputs must be within the common mode range of +2.5 Volts.  Output is in millivolts.

A similar instruction is available for single-ended measurements (see comparison).

Instruction 2 has the following parameters:

•	Parameter 1 -- Repetitions

•	Parameter 2 -- Range

•	Parameter 3 -- Differential Channel

•	Parameter 4 -- Input Location

•	Parameter 5 -- Multiplier

•	Parameter 6 -- Offset


Repetitions

The number of sensors measured with this instruction.  Each measurement uses the same range, multiplier, and offset.  The sensors must be wired in consecutive channels.

For more information, see General Repetition Information.


Repetitions

The number of sensors measured with this instruction.  Each measurement uses the same range, multiplier, and offset.  The sensors must be wired in consecutive channels.


Range

       Integration Methods

-------------------------------------------

60 Hz	50 Hz	|	Full Scale

Slow 	Fast 	  Rej 	  Rej	|	   Range

  01	  11	   21	  31	|	+   2.5 mV

  02	  12	   22	  32	|	+   7.5 mV

  03	  13	   23	  33	|	+  25 mV

  04	  14	   24	  34	|	+ 250 mV

  05	  15	   25	  35	|	+2500 mV

Example -- An entry of 15 selects the fast integration and a full scale range of +2500 mV.

For more information, see Integration Methods.


Differential (DIFF) Channel

The analog channel where the sensor(s) has been wired.

When REPS are greater than 1, this entry is the first sensor's channel.


Location

The input location which will store this instruction's first measurement.

For more information, see Input Location Information.


Instruction 3 -- Pulse

An Input/Output Instruction that counts high frequency, low level AC, and switch closure pulses.  This instruction's output depends on the configuration designated in parameter 3.

A 16-bit rather than 8-bit mode is also available for counting high frequency and low level AC pulses.

Instruction 3 has the following parameters:

•	Parameter 1 -- Repetitions

•	Parameter 2 -- Pulse Channel

•	Parameter 3 -- Configuration

•	Parameter 4 -- Input Location

•	Parameter 5 -- Multiplier

•	Parameter 6 -- Offset

Notes:

Pulse channel 3 is available for switch closure only.

If more than one Instruction 3 is in your program, all of them must be placed in the same table.

Pulse Count Instructions that are in a subroutine must be called from Table 2.


Repetitions

Enter the number of sensors that will be measured with this instruction.

Each measurement uses the same configuration, multiplier, and offset.  The sensors must be wired in consecutive channels.

For more information, see General Repetition Information.


Repetitions

Enter the number of sensors that will be measured with this instruction.  Each measurement uses the same configuration, multiplier, and offset.  The sensors must be wired in consecutive channels.


Pulse Channel

Enter the channel where the sensor has been wired.

Note:   The 16-bit counter option requires the sensor to be wired into pulse channel 1.  Pulse channel 3 is available for switch closure only.

When REPS are greater than 1, this entry is the first sensor's channel.

Example:   If REPS are 2 and the sensors are wired into channels P1 and P2, the correct entry is 1.


Configuration

Record	 Discard

    all    	   bad	Output	 |

counts 	 Interval	Hertz	 |                        Pulse

   00	    10	   20	 |	High Frequency (index to change

 |	from 8 Hz to 64 Hz reset)

   01	    11	   21	 |	Low Level AC (index to change from

 |	 8 Hz to 64 Hz reset)

   02	    12	   22	 |	Switch Closure

   03	    13	   23	 |	High Frequency, 16-bit counter

   04	    14	   24	 |	Low Level AC, 16-bit counter

Notes:   The 16-bit counter options require the sensor to be wired into pulse channel 1.  When using pulse channel 3 (P3), the pulse type must be switch closure (option 02, 12, or 22).

Example:    An entry of 11 selects a low level AC pulse type with the pulses discarded when they occur after the execution interval.

For more information, see Pulse Configuration Information.


Pulse Configuration Information

Pulse Types

High Frequency - pulses are incremented when the input voltage changes from below 1.5 volts to above 3.5 volts; anemometers produce high frequency pulses.

Low Level AC - the frequency of AC signals from magnetic pulse flow transducers or other low voltage, sine wave inputs are counted.

Switch Closure - the number of switch closures is counted; tipping bucket raingages are sensors with switch closures.

Notes:

High frequency and low level AC pulses can also be counted in a 16-bit rather than 8-bit mode.  The 16-bit counter has a higher maximum count rate (250 kHz whereas the 8-bit's is 2000 Hz).  The 16-bit counter option requires the sensor to be wired into pulse channel 1.

Pulse channel 3 is available for switch closure only.

Methods for Handling Excessive Intervals

Record All Counts - outputs the total number of pulses counted.  This option is required when pulse counts are totaled because missing counts can significantly affect the totaled value.

Discard Bad Interval - outputs the number of pulses counted that occurred within the execution interval.  This option is used when the pulse count's processing is dependent on the sampling interval (e.g., speed, RPM).

Output Hertz - allows the use of a conversion factor that is independent of the execution interval.


Location

Enter the input location that will store the initial pulse measurement.

For more information, see Input Location Information.


Instruction 4 - Excite, Delay, Single-Ended

An Input/Output Instruction that applies an excitation voltage, delays for a specified amount of time, and then makes a single-ended voltage measurement.

Single-ended measurements measure the input's voltage with respect to ground; output is in millivolts.  The delay minimizes settling errors.

Instruction 8 is a similar instruction but is for differential measurements (see single-ended and differential comparison).

This measurement's resistance can also be calculated.

Instruction 4 has the following parameters:

•	Parameter 1 -- Repetitions

•	Parameter 2 -- Range

•	Parameter 3 -- Single-Ended Channel

•	Parameter 4 -- Excitation Channel

•	Parameter 5 -- Delay

•	Parameter 6 -- Excitation, mV

•	Parameter 7 -- Input Location

•	Parameter 8 -- Multiplier

•	Parameter 9 -- Offset


Repetitions

Enter the number of sensors that will be measured with this instruction.  The sensors must be wired in consecutive channels.

Each measurement will use the same range, delay, excitation, multiplier, and offset.

For more information, see General Repetition Information.


Repetitions

Enter the number of sensors that will be measured with this instruction.  Each measurement will use the same range, delay, excitation, multiplier, and offset.  The sensors must be wired in consecutive channels.


Range

 Integration Methods |

Slow 	Fast	| Full Scale Range

  01	  11	|	+   2.5 mV

  02	  12	|	+   7.5 mV

  03	  13	|	+  25 mV

  04	  14	|	+ 250 mV

  05	  15	|	+2500 mV

Example -- An entry of 15 selects the fast integration and a full scale range of +2500 mV.

Note:  The 50 Hz and 60 Hz rejection is typically not used for this instruction because delays other than zero prevent the precise timing used for 50 Hz and 60 Hz rejection.  The delay is set in parameter 5.

For more information, see Integration Methods.


Single-Ended (SE) Channel

Enter the analog channel where the sensor has been wired.  When repetitions are greater than 1, this entry is the first sensor's channel.


Excitation Channel Options

1	Excites all REPS with excitation channel 1.

2	Excites all REPS with excitation channel 2.

11	Excites the first sensor with excitation channel 1 and the second sensor with excitation channel 2.


Delay, 0.01 seconds

Enter the number of seconds that the voltage measurement will be delayed.  This entry must be in increments of 0.01 seconds.


Excitation, mV

Enter the excitation voltage that will be applied.  A negative excitation voltage can be entered.


Location

Enter the input location that will store this instruction's first measurement.

For more information, see Input Location Information.


Instruction 5 -- AC Half Bridge

An Input/Output Instruction that applies an excitation voltage to a half bridge and makes a single-ended voltage measurement of the bridge output; single-ended measurements measure voltage with respect to ground.

The excitation voltage is then reversed and the measurement is repeated.  The final value is the difference between the two measurements ratioed to the excitation voltage.

Resistance can also be calculated.

Instruction 5 has the following parameters:

•	Parameter 1 -- Repetitions

•	Parameter 2 -- Range

•	Parameter 3 -- Single-Ended Channel

•	Parameter 4 -- Excitation Channel

•	Parameter 5 -- Excitation, mV

•	Parameter 6 -- Input Location

•	Parameter 7 -- Multiplier

•	Parameter 8 -- Offset


Repetitions

Enter the number of sensors that will be measured with this instruction.  Each measurement uses the same range, excitation, multiplier, and offset.

For more information, see General Repetition Information.


Repetitions

Enter the number of sensors that will be measured with this instruction.  Each measurement uses the same range, excitation, multiplier, and offset.  The sensors must be wired in consecutive channels.


Range

The slow integration is NOT used for AC half bridge measurements because of possible polarization errors.

  Integration Methods

--------------------------------

60 Hz	50 Hz	|	Full Scale

Fast 	  Rej 	  Rej	|	   Range

  11	   21	  31	|	+   2.5 mV

  12	   22	  32	|	+   7.5 mV

  13	   23	  33	|	+  25 mV

  14	   24	  34	|	+ 250 mV

  15	   25	  35	|	+2500 mV

Example -- An entry of 15 selects the fast integration and a full scale range of +2500 mV.

For more information, see Integration Methods.


Single-Ended (SE) Channel

Enter the analog channel where the sensor has been wired.  When repetitions are greater than 1, this entry is the first sensor's channel.


Excitation Channel Options

1	Excites all REPS with excitation channel 1.

2	Excites all REPS with excitation channel 2.

11	Excites the first sensor with excitation channel 1 and the second sensor with excitation channel 2.


Excitation, mV

Enter the excitation voltage that will be applied.   A negative excitation voltage can be entered.


Location

Enter the input location that will store the initial AC half bridge measurement.

For more information, see Input Location Information.


Instruction 6 -- Full Bridge

An Input/Output Instruction that applies an excitation voltage to a full bridge and makes a differential voltage measurement of the bridge output; differential measurements measure the voltage between two inputs.

The measurement is made with both a positive and a negative excitation voltage polarity.  The result is 1000 times the bridge output ratio.

Resistance can also be calculated.

Instruction 6 has the following parameters:

•	Parameter 1 -- Repetitions

•	Parameter 2 -- Range

•	Parameter 3 -- Differential Channel

•	Parameter 4 -- Excitation Channel

•	Parameter 5 -- Excitation, mV

•	Parameter 6 -- Input Location

•	Parameter 7 -- Multiplier

•	Parameter 8 -- Offset


Repetitions

Enter the number of sensors that will be measured with this instruction.  Each measurement uses the same range, excitation, multiplier, and offset.

For more information, see General Repetition Information.


Repetitions

Enter the number of sensors that will be measured with this instruction.  Each measurement uses the same range, excitation, multiplier, and offset.  The sensors must be wired in consecutive channels.


Range

Integration Methods

-------------------------------------------

60 Hz	50 Hz	|	Full Scale

Slow 	Fast 	  Rej 	  Rej	|	   Range

  01	  11	   21	  31	|	+   2.5 mV

  02	  12	   22	  32	|	+   7.5 mV

  03	  13	   23	  33	|	+  25 mV

  04	  14	   24	  34	|	+ 250 mV

  05	  15	   25	  35	|	+2500 mV

Example -- An entry of 15 selects the fast integration and a full scale range of +2500 mV.

For more information, see Integration Methods.


Differential (DIFF) Channel

Enter the analog channel where the sensor(s) has been wired.

When REPS are greater than 1, this entry is the first sensor's channel.


Excitation Channel Options

1	Excites all REPS with excitation channel 1.

2	Excites all REPS with excitation channel 2.

11	Excites the first sensor with excitation channel 1 and the second sensor with excitation channel 2.


Excitation, mV

Enter the excitation voltage that will be applied.  A negative excitation voltage can be entered.


Location

Enter the input location that will store the initial full bridge measurement.

For more information, see Input Location Information.


Instruction 7 -- 3-Wire Half Bridge Measurement

An Input/Output Instruction that applies an excitation voltage and measures the voltage of the reference resistor and the sensor's sensing wire (the reference resistor and sensing wire are wired to adjacent single-ended channels).

The excitation voltage is then reversed and the measurements are repeated.

The two measurements are used to calculate the ratio of the voltage across the sensor to the voltage across the reference resistor.

Resistance can also be calculated.

Instruction 7 has the following parameters:

•	Parameter 1 -- Repetitions

•	Parameter 2 -- Range

•	Parameter 3 -- Single-Ended Channel

•	Parameter 4 -- Excitation Channel

•	Parameter 5 -- Excitation, mV

•	Parameter 6 -- Input Location

•	Parameter 7 -- Multiplier

•	Parameter 8 -- Offset


Repetitions

Enter the number of sensors that will be measured with this instruction.  Each measurement uses the same range, excitation, multiplier, and offset.  The sensors must be wired in consecutive channels.

For more information, see General Repetition Information.


Repetitions

Enter the number of sensors that will be measured with this instruction.  Each measurement uses the same range, excitation, multiplier, and offset.  The sensors must be wired in consecutive channels.


Range

Integration Methods

-------------------------------------------

60 Hz	50 Hz	|	Full Scale

Slow 	Fast 	  Rej 	  Rej	|	   Range

  01	  11	   21	  31	|	+   2.5 mV

  02	  12	   22	  32	|	+   7.5 mV

  03	  13	   23	  33	|	+  25 mV

  04	  14	   24	  34	|	+ 250 mV

  05	  15	   25	  35	|	+2500 mV

Example -- An entry of 15 selects the fast integration and a full scale range of +2500 mV.

For more information, see Integration Methods.


Single-Ended (SE) Channel

Enter the analog channel where the sensor has been wired.  When REPS are greater than 1, this entry is the first sensor's channel.


Excitation Channel Options

1	Excites all REPS with excitation channel 1.

2	Excites all REPS with excitation channel 2.

11	Excites the first sensor with excitation channel 1 and the second sensor with excitation channel 2.


Excitation, mV

Enter the excitation voltage that will be applied.  A negative excitation voltage can be entered.


Location

Enter the input location that will store the initial 3-wire half bridge measurement.

For more information, see Input Location Information.


Instruction 8 -- Excite, Delay, Differential

An Input/Output Instruction that applies an excitation voltage, delays for a specified amount of time, and then makes a differential voltage measurement.

Differential measurements measure the voltage between two inputs; both inputs must be within the common mode range of +2.5 Volts.  The output is in millivolts.  The delay minimizes settling errors.

A similar instruction  is available for single-ended measurements (see comparison).  Resistance can also be calculated.

Instruction 8 has the following parameters:

•	Parameter 1 -- Repetitions

•	Parameter 2 -- Range

•	Parameter 3 -- Differential Channel

•	Parameter 4 -- Excitation Channel

•	Parameter 5 -- Delay

•	Parameter 6 -- Excitation, mV

•	Parameter 7 -- Input Location

•	Parameter 8 -- Multiplier

•	Parameter 9 -- Offset


Repetitions

Enter the number of sensors that will be measured with this instruction.  Each measurement uses the same range, delay, excitation, multiplier, and offset.  The sensors must be wired in consecutive channels.

For more information, see General Repetition Information.


Repetitions

Enter the number of sensors that will be measured with this instruction.  Each measurement uses the same range, delay, excitation, multiplier, and offset.  The sensors must be wired in consecutive channels.


Range

Integration Methods

 ------------------------------|	Full Scale

Slow 	Fast	|	   Range

  01	  11	|	+   2.5 mV

  02	  12	|	+   7.5 mV

  03	  13	|	+  25 mV

  04	  14	|	+ 250 mV

  05	  15	|	+2500 mV

Example -- An entry of 15 selects the fast integration and a full scale range of +2500 mV.

Note --The 50 Hz and 60 Hz rejection is not allowed for this instruction because this instruction adds delay which prevents the precise timing used for 50 Hz and 60 Hz rejection.

For more information, see Integration Methods.


Differential (DIFF) Channel

Enter the analog channel where the sensor(s) has been wired.

When REPS are greater than 1, this entry is the first sensor's channel.


Excitation Channel Options

1	Excites all REPS with excitation channel 1.

2	Excites all REPS with excitation channel 2.

11	Excites the first sensor with excitation channel 1 and the second sensor with excitation channel 2.


Delay, 0.01 seconds

Enter the number of seconds that the voltage measurement will be delayed.  This entry must be in increments of 0.01 seconds.


Excitation, mV

Enter the excitation voltage that will be applied.  A negative excitation voltage can be entered.


Location

Enter the input location that will store this instruction's first measurement.

For more information, see Input Location Information.


Inst. 9 - Full Bridge w/Excit. Compensation

An Input/Output Instruction that applies an excitation voltage and makes two differential measurements (wired in consecutive channels).

Differential measurements measure the voltage between two inputs; both inputs must be within the common mode range of +2.5 Volts.  The measurements are made with both positive and negative excitation voltage.

The result is the voltage measured on the second channel divided by the voltage measured on the first.  The specific units depend on the voltage ranges chosen.  If code 5, 15, 25, or 35 is chosen for parameter 2, the result is millivolts output per volt excitation.  Otherwise, the result is millivolts output per millivolt excitation.

This instruction can be used to make either full bridge or half bridge measurements.  Resistance for both full bridge and half bridge  measurements can be calculated.

Instruction 9 has the following parameters:

•	Parameter 1 -- Repetitions

•	Parameter 2 -- Excitation Range

•	Parameter 3 -- Bridge Range

•	Parameter 4 -- Differential Channel

•	Parameter 5 -- Excitation Channel

•	Parameter 6 -- Excitation, mV

•	Parameter 7 -- Input Location

•	Parameter 8 -- Multiplier

•	Parameter 9 -- Offset


Repetitions

Because this instruction requires the sensor to be wired into two differential channels and the CR500 only has two differential channels, this entry must be one.


Excitation Range

Integration Methods

-------------------------------------------

60 Hz	50 Hz	|	Full Scale

Slow 	Fast 	  Rej 	  Rej	|	   Range

  01	  11	   21	  31	|	+   2.5 mV

  02	  12	   22	  32	|	+   7.5 mV

  03	  13	   23	  33	|	+  25 mV

  04	  14	   24	  34	|	+ 250 mV

  05	  15	   25	  35	|	+2500 mV

Example -- An entry of 15 selects the fast integration and a full scale range of +2500 mV.

For more information, see Integration Methods.


Bridge Range

Integration Methods

-------------------------------------------

60 Hz	50 Hz	|	Full Scale

Slow 	Fast 	  Rej 	  Rej	|	   Range

  01	  11	   21	  31	|	+   2.5 mV

  02	  12	   22	  32	|	+   7.5 mV

  03	  13	   23	  33	|	+  25 mV

  04	  14	   24	  34	|	+ 250 mV

  05	  15	   25	  35	|	+2500 mV

Example -- An entry of 15 selects the fast integration and a full scale range of +2500 mV.

For more information, see Integration Methods.


Differential (DIFF) Channel

Because this instruction makes two differential measurements, each sensor should be wired into two consecutive differential channels.  This parameter's entry is the first differential channel where the sensor has been wired.


Excitation Channel Options

1	Excites all REPS with excitation channel 1.

2	Excites all REPS with excitation channel 2.


Excitation, mV

Enter the excitation voltage that will be applied.  A negative excitation voltage can be entered.


Location

Enter the input location that will store the first full bridge measurement.

For more information, see Input Location Information.


Instruction 10 - Battery Voltage

An Input/Output instruction that measures the datalogger's battery voltage (in volts) and places this measurement in an input location (parameter 1).

This instruction allows you to monitor the battery's performance.


Location

Enter the input location that will store the battery's voltage.

For a detailed description of input locations, see Input Location Information.


Instruction 11 -- Temperature (107/107B)

An Input/Output Instruction that measures the 107 and 107B thermistors.  Output is in degree Celsius.

Instruction 11 has the following parameters:

•	Parameter 1 -- Repetitions

•	Parameter 2 -- Single-Ended Channel

•	Parameter 3 -- Excitation/Integration Code

•	Parameter 4 -- Input Location

•	Parameter 5 -- Multiplier

•	Parameter 6 -- Offset


Repetitions

Enter the number of sensors that will be measured with this instruction.  Each measurement uses the same Multiplier and Offset.  The sensors must be wired in consecutive channels.

For more information, see General Repetition Information.


Repetitions

Enter the number of sensors that will be measured with this instruction.  Each measurement uses the same multiplier and offset.

The sensors must be wired in consecutive channels.


Single-Ended (SE) Channel

Enter the analog channel where the sensor has been wired.  When REPS are greater than 1, this entry will be the first sensor's channel.


Excitation/Integration Codes

Code	Result

  0x 	Excite all REPS with excitation channel x.

  11	Excites the first sensor with excitation channel 1 and the second sensor with excitation channel 2.

  2x	Excite all REPs with channel x, 60 Hz rejection, 10 ms delay.

  3x	Excite all REPs with channel x, 50 Hz rejection, 10 ms delay.

  41	Excites the first sensor with excitation channel 1 and the second sensor with excitation channel 2, 60 Hz rejection, 10 ms delay.

  51	Excites the first sensor with excitation channel 1 and the second sensor with excitation channel 2, 50 Hz rejection, 10 ms delay.

Examples:

If the code is 01, all REPS are excited with excitation channel E1.


Location

Enter the input location that will store the first temperature measurement.

For more information, see Input Location Information.


Instruction 12 -- Relative Humidity (207)

An Input/Output Instruction that measures relative humidity with the 207 probe.  The output is in percent RH.

Instruction 12 has the following parameters:

•	Parameter 1 -- Repetitions

•	Parameter 2 -- Single-Ended Channel

•	Parameter 3 -- Excitation Channel

•	Parameter 4 -- Temperature Location

•	Parameter 5 -- R.H. Location

•	Parameter 6 -- Multiplier

•	Parameter 7 -- Offset


Repetitions

Enter the number of sensors that will be measured with this instruction.  Each measurement uses the same multiplier and offset.  The sensors must be wired in consecutive channels.

For more information, see General Repetition Information.


Repetitions

Enter the number of sensors that will be measured with this instruction.  Each measurement uses the same multiplier and offset.

The sensors must be wired in consecutive channels.


Single-Ended (SE) Channel

Enter the analog channel where the sensor has been wired.  When REPS are greater than 1, this entry is the first sensor's channel.


Excitation Channel Options

1	Excites all REPS with excitation channel 1.

2	Excites all REPS with excitation channel 2.

11	Excites the first sensor with excitation channel 1 and the second sensor with excitation channel 2.


Temperature Location

Enter the input location that holds the reference temperature measurement.

For more information, see Input Location Information.


Relative Humidity Location

Enter the input location that will store the first relative humidity measurement.

For more information, see Input Location Information.


Instruction 16 - RTD Temperature

A Processing Instruction that converts the resistance of a Platinum Resistance Thermometer (PRT) to temperature.  If a multiplier of 1 and an offset of 0 are used, the output is in degrees Celsius.

The input to the temperature calculation is the ratio of the PRT resistance at the temperature being measured (Rs) to its resistance at 0 degrees C (Ro).  A bridge measurement (Instruction 6  with Instruction 59, Instruction 7, or Instruction 9) is used to measure the PRT in a bridge and to calculate the ratio, Rs/Ro.

Instruction 16 has the following parameters:

•	Parameter 1 -- Repetitions

•	Parameter 2 -- R/R0 Location

•	Parameter 3 -- Input Location

•	Parameter 4 -- Multiplier

•	Parameter 5 -- Offset


Repetitions

Enter the number of sensors that will be measured with this instruction.  Each measurement uses the same R/R0 ratio, multiplier, and offset.  The sensors must be wired in consecutive channels.

For more information, see Repetition Information.


Repetitions

Enter the number of sensors that will be measured with this instruction.  Each measurement uses the same R/R0 location, multiplier, and offset.

The sensors must be wired in consecutive channels.


R/R0 Location

Enter the input location that holds the R/R0 ratio.

For more information, see Input Location Information.


Location

Enter the input location that will store the first temperature measurement.

For more information, see Input Location Information.


Instruction 17 - Internal Temperature

An Input/Output Instruction that measures the CR500's internal temperature in degrees Celsius and places the temperature in an input location (parameter 1).


Location

Enter the input location that will store the internal temperature measurement.

For a detailed description of input locations, see Input Location Information.


Instruction 18 - Time

An Input/Output Instruction that divides the current time by a number specified in parameter 2 and stores the remainder.

The actual time can be stored by entering, for parameter 2, a 0 or a number greater than the maximum.

Instruction 18 has the following parameters:

•	Parameter 1 -- Option Codes

•	Parameter 2 -- Mod/By

•	Parameter 3 -- Input Location


Option Codes Description
Option Codes

0	seconds into minute (max 59)

1	minutes into day (max 1439)

2	hours into year (max 8784 on leap year, 8760 otherwise)

3	store year, day, hour, minutes, seconds in 5 consecutive locations (modulo divide not used).


Mod/By

Enter the number that the current time will be modulo divided by; enter zero to store the current time.


Location

Enter the input location that will store the time.

If code 3 is chosen for parameter 1, this location will store the year; consecutive locations will store the day, hour, minute, and second.

For more information, see Input Location Information.


Instruction 19 - Signature

An Input/Output Instruction that stores the signature of the ROM and RAM in an input location (parameter 1).

This instruction allows the user to detect program changes or ROM failure.

The signature is determined by the CR500 PROM, the size of RAM, and the entries in the *1, *2, *3, *A, and *C modes.

Note:   This is not the *B mode's signature.


Location

Enter the input location that will store the signature.

For a detailed description of input locations, see Input Location Information.


Instruction 20 - Set Port

An Input/Output Instruction that sets or configures the control ports.

Instruction 20 has the following parameters:

•	Parameter 1 -- NOT USED

•	Parameter 2 -- Configure Port 1


NOT USED

This entry is always zero because the parameter is not used for this instruction.


Configure port 1

Code	Description

   0	Set low

   1	Set high

   2	Toggle

   3	1 ms duration

   4	10 ms duration

   5	100 ms duration

   6	1 s duration

   7 	Configure as output

   8	Configure as input

   9	No change


Instruction 21 - Pulse Port with Duration

An Input/Output Instruction that pulses a control port for a specified amount of time in hundredths of seconds.

The pulse works as a toggle (e.g., if the port is high before the instruction is executed, it will pulse low).

Any value less than 1, including 0, gives a pulse of 10 milliseconds.  The maximum input value is limited to 65,000 which gives a pulse length of 650 seconds.

Instruction 21 has the following parameters:

•	Parameter 1 -- Control Port

•	Parameter 2 -- Input Location


Control Port

Enter the number of the port that will be pulsed.


Input Location

Enter the input location that holds the pulse length.

For a detailed description of input locations, see Input Location Information.


Instruction 22 - Excitation with Delay

An Input/Output Instruction that is used with other instructions to measure a response to a timed excitation.

This instruction turns on the excitation for a specified amount of time; after the excitation is turned off, the program is delayed a specified amount of time.

Instruction 22 has the following parameters:

•	Parameter 1 -- Excitation Channel

•	Parameter 2 -- Delay with Excitation

•	Parameter 3 -- Delay after Excitation

•	Parameter 4 -- Excitation or Input Location


Excitation Channel

Enter the excitation channel where the sensor has been wired.

When this entry is indexed, parameter 4 becomes an input location.  For more information about indexing parameters, see Indexing Parameters.


Excitation Channel

Enter the excitation channel where the sensor has been wired.

When this entry is indexed, parameter 4 becomes an input location.


Delay with Excitation

Enter the amount of time that the excitation will be applied.

This entry must be greater than 0 and entered in increments of 0.01 seconds.


Delay after Excitation

Enter the amount of time the program will be delayed after the excitation has been turned off.

This entry must be greater than 0 and entered in increments of 0.01 seconds.


Excitation or Input Location

Excitation (mV) -- enter the excitation voltage in millivolts.  Index this entry for a negative voltage.  For information about indexing parameters, see Indexing Parameters.

Input Location -- if parameter 1 has been indexed, enter the input location that holds the excitation voltage.  For a detailed description of input locations, see Input Location Information.


Excitation or Input Location

Excitation (mV) -- enter the excitation voltage in millivolts.  Index this entry for a negative voltage.

Input Location -- if parameter 1 has been indexed, enter the input location that holds the excitation voltage.


Instruction 24 - Calibration

An Input/Output Instruction that implements a complete calibration when this instruction occurs in the program.

The calibration will be stored in 19 consecutive input locations.  The first input location is designated in parameter 1.

Note:    The automatic calibration is disabled (see comparison of Instruction 24 and automatic calibration).  By pressing the F4 function key when entering parameter 1's first entry, the automatic calibration is not disabled and the automatic calibration results are stored in the input locations.  If -99999 appears in any of the locations, the CR500 has a hardware problem or requires factory calibration.


Instruction 24 versus Automatic Calibration

Instruction 24's calibration takes approximately 2.8 seconds to complete, whereas the automatic calibration has a 15 minute time constant.

Instruction 24's calibration is advantageous over automatic calibrations for applications where:

•	The CR500 is exposed to extreme temperature gradients.

•	Automatic calibration interferes with the sampling rate, and the ambient temperature is stable enough to allow calibration at specific points during program execution.


Location

Enter the first input location for the calibration values; 19 consecutive locations are used.

To store the automatic calibration values, press the F4 function key before entering the location number.

For a detailed description of input locations, see Input Location Information.


Instruction 25 - Read Ports

An Input/Output Instruction that reads the status of a group of ports and places the status in an input location (parameter 2).

The mask (parameter 1) designates the group of ports that are read.

The number stored in the input location is the sum of the values of the ports that are set high.  For the status reading, the ports have the following values:

PORT  	VALUE

  C2	     2

  C1	     1

Examples:

The following examples assume all ports are read (i.e., a mask value of 3):

•	When ports C1 and C2 are set high, 3 (2 + 1) is stored.

•	When only C2 is set high, 2 is stored.

•	When no ports are set high, 0 is stored.


Mask

Enter the sum of the values that correspond to the desired ports:

PORT  	VALUE

  C2	     2

  C1	     1


Location

Enter the input location that will store the status of the ports.

For a detailed description of input locations, see Input Location Information.


Instruction 26 - Timer

An Input/Output Instruction that measures the number of seconds that has elapsed since the specified conditions have occurred.

The time will be stored in an input location (parameter 1).

Note:   This instruction resets the timer when a 0 is entered for parameter 1.  Time is tracked in 0.125 second increments.


Location

Enter the input location that will store the time in seconds; the timer is reset by entering a zero.

For a detailed description of input locations, see Input Location Information.


Instruction 27 - Period Average, SE

An Input/Output Instruction that measures a time period for a specified number of cycles of an input frequency, then divides the time period by the number of cycles, obtaining the average period of a single cycle.

The output units can either be microseconds or kHz.  This is a single-ended measurement.

Instruction 27 has the following parameters:

•	Parameter 1 -- Repetitions

•	Parameter 2 -- Option/Range

•	Parameter 3 -- Single-Ended Channel

•	Parameter 4 -- Number of Cycles

•	Parameter 5 -- Time-Out (0.01 sec)

•	Parameter 6 -- Input Location

•	Parameter 7 -- Multiplier

•	Parameter 8 -- Offset


Repetitions

Enter the number of sensors that will be measured with this instruction.  The sensors must be wired in consecutive channels.

Each measurement uses the same option/gain, number of cycles, time-out, multiplier, and offset.

For more information, see General Repetition Information.


Repetitions

Enter the number of sensors that will be measured with this instruction.  The sensors must be wired in consecutive channels.

Each measurement uses the same option/gain, number of cycles, time-out, multiplier, and offset.


Option/Range

Code	Max. Freq.

  x1	8 kHz @ 2 mV peak-to-peak

  x2	20 kHz @ 3 mV peak-to-peak

  x3	50 kHz @ 12 mV peak-to-peak

  x4	200 kHz @ 2 V peak-to-peak

 Where:	x = 0   Output period in microseconds

x = 1   Output frequency in kHz


Single-Ended (SE) Channel

Enter the analog channel where the sensor has been wired.  When REPS are greater than 1, this entry is the first sensor's channel.


Number of Cycles

Enter the number of cycles that will be measured.


Time Out

Enter the maximum length of time (in units of 0.01 sec.) the instruction will wait for the specified number of cycles.

This entry should be at least the maximum duration of the number of cycles specified + 1 1/2 cycles.  If the specified number of cycles has not occurred within this time period, the input location will store -99999.


Location

Enter the input location that will store the first period average.

For more information, see Input Location Information.


Instruction 28 - Vibrating Wire, SE

An Input/Output Instruction that excites a vibrating wire sensor with a swept frequency (from low to high), then measures the period of the response and calculates 1/T^2, where T is the period in ms.

An AVW1 or AVW4 Vibrating Wire Interface is usually required with these sensors.

Instruction 28 has the following parameters:

•	Parameter 1 -- Repetitions

•	Parameter 2 -- Single-Ended Channel

•	Parameter 3 -- Excitation Channel

•	Parameter 4 -- Start Frequency

•	Parameter 5 -- End Frequency

•	Parameter 6 -- Number of Cycles

•	Parameter 7 -- Delay, 0.01 sec.

•	Parameter 8 -- Input Location

•	Parameter 9 -- Multiplier

•	Parameter 10 -- Offset


Repetitions

Enter the number of sensors that will be measured with this instruction.  The sensors must be wired in consecutive channels.

By pressing the F4 function before entering the REPS value, the excitation is only applied to the first REP.  Otherwise, each REP uses the same excitation.  Each measurement also uses the same starting frequency, ending frequency, number of cycles, delay, multiplier, and offset.

For more information, see General Repetition Information.


Repetitions

Enter the number of sensors that will be measured with this instruction.  The sensors must be wired in consecutive channels.

By pressing the F4 function before entering the REPS value, the excitation is only applied to the first REP.  Otherwise, each REP uses the same excitation.  Each measurement also uses the same starting frequency, ending frequency, number of cycles, delay, multiplier, and offset.


Single-Ended (SE) Channel

Enter the analog channel where the sensor has been wired.  When REPS are greater than 1, this entry is the first sensor's channel.


Excitation Channel Options

1	Excites all REPS with excitation channel 1.

2	Excites all REPS with excitation channel 2.

11	Excites the first sensor with excitation channel 1 and the second sensor with excitation channel 2.


Starting Frequency

Enter in hundreds of Hz the lowest frequency of the sweep.


Ending Frequency

Enter in hundreds of Hz the highest frequency of the sweep.


Number of Cycles

Enter the number of cycles that will be measured.  An entry of 0 measures no cycles.


Delay, 0.01 seconds

Enter the amount of time before the excitation will be applied to the next repetition.


Location

Enter the input location that will store the first 1/T^2 value.

For more information, see Input Location Information.


Instruction 29 -- INW Enhanced Temperature Transducer

An Input/Output Instruction that measures an Instrumentation Northwest, Inc. enhanced temperature transducer.

This instruction measures pressure and temperature.  These measurements are stored in two consecutive input locations starting at the location specified in parameter 3.

Instruction 29 has the following parameters:

•	Parameter 1 -- Differential Channel

•	Parameter 2 -- Excitation Channel

•	Parameter 3 -- Destination Location

•	Parameter 4 -- Pressure Range

•	Parameter 5 -- Enhanced Parameter 2

•	Parameter 6 -- Enhanced Parameter 3

•	Parameter 7 -- Enhanced Parameter 4

•	Parameter 8 -- Enhanced Parameter 5

•	Parameter 9 -- Enhanced Parameter 6

•	Parameter 10 -- Enhanced Parameter 7

•	Parameter 11 -- Enhanced Parameter 8

•	Parameter 12 -- Enhanced Parameter 9

•	Parameter 13 -- Enhanced Parameter 10

•	Parameter 14 -- Enhanced Parameter 11

•	Parameter 15 -- Enhanced Parameter 12

•	Parameter 16 -- Enhanced Parameter 13

•	Parameter 17 -- Enhanced Parameter 14

•	Parameter 18 -- Enhanced Parameter 15

•	Parameter 19 -- Enhanced Parameter 16

•	Parameter 20 -- Enhanced Parameter 17

•	Parameter 21 -- Enhanced Parameter 18

•	Parameter 22 -- Enhanced Parameter 19

•	Parameter 23 -- Enhanced Parameter 20


Differential (DIFF) Channel

Enter a one.  This sensor requires two adjacent differential channels.


Excitation Channel

Enter the excitation channel where the sensor has been wired.


Destination Location

Enter the input location that will store the pressure measurement.  The next consecutive location will automatically store the sensor's temperature.

For more information, see Input Location Information.


Pressure Range (PSIG)

Enter the PSIG range listed on the manufacturer's calibration sheet.


Enhanced Parameter 2

Enter the second Enhanced Measurement Parameter listed on the manufacturer's calibration sheet.


Enhanced Parameter 3

Enter the third Enhanced Measurement Parameter listed on the manufacturer's calibration sheet.


Enhanced Parameter 4

Enter the fourth Enhanced Measurement Parameter listed on the manufacturer's calibration sheet.


Enhanced Parameter 5

Enter the fifth Enhanced Measurement Parameter listed on the manufacturer's calibration sheet.


Enhanced Parameter 6

Enter the sixth Enhanced Measurement Parameter listed on the manufacturer's calibration sheet.


Enhanced Parameter 7

Enter the seventh Enhanced Measurement Parameter listed on the manufacturer's calibration sheet.


Enhanced Parameter 8

Enter the eighth Enhanced Measurement Parameter listed on the manufacturer's calibration sheet.


Enhanced Parameter 9

Enter the ninth Enhanced Measurement Parameter listed on the manufacturer's calibration sheet.


Enhanced Parameter 10

Enter the tenth Enhanced Measurement Parameter listed on the manufacturer's calibration sheet.


Enhanced Parameter 11

Enter the eleventh Enhanced Measurement Parameter listed on the manufacturer's calibration sheet.


Enhanced Parameter 12

Enter the twelfth Enhanced Measurement Parameter listed on the manufacturer's calibration sheet.


Enhanced Parameter 13

Enter the thirteenth Enhanced Measurement Parameter listed on the manufacturer's calibration sheet.


Enhanced Parameter 14

Enter the fourteenth Enhanced Measurement Parameter listed on the manufacturer's calibration sheet.


Enhanced Parameter 15

Enter the fifteenth Enhanced Measurement Parameter listed on the manufacturer's calibration sheet.


Enhanced Parameter 16

Enter the sixteenth Enhanced Measurement Parameter listed on the manufacturer's calibration sheet.


Enhanced Parameter 17

Enter the seventeenth Enhanced Measurement Parameter listed on the manufacturer's calibration sheet.


Enhanced Parameter 18

Enter the eighteenth Enhanced Measurement Parameter listed on the manufacturer's calibration sheet.


Enhanced Parameter 19

Enter the nineteenth Enhanced Measurement Parameter listed on the manufacturer's calibration sheet.


Enhanced Parameter 20

Enter the twentieth Enhanced Measurement Parameter listed on the manufacturer's calibration sheet.


Instruction 30 --  Z = F

A Processing Instruction that stores a fixed value (F) in an input location (Z).  The fixed value is in scientific notation.

Instruction 30 has the following parameters:

•	Parameter 1 -- F (mantissa)

•	Parameter 2 -- Exponent of 10

•	Parameter 3 -- Z  (Input Location)

A maximum of four digits can be entered for the mantissa (decimal points and negative signs do not count as digits).  When the entire number is less than or equal to four digits, it can be entered in the mantissa's parameter with a zero entered in parameter 2.

Examples:

For a fixed value of 3255, parameter 1's entry is 3255 and parameter 2's entry is 0.

For a fixed value of -32, parameter 1's entry is -32 and parameter 2's entry is 0, or parameter 1's entry is -3.2 and parameter 2's entry is 1 (-32 = -3.2 x 10^1).

For a fixed value of 400,000 (4 x 10^5 in scientific notation), parameter 1's entry is 4 and parameter 2's entry is 5.

For a fixed value of 0.00004 (4 x 10^(-5) in scientific notation), parameter 1's entry is 4 and parameter 2's entry is -5.


F (fixed floating-point number)

Enter the mantissa.

A maximum of four digits can be entered for the mantissa (decimal points and negative signs do not count as digits).  When the entire number is less than or equal to four digits, it can be entered in this parameter with a zero entered in parameter 2.

Examples:

For a fixed value of 3255, this entry is 3255.

For a fixed value of -32, this entry is -32 assuming parameter 2 is 0 or this entry is -3.2 assuming parameter 2 is 1.

For a fixed value of 400,000 (4 x 10^5 in scientific notation), this entry is 4.

For a fixed value of 0.00004 (4 x 10^(-5) in scientific notation), this entry is 4.


Exponent of 10

Enter the exponent of 10.

A maximum of four digits can be entered for the mantissa (decimal points and negative signs do not count as digits).  When the entire number is less than or equal to four digits, it can be entered in the mantissa's parameter with a zero entered in this parameter.

Examples:

For a fixed value of 3255, this entry is 0 (3255 x 10^0 = 3255).

For a fixed value of -32, this entry is 0 when parameter 1's entry is -32 (-32 x 10^0=-32); this entry is 1 when parameter 1's entry is -3.2 (-3.2 x 10^1 = -32).

For a fixed value of 400,000 (4 x 10^5 in scientific notation), this entry is 5.

For a fixed value of 0.00004 (4 x 10^(-5) in scientific notation), this entry is -5.


Z

Enter the input location that will store the fixed value.

For a detailed description of input locations, see Input Location Information.


Instruction 31 --  Z = X

A Processing Instruction that stores an input location's value in an another input location.

Instruction 31 has the following parameters:

•	Parameter 1 -- X  (Input Location)

•	Parameter 2 -- Z  (Input Location)


X

Enter the original input location.

For a detailed description of input locations, see Input Location Information.


Z

Enter the input location that will store the value that is currently in input location X.

For a detailed description of input locations, see Input Location Information.


Instruction 32 --  Z = Z + 1

A Processing Instruction that adds a 1 to the value stored in an input location (parameter 1).

Example:   If 2 is originally stored in input location 5, this instruction will store a 3 in input location 5.


Z

Enter the input location.

For a detailed description of input locations, see Input Location Information.


Instruction 33 -- Z = X + Y

A Processing Instruction that adds the value stored in an input location (X) to the value stored in another location (Y).

Instruction 33 has the following parameters:

•	Parameter 1 -- X  (Input Location)

•	Parameter 2 -- Y  (Input Location)

•	Parameter 3 -- Z  (Input Location)


X

Enter the first input location.

For a detailed description of input locations, see Input Location Information.


Y

Enter the second input location.

For a detailed description of input locations, see Input Location Information.


Z

Enter the input location that will store the sum of the values that are stored in the other input locations.

For a detailed description of input locations, see Input Location Information.


Instruction 34 --  Z = X + F

A Processing Instruction that adds the value stored in an input location to a fixed number.

Instruction 34 has the following parameters:

•	Parameter 1 -- X (Input Location)

•	Parameter 2 -- F (fixed number)

•	Parameter 3 -- Z (Input Location)


X

Enter the input location that holds the value that will be added to the fixed floating point number (F).

For a detailed description of input locations, see Input Location Information.


F (fixed floating-point number)

Enter the number that will be added to the value in input location X.


Z

Enter the input location that will store the sum.

For a detailed description of input locations, see Input Location Information.


Instruction 35 --  Z = X - Y

A Processing Instruction that subtracts the value contained in an input location (Y) from the value contained in another input location (X).

Instruction 35 has the following parameters:

•	Parameter 1 -- X  (Input Location)

•	Parameter 2 -- Y  (Input Location)

•	Parameter 3 -- Z  (Input Location)


X

Enter the first input location.

For a detailed description of input locations, see Input Location Information.


Y

Enter the input location whose value will be subtracted from the value contained in the other location.

For a detailed description of input locations, see Input Location Information.


Z

Enter the input location that will store the result.

For a detailed description of input locations, see Input Location Information.


Instruction 36 --  Z = X * Y

A Processing Instruction that multiplies the value contained in an input location (X) to the value contained in another input location (Y).

Instruction 36 has the following parameters:

•	Parameter 1 -- X  (Input Location)

•	Parameter 2 -- Y  (Input Location)

•	Parameter 3 -- Z  (Input Location)


X

Enter the first input location.

For a detailed description of input locations, see Input Location Information.


Y

Enter the second input location.

For a detailed description of input locations, see Input Location Information.


Z

Enter the input location that will store the product.

For a detailed description of input locations, see Input Location Information.


Instruction 37 --  Z = X * F

A Processing Instruction that multiplies the value stored in an input location (X) by a fixed floating point number (F).

Instruction 37 has the following parameters:

•	Parameter 1 -- X (Input Location)

•	Parameter 2 -- F (fixed number)

•	Parameter 3 -- Z (Input Location)


X

Enter the input location that holds the value that is multiplied by the fixed number (F).

For a detailed description of input locations, see Input Location Information.


F  (fixed floating point number)

Enter the number that will be multiplied by the value stored in input location X.


Z

Enter the input location that will store the product.

For a detailed description of input locations, see Input Location Information.


Instruction 38 --  Z = X/Y

A Processing Instruction that divides the value contained in an input location (X) by the value contained in another input location (Y).

When the value contained in Y is the number zero, 99999 will be stored.

Instruction 38 has the following parameters:

•	Parameter 1 -- X  (Input Location)

•	Parameter 2 -- Y  (Input Location)

•	Parameter 3 -- Z  (Input Location)


X

Enter the input location that will contain the numerator.

For a detailed description of input locations, see Input Location Information.


Y

Enter the input location that will contain the denominator.

When this input location's value is the number zero, 99999 will be stored in input location Z.

For a detailed description of input locations, see Input Location Information.


Z

Enter the input location that will store the result.  This location will store 99999 when the value contained in Y is the number zero.

For a detailed description of input locations, see Input Location Information.


Instruction 39 -- Z = SQRT(X)

A Processing Instruction that takes the square root of the value contained in an input location (X) and stores the result in another input location (Z).

When the value in X is negative, zero is stored in input location Z.

Instruction 39 has the following parameters:

•	Parameter 1 -- X  (Input Location)

•	Parameter 2 -- Z  (Input Location)


X

Enter the input location.  When the value stored in this location is negative, zero will be stored in Z.

For a detailed description of input locations, see Input Location Information.


Z

Enter the input location that will store the square root.  Zero is stored in this location when the value contained in X is negative.

For a detailed description of input locations, see Input Location Information.


Instruction 40 -- Z = LN(X)

A Processing Instruction that takes the natural logarithm of the value contained in an input location (X) and stores the result in another input location (Z).

When the value contained in X is zero or negative, -99999 is stored in Z.

Instruction 40 has the following parameters:

•	Parameter 1 -- X  (Input Location)

•	Parameter 2 -- Z  (Input Location)


X

Enter the input location.

When the value contained in this location is zero or negative, -99999 will be stored in Z.

For a detailed description of input locations, see Input Location Information.


Z

Enter the input location that will store the natural log.

When the value contained in X is zero or negative, -99999 is stored in this location.

For a detailed description of input locations, see Input Location Information.


Instruction 41 -- Z = EXP(X)

A Processing Instruction that raises "base e" to the power of the value contained in an input location (X).  The result is stored in another input location (Z).

Instruction 41 has the following parameters:

•	Parameter 1 -- X  (Input Location)

•	Parameter 2 -- Z  (Input Location)

Examples:

When X contains a 5, the number stored is e^5 (148.41).

When X contains a 1, the number stored is e^(1) which equals e (2.72).

When X contains a -1, the number stored is e^(-1) which equals 1/e (0.37).

When X contains a -2, the number stored is e^(-2) which equals 1/(e^2).

When X contains a 0, the number stored is e^0 which equals 1.


X

Enter the input location that contains the exponent.

For a detailed description of input locations, see Input Location Information.


Z

Enter the input location that will store the result.

For a detailed description of input locations, see Input Location Information.


Instruction 42 --  Z = 1/X

A Processing Instruction that takes the inverse of the value contained in an input location (X) and stores the result in another input location (Z).

When the value contained in X is zero, 99999 is stored.

Instruction 42 has the following parameters:

•	Parameter 1 -- X  (Input Location)

•	Parameter 2 -- Z  (Input Location)

Examples:

When X contains a 2, 0.5 (1/2 = 0.5) is stored.

When X contains 0.5, 2 (1/(0.5) = 2) is stored.

When X contains a -2, -0.5 is stored.

When X contains -0.5, -2 is stored.


X

Enter an input location.

If the value contained in this location is zero, 99999 will be stored.

For a detailed description of input locations, see Input Location Information.


Z

Enter the input location that will store the inverse.

When the value contained in X is zero, 99999 will be stored in this location.

For a detailed description of input locations, see Input Location Information.


Instruction 43 --  Z = ABS(X)

A Processing Instruction that takes the absolute value of the number stored in an input location (X) and stores the result in another input location (Z).

Instruction 43 has the following parameters:

•	Parameter 1 -- X  (Input Location)

•	Parameter 2 -- Z  (Input Location)

Examples:

If X contains a 5, 5 is stored in Z.

If X contains a -5, 5 is stored in Z.


X

Enter the input location that contains the value.

For a detailed description of input locations, see Input Location Information.


Z

Enter the input location that will store the absolute value.

For a detailed description of input locations, see Input Location Information.


Instruction 44 --  Z = FRAC(X)

A Processing Instruction that takes the fractional portion (i.e., the numbers to the right of the decimal) of the value contained in an input location (X).  The result is stored in another input location (Z).

Instruction 44 has the following parameters:

•	Parameter 1 -- X  (Input Location)

•	Parameter 2 -- Z  (Input Location)

Examples:

When the value contained in X is 6, .0 is stored.

When the value contained in X is 6.25, .25 is stored.

When the value contained in X is 0.25, .25 is stored.


X

Enter the input location that holds the number.

For a detailed description of input locations, see Input Location Information.


Z

Enter the input location that will store the fractional portion of the number.

For a detailed description of input locations, see Input Location Information.


Instruction 45 --  Z = INT(X)

A Processing Instruction that takes the integer portion (truncates the decimal portion) of the value stored in an input location (X).  The result is stored in another input location (Z).

Instruction 45 has the following parameters:

•	Parameter 1 -- X  (Input Location)

•	Parameter 2 -- Z  (Input Location)

Examples:

When the value contained in X is 6, 6 is stored.

When the value contained in X is 6.75, 6 is stored.

When the value contained in X is 0.75, 0 is stored.


X

Enter the input location that holds the floating point number.

For a detailed description of input locations, see Input Location Information.


Z

Enter the input location that will store the integer portion of the number.

For a detailed description of input locations, see Input Location Information.


Instruction 46 --  Z = X MOD F

A Processing Instruction that divides the value contained in an input location (X) by a fixed floating point number (F) and then stores the remainder in another input location (Z).

When F is zero, the number stored in Z is the number contained in X.

Instruction 46 has the following parameters:

•	Parameter 1 -- X (Input Location)

•	Parameter 2 -- F (fixed number)

•	Parameter 3 -- Z (Input Location)

Examples:

If X contains a 6 and F is 0, the number that will be stored in Z is 6.

If X contains a 10 and F is 5, the number that will be stored in Z is 0.

If X contains a 13 and F is 5, the number that will be stored in Z is 3.

If X contains a 0 and F is 7, the number that will be stored in Z is 0.  (When X contains a 0, the number stored in Z will always be 0.)


X

Enter the input location that contains the number that will be divided by the fixed number.

For a detailed description of input locations, see Input Location Information.


F (fixed floating point number)

Enter the number that will divide the value stored in the input location.


Z

Enter the input location that will store the remainder.

For a detailed description of input locations, see Input Location Information.


Instruction 47 --  Z = X ^ Y

A Processing Instruction that raises the value contained in an input location (X) to the value contained in another input location (Y) and stores the result in a third input location (Z).

Instruction 47 has the following parameters:

•	Parameter 1 -- X  (Input Location)

•	Parameter 2 -- Y  (Input Location)

•	Parameter 3 -- Z  (Input Location)

Examples:

When the value contained in X is a 2 and the value contained in Y is a 3, Z will store an 8 (2^3 = 8).

When the value contained in X is a 2 and the value contained in Y is a -2, Z will store a 0.25 (2^(-2) = 1/(2^2) = 1/4).

When the value contained in X is a 4 and the value contained in Y is 0.5, Z will store a 2 (4^(0.5) = square root of 4 = 2).

When the value contained in X is a 4 and the value contained in Y is -0.5, Z will store a 0.5 (4^(-0.5) = 1/(4^(0.5)) = 1/2).

When the value contained in X is a 4 and the value contained in Y is 0, Z will store a 1 (4^0 = 1; any number to the zero power, including zero, equals 1).

When the value contained in X is a 0 and the value contained in Y is 4, Z will store a 0 (0^4 = 0; zero to the power of any number other than 0 equals 0).


X

Enter the input location that contains the base.

For a detailed description of input locations, see Input Location Information.


Y

Enter the input location that contains the exponent.

For a detailed description of input locations, see Input Location Information.


Z

Enter the input location that will store the result.

For a detailed description of input locations, see Input Location Information.


Instruction 48 --  Z = SIN(X)

A Processing Instruction that calculates the sine of the value contained in an input location (X); the value is in degrees.  The result is stored in another input location (Z).

Trigonometric identities allow this instruction to be used for other trigonometric functions.

Instruction 48 has the following parameters:

•	Parameter 1 -- X  (Input Location)

•	Parameter 2 -- Z  (Input Location)


Trigonometric Identities

   Trig   	Inst

 Function	Identity  	used

  cos(x)	sin(x+90)	P34, P48

  tan(x)	(sin(x))/(sin(x+90))	P48, P34, P48, P38

  cot(x)	(sin(x+90))/(sin(x))	P34, P48, P48, P38

  sec(x)	1/sin(x)  	P48, P42

  csc(x)	1/sin(x+90)	P34, P48, P42


X

Enter the input location that contains the angle in degrees.

For a detailed description of input locations, see Input Location Information.


Z

Enter the input location that will store the sine.

For a detailed description of input locations, see Input Location Information.


Instruction 49 -- Spatial Maximum

A Processing Instruction that detects the spatial maximum of a group of input locations.

This instruction can also record the number of the input location that contained the spatial maximum.

Instruction 49 has the following parameters:

•	Parameter 1 -- Swath

•	Parameter 2 -- 1st Location

•	Parameter 3 -- Maximum Location

Note:   Edlog allocates only one of the input locations needed for this instruction.  The additional input locations must be inserted manually using the Input Location Editor.  For information on manually inserting input locations, refer to Manually Inserting Input Locations Into Edlog.


Swath

Enter the number of input locations used for finding the spatial maximum.


1st Location

Enter the initial input location.

For a detailed description of input locations, see Input Location Information.


Maximum Option

0xxx   	Stores the spatial maximum in location xxx.

1xxx   	Stores the spatial maximum in location xxx and the number of the input location that contained the maximum value is stored in location xxx+1.

Note:   To enter, press <ctrl> left arrow or use the computer's mouse to move the cursor to where the location number is entered.

Examples:

When this entry is 0012, the maximum is stored in input location 12.

When this entry is 1012, the maximum is stored in input location 12 and the input location number that contained the maximum is stored in input location 13.

For a detailed description of input locations, see Input Location Information.


Maximum Option

0xxx   	Stores the spatial maximum in location xxx.

1xxx   	Stores the spatial maximum in location xxx and the number of the input location that contained the maximum value is stored in location xxx+1.

Note:   To enter, press <ctrl> left arrow or use the computer's mouse to move the cursor to where the location number is entered.


Instruction 50 -- Spatial Minimum

A Processing Instruction that detects the spatial minimum of a group of input locations.

This instruction can also record the number of the input location that contained the minimum.

Instruction 50 has the following parameters:

•	Parameter 1 -- Swath

•	Parameter 2 -- 1st Location

•	Parameter 3 -- Minimum Location

Note:   Edlog allocates only one of the input locations needed for this instruction.  The additional input locations must be inserted manually using the Input Location Editor.  For information on manually inserting input locations, refer to Manually Inserting Input Locations Into Edlog.


Swath

Enter the number of input locations used for finding the spatial minimum.


1st Location

Enter the initial input location.

For a detailed description of input locations, see Input Location Information.


Minimum Option

0xxx   	Stores the spatial minimum in location xxx.

1xxx   	Stores the spatial minimum in location xxx and the number of the input location that contained the minimum value is stored in location xxx+1.

Note:   To enter, press <ctrl> left arrow or use the computer's mouse to move the cursor to where the location number is entered.

Examples:

When this entry is 0012, the minimum is stored in input location 12.

When this entry is 1012, the minimum is stored in input location 12 and the input location number that contained the minimum is stored in input location 13.

For a detailed description of input locations, see Input Location Information.


Minimum Option

0xxx   	Stores the spatial minimum in location xxx.

1xxx   	Stores the spatial minimum in location xxx and the number of the input location that contained the minimum value is stored in location xxx+1.

Note:   To enter, press <ctrl> left arrow or use the computer's mouse to move the cursor to where the location number is entered.


Instruction 51 -- Spatial Average

A Processing Instruction that detects the spatial average of a group of input locations.

Instruction 51 has the following parameters:

•	Parameter 1 -- Swath

•	Parameter 2 -- 1st Location

•	Parameter 3 -- Average Location


Swath

Enter the number of input locations used for finding the spatial average.


1st Location

Enter the initial input location.

For a detailed description of input locations, see Input Location Information.


Average Location

Enter the input location that will store the average.

For a detailed description of input locations, see Input Location Information.


Instruction 52 -- Running Average

A Processing Instruction that computes a running average.

The most recent n values (where n is the number specified in parameter 4) are kept in intermediate storage.  When this instruction is executed, the current value writes over the oldest value then the average is calculated and stored in the destination location.

Instruction 52 has the following parameters:

•	Parameter 1 -- Repetitions

•	Parameter 2 -- Source Location

•	Parameter 3 -- Destination Location

•	Parameter 4 -- Number of Values (n)


Repetitions

Enter the number of running averages that will be computed.

For more information, see General Repetition Information.


Repetitions

Enter the number of running averages that will be computed.


1st Source Location

Enter the initial input location that contains the values that will be used to compute the running average.  Repetitions must be stored in consecutive locations.

For a detailed description of input locations, see Input Location Information.


1st Destination Location

Enter the input location that will store the initial running average.  The running averages of the repetitions will be stored in consecutive locations.

For a detailed description of input locations, see Input Location Information.


Number of Values in Average Window (n)

Enter the number of values that will be used to compute the running averages.


Instruction 53 --  A * X + B

A Processing Instruction that for 4 input locations multiplies the input location's value with a number (fixed floating point) then adds another number (fixed floating point) to the product and places the result in the original input location.

Instruction 53 has the following parameters:

•	Parameter 1 -- Start Location

•	Parameter 2 -- A1

•	Parameter 3 -- B1

•	Parameter 4 -- A2

•	Parameter 5 -- B2

•	Parameter 6 -- A3

•	Parameter 7 -- B3

•	Parameter 8 -- A4

•	Parameter 9 -- B4

Example:

For the following:

Input	Input Loc	Mult	Add

Loc No	Value (X)	 (A)	(B)

   12	     5	  2	-4

   13	     3	  1	 5

   14	   10	  6	 0

   15	   33	  0	 6

 Input location 12 will contain:    (5 x 2) + (-4) = (5 x 2) - 4 = 6.

 Input location 13 will contain:     (3 x 1) + 5 = 8.

 Input location 14 will contain:    (10 x 6) + 0 = 60.

 Input location 15 will contain:    (33 x 0) + 6 = 6


Start Location

Enter the initial input location whose value will be multiplied by the number entered in parameter 2 and that product will be added to parameter 3.

For a detailed description of input locations, see Input Location Information.


A1 (fixed floating point number)

Enter the number that will be multiplied by the value contained in the initial input location.


B1 (fixed floating point number)

Enter the number that will be added to the product of A1 and the initial input location's value.


A2 (fixed floating point number)

Enter the number that will be multiplied by the value contained in the second input location.


B2 (fixed floating point number)

Enter the number that will be added to the product of A2 and the second input location's value.


A3 (fixed floating point number)

Enter the number that will be multiplied by the value contained in the third input location.


B3 (fixed floating point number)

Enter the number that will be added to the product of A3 and the third input location's value.


A4 (fixed floating point number)

Enter the number that will be multiplied by the value contained in the fourth input location.


B4 (fixed floating point number)

Enter the number that will be added to the product of A4 and the fourth input location's value.


Instruction 54 -- Block Move

A Processing Instruction that copies the values stored in a group of input locations to another group of input locations.

Note:   Edlog allocates only one of the input locations needed for this instruction.  The additional input locations must be inserted manually using the Input Location Editor.  For information on manually inserting input locations, refer to Manually Inserting Input Locations Into Edlog.

Instruction 54 has the following parameters:

•	Parameter 1 -- Number of Values

•	Parameter 2 -- Source Location

•	Parameter 3 -- Source Step

•	Parameter 4 -- Destination Location

•	Parameter 5 -- Destination Step

The number of values, source location, and source step parameters determine which values are copied.

Examples:

For the following examples, the number of values is 4 and the source location is 1:

•	When the source step is 1, the values stored in locations 1, 2, 3, & 4 will be copied.

•	When the source step is 2, the values stored in locations 1, 3, 5, & 7 will be copied.

•	When the source step is 10, the values stored in locations 1, 11, 21, & 31 will be copied.

The destination location and destination step parameters determine where the values will be copied.

Examples:

For the following examples, the number of values is 4 and the destination location is 11:

•	When the destination step is 1, the values will be copied into locations 11, 12, 13, & 14.

•	When the destination step is 2, the values will be copied into locations 11, 13, 15, & 17.

•	When the destination step is 10, the values will be copied into locations 11, 21, 31, & 41.


Number of Values

Enter the number of values that will be copied.


Source Location

Enter the input location that holds the first value that will be copied.  For a detailed description of input locations, see Input Location Information.

Note:   The source step will determine the other values that will be copied.


Source Step

The following method determines the group of values that will be copied:

 Source Step

      Entry         	Copies the values from:

0	the source location into every destination location (this can be used to initialize a block of input locations with the same value such as 0)

1	consecutive locations

2	every other location

.

.

.

n	every nth location

Examples:

For the following examples, the number of values is 4 and the source location is 1:

•	When the source step is 1, the values stored in locations 1, 2, 3, & 4 will be copied.

•	When the source step is 2, the values stored in locations 1, 3, 5, & 7 will be copied.

•	When the source step is 10, the values stored in locations 1, 11, 21, & 31 will be copied.


Destination Location

Enter the input location where the first value will be copied.

For a detailed description of input locations, see Input Location Information.

Note:   The destination step determines where the other values will be copied.


Destination Step

The following method determines where the values are copied:

  Dest. Step

      Entry         	Values are copied into:

1	consecutive locations

2	every other location

.

.

.

n	every nth location

Examples:

For the following examples, the number of values is 4 and the destination location is 11:

•	When the destination step is 1, the values will be copied into locations 11, 12, 13, & 14.

•	When the destination step is 2, the values will be copied into locations 11, 13, 15, & 17.

•	When the destination step is 10, the values will be copied into locations 11, 21, 31, & 41.


Instruction 55 -- 5th Order Polynomial

A Processing Instruction that evaluates the following equation:

 F(X)=C0+C1X+C2(X^2)+C3(X^3)+C4(X^4)+C5(X^5)

Where

X -- a value stored in an input location.

C0  through  C5 -- coefficients (floating point numbers).  Coefficients outside the range of +99999 must be prescaled.

Instruction 55 has the following parameters:

•	Parameter 1 -- Repetitions

•	Parameter 2 -- X (Input Location)

•	Parameter 3 -- F(X)

•	Parameter 4 -- C0

•	Parameter 5 -- C1

•	Parameter 6 -- C2

•	Parameter 7 -- C3

•	Parameter 8 -- C4

•	Parameter 9 -- C5


Pre-scaling Coefficients

The X value can be scaled to change coefficients that are originally out of the +99999 range.  X is also scaled when the coefficients are close to 0 increasing the significant digits.

The X value is scaled by using Instruction 37 to multiply the X value with a fixed number (scaled value).  The scaled value can be any number that will put the coefficient within range without putting the other coefficients out of range.  When the X value is scaled, the coefficients must be changed to the following:

 C0 = C0

 C1 = C1/(scaled value)

 C2 = C2/(scaled value)^2

 C3 = C3/(scaled value)^3

 C4 = C4/(scaled value)^4

 C5 = C5/(scaled value)^5

Example:

If the original equation is:

 F(X) = 1+10X+100X^2+1000X^3+10,000X^4+100,000X^5

Coefficient C5 (100,000) is outside the range of +99999.  By using Instruction 37 with an F of 10, the coefficients become:

 C0 = 1

 C1 = 10/10 = 1

 C2 = 100/(10)^2 = 1

 C3 = 1000/(10)^3 = 1

 C4 = 10,000/(10)^4 = 1

 C5 = 100,000/(10)^5 = 1

The equation is now:

 G(X) = 1 + X + X^2 + X^3 + X^4 + X^5

Coefficient C5 is now within range.


Repetitions

Enter the number of polynomials that will be calculated.  Each polynomial uses the same coefficients (parameters 4 through 9).

For more information, see General Repetition Information.


Repetitions

Enter the number of polynomials that will be calculated.  Each polynomial uses the same coefficients (parameters 4 through 9).


X

Enter the initial input location.

For a detailed description of input locations, see Input Location Information.


F(X)

Enter the input location that will store the result.

For a detailed description of input locations, see Input Location Information.


C0 (floating point number)

Enter the C0 coefficient for the equation:

 F(X)=C0+C1X+C2(X^2)+C3(X^3)+C4(X^4)+C5(X^5)


C1 (floating point number)

Enter the C1 coefficient for the equation:

 F(X)=C0+C1X+C2(X^2)+C3(X^3)+C4(X^4)+C5(X^5)


C2 (floating point number)

Enter the C2 coefficient for the equation:

 F(X)=C0+C1X+C2(X^2)+C3(X^3)+C4(X^4)+C5(X^5)


C3 (floating point number)

Enter the C3 coefficient for the equation:

 F(X)=C0+C1X+C2(X^2)+C3(X^3)+C4(X^4)+C5(X^5)


C4 (floating point number)

Enter the C4 coefficient for the equation:

 F(X)=C0+C1X+C2(X^2)+C3(X^3)+C4(X^4)+C5(X^5)


C5 (floating point number)

Enter the C5 coefficient in the equation:

 F(X)=C0+C1X+C2(X^2)+C3(X^3)+C4(X^4)+C5(X^5)


Inst. 56 -- Saturation Vapor Pressure

A Processing Instruction that calculates saturation vapor pressure over water (SVPW) in kilopascals from air temperature (degree Celsius) and stores the SVPW in an input location.

The saturation vapor pressure over ice (0 to -50 degree C temperature range) can also be calculated.

Instruction 56 has the following parameters:

•	Parameter 1 -- Temperature Location

•	Parameter 2 -- Vapor Pressure Location


Vapor Pressure Over Ice

The saturation vapor pressure over ice (SVPI) is calculated with the following equation:

 SVPI = -0.0486 + 0.85471X + 0.2441X^2

Where X is the SVPW calculated by Instruction 56.

The SVPI equation is calculated with Instruction 55 using these coefficients:

C0 = -0.0486	C3 = 0

C1 = 0.85471	C4 = 0

C2 = 0.2441	C5 = 0


Temperature

Enter the input location that holds the temperature measurement.

For a detailed description of input locations, see Input Location Information.

Note:   The temperature must be in degrees Celsius.


Location

Enter the input location that will store the SVPW value.

For a detailed description of input locations, see Input Location Information.


Instruction 57 -- Vapor Pressure from Wet/Dry-Bulb Temperatures

A Processing Instruction that calculates vapor pressure (kilopascals) from wet and dry-bulb temperatures (degrees Celsius) and air pressure (kilopascals).

Often, the daily fluctuation in air pressure is small enough that a fixed entry of the standard pressure for the site's elevation is sufficient.  For increased accuracy, a pressure sensor can be used to provide the current air pressure.

Instruction 57 has the following parameters:

•	Parameter 1 -- Pressure Location

•	Parameter 2 -- Dry-Bulb Temperature Location

•	Parameter 3 -- Wet-Bulb Temperature Location

•	Parameter 4 -- Vapor Pressure Location


Pressure (kilopascals)

Enter the input location that holds the air pressure value.

For a detailed description of input locations, see Input Location Information.


Dry-Bulb Temperature (degrees Celsius)

Enter the input location that stores the dry-bulb temperature.

For a detailed description of input locations, see Input Location Information.


Wet-Bulb Temperature (degrees Celsius)

Enter the input location that stores the wet-bulb temperature.

For a detailed description of input locations, see Input Location Information.


Location

Enter the input location that will store the vapor pressure (kilopascals).

For a detailed description of input locations, see Input Location Information.


Instruction 58 -- Low Pass Filter

A Processing Instruction that approximates a number for an analog resistor low pass filter with the following equation:

 F(Xi) = W*Xi + F(Xi-1)*(1-W)

 Where:	Xi = input sample,

W = user-specified weighting function where:

0 < W < 1

If W = 0, F(X1) = X1

if W = 1, F(X1) = X

F(Xi-1) = output calculated for previous sample.

On the first execution after compiling, F(X) is set equal to X.

Instruction 58 has the following parameters:

•	Parameter 1 -- Repetitions

•	Parameter 2 -- Input X

•	Parameter 3 -- Result X

•	Parameter 4 -- Weighted F


Repetitions

Enter the number of low pass filter calculations that will be performed.

For more information, see General Repetition Information.


Repetitions

Enter the number of low pass filter calculations that will be performed.


Sample

Enter the first input location that will hold the values that are sampled (e.g., the Xi values in the following equation).

F(Xi) = W*Xi + F(Xi-1)*(1-W)

For a detailed description of input locations, see Input Location Information.


Result X

Enter the input location that will store the result.

For a detailed description of input locations, see Input Location Information.


Weighting Factor

Enter the user-specified weighting factor.

F(Xi) = W*Xi + F(Xi-1)*(1-W)

Where:	0 < W < 1

if W = 0, F(X1) = X1

if W = 1, F(X1) = X


Instruction 59 -- Bridge Transform

A Processing Instruction that calculates resistance (Rs) with the following equation:

 Rs = Rf(X/(1-X))

Instruction 59 has the following parameters:

•	Parameter 1 -- Repetitions

•	Parameter 2 -- X (input location)

•	Parameter 3 -- Rf (fixed multiplier)

Typically X is the input location that stores the value derived by Instructions 4, 5, 6, 8, or 9 (full bridge only) and the appropriate multiplier and offset.

The Rf value depends on whether Instruction 4, Instruction 5, or Instructions 6, 8, or 9 (full bridge only) is used.  The result is stored in the original input location.


Resistance for Instruction 4

RESISTANCE FOR X = Vx(Rs/(Rs+Rf)

Resistance	Inst.#  Mult; Offset

Rf * X/Vx 	Inst. 4   Mult=1/Vx; offset=0

Rs =	 1-X/Vx   	Inst. 59   Mult=Rf

 	Rs * (1-X/Vx)  	Inst. 4  Mult=1/Vx; offset=0

 Rf =         X/Vx	Inst. 59 Mult=1/Rs

Inst. 42


Resistance for Instruction 5

RESISTANCE FOR X = Rs/(Rs+Rf)

Resistance	Inst.#  Mult; Offset

(Rf) * X  	Inst. 5   Mult=1; offset=0

Rs =      1-X	Inst. 59   Mult=Rf

Rs * (1-X)	Inst. 5   Mult=1; offset=0

 Rf =          X	Inst. 59 Mult=1/Rs

Inst. 42


Resistance for Instructions 6, 8, & 9 (full bridge only)

RESISTANCE FOR X=1000[R3/(R3+R4)-R2/(R1+R2)]

Resistance	Inst.#   Mult; Offset

Inst 6,9 Mult=-0.001;

Inst. 8  Mult=1/Vx;

R2 * (1-X1)	Inst.6,8,9 offset = R3/(R3+R4)

 R1 =         X1  	Inst. 59   Mult = 1/R2

Inst.42

where,

X1 =(-X/1000) + (R3)/( R3+R4)

 ----------------------------------------------------------------------

 R2 =(X2/(1-X2))	Inst 6,9 Mult=-0.001;

     offset = R3/(R3+R4)

 where, X2 = X1	Inst. 59   Mult = R1

 ----------------------------------------------------------------------

 R3 = R4 * (X3/(1-X3))	Inst. 6,9 Mult=0.001;

      offset = R2/(R1+R2)

 	Inst. 59   Mult = R4

where,

X3 = (X/1000) + R2/(R1+R2)

 ----------------------------------------------------------------------

 R4 = R3 * (1-X4)/X4	Inst. 6,9 Mult=0.001;

      offset = R2/(R1+R2)

Inst. 59  Mult = 1/R3

 where, X4 = X3	Inst. 42


Resistance for Instructions 7 and 9 (half bridge only)

RESISTANCE FOR X = Rs/Rf

Resistance	Inst.#  Mult; Offset

Rs = Rf(X)	Inst. 7, 9  Mult=Rf; offset=0

Rf = Rs/X	Inst. 7, 9 Mult=1/Rs; offset=0

Inst. 42


Repetitions

Enter the number of times that the equation Rs=Rf(X/(1-X)) will be calculated.  Each repetition uses the same Rf.

For more information, see General Repetition Information.


Repetitions

Enter the number of times that the equation Rs=Rf(X/(1-X)) will be calculated.


X

Enter the initial input location.

For a detailed description of input locations, see Input Location Information.


Multiplier (Rf)

Enter the Rf value for this equation Rs=Rf(X/(1-X)).

The Rf value depends on whether Instruction 4, Instruction 5, or Instructions 6, 8, or 9 (full bridge only) is used.


Multiplier (Rf)

Enter the Rf value for this equation Rs=Rf(X/(1-X)).


Instruction 61 -- Indirect Move

A Processing Instruction that copies data from one input location to another.  This is called an indirect move because each parameter refers to an input location, which contains an input location of the value to be moved.

Instruction 61 has the following parameters:

•	Parameter 1 -- Source X (Input Location)

•	Parameter 2 -- Destination X (Input Location)


Source X

Enter the input location that contains the input location of the value to be copied.

If this parameter is indexed, the actual input location is calculated by adding the current index counter to the value in the specified input location.  For information about indexing parameters, see Indexing Parameters.

For a detailed description of input locations, see Input Location Information.


Destination X

Enter the input location that contains the input location for the destination of parameter 1.

If this parameter is indexed, the actual input location is calculated by adding the current index counter to the value in the specified input location.  For information about indexing parameters, see Indexing Parameters.

For a detailed description of input locations, see Input Location Information.


Instruction 63 -- Extended Parameters

A Processing Instruction that is used immediately after Instruction 97 to enter RF IDs, phone numbers, and optional modem command strings.  For more information, see Parameter Entries.

This instruction can be entered several times in a sequence.


Instruction 63 or 68 Parameter Entry

Enter one of the following:

•	An "88" (first parameter only) to increase the delay between the time the datalogger initiated call is made and the time the call-back ID is sent.

•	The length of the delay (second parameter only) when you have entered an "88" for the first parameter

•	A single-digit of the phone number

•	A single-digit of an RF ID

•	A "32" to separate RF IDs (ASCII code for space)

•	A "70" after last RF ID (ASCII code for F)

•	An "84" between an RF ID and a phone number (ASCII code for T)

•	A "13" to complete the string (ASCII code for "carriage return")

•	An ASCII code for the next character of an optional modem command string (for more information, see ASCII characters).

The datalogger will automatically send the following modem commands before the phone number:

ATV0   	The phone modem uses numeric result codes rather than words.

ATS7=180	The phone modem waits 180 seconds for carrier.

ATDT    	The phone modem dials the phone number using "Touch Tones".

For more information, see the following examples:

•	Datalogger-to-Phone Example

•	Datalogger-to-RF Example

•	Datalogger-to-RF-to-Phone Example


Parameter 1

Enter a single-digit of an RF ID or phone number or the appropriate ASCII code.

-or-

Enter an 88 to increase the delay between the time the datalogger initiated call is made and the time the 3-digit call-back ID is sent.


Parameter 2

Enter a single-digit of an RF ID or phone number or the appropriate ASCII code.

-or-

When you have entered an 88 first parameter, enter the length of the delay.


Parameter 3

Enter a single-digit of an RF ID or phone number or the appropriate ASCII code.


Parameter 4

Enter a single-digit of an RF ID or phone number or the appropriate ASCII code.


Parameter 5

Enter a single-digit of an RF ID or phone number or the appropriate ASCII code.


Parameter 6

Enter a single-digit of an RF ID or phone number or the appropriate ASCII code.


Parameter 7

Enter a single-digit of an RF ID or phone number or the appropriate ASCII code.


Parameter 8

Enter a single-digit of an RF ID or phone number or the appropriate ASCII code.


Datalogger-to-Phone Example

The following is a section of a Datalogger program that uses Instruction 97 and Instruction 63 or 68 to transmit data via phone modem:

 08:  Initiate Telecommunications (P97)

   01:     21	Phone Modem/1200 Baud

   02:       1	Disabled when Flag 1 is High

   03:     80	Seconds Call Time Limit

   04: 3600	Seconds Before Fast Retry

   05:       2	Fast Retries

   06: 1440	Minutes before Slow Retry

   07:       1	Failures Loc [ Failures ]

   08:   123	Call-back ID

 ; Enter phone number 555-9701

 09:  Extended Parameters (P63 or P68)

   01:       5	Option (first digit of phone #)

   02:       5	Option (second digit of phone #)

   03:       5	Option (third digit of phone #)

   04:       9	Option (fourth digit of phone #)

   05:       7	Option (fifth digit of phone #)

   06:       0	Option (sixth digit of phone #)

   07:       1	Option (last digit of phone #)

   08:     13	Option (completes the string)


Datalogger-to-RF-to-Phone Example

The following is a section of a Datalogger program that uses Instruction 97 and Instruction 63 or 68 to transmit data from an RF station to a computer via a phone modem:

 08:  Initiate Telecommunications (P97)

   01:     01	RF Modem/1200 Baud

   02:       1	Disabled when Flag 1 is High

   03:   360	Seconds Call Time Limit

   04: 3600	Seconds Before Fast Retry

   05:       3	Fast Retries

   06: 1440	Minutes before Slow Retry

   07:       1	Failures Loc [ Failures ]

   08:   234	Call-back ID

 ; Enter the RF ID (ID# 255) then start entering

 ; the phone number (555-9701) at the PC

 09:  Extended Parameters (P63 or P68)

  01:       2	Option (first digit of RF ID)

  02:       5	Option (second digit of RF ID)

  03:       5	Option (last digit of RF ID)

  04:     32	Option (ends RF IDs)

  05:     84	Option (separates RF and Phone)

  06:       5	Option (first digit of phone #)

  07:       5	Option (second digit of phone #)

  08:       5	Option (third digit of phone #)

 ; Enter the last digits of the phone number

 10:  Extended Parameters (P63 or P68)

   01:       9	Option (fourth digit of phone #)

   02:       7	Option (fifth digit of phone #)

   03:       0	Option (sixth digit of phone #)

   04:       1	Option (last digit of phone #)

   05:     13	Option (completes the string)

   06:       0	Option (unused parameter)

   07:       0	Option (unused parameter)

   08:       0	Option (unused parameter)


Datalogger-to-RF Example

The following is a section of a Datalogger program that uses Instruction 97 and Instruction 63 or 68 to transmit data via an RF modem:

 08:  Initiate Telecommunications (P97)

   01:     02	RF Modem/9600 Baud

   02:       1	Disabled when Flag 1 is High

   03:   360	Seconds Call Time Limit

   04: 3600	Seconds Before Fast Retry

   05:       3	Fast Retries

   06: 1440	Minutes before Slow Retry

   07:       1	Failures Loc [ Failures ]

   08:   220	Call-back ID

 ; Enter RF ID (ID# 255)

 09:  Extended Parameters (P63 or P68)

  01:       2	Option (first digit of RF ID)

  02:       5	Option (second digit of RF ID)

  03:       5	Option (last digit of RF ID)

  04:     70	Option (after last RF ID)

  05:     13	Option (completes the string)

  06:       0	Option (unused parameter)

  07:       0	Option (unused parameter)

  08:       0	Option (unused parameter)


Decimal Characters

The following tables lists the decimal characters that represent the ASCII characters.

•	Table 1 -- lists CONTROL, SPACE, and DEL characters

•	Table 2 -- lists punctuation and mathematical symbols

•	Table 3 -- lists numbers

•	Table 4 -- lists letters


Table 1 -- Decimal Characters for Control Characters, Spaces, & Delete

    ASCII	|	    ASCII

 Decimal	Characters	|	Decimal	Characters

      0	CONTROL @	|	     17	CONTROL Q

      1	CONTROL A	|	     18	CONTROL R

      2	CONTROL B	|	     19	CONTROL S

      3	CONTROL C	|	     20	CONTROL T

      4	CONTROL D	|	     21	CONTROL U

      5	CONTROL E	|	     22	CONTROL V

      6	CONTROL F	|	     23	CONTROL W

      7	CONTROL G	|	     24	CONTROL X

      8	CONTROL H	|	     25	CONTROL Y

      9	CONTROL I	|	     26	CONTROL Z

    10	CONTROL J	|	     27	CONTROL [

     11	CONTROL K	|	     28	CONTROL \

     12	CONTROL L	|	     29	CONTROL ^

     13	CONTROL M	|	     30	CONTROL ]

     14	CONTROL N	|	     31	CONTROL _

     15	CONTROL O	|	     32	SPACE

     16	CONTROL P	|	    127	DEL


Table 2 -- Decimal Characters for Punctuation and Math Symbols

    ASCII	|	    ASCII

 Decimal	Characters	|	Decimal	Characters

     33	       !	|	     59	         ;

     34	       "	|	     60	        <

     35	       #	|	      61	        =

     36	       $	|	      62	        >

     37	       %	|	      63	        ?

     38	       &	|	      64	       @

     39	        '	|	      91	        [

     40	        (	|	      92	        \

     41	         )	|	      93	        ]

     42	         *	|	      94	        ^

     43	        +	|	      95	        _

     44	         ,	|	      96	        `

     45	         -	|	     123	         {

     46	         .	|	     124	         |

     47	         /	|	     125	         }

     58	         :	|	     126	        ~


Table 3 -- Decimal Characters for Numbers

    ASCII

 Decimal	Characters

      48	       0

      49	       1

      50	       2

      51	       3

      52	       4

      53	       5

      54	       6

      55	       7

      56	       8

      57	       9


Table 4 -- Decimal Characters for Letters

    ASCII	|	    ASCII

 Decimal	Characters	|	Decimal	Characters

      65	        A	|	      97	        a

      66	        B	|	      98	        b

      67	        C	|	      99	        c

      68	        D	|	     100	        d

      69	        E	|	     101	        e

      70	        F	|	     102	         f

      71	        G	|	     103	        g

      72	        H	|	     104	        h

      73	         I	|	     105	         i

      74	        J	|	     106	         j

      75	        K	|	     107	        k

      76	        L	|	     108	         l

      77	        M	|	     109	       m

      78	        N	|	     110	        n

      79	        O	|	     111	        o

      80	        P	|	     112	        p

      81	        Q	|	     113	        q

      82	        R	|	     114	         r

      83	        S	|	     115	        s

      84	        T	|	     116	         t

      85	        U	|	     117	        u

      86	        V	|	     118	        v

      87	        W	|	     119	       w

      88	        X	|	     120	        x

      89	        Y	|	     121	        y

      90	        Z	|	     122	        z


Instruction 65 -- Bulk Load

A Processing Instruction that loads up to eight fixed values into input locations.

Instruction 65 has the following parameters:

•	Parameter 1 -- F (fixed floating point number)

•	Parameter 2 -- F (fixed floating point number)

•	Parameter 3 -- F (fixed floating point number)

•	Parameter 4 -- F (fixed floating point number)

•	Parameter 5 -- F (fixed floating point number)

•	Parameter 6 -- F (fixed floating point number)

•	Parameter 7 -- F (fixed floating point number)

•	Parameter 8 -- F (fixed floating point number)

•	Parameter 9 -- Input Location


Parameter 1 (F)

Enter the first fixed value.


Parameter 2 (F)

Enter the second fixed value.


Parameter 3 (F)

Enter the third fixed value.


Parameter 4 (F)

Enter the fourth fixed value.


Parameter 5 (F)

Enter the fifth fixed value.


Parameter 6 (F)

Enter the sixth fixed value.


Parameter 7 (F)

Enter the seventh fixed value.


Parameter 8 (F)

Enter the eighth fixed value.


Location

Enter the input location that will store the first fixed value.  The other values will be stored in consecutive locations.

For a detailed description of input locations, see Input Location Information.


Instruction 66 -- Arctangent

A Processing Instruction that calculates the angle (degrees) whose tangent is X/Y.  The signs of X and Y will determine the quadrant of the angle:

Sign	Sign

 Quadrant	of X	of Y	 Angle (degrees)

         I 	  +	  +	       0 to 90

        II 	  +	   -	     90 to 180

       III 	   -	   -	   180 to 270

       IV 	   -	  +	   270 to 0

Instruction 66 has the following parameters:

•	Parameter 1 -- X  (Input Location)

•	Parameter 2 -- Y  (Input Location)

•	Parameter 3 -- Z  (Input Location)


X

Enter the input location that will contain the X value of arctan X/Y.  The signs of X and Y will determine the quadrant of the angle:

Sign	Sign

 Quadrant	of X	of Y	 Angle (degrees)

         I 	  +	  +	       0 to 90

        II 	  +	   -	     90 to 180

       III 	   -	   -	   180 to 270

       IV 	   -	  +	   270 to 0

For a detailed description of input locations, see Input Location Information.


Y

Enter the input location that will contain the Y value of arctan X/Y.  The signs of X and Y will determine the quadrant of the angle:

Sign	Sign

 Quadrant	of X	of Y	 Angle (degrees)

         I 	  +	  +	       0 to 90

        II 	  +	   -	     90 to 180

       III 	   -	   -	   180 to 270

       IV 	   -	  +	   270 to 0

If 0 is entered for this parameter the value stored in Z will be the arc tangent of X.  The result will be limited to +90 degrees.

For a detailed description of input locations, see Input Location Information.


Z

Enter the input location that will store the arctangent.  The signs of X and Y will determine the quadrant of the angle that's stored in this input location:

Sign	Sign

 Quadrant	of X	of Y	 Angle (degrees)

         I 	  +	  +	       0 to 90

        II 	  +	   -	     90 to 180

       III 	   -	   -	   180 to 270

       IV 	   -	  +	   270 to 0

For a detailed description of input locations, see Input Location Information.


Instruction 68
Instruction 68 -- Extended Parameter, 4-digit

A Processing Instruction that is used immediately after Instruction 97 to enter RF IDs, phone numbers, and optional modem command strings.  For more information, see Parameter Entries.

This instruction can be entered several times in a sequence.


Parameter 1

Enter a single-digit of an RF ID, phone number, or the appropriate ASCII code, or enter an 88 to increase the delay between the time the datalogger initiated call is made and the time the 3-digit call-back ID is sent.


Parameter 2

Enter a single-digit of an RF ID or phone number or the appropriate ASCII code or when you have entered an 88 for the first parameter, enter the length of the delay.


Parameter 3

Enter a single-digit of an RF ID or phone number or the appropriate ASCII code.


Parameter 4

Enter a single-digit of an RF ID or phone number or the appropriate ASCII code.


Parameter 5

Enter a single-digit of an RF ID or phone number or the appropriate ASCII code.


Parameter 6

Enter a single-digit of an RF ID or phone number or the appropriate ASCII code.


Parameter 7

Enter a single-digit of an RF ID or phone number or the appropriate ASCII code.


Parameter 8

Enter a single-digit of an RF ID or phone number or the appropriate ASCII code.


Instruction 70 -- Sample

An Output Processing Instruction that when the output flag is set high, copies the current values from the specified input location(s) to final storage.

When Repetitions are greater than 1, this instruction will copy consecutive input locations.

Instruction 70 has the following parameters:

•	Parameter 1 -- Repetitions

•	Parameter 2 -- Input Location


Repetitions

Enter the number of input locations whose values will be copied to final storage.

For more information, see General Repetition Information.


Repetitions

Enter the number of input locations whose values will be copied to final storage.


Location

Enter the initial input location.  Repetitions must be stored in consecutive locations.

For a detailed description of input locations, see Input Location Information.


Instruction 71 -- Average

An Output Processing Instruction that averages the values in the specified input location(s) since the last output interval and stores this average in final storage.

Instruction 71 has the following parameters:

•	Parameter 1 -- Repetitions

•	Parameter 2 -- Input Location


Repetitions

Enter the number of input locations whose values will be averaged over the given output interval.

For more information, see General Repetition Information.


Repetitions

Enter the number of input locations whose values will be averaged over the given output interval.


Location

Enter the initial input location.  Repetitions must be stored in consecutive locations.

For a detailed description of input locations, see Input Location Information.


Instruction 72 -- Totalize

An Output Processing Instruction that stores the totaled value over the given output interval for each specified input location.

Instruction 72 has the following parameters:

•	Parameter 1 -- Repetitions

•	Parameter 2 -- Input Location


Repetitions

Enter the number of input locations whose values will be totaled over the given output interval.

For more information, see General Repetition Information.


Repetitions

Enter the number of input locations whose values will be totaled over the given output interval.


Location

Enter the initial input location.  Repetitions must be stored in consecutive locations.

For a detailed description of input locations, see Input Location Information.


Instruction 73 -- Maximum

An Output Processing Instruction that stores the maximum value of the given output interval for each specified input location.

An internal flag is set whenever a new maximum occurs.  This flag can be tested with Instruction 79.  The time when the maximum value(s) occur can also be stored.

Instruction 73 has the following parameters:

•	Parameter 1 -- Repetitions

•	Parameter 2 -- Time of Maximum Options

•	Parameter 3 -- Input Location


Repetitions

Enter the number of input locations.

For more information, see General Repetition Information.


Repetitions

Enter the number of input locations.


Time of Maximum Options

00	Store maximum value only (time of max. not stored).

01	Store time of maximum in seconds.

10	Store time of maximum in hours and minutes.

11	Store time of maximum in hours, minutes, and seconds.


Location

Enter the initial input location.  Repetitions must be stored in consecutive locations.

For a detailed description of input locations, see Input Location Information.


Instruction 74 -- Minimum

An Output Processing Instruction that stores the minimum value of the given output interval for each specified input location.

An internal flag is set whenever a new minimum occurs.  This flag can be tested with Instruction 79.  The time when the minimum value(s) occur can also be stored.

Instruction 74 has the following parameters:

•	Parameter 1 -- Repetitions

•	Parameter 2 -- Time of Minimum Options

•	Parameter 3 -- Input Location


Repetitions

Enter the number of input locations.

For more information, see General Repetition Information.


Repetitions

Enter the number of input locations.


Time of Minimum Options

00	Store minimum value only (time of min. not stored).

01	Store time of minimum in seconds.

10	Store time of minimum in hours and minutes.

11	Store time of minimum in hours, minutes, and seconds.


Location

Enter the initial input location.  Repetitions must be stored in consecutive locations.

For a detailed description of input locations, see Input Location Information.


Instruction 77 -- Record Real Time

An Output Processing Instruction that records the current time in Final Storage.

You have several options for recording the current time (see Parameter 1 -- Time Options).


Time Options

Code	Time Option

 xxx1	Seconds (with a resolution of 0.125 sec.)

 xx1x	HOUR-MINUTE, 0000 at midnight

 xx2x	HOUR-MINUTE, 2400 at midnight

 x1xx	Day of Year (e.g., Jan. 31 is 31, Feb. 1 is 32)

 x2xx	Day of Year, previous day at midnight

 1xxx	Year

Note:   Any combination of Year, Day, HR-MIN, and seconds is possible; enter a 0 for no output.  If a 1 is entered in the hour/minute or day-of-year position, midnight is recorded as 0000 and the date reflects the start of a new 24 hour day.  If a 2 is entered in the hour/minute or day-of-year position, midnight is recorded as 2400 hours and the date reflects the date of the last 24 hours.

For more information, see Instruction 77 Examples.


Time Options

Code	Time Option

 xxx1	Seconds (with a resolution of 0.125 sec.)

 xx1x	HOUR-MINUTE, 0000 at midnight

 xx2x	HOUR-MINUTE, 2400 at midnight

 x1xx	Day of Year (e.g., Jan. 31 is 31, Feb. 1 is 32)

 x2xx	Day of Year, previous day at midnight

 1xxx	Year

Note:   Any combination of Year, Day, HR-MIN, and seconds is possible; enter a 0 for no output.  If a 1 is entered in the hour/minute or day-of-year position, midnight is recorded as 0000 and the date reflects the start of a new 24 hour day.  If a 2 is entered in the hour/minute or day-of-year position, midnight is recorded as 2400 hours and the date reflects the date of the last 24 hours.


Instruction 77 Examples

Option Code

       Entry        	Records

       1111	year, day of year, hour, minutes, seconds

       0120	day of year, hours, minutes with midnight recorded as 2400

(seconds not recorded).  Records the same values as 0210 and 0220.

       0201	day of year with the previous day at midnight, seconds

       1100	year, day of year


Instruction 78 -- Resolution

An Output Processing Instruction that sets the Final Storage resolution for the output instructions which follow.

Parameter 1 -- Resolution Codes sets the Final Storage format as either high or low resolution.

Low resolution is the default; at the beginning of each program table execution, the resolution is low.  If an Instruction 78 is encountered that sets the resolution high, the resolution will remain high until another Instruction 78 sets it low or until the end of the table is reached.


Resolution Codes

Code	Resolution

   0	     Low

   1	    High


Instruction 79 -- Sample on Max/Min

An Output Processing Instruction that immediately follows Instruction 73 (maximum) or Instruction 74 (minimum).

Instruction 79 samples the specified input locations when a new maximum or minimum is detected.  When the output flag is set, the sampled values are transferred to Final Storage.

Instruction 79 has the following parameters:

•	Parameter 1 -- Repetitions

•	Parameter 2 -- Starting Input Location

When Instruction 73 or 74's repetitions are greater than 1, Instruction 79 samples whenever a new maximum or minimum occurs in ANY of the locations.


Repetitions

Enter the number of input locations to sample when Instruction 73 or Instruction 74 detects a new maximum or minimum in its location(s).

When Instruction 73 or 74's repetitions are greater than 1, Instruction 79 samples whenever a new maximum or minimum occurs in ANY of the locations.

For general information about repetitions, see Repetition Information.


Repetitions

Enter the number of input locations to sample when instruction 73 or instruction 74 detects a new maximum or minimum in its location(s).


Location

Enter the first input location to sample.

For a detailed description of input locations, see Input Location Information.


Instruction 80 -- Set Active Storage Area

An Output Processing Instruction that redirects the output data to Final Storage or an input location.

This instruction should immediately follow the instruction that sets the output flag to 0.  If it doesn't follow an output flag instruction, a warning will be displayed.

When data is sent to a Final Storage area, parameter 2 can be used to set the output array's ID.

Instruction 80 has the following parameters:

•	Parameter 1 -- Option

•	Parameter 2 -- ID or Location

Caution:

(1)	Edlog allocates only one of the input locations needed for this instruction.  The additional input locations must be inserted manually using the Input Location's Editor.  For information on manually inserting input locations, refer to Manually Inserting Input Locations Into Edlog.

(2)	A unique array ID number should be used for each output array.


Option

Option	Description

    1	Send data to Final Storage

    3	Send data to an input location

Caution:

(1)	Edlog allocates only one of the input locations needed for this instruction.  The additional input locations must be inserted manually using the Input Location's Editor.  For information on manually inserting input locations, refer to Manually Inserting Input Locations Into Edlog.

(2)	A unique array ID number should be used for each output array.


Location/ID

Option 1 for Parameter 1

Enter the output array ID (1 through 511 are valid IDs).

Notes:

(1)	If 0 is entered, a default array ID will be used.  This default ID number will be based on the program table where the instruction appears, and the instruction's position within the table.

(2)	A unique array ID number should be used for each output array.

Option 3 for Parameter 1

Enter the input location.  For a detailed description of input locations, see Input Location Information.

Caution:

(1)	Edlog allocates only one of the input locations needed for this instruction.  The additional input locations must be inserted manually using the Input Location's Editor.  For information on manually inserting input locations, refer to Manually Inserting Input Locations Into Edlog.

(2)	A unique array ID number should be used for each output array.


Location/ID

Storage area option 1

Enter the output array ID (1 through 511 are valid IDs).

Note:   If 0 is entered, a default array ID will be used.  This default ID number will be based on the program table where the instruction appears, and the instruction's position within the table.

Storage area option 3

Enter the input location.

Caution:  When directing the data to an input location, the location must be allocated using Edit|Input Labels.


Instruction 82 -- Standard Deviation

An Output Processing Instruction that calculates the standard deviation of the values that have been stored in an input location since the last output.

Instruction 82 has the following parameters:

•	Parameter 1 -- Repetitions

•	Parameter 2 -- Location


Repetitions

Enter the number of input locations whose standard deviations will be calculated.

For more information, see General Repetition Information.


Repetitions

Enter the number of input locations whose standard deviations will be calculated.


Location

Enter the initial input location whose values will be used to calculate the standard deviation.  Repetitions must be stored in consecutive locations.

For more information, see General Input Location Information.


Instruction 83 -- If Case Location < F

A Program Control Instruction that executes a command if the case specified in Instruction 93 is less than F (a fixed floating point number).

Instruction 83 has the following parameters:

•	Parameter 1 -- F (fixed number)

•	Parameter 2 -- Command Code

Notes:   This instruction must follow instruction 93 (BEGIN CASE) or an error occurs.  When this instruction uses code 30 for parameter 2, an end instruction is required and this If Then/Else sequence may be nested.


F (fixed floating point number)

Enter the lower limit for Instruction 93.


Command Codes

Codes   	Description (also see notes)

      0	Go to the end of the program table

1-9, 79-99	Call Subroutine No. 1-9, 79-99 (e.g., code 79 calls subroutine 79)

   10-19	Set flags 0-9 high (e.g., code 10 sets flag 0 high; see note 4)

   20-29	Set flags 0-9 low (e.g., code 20 sets flag 0 low; see note 4)

     30	Then Do

     31	Exit loop if true

     32	Exit loop if false

     41	Set Port 1 high

     51	Set Port 1 low

     61	Toggle Port 1

     71	Pulse Port 1

Notes:

1.	If command code 0 is executed while in a subroutine, execution jumps directly to the end of the table that called the subroutine.

2.	If a subroutine that does not exist is called, an error occurs.

3.	Subroutine 98 can be called by control port 2.

4.	Flag 0 is the output flag (this flag must be set to send data to final storage); flags 1 - 8 are user flags; flag 9 is the intermediate processing disable flag (this flag is typically only used by advanced Edlog programmers).

5.	Command codes 31 and 32 can only be used when this instruction is in a loop (Instruction 87).  Otherwise an error occurs.


Instruction 85 -- Beginning of Subroutine

A Program Control Instruction that marks the beginning of a subroutine.  Instruction 85 is used only in the subroutine table (table 3)

Each subroutine begins with this instruction and ends with Instruction 95 (END).  If a second Instruction 85 is encountered before an END (Instruction 95), an error occurs.

Parameter 1 (Subroutine Number) labels the subroutine.  An error occurs when several Instruction 85s have the same entry for parameter 1.

Subroutines may be nested (see Nesting Subroutines).


Nesting Subroutines

Subroutines may call other subroutines.

The maximum nesting level is 7.  A nesting level greater than 7 results in an error.


Subroutine Number

Enter the subroutine's number (valid entries are 1-9, 79-99).

Subroutines are executed when the subroutine number is called by a Program Control Command.  Subroutine 98 can also be called by control port 2.

Note:   An error will occur when several instruction 85s have the same entry for parameter 1.


Subroutine Number

Enter the subroutine's number (valid entries are 1-9, 79-99).

Note:   An error will occur when several instruction 85s have the same entry for parameter 1.


Subroutine 98

Subroutine 98 will be executed after control port 2 goes high.  If an instruction is running when the port goes high, the instruction will be completed before the subroutine is executed.


Instruction 86 -- Do

A Program Control Instruction that unconditionally executes a command (see Parameter 1 -- Command Codes).


Command Codes

  Codes   	Description (also see notes)

      0	Go to the end of the program table

1-9, 79-99	Call Subroutine No. 1-9, 79-99 (e.g., code 79 calls subroutine 79)

   10-19	Set flags 0-9 high (e.g., code 10 sets flag 0 high; see note 4)

   20-29	Set flags 0-9 low (e.g., code 20 sets flag 0 low; see note 4)

     30	Then Do

     31	Exit loop if true

     32	Exit loop if false

     41	Set Port 1 high

     51	Set Port 1 low

     61	Toggle Port 1

     71	Pulse Port 1

Notes:

1.	If command code 0 is executed while in a subroutine, execution jumps directly to the end of the table that called the subroutine.

2.	If a subroutine that does not exist is called, an error occurs.

3.	Subroutine 98 can be called by control port 2.

4.	Flag 0 is the output flag (this flag must be set to send data to final storage); flags 1 - 8 are user flags; flag 9 is the intermediate processing disable flag (this flag is typically only used by advanced Edlog programmers).

5.	Command codes 31 and 32 can only be used when this instruction is in a loop (Instruction 87).  Otherwise an error occurs.


Instruction 87 -- Beginning of Loop

This is a Program Control Instruction.  Instructions that lie between this instruction and Instruction 95 (End) are repeated.

Loops can be nested, see Nesting Loops.

Instruction 87 has the following parameters:

•	Parameter 1 -- Delay

•	Parameter 2 -- Loop Count

When a processing instruction is used within a loop, data will be stored in the same input location with each pass through the loop unless the input location has been indexed (see note 1).  To index, press F4 while the cursor is placed within the input location parameter.  When indexed, the input location will be incremented by one with each pass through the loop.

Output instructions will use the same number of Intermediate Storage locations as when they're not in a loop.

Notes:

1.	Indexing input locations is not supported in Output Processing Instructions.

2.	Edlog does not allocate new input locations for instructions within loops.  You must allocate the input locations using the Input Location Editor.


Nesting Loops And/Or If Then/Else Sequences

Nesting is when loops and/or If Then/Else sequences are within other loops and/or If Then/Else sequences.

The If Then/Else sequences are when command code 30 is used with Instruction 83, Instruction 88, Instruction 89, Instruction 91, or Instruction 92.

Up to 11 loops and/or If Then/Else sequences can be nested.  If the nesting level is more than 11, an error occurs.  When an If Then/Else sequence uses Instruction 94 (Else), the nesting level is considered to be 2.

Indexed input locations that are within nested loops are indexed to the inner most loop (indexing input locations is only supported in Processing Instructions).


Delay

Enter how often that the passes through the loop will be executed.

The delay must be entered as a multiple of the execution interval.

Example:   If the execution interval is one second and the delay is 5, the passes through the loop are 5 seconds apart.


Loop Count

Enter the number of times to execute the loop.

When this parameter is 0, the loop will be repeated until an exit loop command (command code 31 or 32) has been executed.

Caution:   An entry of 0 without an exit loop command produces an endless loop.


Instruction 88 -- If X <=> Y

A Program Control Instruction that compares the values contained in two input locations and if the comparison is true, the specified command is executed.

Instruction 88 has the following parameters:

•	Parameter 1 -- X (Input Location)

•	Parameter 2 -- Comparison Code

•	Parameter 3 -- Y (Input Location)

•	Parameter 4 -- Command Code

Note:   When this instruction uses code 30 for parameter 4, an end instruction is required and this If Then/Else sequence may be nested.


X

Enter the first input location whose value will be compared.

For a detailed description of input locations, see Input Location Information.


Comparison Codes

Code	Comparison

   1	     X = Y

   2	  X not = Y

   3	     X > Y

   4	     X < Y

Where

X -- the value contained in parameter 1's input location.

Y -- the value contained in parameter 3's input location.


Y

Enter the second input location whose value will be compared.

For a detailed description of input locations, see Input Location Information.


Command Codes

  Codes   	Description (also see notes)

      0	Go to the end of the program table

1-9, 79-99	Call Subroutine No. 1-9, 79-99 (e.g., code 79 calls subroutine 79)

   10-19	Set flags 0-9 high (e.g., code 10 sets flag 0 high; see note 4)

   20-29	Set flags 0-9 low (e.g., code 20 sets flag 0 low; see note 4)

     30	Then Do

     31	Exit loop if true

     32	Exit loop if false

     41	Set Port 1 high

     51	Set Port 1 low

     61	Toggle Port 1

     71	Pulse Port 1

Notes:

1.	If command code 0 is executed while in a subroutine, execution jumps directly to the end of the table that called the subroutine.

2.	If a subroutine that does not exist is called, an error occurs.

3.	Subroutine 98 can be called by control port 2.

4.	Flag 0 is the output flag (this flag must be set to send data to final storage); flags 1 - 8 are user flags; flag 9 is the intermediate processing disable flag (this flag is typically only used by advanced Edlog programmers).

5.	Command codes 31 and 32 can only be used when this instruction is in a loop (Instruction 87).  Otherwise an error occurs.


Instruction 89 -- If X <=> F

A Program Control Instruction that compares a value contained in an input location with a fixed value (floating point number).  If the comparison is true, the specified command is executed.

Instruction 89 has the following parameters:

•	Parameter 1 -- X (Input Location)

•	Parameter 2 -- Comparison Code

•	Parameter 3 -- F (fixed number)

•	Parameter 4 -- Command Code

Note:   When this instruction uses code 30 for parameter 4, an end instruction is required and this If Then/Else sequence may be nested.


X

Enter the input location that contains the value that is compared to the fixed value (F).

For a detailed description of input locations, see Input Location Information.


Comparison Codes

Code	Comparison

   1	     X = F

   2	  X not = F

   3	     X > F

   4	     X < F

Where

X -- the value contained in parameter 1's input location.

F -- parameter 3's floating point number.


F (fixed floating point number)

Enter the number that will be compared with the value contained in parameter 1's input location.


Command Codes

  Codes   	Description (also see notes)

      0	Go to the end of the program table

1-9, 79-99	Call Subroutine No. 1-9, 79-99 (e.g., code 79 calls subroutine 79)

   10-19	Set flags 0-9 high (e.g., code 10 sets flag 0 high; see note 4)

   20-29	Set flags 0-9 low (e.g., code 20 sets flag 0 low; see note 4)

     30	Then Do

     31	Exit loop if true

     32	Exit loop if false

     41	Set Port 1 high

     51	Set Port 1 low

     61	Toggle Port 1

     71	Pulse Port 1

Notes:

1.	If command code 0 is executed while in a subroutine, execution jumps directly to the end of the table that called the subroutine.

2.	If a subroutine that does not exist is called, an error occurs.

3.	Subroutine 98 can be called by control port 2.

4.	Flag 0 is the output flag (this flag must be set to send data to final storage); flags 1 - 8 are user flags; flag 9 is the intermediate processing disable flag (this flag is typically only used by advanced Edlog programmers).

5.	Command codes 31 and 32 can only be used when this instruction is in a loop (Instruction 87).  Otherwise an error occurs.


Instruction 90 -- Step Loop Index

A Program Control Instruction that is used within a loop that has been indexed (so that the values for each pass through the loop are stored in consecutive input locations instead of overwriting the same input location).  With each pass through the loop, the index counter will be incremented by the amount specified in parameter 1 (step).

For more information, see Loop Index Example.


Loop Index Example

Suppose 4 is specified in parameter 1, the loop count is 5, and the instruction that follows this instruction stores a value in input location 1, then:

•	The first pass through the loop the value will be stored in input location = 1+(0*4)=1.

•	The second pass through the loop the value will be stored in input location = 1+(1*4)=5.

•	The third pass through the loop the value will be stored in input location = 1+(2*4)=9.

•	The fourth pass through the loop the value will be stored in input location = 1+(3*4)=13.

•	The fifth pass through the loop the value will be stored in input location = 1+(4*4)=17.


Step

Enter the amount that the locations will be incremented.


Instruction 91 -- If Flag/Port

A Program Control Instruction that executes a command when the specified flag or port status is met.

Instruction 91 has the following parameters:

•	Parameter 1 -- Flag or Port Option

•	Parameter 2 -- Command Code

Note:   When this instruction uses code 30 for parameter 2, an end instruction is required and this If Then/Else sequence may be nested.


Flag/Port Option

Code	Flag/Port Option

  1x	Do if flag x is high

  2x	Do if flag x is low

  41	Do if port 1 is high

  51	Do if port 1 is low

  40	Do if modem is on

  50	Do if modem is off

Notes:

Flag 0 is the output flag (this flag must be set to send data to final storage); flags 1 through 8 are user flags; flag 9 is the intermediate processing disable flag (this flag is typically only used by advanced Edlog programmers).


Command Codes

  Codes   	Description (also see notes)

      0	Go to the end of the program table

1-9, 79-99	Call Subroutine No. 1-9, 79-99 (e.g., code 79 calls subroutine 79)

   10-19	Set flags 0-9 high (e.g., code 10 sets flag 0 high; see note 4)

   20-29	Set flags 0-9 low (e.g., code 20 sets flag 0 low; see note 4)

     30	Then Do

     31	Exit loop if true

     32	Exit loop if false

     41	Set Port 1 high

     51	Set Port 1 low

     61	Toggle Port 1

     71	Pulse Port 1

Notes:

1.	If command code 0 is executed while in a subroutine, execution jumps directly to the end of the table that called the subroutine.

2.	If a subroutine that does not exist is called, an error occurs.

3.	Subroutine 98 can be called by control port 2.

4.	Flag 0 is the output flag (this flag must be set to send data to final storage); flags 1 - 8 are user flags; flag 9 is the intermediate processing disable flag (this flag is typically only used by advanced Edlog programmers).

5.	Command codes 31 and 32 can only be used when this instruction is in a loop (Instruction 87).  Otherwise an error occurs.


Instruction 92 -- If Time Is

A Program Control Instruction that executes a command at a specified time.

Instruction 92 has the following parameters:

•	Parameter 1 -- Time into Interval

•	Parameter 2 -- Interval

•	Parameter 3 -- Command Code

Note:   When this instruction uses code 30 for parameter 3, an end instruction is required and this If Then/Else sequence may be nested.

The time is specified as the number of minutes or seconds into an interval.  The time interval is synchronized with real time, where the first interval of the day starts at midnight.

Caution:  The values entered for parameter 1 and parameter 2 must be different or the command specified in parameter 3 will never be executed.

Examples:

If a 60 minute time interval is specified with 0 minutes Into the Interval, the command is executed at 1:00 a.m., 2:00 a.m., 3:00 a.m., . . . , 10:00 p.m., 11:00 p.m., 12:00 p.m.

If a 60 minute time interval is specified with 5 minutes Into the Interval, the command is executed at 1:05 a.m., 2:05 a.m., 3:05 a.m., . . . , 10:05 p.m., 11:05 p.m., 12:05 p.m.


Time into Interval

Entry	Description

xxx	Time into interval is xxx minutes.

xxx--	Time into interval is xxx seconds

(press the F4 function key to index which causes it to read seconds).

Notes:

When this parameter is NOT indexed, the units for parameter 2 are minutes; when indexed, the units are seconds.

When not indexed, this parameter's maximum value is 1439 minutes.

When indexed, enter a value less than or equal to 59.  If you enter a value greater than 59, Edlog will compile this program but you'll get an error when you attempt to download it to the datalogger.

Caution:  The value entered for this parameter must be different than parameter 2's entry or the command specified in parameter 3 will never be executed.


Interval

Enter the interval time.

Notes:

When parameter 1 is NOT indexed, the units for this parameter are minutes; when indexed, the units are seconds.

When parameter 1 is not indexed, the maximum value for this parameter is 1440 minutes.

When parameter 1 is indexed, enter a value less than or equal to 60.  If you enter a value greater than 60, Edlog will compile this program but you'll get an error when you attempt to download it to the datalogger.

Caution: The value entered for this parameter must be different than parameter 1's entry or the command specified in parameter 3 will never be executed.  If this parameter's entry is zero, the command is NOT executed.


Command Codes

  Codes   	Description (also see notes)

      0	Go to the end of the program table

1-9, 79-99	Call Subroutine No. 1-9, 79-99 (e.g., code 79 calls subroutine 79)

   10-19	Set flags 0-9 high (e.g., code 10 sets flag 0 high; see note 4)

   20-29	Set flags 0-9 low (e.g., code 20 sets flag 0 low; see note 4)

     30	Then Do

     31	Exit loop if true

     32	Exit loop if false

     41	Set Port 1 high

     51	Set Port 1 low

     61	Toggle Port 1

     71	Pulse Port 1

Notes:

1.	If command code 0 is executed while in a subroutine, execution jumps directly to the end of the table that called the subroutine.

2.	If a subroutine that does not exist is called, an error occurs.

3.	Subroutine 98 can be called by control port 2.

4.	Flag 0 is the output flag (this flag must be set to send data to final storage); flags 1 - 8 are user flags; flag 9 is the intermediate processing disable flag (this flag is typically only used by advanced Edlog programmers).

5.	Command codes 31 and 32 can only be used when this instruction is in a loop (Instruction 87).  Otherwise an error occurs.


Instruction 93 -- Case

A Program Control Instruction that marks the beginning of a case statement.

Instruction 95 (End) must close the case statement.

Parameter 1 -- Case Location designates an input location whose value will be compared with a particular case.  The case is specified in Instruction 83.


Case Location

Enter the input location whose value will be compared with a particular case that is specified in Instruction 83.

For a detailed description of input locations, see Input Location Information.


Instruction 94 -- Else

A Program Control Instruction marks the beginning of instructions to be executed when a comparison is false.  Instruction 94 is used when command code 30 is used with Instruction 83, 88, 89, 91, or 92.

An error occurs when Instruction 94 (ELSE) is used and command code 30 is not used with Instruction 83, 88, 89, 91, or 92.


Instruction 95 -- End

A Program Control Instruction that indicates the end/return of a subroutine (Instruction 85), or the end of a loop (Instruction 87), an If Then/Else sequence (command code 30 with Instruction 83, 88, 89, 91, or 92), or a case statement (Instruction 93).

Loops, If Then/Else sequences, case statements, or subroutines that are not followed by Instruction 95 (END) yield an error.

An error also occurs if Instruction 95 is used without a loop, if/then sequence, case statement, or subroutine.


Instruction 96 -- Serial Out

A Program Control Instruction that sends the data in the Final Storage to a storage module, computer, or printer.

Instruction 96 is typically entered after the output instructions to transfer all of the Final Storage's data.  Other program control instructions can also be used with this instruction, allowing the data to be transferred only during specific conditions.

Parameter 1 -- Device/Baud Codes designates the device and format used, and if required, the baud rate.

Note:   Most often this instruction is used to send data to a storage module.  In this case, 71 is used for parameter 1.


Device/Baud Codes (y = baud rate code)

Code	Option/Device Description

   1y	Printable ASCII, addressed print device

   2y	Comma Separated ASCII, addressed print device

   3y	Binary Final Storage Format, addressed print device

   4y	Printable ASCII / serial printer, computer, or pin-enabled print device

   5y	Comma Separated ASCII / serial printer, computer, or pin-enabled print device

   6y	Binary Final Storage Format / serial printer, computer, or pin-enabled print device

  7N	Send data to storage module address N

  7N--	Filemark to storage module N (press F4 to index)

Code (y)	Baud Rate

   0	300

   1	1200

   2	9600

   3	76800

   4	300 w/checksum, Comma Separated ASCII only

   5	1200 w/checksum, Comma Separated ASCII only

   6	9600 w/checksum, Comma Separated ASCII only

   7	76800 w/checksum, Comma Separated ASCII only

Notes:

•	Valid storage module addresses are numbers from 1 through 8; an entry of 71 sends the data to the storage module with the lowest address.

•	The filemark to storage module option separates the data from different outputs.


Device/Baud Codes (y = baud rate code)

Code	Option/Device Description

   1y	Printable ASCII, addressed print device

   2y	Comma Separated ASCII, addressed print device

   3y	Binary Final Storage Format, addressed print device

   4y	Printable ASCII / serial printer, computer, or pin-enabled print device

   5y	Comma Separated ASCII / serial printer, computer, or pin-enabled print device

   6y	Binary Final Storage Format / serial printer, computer, or pin-enabled print device

  7N	Send data to storage module address N (valid addresses are numbers from 1 through 8)

 7N--	Filemark to storage module N (press F4 to index)

Code (y)	Baud Rate

   0	300

   1	1200

   2	9600

   3	76800

   4	300 w/checksum, Comma Separated ASCII only

   5	1200 w/checksum, Comma Separated ASCII only

   6	9600 w/checksum, Comma Separated ASCII only

   7	76800 w/checksum, Comma Separated ASCII only


Instruction 97 -- Initiate Telecommunications

Instruction 97 is a Program Control Instruction that makes the following types of calls:

•	Datalogger calls a computer to send data.

•	Datalogger calls a voice phone using our voice-synthesized modem.

•	Datalogger calls a remote datalogger.

Instruction 97 has the following parameters:

•	Parameter 1 -- Modem/Baud Rate Codes

•	Parameter 2 -- Flag

•	Parameter 3 -- Time Limit on Call

•	Parameter 4 -- Fast Delay

•	Parameter 5 -- Number of Retries

•	Parameter 6 -- Slow Delays

•	Parameter 7 -- Failure Location

•	Parameter 8 -- Call-back ID

Caution:   DO NOT put Instruction 97 inside a loop or conditional statement; it must be executed each time the table is run.


Datalogger Calling a Computer

At least one Instruction 63 or Instruction 68 must follow this instruction.

When the interrupt disable flag (parameter 2) is set low and the program reaches this instruction, the CR500 uses the modem specified in parameter 1 and the path specified in Instruction(s) 63 or 68 to call a computer.

The datalogger will continue to attempt communications until the interrupt disable flag has been set high.  The interrupt disable flag is automatically set high after telecommunications has been successfully completed.

Once the datalogger connects with the computer, the datalogger identifies itself by sending the ID number specified in parameter 8.  The computer will echo the ID back to the datalogger and telecommunications is initiated when the CR500 receives the correct ID.  This ID informs the computer of the station file/setup used to collect the datalogger's data or to run any specified batch files.

If an incorrect character is received, the CR500 retransmits the ID.  If the correct response is not received within the time allotted in parameter 3, the datalogger hangs up and calls back later (see parameter 4, parameter 5, and parameter 6).  The number of unsuccessful attempts is stored in an input location (parameter 7).

Once a successful call has been made, zero will be stored in the input location.

Caution:   DO NOT put Instruction 97 inside a loop or conditional statement; it must be executed each time the table is run.


Datalogger Calling a Voice Phone

Campbell Scientific offers a separate software package which modifies a DLD file to enable voice communication when a datalogger is used with a VS1 or COM300 voice modem.  The file must first be created in Edlog, and it must include Instruction 97.  The file is then edited using the voice communication software to add the spoken messages.

When the interrupt disable flag (parameter 2) is set low and the program reaches this instruction, the CR500 uses our voice-synthesized modem to call a voice phone.  The phone number to be called is designated in the voice communication software.

The datalogger will continue to attempt communications until the interrupt disable flag has been set high.  This flag must be manually set high by the person who answers the voice phone or set high by an event in the datalogger program.

Note:   This type of call does not require a subsequent Instruction 63 or 68.  The telephone number to be dialed and the messages to be announced are added to the datalogger program using the voice communication software.  For more information, see the manual for our voice-synthesized modem.

After a person, answering machine, or pager answers the phone, the voice synthesized modem prompts the user to enter the pound key to hear the announcement.  The datalogger site is identified by the callback ID number.

The number of unsuccessful callback attempts is stored in an input location (specified by parameter 7).Once a successful call has been made, zero will be stored in the input location.

Caution:   DO NOT put Instruction 97 inside a loop or conditional statement; it must be executed each time the table is run.


Datalogger Calling a Remote Datalogger

At least one Instruction 63 or Instruction 68 must follow this instruction.  Besides specifying the modem path and/or phone number, Instruction 63 or 68 tells the remote datalogger what to do.

When the interrupt disable flag (parameter 2) is set low and the program reaches this instruction, the calling CR500 uses the modem specified in parameter 1 and the path specified by Instruction 63 or 68 to call a remote datalogger.  The calling datalogger will continue to attempt communications until the interrupt disable flag has been set high or the time allotted in parameter 3 has passed.

The flag is automatically set high after a successful call has ended.

Once the calling datalogger connects with the remote datalogger, the calling datalogger will toggle a flag in the remote datalogger and wait until that flag goes low.  The data stored in the specified input location of the remote datalogger will then be copied into consecutive input locations in the calling datalogger.  The copied data is stored in the location after the one designated in parameter 7.

Note:   Datalogger-to-datalogger calls do not allow retries of unsuccessful calls.  Parameters 4, 5, 6, and 8 are not used for datalogger-to-datalogger calls and should be left as zero.

Caution:   DO NOT put Instruction 97 inside a loop or conditional statement; it must be executed each time the table is run.


Modem/Baud Rate Codes

 Baud Rates/Codes

--------------------------------

Modems	300	1200	9600

RF (RF95)	 00	  01	  02

Direct (Short-Haul)	 10	  11	  12

Phone	 20	  21	  22

VS1 or COM300 Voice Call-Back	 NA	  31	 NA

VS1 or COM300 Data Call-Back	 40	  41	  42 (COM300 only)

RF (RF95, SDC State)	 50	  51	  52

NA -- Not Applicable

Baud Rates --the speed of transmission of information across a serial interface, expressed in units of bits per second.


Interrupt Disable Flag

Enter an integer from 1 through 8 to set the user flag which will be used as the interrupt disable flag.  While this flag is low, the datalogger will attempt to call a computer or voice phone.

Note:  The only indication the datalogger has that a call has been successful is that the flag has been set high.  RF, short-haul, and phone modems automatically set this flag high after a successful call has ended.  However when using a voice modem, this flag must be manually set high by the person who answers the voice phone or set high by an event in the datalogger program.  If the flag is not set high, the datalogger will continue to call on the retry intervals even though the first call may have been successful.


Time Limit on Call

Enter the number of seconds the datalogger will wait for a correct call-back ID before hanging up.  This time limit is timed from the start of the instruction and must include the dialing time.

Note:   When using voice callback, this parameter sets the amount of time before the datalogger goes into voice communication mode once this instruction has been executed.  Therefore, the time limit needs to be long enough to allow the telephone number to finish dialing.


Seconds Before Fast Retry (Fast Delay)

Enter the number of seconds the datalogger will wait before calling again if there wasn't an answer.

At first the datalogger will call back at a faster rate.  The number of calls using the fast delay is specified by parameter 5.

Notes:

(1)	Between each call, a different offset will be added to the fast delay, reducing the chances that the phone line will be busy.  The offset will always be in the range of 0 to 1/2 the fast delay.

(2)	Datalogger-to-datalogger calls do not allow retries of unsuccessful calls.  This parameter is not used for datalogger-to-datalogger calls and should be left as zero.


Number of Tries

Enter the number of retries that will use the fast delay (parameter 4).

Note:   Datalogger-to-datalogger calls do not allow retries of unsuccessful calls.  This parameter is not used for datalogger-to-datalogger calls and should be left as zero.


Minutes Before Slow Retry (Slow Delay)

Enter the number of minutes the datalogger will wait before calling again if there wasn't an answer using the fast delay (parameter 4).

The slow delay will be used until the correct response has been received or the execution interval is up.

Notes:

(1)	Between each call a different offset will be added to the slow delay, reducing the chances that the phone line will be busy.  The offset will always be in the range of 0 to 1/2 the slow delay.

(2)	Datalogger-to-datalogger calls do not allow retries of unsuccessful calls.  This parameter is not used for datalogger-to-datalogger calls and should be left as zero.


Failures Input Location

Enter the input location that will store the number of unsuccessful calls.

For a detailed description of input locations, see Input Location Information.


Call-Back ID

Using an RF, Short-Haul, or Phone Modem to Call a Computer

Enter the number the datalogger will send to the computer when the interrupt disable flag has been set low.  This ID must be correctly transmitted back to the datalogger for telecommunications to be fully established.

Datalogger-to-Datalogger Calls

This parameter is not used and should be left as zero.

Using a Voice Modem

This ID is used to identify the station that is calling.  When you answer the phone, you get the message "Press Pound to Hear Callback Message Number XXX".  XXX will be the number that has been entered for this parameter.


Instruction 105 -- SDI-12 Recorder

An Input/Output Instruction that allows data to be collected from an SDI-12 sensor; each sensor requires a separate instruction 105.

Note:   Instruction 106 enables a CR500 to be used as an SDI-12 sensor.

Instruction 105 has the following parameters:

•	Parameter 1 -- Address

•	Parameter 2 -- Command

•	Parameter 3 -- Port

•	Parameter 4 -- Location

•	Parameter 5 -- Multiplier

•	Parameter 6 -- Offset

Note:   Edlog allocates only one of the input locations needed for this instruction.  The additional input locations must be inserted manually using the Input Location Editor.  For information on manually inserting input locations, refer to Manually Inserting Input Locations Into Edlog.


Address

Enter the address that will identify the SDI-12 sensor.

Valid Entries

Entry	Description

0 - 9	standard addresses

65 - 90	decimal values for ASCII upper-case letters

97 - 122	decimal values for ASCII lower-case letters

For a list of the decimal values for the upper- or lower-case letters, click on Decimal Characters for Letters.


Address

Enter the address that will identify the SDI-12 sensor.

Valid Entries

Entry	Description

0 - 9	standard addresses

65 - 90	decimal values for ASCII upper-case letters

97 - 122	decimal values for ASCII lower-case letters


Command Code
Command Codes

Entry	Command	Description

    0	       M	Initiate measurements

   0--	       C	Initiate concurrent measurement

 1 - 9	  M1 - M9	Additional measurement commands specified by

the SDI-12 sensor.

   10	       V	Initiate verify sequence.

   11	        I	Send identification.

Notes:

•	M, M1-M9, and V command sequences have numerical results that are stored in the input location specified in parameter 4.

•	The I command's response is text which is put directly into the Final Storage area.


Port

Enter the CR500 control port where the SDI-12 sensor will be wired.


Location

Enter the input location that will store the SDI-12 sensor's data.  Multiple values will be stored in consecutive locations.

If the CR500 receives incorrect or no responses from the SDI-12 sensor, the CR500 will retry the operation.  If the datalogger doesn't receive a valid response, -9999 will be stored in the first input location; the other locations will contain the previous responses.

For more information about input locations, see Input Location Information.


Instruction 106 -- SDI-12 Sensor

An Input/Output Instruction that allows a CR500 to be used as an SDI-12 sensor by supplying measurement data to an SDI-12 recorder (see instruction 105).

Instruction 106 should always be the second instruction in subroutine 98; the first instruction must be Instruction 85 (begin subroutine).  For the CR500 to operate like an SDI-12 sensor, an SDI-12's data line must be wired into the CR500's control port 2.  This allows subroutine 98 to be called whenever there is activity on the data line.

There are two datalogger programming techniques which use instruction 106.  For information, see Measurement Technique 1, Measurement Technique 2, and Combination of Techniques.

Instruction 106 has the following parameters:

•	Parameter 1 -- Address

•	Parameter 2 -- Time/Values Codes

•	Parameter 3 -- Location

Note:   Edlog allocates only one of the input locations needed for this instruction.  The additional input locations must be inserted manually using the Input Location Editor.  For information on manually inserting input locations, refer to Manually Inserting Input Locations Into Edlog.


Measurement Technique 1

Enter the measurement instructions in subroutine 98.  This causes the measurements to be made in response to the recorder's command.


Measurement Technique 2

Enter the measurement instructions in the main program (table 1 or 2) and have subroutine 98 contain only Instructions 85 (begin subroutine), 106 (SDI-12 sensor), and 95 (end).

The advantage of this technique is that the CR500 will make and store measurements independently of the SDI-12 recorder.


Combination of Techniques

Combining the techniques allows the CR500 to be used as an SDI-12 sensor while the CR500 also makes independent measurements.

The following rules must be observed or measurements might be missed:

1.	The execution interval of the main program (table 1 or 2) must be longer than subroutine 92's execution rate.

2. 	If the main program is executed often, each of the main program's instructions must execute in less than 1/3 second; most instructions execute fast enough.


Address

Enter the address for the CR500.  The CR500 must have a unique address.

Valid Entries

Entry	Description

0 - 9	standard addresses

65 - 90	decimal values for ASCII upper-case letters

97 - 122	decimal values for ASCII lower-case letters

For a list of the decimal values for the upper- or lower-case letters, click on Decimal Characters for Letters.

Note:  The SDI-12 recorder transmits to the CR500 a Break and the CR500's address.  If the Break and address are not received, the measurements are not supplied to the recorder and the remainder of the subroutine is not executed.


Address

Enter the address for the CR500.  The CR500 must have a unique address.

Valid Entries

Entry	Description

0 - 9	standard addresses

65 - 90	decimal values for ASCII upper-case letters

97 - 122	decimal values for ASCII lower-case letters


Time/Values

Enter in the form of ttnn, where:

tt -- the time (seconds) required to complete subroutine 98

nn -- the number of input location values used

Note:  This instruction should always be the second instruction in subroutine 98; the first instruction must be Instruction 85 (begin subroutine).  For the CR500 to operate like an SDI-12 sensor, an SDI-12's data line must be wired into the CR500's control port 2.  This allows subroutine 98 to be called whenever there is activity on the data line.


Time/Values

Enter in the form of ttnn, where:

tt -- the time (seconds) required to complete subroutine 98.

nn -- the number of input location values used.


Location

Enter the initial input location whose values will be sent to the SDI-12 recorder.

The number of input locations sent depends on Instruction 105 in the SDI-12 recorder datalogger.  For more information about the starting input location in the sensor datalogger and number of values requested by the recorder datalogger, see:

•	Commands M, M1-M9

•	Command V

•	Command I

For detailed information about input locations, see Input Location Information.


SDI-12 Recorder Commands M, M1 - M9

With these commands, the input locations will store measurements.

Each command's initial input location number will be:	(parameter 3) + (n*x)

Where:

n	Specified in parameter 2

x	The number after the M command; a 0 for command M or a number from 1 through 9 for commands M1 - M9.


SDI-12 Recorder Command V

Three values will be sent in response to this command.  The first value will be the number of watchdog errors (E08); the second will be the number of table overrun errors and the third will be a signature of the CR500's memory.

The signature allows the detection of program changes or ROM failure and will be determined by the CR500 PROM, the size of RAM, and the entries in tables 1, 2, and 3 and the *A and *C modes.


SDI-12 Recorder Command I

The CR500 will send directly to the Final Storage area this string:

10CAMPBELL CR500 001 aaaa

Where:

aaaa -- the number from the eighth window of the *B mode.


Instruction 111 -- Run Program From Flash

A Program Control Instruction that loads a program stored in FLASH into RAM.  The program in RAM is replaced by the FLASH program.  Valid program numbers are 1 through 98; however, the actual number of programs which can be stored is limited by the flash memory size.

This instruction has one parameter:    Parameter 1 -- Flash Program Number (Name).

Caution:   The memory allocation must be the same between the program in RAM and the program that is loaded from FLASH or the data in Final Storage will be lost.


Flash Program Number (Name)

Enter the number of the program stored in the datalogger's FLASH memory that will be loaded into RAM.

Index this entry to compile the program without resetting input storage, flags, or ports (*6 mode).  Also see Indexing Parameters.


Flash Program Number (Name)

Enter the number of the program stored in the datalogger's FLASH memory that will be loaded into RAM.

Index this entry to compile the program without resetting input storage, flags, or ports (*6 mode).


Instruction 114 -- Set Real Time Clock

An Input/Output Instruction that allows the lithium-backed clock to be set from the values that are contained in input locations.

Instruction 114 has the following parameters:

•	Parameter 1 -- Option Code

•	Parameter 2 -- Input Location


Option Code

Code	Description

   0	set time with hr, min, sec using 3 input locations.

   1	set time with day, hr, min, sec using 4 input locations.

   2	set time with yr, day, hr, min, sec using 5 input locations.


Location

Enter the first input location that contains the value that will set the clock.

For more information about input locations, see Input Location Information.


Instruction 117 -- Read ID

An Input/Output Instruction that stores the datalogger's ID in an input location (parameter 1).

Instruction 117 allows the ID to be sampled (Instruction 70) and output as part of the data stream.  This is especially useful when the user is retrieving data from several dataloggers.


Input Location

Enter the input location that will store the datalogger ID.

For a detailed description of input locations, see Input Location Information.


Instruction 120 -- Data Transfer to TGT

A Program Control Instruction that transfers the final storage data to the TGT1 transmitter's buffer, designates locations for the forward and reflected power, and automatically compares the datalogger clock with the transmitter's.

The TGT1 transmitter supports one-way communications via the GOES satellite system.

Instruction 120 has the following parameters:

•	Parameter 1 -- Buffer Selection

•	Parameter 2 -- Forward/Reflected Power Location


Buffer Selection

Code	Description

0	binary mode, self-timed buffer, appends the new data to the old

1	binary mode, self-timed buffer, writes over the old data

10	binary mode, random buffer, appends the new data to the old

11	binary mode, random buffer, writes over the old data

100	ASCII mode, self-timed buffer, appends the new data to the old

101	ASCII mode, self-timed buffer, writes over the old data

110	ASCII mode, random buffer, appends the new data to the old

111	ASCII mode, random buffer, writes over the old data

Notes:

•	The binary mode has 3-bytes per data point.

•	The ASCII mode has 7-bytes per data point.

•	For more information about the buffers, see transmitter's buffer.


FWD/REF Power Location

Enter the starting input location that will store the forward power reading.  The next consecutive location will automatically store the reflected power reading.  If you enter a 0 for this parameter, the values for forward and reflected power will not be saved in an input location.

For more information about forward and reflected power, see forward and reflected power.

Example:   When the location number of this entry is 10, the forward power will be stored in input location number 10 and the reflected power will be stored in input location number 11.

For a detailed description of input locations, see Input Location Information.

Note:   Edlog allocates only one of the input locations needed for this instruction.  The additional input locations must be inserted manually using the Input Location Editor.  For information on manually inserting input locations, refer to Manually Inserting Input Locations Into Edlog.


Forward and Reflected Power

The forward and reflected power are measured (in decimal units) and updated during each transmission.

The forward power must be within the 165 to 215 range for the transmitter's output level to be within specifications.

The antenna/cable assembly is operating properly when the percent of power reflected is less than 5.  This percentage can be estimated with the following equation:

 % power reflected = [((ref + 17.4)/(fwd + 17.4))^2 x 100] - 1

When the percent of power reflected is greater than or equal to 5, one or more of the following situations exist and must be corrected to avoid losing data:

•	The antenna is not connected.

•	The antenna is too close to metal.

•	The user is transmitting inside a building.

•	The antenna is covered with snow or ice.

•	The frequency that the antenna is tuned to doesn't match the transmitter's frequency.

•	There is a problem with the coaxial cable connector/connection.

•	There is a problem with the antenna cable.


Self-timed and Random Buffers

The TGT1 has two buffers.  One buffer stores the self-timed data; the other stores the random.

Self-timed data are transmitted only during a predetermined time frame.  The self-timed data are erased from the transmitter's buffer after each transmission.

Random data are transmitted immediately after a threshold has been exceeded.  The transmission is then randomly repeated to assure it is received.


Instruction 121 -- Data Transfer of ARGOS ST-13

A Program Control Instruction that sends data via the Telonics ST-13 transmitter and the Argos satellite system.

Instruction 121 has the following parameters:

•	Parameter 1 -- Command Byte #1

•	Parameter 2 -- Command Byte #2

•	Parameter 3 -- Command Byte #3

This instruction outputs the command bytes and all of the data in the active final storage area.


Command Byte #1

Enter the decimal representation of command byte #1.

Note:   The value and function of these command bytes are described in the Telonics ST-13 Asynchronous Serial User's Guide.  The Telonics ST-13 Asynchronous Serial User's Guide lists the commands as binary values; the commands must be converted to decimal.


Command Byte #2

Enter the decimal representation of command byte #2.

Note:   The value and function of these command bytes are described in the Telonics ST-13 Asynchronous Serial User's Guide.  The Telonics ST-13 Asynchronous Serial User's Guide lists the commands as binary values; the commands must be converted to decimal.


Command Byte #3

Enter the decimal representation of command byte #3.

Note:   The value and function of these command bytes are described in the Telonics ST-13 Asynchronous Serial User's Guide.  The Telonics ST-13 Asynchronous Serial User's Guide lists the commands as binary values; the commands must be converted to decimal.


Instruction 123 -- Automatic Setup of TGT1

A Program Control Instruction that defines the transmitter's address, the transmission intervals, and the uplink channels.

The TGT1 transmitter supports one-way communications via the GOES satellite system.

Instruction 123 has the following parameters:

•	Parameter 1 -- Address

•	Parameter 2 -- Address

•	Parameter 3 -- Address

•	Parameter 4 -- Address

•	Parameter 5 -- Address

•	Parameter 6 -- Address

•	Parameter 7 -- Address

•	Parameter 8 -- Address

•	Parameter 9 -- Self-Timed Uplink Channel

•	Parameter 10 -- Random Uplink Channel

•	Parameter 11 -- Self-Timed Interval (Days)

•	Parameter 12 -- Self-Timed Interval (Hours)

•	Parameter 13 -- Self-Timed Interval (Minutes)

•	Parameter 14 -- Self-Timed Interval (Seconds)

•	Parameter 15 -- Random Interval (Hours)

•	Parameter 16 -- Random Interval (Minutes)

•	Parameter 17 -- Random Interval (Seconds)

•	Parameter 18 -- Initial Self-Timed Transmission (Hours)

•	Parameter 19 -- Initial Self-Timed Transmission (Minutes)

•	Parameter 20 -- Initial Self-Timed Transmission (Seconds)

•	Parameter 21 -- Transmit Window Length

•	Parameter 22 -- Preamble

•	Parameter 23 -- Buffer


Address

Enter the first digit of the NESDIS-assigned address.

Convert the letters in the address to their decimal equivalent.


Address

Enter the second digit of the NESDIS-assigned address.

Convert the letters in the address to their decimal equivalent.


Address

Enter the third digit of the NESDIS-assigned address.

Convert the letters in the address to their decimal equivalent.


Address

Enter the fourth digit of the NESDIS-assigned address.

Convert the letters in the address to their decimal equivalent.


Address

Enter the fifth digit of the NESDIS-assigned address.

Convert the letters in the address to their decimal equivalent.


Address

Enter the sixth digit of the NESDIS-assigned address.

Convert the letters in the address to their decimal equivalent.


Address

Enter the seventh digit of the NESDIS-assigned address.

Convert the letters in the address to their decimal equivalent.


Address

Enter the eighth digit of the NESDIS-assigned address.

Convert the letters in the address to their decimal equivalent.


Self-Timed Uplink Channel

Enter the NESDIS-assigned self-timed uplink channel.  If not assigned a self-timed channel, type in zeros.


Random Uplink Channel

Enter the NESDIS-assigned random uplink channel.  If not assigned a random channel, type in zeros.


Self-Timed Transmission Interval (Days)

Enter the days portion of the NESDIS-assigned self-timed transmission interval.

Note:  This is a 24-hour format.  Valid entries are 0 through 30.


Self-Timed Transmission Interval (Hours)

Enter the hours portion of the NESDIS-assigned self-timed transmission interval.

Note:   This is a 24-hour format.  Valid entries are 0 through 23.


Self-Timed Transmission Interval (Minutes)

Enter the minutes portion of the NESDIS-assigned self-timed transmission interval.

Note:   This is a 24-hour format.  Valid entries are 0 through 59.


Self-Timed Transmission Interval (Seconds)

Enter the seconds portion of the NESDIS-assigned self-timed transmission interval.

Note:   This is a 24-hour format.  Valid entries are 0 through 59.


Random Transmission Interval (hours)

Enter the hours portion of the NESDIS-assigned random transmission interval.

Note:  This is a 24-hour format.  Valid entries are 0 through 23.


Random Transmission Interval (minutes)

Enter the minutes portion of the NESDIS-assigned random transmission interval.

Note:  This is a 24-hour format.  Valid entries are 0 through 59.


Random Transmission Interval (seconds)

Enter the seconds portion of the NESDIS-assigned random transmission interval.

Note:  This is a 24-hour format.  Valid entries are 0 through 59.


Initial Self-Timed Transmission (Hours)

Enter the hours portion of the initial self-timed transmission.

Note:  This is a 24-hour format.  Valid entries are 0 through 23.


Initial Self-Timed Transmission (Minutes)

Enter the minutes portion of the initial self-timed transmission.

Note:  This is a 24-hour format.  Valid entries are 0 through 59.


Initial Self-Timed Transmission (Seconds)

Enter the seconds portion of the initial self-timed transmission.

Note:  This is a 24-hour format.  Valid entries are 0 through 59.


Assigned Transmission Window

Option	Description

0	1 minute window

1	2 minute window


Transmission Preamble

Option	Description

0	short preamble (0.98 seconds)

4	long preamble (7.3 seconds)


Buffer

Option	Description

1	self-timed buffer

2	random buffer

3	both buffers

Note:  These buffers must match the buffers designated in parameter 1 of Instruction 120.


Instruction 130 -- Status Monitor

An Input/Output Instruction that stores in an input location an error count or status information from the datalogger's *B mode.

Instruction 130 has the following parameters:

•	Parameter 1 -- Options

•	Parameter 2 -- Input Location


Option Code

Except for option 3, indexing this entry will store *B's status information and then clear the *B value.  If this entry is not indexed, the error count will be stored.  For information about indexing parameters, see Indexing Parameters.

Option	Description

     0	Read watchdog or E08 errors

     1	Read table overruns

     2	Read low 12 V detection


Input Location

Enter the input location that will store the error count or the *B status information.

For a detailed description of input locations, see Input Location Information.


Instruction 131 - Extended Vibrating Wire

An Input/Output Instruction that excites a Slope Indicator vibrating wire sensor with a swept frequency (from low to high), then measures the period of the response and calculates frequency in Hertz.

An AVW1 or AVW4 Vibrating Wire Interface is usually required with these sensors.  A delay of at least 25 ms between excitation and measurement is recommended.

Instruction 131 has the following parameters:

•	Parameter 1 -- Repetitions

•	Parameter 2 -- Range Options

•	Parameter 3 -- Single-Ended Channel

•	Parameter 4 -- Excitation Channel

•	Parameter 5 -- Start Frequency

•	Parameter 6 -- End Frequency

•	Parameter 7 -- Sweep

•	Parameter 8 -- Number of Steps

•	Parameter 9 -- Delay after Excitation before Measurement

•	Parameter 10 -- Cycles

•	Parameter 11 -- Delay between Reps

•	Parameter 12 -- Input Location

•	Parameter 13 -- Multiplier

•	Parameter 14 -- Offset


Repetitions

Enter the number of sensors that will be measured with this instruction.  The sensors must be wired in consecutive channels.

By pressing the F4 function before entering the REPS value, the excitation is only applied to the first REP.  Otherwise, each REP uses the same excitation.  Each measurement also uses the same starting frequency, ending frequency, sweep, number of steps, delay before measurement, cycles, multiplier, and offset.

For more information, see General Repetition Information.


Repetitions

Enter the number of sensors that will be measured with this instruction.  The sensors must be wired in consecutive channels.

By pressing the F4 function before entering the REPS value, the excitation is only applied to the first REP.  Otherwise, each REP uses the same excitation.  Each measurement also uses the same starting frequency, ending frequency, sweep, number of steps, delay before measurement, cycles, multiplier, and offset.


Range Options

Code	Max. Freq.

   1	8 kHz @ 2 mV peak-to-peak

   2	20 kHz @ 3 mV peak-to-peak

   3	50 kHz @ 12 mV peak-to-peak

   4	200 kHz @ 2 V peak-to-peak

Note:   The output period is in microseconds.


Single-Ended (SE) Channel

Enter the analog channel where the sensor has been wired.  When REPS are greater than 1, this entry is the first sensor's channel.


Excitation Channel Options

1	Excites all REPS with excitation channel 1.

2	Excites all REPS with excitation channel 2.

11	Excites the first sensor with excitation channel 1 and the second sensor with excitation channel 2.


Starting Frequency

Enter in Hertz the lowest frequency of the sweep.


Ending Frequency

Enter in Hertz the highest frequency of the sweep.


Sweep

Enter the amount of time, in milliseconds, to sweep between the specified frequencies.


Number of Steps

Enter the number of steps to use while sweeping from the starting frequency to the ending frequency.


Delay after Excitation before Measurement

Enter the amount of time, in milliseconds, to delay after the excitation before the measurement is made.

Note:   A delay of at least 25 ms between excitation and measurement is recommended.


Cycles

Enter the number of cycles that will be measured.


Delay between Reps

Enter the amount of time, in milliseconds, before the excitation will be applied to the next repetition.


Location

Enter the input location that will store the Hertz value obtained after the number of cycles specified in parameter 10.

The next consecutive location will store the result after one fifth the number of cycles specified in parameter 10.  Typically the first value is the one to use.

For more information, see Input Location Information.


Instruction 221 -- Transmit ALERT/IFLOWS Packet

A Program Control Instruction that is available as a special.  This instruction transmits ALERT/IFLOWS packets.

Instruction 221 has the following parameters:

•	Parameter 1 -- Sensor ID

•	Parameter 2 -- Packet ID

•	Parameter 3 -- Transmission Warm-up Time Location


Sensor ID

Enter the Input Location that holds the sensor ID.

For a detailed description of input locations, see Input Location Information.


Packet ID

Enter the Input Location that holds the packet ID.

For a detailed description of input locations, see Input Location Information.


Transmission Warm-up Time

Enter the Input Location that holds the amount of warm-up time.

For a detailed description of input locations, see Input Location Information.