TheCR23X MICROLOGGER is warranted by CAMPBELL SCIENTIFIC,
INC. to be free from defects in materials and workmanship under normal use
and service for thirty-six (36) months from date of shipment unless specified
otherwise. Batteries have no warranty. CAMPBELL SCIENTIFIC, INC.'s
obligation under this warranty is limited to repairing or replacing (at
CAMPBELL SCIENTIFIC, INC.'s option) defective products. The customer
shall assume all costs of removing, reinstalling, and shipping defective
products to CAMPBELL SCIENTIFIC, INC. CAMPBELL SCIENTIFIC,
INC. will return such products by surface carrier prepaid. This warranty shall
not apply to any CAMPBELL SCIENTIFIC, INC. products which have been
subjected to modification, misuse, neglect, accidents of nature, or shipping
damage. This warranty is in lieu of all other warranties, expressed or implied,
including warranties of merchantability or fitness for a particular purpose.
CAMPBELL SCIENTIFIC, INC. is not liable for special, indirect, incidental,
or consequential damages.
Products may not be returned without prior authorization. The following
contact information is for US and International customers residing in countries
served by Campbell Scientific, Inc. directly. Affiliate companies handle
repairs for customers within their territories. Please visit
www.campbellsci.com to determine which Campbell Scientific company
serves your country. To obtain a Returned Materials Authorization (RMA),
contact CAMPBELL SCIENTIFIC, INC., phone (435) 753-2342. After an
applications engineer determines the nature of the problem, an RMA number
will be issued. Please write this number clearly on the outside of the shipping
container. CAMPBELL SCIENTIFIC's shipping address is:
CAMPBELL SCIENTIFIC, INC.
RMA#_____
815 West 1800 North
Logan, Utah 84321-1784
CAMPBELL SCIENTIFIC, INC. does not accept collect calls.
CR23X MEASUREMENT AND CONTROL MODULE
TABLE OF CONTENTS
PDF viewers note: These page numbers refer to the printed version of this document. Use
the Adobe Acrobat® bookmarks tab for links to specific sections.
1. Storing Data - Data are stored in Final
Storage only by Output Processing
Instructions and only when the Output Flag
(Flag 0) is set. (Sections OV4.1.1 and
3.7.1)
2. Storing Date and Time - Date and time are
stored with the data in Final Storage ONLY
if the Real Time Instruction 77 is used.
(Section 11)
3. Data Transfer - On-line data transfer from
Final Storage to peripherals (printer,
Storage Module, etc.) occurs only if enabled
with Instruction 96 in the datalogger
program. (Sections 4 and 12)
4. Final Storage Resolution - All Input
6
Storage values are displayed (
mode) as high resolution with a maximum
value of 99999. However, the default
resolution for data stored in Final Storage is
low resolution, maximum value of 6999.
Results exceeding 6999 are stored as 6999
unless Instruction 78 is used to store the
values in Final Storage as high resolution
values. (Sections 2.2.1 and 11)
5. Floating Point Format - The computations
performed in the CR23X use floating point
arithmetic. CSI's 4 byte floating point
numbers contain a 23 bit binary mantissa
and a 6 bit binary exponent. The largest
and smallest numbers that can be stored
and processed are 9 x 10
18
and 1 x 10
-19
,
respectively. (Section 2.2.2)
6. Erasing Final Storage - Data in Final
Storage can be erased without altering the
program by using the
A Mode to
repartition memory. (Section 1.5.2)
7. ALL memory can be erased and the
CR23X completely reset by entering 98765
for the number of bytes allocated to
Program Memory. (
A Window 5,
Section 1.5.2)
vii
CAUTIONARY NOTES
1. Damage will occur to the analog input
circuitry if voltages in excess of ±16 V are
applied for a sustained period. Voltages in
excess of ±8 V will cause errors and
possible overranging on other analog input
channels.
2. Do not download an operating system (OS)
written for a particular datalogger model into
the hardware of another datalogger model.
The datalogger will sustain damage and
must be returned to the factory for repair.
This is of concern only when updated
operating systems are purchased from
Campbell Scientific.
3. When using the CR23X with the
rechargeable battery option, remember that
the sealed lead acid batteries are
permanently damaged if deep discharged.
The cells are rated at a 7 Ahr capacity but
experience a slow discharge even in
storage. It is advisable to maintain a
continuous charge on the battery, whether
in operation or storage (Section 14).
4. When connecting external power to the
CR23X, first, remove the green power
connector from the CR23X panel. Then
insert the positive 12 V lead into the rightmost terminal of the green connector. Next,
insert the ground lead to the left terminal.
Double check polarity before plugging the
green connector into the panel.
5. Voltages in excess of 5 volts should not be
applied to a control port.
6. The CR23X contains desiccant to protect
against excess humidity. To reduce vapor
transfer into the ENC 12/14 or ENC 16/18
enclosure, plug the cable entry conduit with
Duct Seal, a putty-type sealant available at
most electrical supply houses. DO NOT
totally seal enclosures equipped with lead
acid batteries. Hydrogen concentration may
build up to explosive levels.
viii
CR23X MICROLOGGER OVERVIEW
Read the Selected Operating Details and Cautionary Notes at the front of the Manual before using the
CR23X.
The CR23X Micrologger combines precision measurement with processing and control capability in a
single battery operated system.
Campbell Scientific, Inc. provides three documents to aid in understanding and operating the CR23X:
1. This Overview
2. The CR23X Operator's Manual
3. The CR23X Prompt Sheet
This Overview introduces the concepts required to take advantage of the CR23X's capabilities. Handson programming examples start in Section OV4. Working with a CR23X will help the learning process,
so don't just read the examples, turn on the CR23X and do them. If you want to start this minute, go
ahead and try the examples, then come back and read the rest of the Overview.
•The sections of the Operator's Manual which should be read to complete a basic understanding of
the CR23X operation are the Programming Sections 1-3, the portions of the data retrieval Sections
4 and 5 appropriate to the method(s) you are using (see OV5), and Section 14 which covers
installation and maintenance.
•Section 6 covers details of serial communications. Sections 7 and 8 contain programming
examples. Sections 9-12 have detailed descriptions of the programming instructions, and Section
13 goes into detail on the CR23X measurement procedures.
The Prompt Sheet is an abbreviated description of the programming instructions. Once familiar with the
CR23X, it is possible to program it using only the Prompt Sheet and on-line prompts as a reference,
consulting the manual if further detail is needed.
OV1. PHYSICAL DESCRIPTION
The CR23X Micrologger with the alkaline
batteries is shown in Figure OV1-1. It is
powered with 10 "D" cells and has only the
power switch on the base. The rechargeable
CR23X has rechargeable lead acid cells. In
addition to the power switch, it has a charger
input plug and an LED which lights when the
charging circuit is active. Rechargeable
CR23Xs should always be connected to a solar
panel or AC charger. The lead acid batteries
provide backup in event of a power failure but
are permanently damaged if their voltage drops
below 11.76 volts. Campbell Scientific does not
warrant batteries.
The 16 character keyboard is used to enter
programs, commands and data; these can be
viewed on the 24 character x 2 line LCD
display.
OV-1
CR23X MICROLOGGER OVERVIEW
1
4
7
8
0
*
A
2
3
B
5
6
C
9
D
#
OV-2
FIGURE OV1-1. CR23X Micrologger
ced
ANALOG INPUTS
Input/Output Instructions
1 Volt (SE)
2 Volt (DIFF)
4 Ex-Del-Se
5 AC Half Br
6 Full Br
7 3W Half Br
8 Ex-Del-Diff
9 6W Full Br
11 Temp (107)
12 RH-(207)
13 Temp-TC SE
14 Temp-TC DIFF
16 Temp-RTD
27 Interval-Freq.
28 Vibrating Wire Meas
29 INW Press
131 Enhan
Signal Ground ( ), for
Analog
Pulse
Excitation
Sensor Shields
SE
DIFF
13 14
SE
DIFF
Vib. Wire
12
34
1
2
HL
HL
15 16
7
8
HL
HL
Continuous
Analog Outputs
133 Analog
EXCITATION OUTPUTS
Input/Output Instructions
4 Ex-Del-Se
5 AC Half Br
6 Full Br
7 3W Half Br
8 Ex-Del-Diff
9 Full Br-Mex
11 Temp (107)
12 RH (207)
22 Del w/Opt Ext
28 Wire Meas
29 INW Press
56
78
910
3
HL
17 18
9
HL
4
HL
19 20
40
HL
5
HL
21 22
11
HL
11 12
HL
23 24
HL
CR23X MICROLOGGER OVERVIEW
PULSE INPUTS
Input/Output Instructions
3 Pulse
6
12
EX1
EX2
EX3
EX4
CAO1
CAO2
POWER OUTCONTROL I/O
G5VG
SW12G12V
12VGC1C2C3C4GC5C6C7C8
SDM
DIGITAL I/O PORTS
Input/Output Instructions
3 Pulse
15 Serial I/O
20 Set Ports
21 Pulse Port
25 Read Ports
100-110, 118 SDM and SDI12
Instructions
134 AM25T
Program Control Instructions
83 If Case < F
86 Do
88 If X <=> Y
89 If X <=> F
91 If flag, port
92 If Time
Command Codes:
4X Set port x high
49 Switched 12 V on
5X Set port x low
59 Switched 12 V off
6X Toggle port x
7X Pulse port x
95 Port Subr.
96 Port Subr.
97 Port Subr.
98 Port Subr.
P1
P2
P3
P4
Power Ground (G), for
G 12V
POWER IN
G
5V
SW-12
12V
Control I/O
GROUND
LUG
External
12 Volt
Power Input
123A
04:REF_TEMP
456B
+21.93
789C
CR23X MICROLOGGER
COMPUTER
CS I/O
SERIAL I/O
Telecommunications
Program Control Instructions
96 Storage Module, Printer, Serial Out
FIGURE OV1-2. CR23X Panel and Associated Programming Instructions
OV-3
CR23X MICROLOGGER OVERVIEW
The 9-pin serial CS I/O port provides
connection to data storage peripherals, such as
the SM192/716 Storage Module, and provides
serial communication to computer or modem
devices for data transfer or remote
programming (Section 6). This 9 pin port does
NOT have the same pin configuration as the 9
pin serial ports currently used on most personal
computers. An SC32A is required to interface
the CS I/O port to a PC or other RS-232 serial
port (Section 6). An optically isolated computer
RS-232 port is also provided for direct
connection to PCs and other RS-232 devices.
The panel contains four terminal strips which
are used for sensor inputs, excitation, control
input/outputs, etc. Figure OV1-2 shows the
CR23X panel and the associated programming
instructions.
OV1.1 WIRING TERMINALS
Wiring terminals are provided on the CR23X to
allow connection of external sensors and other
devices.
OV1.1.1 ANALOG INPUTS
The terminals labeled 1H to 12L are analog
voltage inputs. These numbers (black) refer to
the high and low inputs to the differential
channels 1 through 12. In a differential
measurement, the voltage on the H input is
measured with respect to the voltage on the L
input. When making single-ended
measurements, either the H or L input may be
used as an independent channel to measure
voltage with respect to the CR23X analog
ground (
). The single-ended channels are
numbered sequentially starting with 1H (blue);
e.g., the H and L sides of differential channel 1
are single-ended channels 1 and 2; the H and L
sides of differential channel 2 are single-ended
channels 3 and 4, etc.
The analog input terminal strips have an
insulated cover to reduce temperature
gradients across the input terminals. The cover
is required for accurate thermocouple
measurements (Section 13.4).
OV1.1.2 EXCITATION OUTPUTS
The terminals labeled EX1, EX2, EX3, and EX4
are precision, switched excitation outputs used
to supply programmable excitation voltages for
resistive bridge measurements. DC or AC
excitation at voltages between -5000 mV and
+5000 mV are user programmable (Section 9).
OV1.1.3 CONTINUOUS ANALOG OUTPUTS (CAO)
Two CAO channels supply continuous output
voltages under program control, for use with strip
charts, x-y plotters, or proportional controllers.
OV1.1.4 PULSE INPUTS
The terminals labeled P1, P2, P3, and P4 are
the pulse counter inputs for the CR23X. They
are programmable for high frequency pulse, low
level AC, or switch closure (Section 9,
Instruction 3).
OV1.1.5 DIGITAL I/O PORTS
Terminals C1 through C8 are digital
Input/Output ports. On power-up they are
configured as input ports, commonly used for
reading the status of an external signal. High
and low conditions are: 3 V < high < 5.5 V; -
0.5 V < low < 0.8 V.
Configured as outputs the ports allow on/off
control of external devices. A port can be set
high (5 V ± 0.1 V), low (<0.1 V), toggled or
pulsed (Sections 3, 8.3, and 12).
Ports C5 through C8 can be configured as
pulse counters for switch closures (Section 9,
Instruction 3) or used to trigger subroutine
execution (Section 1.1.2).
Built in Zener diodes on the eight control ports
limit input voltage to acceptable levels of < =
5.6 VDC. Do not apply voltages greater than
16 VDC. A voltage of 5.0 VDC is preferred.
OV1.1.6 GROUNDS
The CR23X has ground terminals marked
and G. Signal returns of analog inputs and
their associated shields along with excitation
voltage returns are to be tied to the
terminals
located in the analog input terminal strips. The
G terminals (Power Grounds) are intended to
carry return currents from the 5 V, SW12, 12 V,
and C1-C8 outputs. Tying these potentially
large return currents to G terminals keeps these
currents from flowing through and corrupting
analog measurements. Offset voltage errors in
single-ended measurements can occur for
large (50 mA) currents flowing into the
terminals in the analog input terminal strips.
OV-4
CR23X MICROLOGGER OVERVIEW
Return currents from the CAO and pulsecounter channels should be tied to the
terminals in the CAO and pulse-counter
terminal strip to prevent them from flowing
through the analog measurement section.
The ground lug is also marked
a rugged ground path from the individual
G terminals to earth or chassis ground for ESD
protection.
Review Section 14.7 for complete grounding
recommendations.
OV1.1.8 5V OUTPUTS
The 5 V (±4.0%) output is commonly used to
power peripherals such as the QD1 Incremental
Encoder Interface, AVW1 or AVW4 Vibrating
Wire Interface.
The 5 V output is common with pin 1 on the CS
I/O 9 pin connector; 200 mA is the maximum
combined output.
OV1.1.9 CS I/O
The 9 pin CS I/O port contains lines for serial
communication between the CR23X and
external devices such as computers, printers,
Campbell modems, Storage Modules, etc. This
port does NOT have the same configuration
as the 9 pin serial ports currently used on
most personal computers. It has a 5 VDC
power line which is used to power peripherals
such as Storage Modules. The same 5 VDC
supply is used for the 5 V output on the lower
right terminal strip. It has a 12 VDC power line
used to power other peripherals such as the
COM200 phone modem. Section 6 contains
technical details on serial communication.
OV1.1.10 COMPUTER RS-232 PORT
This port is an optically isolated standard 9 pin
RS-232 DCE/DTE port. It can be connected
directly to the serial port of most personal
computers. A 6 foot 9 to 9 pin serial cable and a
9 to 25 pin adapter are included with the CR23X
to connect this port to a PC serial port.
OV1.1.11 SWITCHED 12 VOLT
The switched 12 volt output can be used to
power sensors or devices requiring an
unregulated 12 volts. The output is limited to
600 mA at 50°C (360 mA at 80°C) current. The
and provides
and
switched 12 volt port is addressed as “Port 9” in
a datalogger program.
When the port is set high, the 12 volts is turned
on; when the port is low, the switched 12 volts is
off (Section 8.12).
OV1.2 CONNECTING POWER TO THE CR23X
The CR23X should be powered by any clean,
battery backed 12 VDC source. The green
power connector on the wiring panel is a plug in
connector that allows the power supply to be
easily disconnected. The power connection is
reverse polarity protected. The datalogger
should be earth or chassis ground during
routine operation. See Section 14 for details on
power supply connections and grounding.
When primary power falls below 11.0 VDC, the
CR23X stops executing its programs. The Low
Voltage Counter (∗B window 9) is incremented
by one each time the primary power falls below
11.0 VDC and E10 is displayed. A double dash
(--) in the 9th window of the ∗B mode indicates
that the CR23X is currently in a low primary
power mode. (Section 1.6)
The datalogger program and stored data
remain in memory, and the clock continues to
keep time when power is disconnected. The
clock and SRAM are powered by an internal
lithium battery. (Section 14.11.2)
OV2. MEMORY AND PROGRAMMING
CONCEPTS
OV2.1 INTERNAL MEMORY
The standard CR23X has 512 Kilobytes of
Flash Electrically Erasable Programmable
Read Only Memory (EEPROM), 128 Kilobytes
Static Random Access Memory (SRAM), and 1
Megabyte of Flash RAM. As an option, the
CR23X can be purchased with 4 Megabyte
Flash for final storage. Operating system
EEPROM stores the operating system, user
programs, and labels. SRAM is used for final
storage data and running the user program.
Final Storage Flash is used for data storage.
The use of the Input, Intermediate, and Final
Storage in the measurement and data
processing sequence is shown in Figure
OV2.1-2. The five areas of SRAM are:
OV-5
CR23X MICROLOGGER OVERVIEW
1. System Memory - used for overhead tasks
such as compiling programs, transferring
data, etc. The user cannot access this
memory.
2. Active Program Memory - available for
user entered programs.
3. Input Storage - Input Storage holds the
results of measurements or calculations.
The
6 Mode is used to view Input
Storage locations for checking current
sensor readings or calculated values. Input
Storage defaults to 64 locations. Additional
locations can be assigned using the
A
Mode.
4. Intermediate Storage - Certain Processing
Instructions and most of the Output
Processing Instructions maintain
intermediate results in Intermediate
Storage. Intermediate storage is
automatically accessed by the instructions
and cannot be accessed by the user. The
default allocation is 64 locations. The
number of locations can be changed using
the
A Mode.
5. Final Storage - Final processed values are
stored here for transfer to printer, solid
state Storage Module or for retrieval via
telecommunication links. Values are stored
in Final Storage only by the Output
Processing Instructions and only when the
Output Flag is set in the user’s program.
Approximately 570,000 locations are
allocated to Final Storage from SRAM on
power up. This number is reduced if Input
or Intermediate Storage is increased.
While the total size of these three areas
remains constant, memory may be
reallocated between the areas to
accommodate different measurement and
processing needs (
A Mode, Section
1.5).
6. Alphanumeric Labels - The CR23X can
be programmed through EDLOG (PC208W
software) to assign alphanumeric labels to
Input Storage and Final Storage locations.
Labels must consist of letters, numbers, or
the underscore ( _ ), and must not begin
with a number.
OV-6
CR23X MICROLOGGER OVERVIEW
A
Flash Memory
(EEPROM)
Total 512 Kbytes
Operating System
(128 Kbytes)
Active Program
(32 Kbytes Code)
Stored Programs
(32 Kbytes Code)
(32 Kbytes Labels)
Temporary Copy of
Current Program
Saved during
download if download
is aborted
(64 Kbytes)
Alphanumeric Labels
(32 Kbytes)
Unassigned
(192 Kbytes)
How it works:
Operating System
The
Flash Memory at the factory.
Memory
running for calculations, buffering data
and general operating tasks.
ny time a user loads a program into
the CR23X, the program is compiled in
SRAM and stored in the
Program
powered off and then on, the Active
Program is loaded from Flash and run.
The Active Program is run in SRAM to
maximize speed. The program
accesses
Intermediate Storage
into
the user.
The Active Program can be copied into
the
program "names" are available, the
number of programs stored is limited
by the available memory. Stored
programs can be retrieved to become
the active program. While programs
are stored one at a time, all stored
programs are erased simultaneously.
That is because the flash memory can
only be written to once before it must
be erased and can only be erased in 16
Kbytes blocks.
(Memory Areas separated by dashed
lines:
can be re-sized by the user.)
1 byte per character stored. 9 bytes
per input location label. All final
storage label characters plus 2 bytes
per table name (array ID name) and
field name.
is used while the CR23X is
areas. If the CR23X is
Input Storage
Final Storage
Stored Programs
is loaded into
System
Active
and
and stores data
for later retrieval by
area. While 98
SRAM/FLASH
Total 1152 Kbytes
32K SRAM
System Memory
4096 Bytes
Active Program
Default
2048 Bytes
Input Storage
Default
112 Bytes
28 Locations
Intermediate Storage
Default
256 Bytes
64 Locations
96K SRAM
Final Storage 1 and 2
98,304 Bytes
49,154 Locations
1M FLASH
Final Storage 1 and 2
917,504 Bytes
458,752 Locations
or
4M FLASH
Final Storage 1 and 2
4,292,610 Bytes
2,146,305 Locations
Final Storage 1 Only
131,072 Bytes
65,536 Locations
Memory available only to
system
Memory shared between
Program, Input Storage,
and Intermediate Storage
Memory allocable to Final
Storage 1 and 2 only
Memory available only to
Final Storage area 1
FIGURE OV2.1-1. CR23X Memory
OV-7
CR23X MICROLOGGER OVERVIEW
OV2.2 PROGRAM TABLES, EXECUTION
INTERVAL AND OUTPUT INTERVALS
The CR23X must be programmed before it will
make any measurements. A program consists
of a group of instructions entered into a
program table. The program table is given an
execution interval which determines how
frequently that table is executed. When the
table is executed, the instructions are executed
in sequence from beginning to end. After
executing the table, the CR23X waits the
remainder of the execution interval and then
executes the table again starting at the
beginning.
The interval at which the table is executed
generally determines the interval at which the
sensors are measured. The interval at which
data are stored is separate from how often the
table is executed, and may range from samples
every execution interval to processed
summaries output hourly, daily, or on longer or
irregular intervals.
Programs are entered in Tables 1 and 2.
Subroutines, called from Tables 1 and 2, are
entered in Subroutine Table 3. The size of
program memory can be fixed or automatically
allocated by the CR23X (Section 1.5).
Table 1 and Table 2 have independent
execution intervals, entered in units of seconds
with an allowable range of 1/100 to 6553.5
seconds. Subroutine Table 3 has no execution
interval, since it is called from Table 1, Table 2,
or an interrupt subroutine.
OV2.2.1 THE EXECUTION INTERVAL
The execution interval specifies how often the
program in the table is executed, which is
usually determined by how often the sensors
are to be measured. Unless two different
measurement rates are needed, use only one
table. A program table is executed sequentially
starting with the first instruction in the table and
proceeding to the end of the table.
Table 1.
Execute every x sec.
0.01 < x < 6553.5
Instructions are executed
sequentially in the order they
are entered in the table.
One complete pass through
the table is made each
execution interval unless
program control instructions
are used to loop or branch
execution.
Normal Order:
MEASURE
PROCESS
CHECK OUTPUT COND.
OUTPUT PROCESSING
FIGURE OV2.2-1. Program and Subroutine Tables
Table 2.
Execute every y sec.
0.01 < y < 6553.5
Table 2 is used if there is a
need to measure and
process data on a separate
interval from that in Table 1.
Table 3.
Subroutines
A subroutine is executed
only when called from Table
1 or 2.
Subroutine Label
Instructions
End
Subroutine Label
Instructions
End
Subroutine Label
Instructions
End
OV-8
CR23X MICROLOGGER OVERVIEW
Each instruction in the table requires a finite
time to execute. If the execution interval is less
than the time required to process the table, an
execution interval overrun (table overrun)
occurs; the CR23X finishes processing the
table and waits for the next execution interval
before initiating the table. When a table
T
overrun occurs,
appears in the lower right
o
corner of the display in the Running Table
mode
0). Overruns and table priority are
(
discussed in Section 1.1.
OV2.2.2. THE OUTPUT INTERVAL
The interval at which output occurs must be an
integer multiple of the execution interval (e.g., a
table cannot have a 10 minute execution
interval and output every 15 minutes).
A single program table can have many different
output intervals and conditions, each with a
unique data set (Output Array). Program
Control Instructions are used to set the Output
Flag. The Output Processing Instructions
which follow the instruction setting the Output
Flag determine the data output and its
sequence. Each additional Output Array is
created by another Program Control Instruction
checking a output condition, followed by Output
Processing Instructions defining the data set to
output.
OV2.3 CR23X INSTRUCTION TYPES
Figure OV2.3-1 illustrates the use of three
different instruction types which act on data.
The fourth type, Program Control, is used to
control output times and vary program
execution. Instructions are identified by
numbers.
I/O Ports and CAO analog output ports are
also addressed with I/O Instructions.
2. PROCESSING INSTRUCTIONS (30-68,
Section 10) perform numerical operations
on values located in Input Storage and
store the results back in Input Storage.
These instructions can be used to develop
high level algorithms to process
measurements prior to Output Processing.
3. OUTPUT PROCESSING INSTRUCTIONS
(69-82, Section 11) are the only
instructions which store data in Final
Storage. Input Storage values are
processed over time to obtain averages,
maxima, minima, etc. There are two types
of processing done by Output Instructions:
Intermediate and Final.
Intermediate processing normally takes
place each time the instruction is executed.
For example, when the Average Instruction
is executed, it adds the values from the
input locations being averaged to running
totals in Intermediate Storage. It also keeps
track of the number of samples.
Final processing occurs only when the
Output Flag is high (Section 3.7.1). The
Output Processing Instructions check the
Output Flag. If the flag is high, final values
are calculated and output. With the
Average, the totals are divided by the
number of samples and the resulting
averages sent to Final Storage.
Intermediate locations are zeroed and the
process starts over. The Output Flag, Flag
0, is set high by a Program Control
Instruction which must precede the Output
Processing Instructions in the user entered
program.
1. INPUT/OUTPUT INSTRUCTIONS (1-29,
100-110, 113-118, 130-134; Section 9)
control the terminal strip inputs and outputs
(Figure OV1.1-2), storing the results in
Input Storage (destination). Multiplier and
offset parameters allow conversion of linear
signals into engineering units. The Digital
4. PROGRAM CONTROL INSTRUCTIONS
(83-98, 111, 120-123, 220; Section 12) are
used for logic decisions, conditional
statements, and to send data to peripherals.
They can set flags and ports, compare
values or times, execute loops, call
subroutines, conditionally execute portions
of the program, etc.
OV-9
CR23X MICROLOGGER OVERVIEW
INPUT/OUTPUT
INSTRUCTIONS
Specify the conversion of a sensor signal
to a data value and store it in Input
Storage. Programmable entries specify:
(1) the measurement type
(2) the number of channels to measure
(3) the input voltage range
(4) the Input Storage Location
(5) the sensor calibration constants
used to convert the sensor output to
engineering units
I/O Instructions also control analog
outputs and digital control ports.
INPUT STORAGE
Holds the results of measurements or
calculations in user specified locations.
The value in a location is written over
each time a new measurement or
calculation stores data to the locations.
OUTPUT PROCESSING
INSTRUCTIONS
Perform calculations over time on the
values updated in Input Storage.
Summaries for Final Storage are
generated when a Program Control
Instruction sets the Output Flag in
response to time or events. Results
may be redirected to Input Storage for
further processing. Examples include
sums, averages, max/min, standard
deviation, histograms, etc.
PROCESSING INSTRUCTIONS
Perform calculations with values in Input
Storage. Results are returned to Input
Storage. Arithmetic, transcendental and
polynomial functions are included.
INTERMEDIATE STORAGE
Provides temporary storage for intermediate
calculations required by the OUTPUT
PROCESSING INSTRUCTIONS; for
example, sums, cross products,
comparative values, etc.
Output Flag set high
FINAL STORAGE
Final results from OUTPUT
PROCESSING INSTRUCTIONS are
stored here for on-line or interrogated
transfer to external devices (Figure
OV5.1-1). When memory is full, new
data overwrites the oldest data.
OV-10
FIGURE OV2.3-1. Instruction Types and Storage Areas
CR23X MICROLOGGER OVERVIEW
OV3. COMMUNICATING WITH CR23X
The user can communicate with the CR23X
through either the integral keyboard and two line
LCD display, or through a telecommunications link
with a terminal or computer. The preferred method
for routine operation is through a
telecommunications link with a personal computer
running Campbell Scientific’s PC208 or PC208W
Datalogger Support Software. These packages
contain a program editor (EDLOG), datalogger
communications, automated telecommunications
data retrieval, a data reduction program (SPLIT),
and programs to retrieve data from Campbell
Scientific Storage Modules.
Some situations, however, require an alternate
communications method. The integral
keyboard is convenient for cursory on-site
inspection of datalogger functions. It can also
be used when becoming familiar with the
dataloggers functional modes as outlined in
Sections OV3.1 through OV5 and Section 1.
A third communications alternative is through a
dumb terminal or a computer terminal emulator
program through a telecommunications link.
Several arcane commands are used in this
mode as outlined in Section 5. The most useful
command to most CR23X users is the 7H
command, which places the CR23X in the
Remote Keyboard Mode. This mode uses the
same commands as when communicating onsite through the integral keyboard and display.
A common way to use this mode is to enter it
through the terminal emulator program in
PC208 or PC208W. Once the
telecommunications link is established, CR-LF
(carriage return - line feed) is issued from the
PC by hitting the <Enter> key several times
while in the terminal emulator. The CR23X will
respond by sending an asterisk (*) to the PC
screen. At the *, 7H followed by a CR-LF is
issued. The CR23X will respond with a greaterthan symbol (>). From the >, the functional
modes can be entered as outlined in Section 1.
OV3.1 CR23X KEYPAD/DISPLAY
On power-up, the "HELLO" message is
displayed while the CR23X checks memory.
The total size of memory is then displayed
(1664 K bytes of memory).
Using the keypad, work through the direct
programming examples in this overview in
addition to using EDLOG and you will have the
basics of CR23X operation as well as an
appreciation for the help provided by the
software and the CR23X on-line help.
The display will turn off automatically if not
continuously updated. The display will stay on if
continuously updated such as occurs in the
∗
and
6 modes. Otherwise, it will turn off
automatically to save 4 mA of power. Time to
display shut off is 3 minutes if left in the
mode, or 6 minutes if left in other modes not
continuously updating the screen. While in the
∗
0 mode, the screen can be manually turned
off by pressing the
#
. Press any other key to
turn it back on.
OV3.1.1 FUNCTIONAL MODES
CR23X/User interaction is broken into different
functional MODES (e.g., programming the
measurements and output, setting time,
manually initiating a block data transfer to
Storage Module, etc.). The modes are referred
to as Star (
accessed by first keying
) Modes since they are
, then the mode
number or letter. Table OV3.1-1 lists the
CR23X Modes.
Because the display uses approximately 4 mA
when active, it is automatically turned off if not
updated for three minutes, except in the
mode, where it is left on indefinitely. The
display can be turned off from the keypad in the
∗
0 mode by pressing #. Pressing any key
except the # key will cause the display to be
turned back on after it has been turned off.
TABLE OV3.1-1.
Mode Summary
Key Mode
∗
0 Compile program, log data and
indicate active Tables
∗
1 Program Table 1
∗
2 Program Table 2
∗
3 Program Table 3, subroutines only
∗
4 Parameter Entry Table
∗
5 Display/set real time clock
∗
6 Display/alter Input Storage data,
toggle flags or control ports.
∗
7 Display Final Storage data
∗
8 Final Storage data transfer to peripheral
∗
9 Storage Module commands
∗
A Memory allocation/reset
∗
B Signature/status
∗
C Security
∗
D Save/load program, set display
contrast, power up settings, ID, etc.
∗
# Used with TGT1 satellite transmitter
∗
∗
0
6
∗
5
OV-11
CR23X MICROLOGGER OVERVIEW
OV3.1.2 KEY DEFINITION
Keys and key sequences have specific
functions when using the keypad or a
computer/terminal in the remote keyboard state
(Section 5). Table OV3.1-2 lists these
functions. In some cases, the exact action of a
key depends on the mode the CR23X is in and
is described with the mode in the manual.
TABLE OV3.1-2 Key Description/Editing
Functions
A, B, C
Keys
, and D repeat when continuously
pressed. Repetitions occur slowly at first and then
speed up.
Action
Key
Any key Turn on display (except #)
0
- 9 Key numeric entries into display
∗
Enter Mode (followed by Mode
Number)
A
Enter/Advance
B
Back up
C
Change the sign of a number or
index a parameter
D
Show Help when “?” is on display
Enter the decimal point
#
Turns off display in ∗ 0
Shows output table name in
∗
Clear the rightmost digit keyed into
the display
# A
Advance to next instruction in
program table (
∗
1, ∗ 2, ∗ 3)
or to next Output Array in Final
Storage (
# B
Back up to previous instruction in
∗
7)
program table or to previous Output
Array in Final Storage
# D
Delete entire instruction
# 0
(then A or CR) Back up to the start of
the current array.
When using a computer/terminal to communicate
with the CR23X (Telecommunications remote
keyboard state) there are some keys available in
addition to those found on the keypad. Table
OV3.1-3 lists these keys.
7
TABLE OV3.1-3. Additional Keys Allowed in
Telecommunications
Key
Action
- Change Sign, Index (same as C)
CR Enter/advance (same as A)
S or ^S Stops transmission of data (10
second time-out; any character
restarts)
C or ^C Aborts transmission of Data
OV3.2 USING COMPUTER WITH DATALOGGER
SUPPORT SOFTWARE
Direct datalogger communication programs in
the datalogger support software (PC208W)
provide menu selection of tools to perform the
datalogger functions (e.g., set clock, send
program, monitor measurements, and collect
data). The user also has the option of directly
entering keyboard commands via a built-in
terminal emulator (Section OV3.3).
When using the support software, the
computer’s baud rate, port, and modem types
are specified and stored in a file for future use.
The simplest and most common interface is to
connect the optically isolated 9 pin “Computer
RS-232” port to a 9 pin PC RS-232 port. An
adapter is supplied with the CR23X for
connection to a 25 pin PC RS-232 port.
Otherwise, an SC32A can be used on the CS I/O
port. The SC32A converts and optically isolates
the voltages passing between the CR23X and the
external terminal device.
The SC12 Two Peripheral cable which comes
with the SC32A is used to connect the CS I/O
port of the CR23X to the 9 pin port of the
SC32A labeled "Datalogger". Connect the
"Terminal/Printer" port of the SC32A to the
serial port of the computer with a straight 25 pin
cable or, if the computer has a 9 pin serial port,
a standard 9 to 25 pin adapter cable.
OV3.3 ASCII TERMINAL OR COMPUTER WITH
TERMINAL EMULATOR
Devices which can be used to communicate
with the CR23X include standard ASCII
terminals and computers programmed to
function as a terminal emulator. See Section
6.7 for details.
OV-12
CR23X MICROLOGGER OVERVIEW
To communicate with any device, the CR23X
enters its Telecommunications Mode and
responds only to valid telecommunications
commands. Within the Telecommunications
Mode, there are 2 "states"; the
Telecommunications Command state and the
Remote Keyboard state. Communication is
established in the Telecommunications command
state. One of the commands is to enter the
Remote Keyboard state (Section 5).
The Remote Keyboard state allows the
keyboard of the computer/terminal to act like
the CR23X keypad. Various datalogger modes
may be entered, including the mode in which
programs may be keyed in to the CR23X from
the computer/terminal.
OV4. PROGRAMMING THE CR23X
A datalogger program is created on a computer
using EDLOG. A program can also be entered
directly into the datalogger using the keypad.
Section OV4.3 describes options for loading the
program into the CR23X.
OV4.1 PROGRAMMING SEQUENCE
In routine applications, the CR23X measures
sensor output signals, processes the
measurements over some time interval and
stores the processed results. A generalized
programming sequence is:
1. Enter the execution interval. In most cases,
the execution interval is determined by the
desired sensor scan rate.
2. Enter the Input/Output instructions required
to measure the sensors.
3. If processing in addition to that provided by
the Output Processing Instructions (step 5)
is required, enter the appropriate
Processing Instructions.
4. Enter the Program Control Instruction to
test the output condition and set the Output
Flag when the condition is met. For
example, use
Instruction 92 to output based on time.
Instruction 86 to output every execution
interval.
Instruction 88 or 89 to output based on a
comparison of values in input locations.
This instruction must precede the Output
Processing Instructions which store data in
Final Storage. Instructions are described in
Sections 9 through 12.
5. Enter the Output Processing Instructions to
store processed data in Final Storage. The
order in which data are stored is
determined by the order of the Output
Processing Instructions in the table.
6. Repeat steps 4 and 5 for additional outputs
on different intervals or conditions.
NOTE: The program must be executed for
output to occur. Therefore, the interval at
which the Output Flag is set must be evenly
divisible by the execution interval. For
example, with a 2 minute execution interval
and a 5 minute output interval, the output
flag will only be set on the even multiples of
the 5 minute intervals, not on the odd. Data
will be output every 10 minutes instead of
every 5 minutes.
Execution intervals and output intervals set with
Instruction 92 are synchronized with real time
starting at midnight.
OV4.2 INSTRUCTION FORMAT
Instructions are identified by an instruction
number. Each instruction has a number of
parameters that give the CR23X the information
it needs to execute the instruction.
The CR23X Prompt Sheet has the instruction
numbers in red, with the parameters briefly
listed in columns following the description.
Some parameters are footnoted with further
description under the "Instruction Option
Codes" heading. The CR23X also has on-line
help available when a “?” appears on the
display. Help is accessed by pressing
For example, Instruction 73 stores the
maximum value that occurred in an Input
Storage location over the output interval.
P73 Maximum
1: Reps
2: TimeOption
3: Loc
The instruction has three parameters (1)
REPetitionS, the number of sequential Input
D
.
OV-13
CR23X MICROLOGGER OVERVIEW
Storage locations on which to find maxima, (2)
TIME, an option of storing the time of
occurrence with the maximum value, and (3)
LOC, the first Input Storage location operated
on by the Maximum Instruction. The codes for
the TIME parameter are listed in the "Instruction
Option Codes".
The repetitions parameter specifies how many
times an instruction's function is to be repeated.
For example, four 107 thermistor probes may be
measured with a single Instruction 11, Temp-107,
with four repetitions. Parameter 2 specifies the
input channel of the first thermistor (the probes
must be connected to sequential channels).
Parameter 4 specifies the Input Storage location
in which to store measurements from the first
thermistor. If location 5 were used and the first
probe was on channel 1, the temperature of the
thermistor on channel 1 would be stored in input
location 5, the temperature from channel 2 in
input location 6, etc.
Detailed descriptions of the instructions are
given in Sections 9-12. Entering an instruction
into a program table is described in OV5.
OV4.3 ENTERING A PROGRAM
Programs are entered into the CR23X in one of
three ways:
Once a program is loaded in the CR23X, the
program will be stored in flash memory and will
automatically be loaded and run when the
datalogger is powered-up.
The program on power up function can also be
achieved by using a Storage Module. Up to 8
programs can be stored in the Storage Module,
the programs may be assigned any of the
numbers 1-8. If the Storage Module is
connected when the CR23X is powered-up the
CR23X will automatically load program number
8, provided that a program 8 is loaded in the
Storage Module (Section 1.8). The program
from the Storage Module will replace the active
program in flash memory.
OV5. PROGRAMMING EXAMPLES
The following examples stress direct interaction
with the CR23X using the keypad. At the
beginning of each example is an EDLOG listing
of the program. You can also participate in the
example by entering the program in EDLOG
and sending it to the CR23X and viewing
measurements with PC208W. (See the
PC208W manual for guidance.) You can also
work through the examples with the 16 key
keypad. You will learn the basics of CR23X
operation as well as an appreciation for the
help provided by the software.
1. Keyed in using the CR23X keypad.
2. Loaded from a pre-recorded listing using
the
D Mode. There are 2 types of
storage/input:
a. Stored on disk/sent from computer.
b. Stored/loaded from Storage Module.
3. Loaded from internal Flash Memory or
Storage Module upon power-up.
A program is created by keying it directly into
the datalogger as described in Section OV5, or
on a PC using PC208W.
Program files (.DLD) can be downloaded directly
to the CR23X using PC208W. Communication
via direct wire, telephone, cellular phone, or
Radio Frequency (RF) is supported.
Programs on disk can be copied to a Storage
Module with the appropriate software. Using the
D Mode to save or load a program from a
Storage Module is described in Section 1.8.
We will start with a simple programming
example. There is a brief explanation of each
step to help you follow the logic. When the
D
example uses an instruction, press
on
parameters marked with "?" for parameter
descriptions. Alternatively, find the instruction
on the Prompt Sheet and follow through the
description of the parameters. Using the
Prompt Sheet or on-line help while going
through these examples will help you become
familiar with their respective formats. Sections
9-12 have more detailed descriptions of the
instructions.
Turn on the CR23X. The programming steps in
the following examples use the keystrokes
possible on the keypad. With a terminal, some
responses will be slightly different.
When the CR23X is powered up, the display
will show:
OV-14
CR23X MICROLOGGER OVERVIEW
Display
Explanation
HELLO On power-up, the CR23X
displays "HELLO" while it
checks the memory
after a few seconds delay
1664 Kbytes The size of the machine's total
memory memory
When the CR23X is turned on, it tests the FLASH
memory and loads the current program to RAM.
After the program compiles successfully, the
CR23X begins executing the program. If a key is
pressed while the CR23X is testing memory
(“HELLO” is on the display), there will be a 128
second delay before compiling and running the
program. This can be used to edit or change the
program before it starts running.
In order to ensure that there is no active
program in the CR23X, load an empty program
using the
D Mode:
Display Will Show:
Key (ID:Data) Explanation
∗
Mode Enter mode
D
13:Enter Command Enter D Mode
00
7
13: 7 is command to
00 7 load program from
flash
A
07:Program ID Execute command
00 7, CR23X is ready
for program
number
0
07:Program ID Load Program 0
00 00 (empty program)
A
Execute program
load, after a short
wait, the display
will show
Prog. operation Indicating that the
complete command is
complete.
OV5.1 SAMPLE PROGRAM 1
EDLOG Listing Program 1:
*Table 1 Program
01: 5.0 Execution Interval (seconds)
1: Panel Temperature (P17)
1: 1 Loc [ CR23XTemp ]
2: Do (P86)
1: 10 Set Output Flag High
3: Sample (P70)
1: 1 Reps
2: 1 Loc [ CR23XTemp ]
In this example the CR23X is programmed to
read its panel temperature (using a built in
thermistor) every 5 seconds and to send the
results to Final Storage.
Display Will Show:
Key (ID:Data) Explanation
∗
Mode Enter mode.
1
Mode 01 Go To Enter Program
0000 Table 1.
A
Scan Interval Advance to
execution
+0000 interval (In seconds)
5
Scan Interval Key in an execution
+0.0000 5 interval of 5 seconds.
A
01:P00 Enter the 5 second
execution interval
and advance to the
first program
instruction location.
1 7
01:P00 Key in Instruction 17
17 which directs the
CR23X to measure
the panel
temperature in
degrees C. This is
an Input/Output
Instruction.
A
Panel Temp Enter Instruction 17
01:Loc and advance to the
0000 first parameter.
1
01:Loc The input location to
0000 1 store the
measurement,
location 1.
OV-15
CR23X MICROLOGGER OVERVIEW
A
02:P00 Enter the location #
and advance to the
second program
instruction.
The CR23X is now programmed to read the panel
temperature every 5 seconds and place the reading
in Input Storage Location 1. The program can be
compiled and the temperature displayed (note that
it is not yet storing data).
Display Will Show:
(ID:Data) Explanation
Key
∗
0 Running Table 1 Exit Table 1, enter
∗
0 Mode, compile
table and begin
logging.
∗
6 Mode 06 Enter Loc Enter ∗ 6 Mode (to
0001 view Input Storage).
A
0001: 21.234 Advance to first
storage location.
Panel temp. is
21.234°C (display
shows actual
temperature so exact
value will vary).
Wait a few seconds:
01:21.423 The CR23X has read
the sensor and stored
the result again. The
internal temp is now
21.423
o
C. The value
is updated every 5
seconds when the
table is executed. At
this point the CR23X is
measuring the
temperature every 5
seconds and sending
the value to Input
Storage. No data are
being saved. The next
step is to have the
CR23X send each
reading to Final
Storage. (Remember,
the Output Flag must
be set first.)
∗
1 Mode 01 Go To Exit ∗ 6 Mode.
Enter 0000 program
table 1.
2 A
02:P00 Advance to 2nd
instruction location
(this is where we left off).
8 6
02:P00 This is the DO
86 instruction (a
Program Control
Instruction).
A
Do Enter 86 and
01:CMD advance to the first
00 parameter (which will
specify the command
to execute).
1 0
01:CMD This command sets
00 10 the Output Flag
(Flag 0) high.
A
03:P00 Enter 10 and
advance to third
program instruction.
7 0
03:P00 The SAMPLE
70 instruction. It directs
the CR23X to take a
reading from an Input
Storage location and
send it to Final
Storage (an Output
Processing
Instruction).
A
Sample Enter 70 and
01:Reps advance to the first
0000 parameter
(repetitions).
1
01:Reps There is only one
0000 input location to
sample; repetitions =
1.
A
02:Loc Enter 1 and advance
0000 to second parameter
(Input Storage
location to sample).
1
02:Loc Input Storage
0000 1 Location 1, where
the
temperature is
stored.
A
04:P00 Enter 1 and advance
to fourth program
instruction.
∗
Mode Exit Table 1.
0
Running Table 1 Enter ∗ 0 Mode,
compile program, log
data.
OV-16
CR23X MICROLOGGER OVERVIEW
The CR23X is now programmed to measure
the internal temperature every 5 seconds and
send each reading to Final Storage. Values in
Final Storage can be viewed using the
∗
Mode.
Display Will Show:
(ID:Data) Explanation
Key
∗
7 Mode 07 Enter ∗ 7 Mode.
The Loc 13 Data
Storage Pointer
(DSP) is at Location
13 (in this example).
A
Array ID Advance to the first
01: value, the Output
+0102 Array ID. 102
indicates the Output
Flag was set by the
second instruction in
Program Table 1.
A
02: Advance to the first
+21.231 stored temperature.
A
Array ID Advance to the next
01: output array. Same
+0102 Output Array ID.
A
02: Advance to 2nd
+21.42 stored temp, 21.42
deg. C.
There are no date and time tags on the data.
They must be put there with Output Instruction
77. Instruction 77 is used in the next example.
If a terminal is used to communicate with the
CR23X, Telecommunications Commands
(Section 5) can be used to view entire Output
Arrays (in this case the ID and temperature) at
the same time.
3: If time is (P92)
1: 0 Minutes (Seconds --) into a
2: 60 Interval (same units as above)
3: 10 Set Output Flag High
4: Real Time (P77)
1: 110 Day,Hour/Minute
5: Average (P71)
1: 2 Reps
2: 1 Loc [ CR23XTemp ]
6: If time is (P92)
1: 0 Minutes (Seconds --) into a
2: 1440 Interval (same units as above)
3: 10 Set Output Flag High
7: Real Time (P77)
1: 110 Day,Hour/Minute
8: Maximum (P73)
1: 1 Reps
2: 10 Value with Hr-Min
3: 2 Loc [ TCTemp ]
9: Minimum (P74)
1: 1 Reps
2: 10 Value with Hr-Min
3: 2 Loc [ TCTemp ]
10: Serial Out (P96)
1: 71 SM192/SM716/CSM1
This second example is more representative of
a real data collection application. Once again,
the panel temperature is measured, but it is
used as a reference temperature for the
differential voltage measurement of a type T
(copper-constantan) thermocouple; the CR23X
is initially supplied with a short type T
thermocouple connected to differential channel
5.
When using a type T thermocouple, the copper
lead (blue) is connected to the high input of the
differential channel, and the constantan lead
(red) is connected to the low input.
A thermocouple produces a voltage that is
proportional to the difference in temperature
between the measurement and the reference
junctions.
OV-17
CR23X MICROLOGGER OVERVIEW
To make a thermocouple (TC) temperature
measurement, the temperature of the reference
junction (in this example, the panel
temperature) must be measured. The CR23X
takes the reference temperature, converts it to
the equivalent TC voltage relative to 0
o
C, adds
the measured TC voltage, and converts the
sum to temperature through a polynomial fit to
the TC output curve (Section 13.4).
Instruction 14 directs the CR23X to make a
differential TC temperature measurement. The
first parameter in Instruction 14 is the number
of times to repeat the measurement. Enter 1,
because in this example there is only one
thermocouple. If there were more than 1 TC,
they could be wired to sequential channels, and
the number of thermocouples entered for
repetitions. The CR23X would automatically
advance through the channels sequentially and
measure all of the thermocouples.
Parameter 2 is the voltage range to use when
making the measurement. The output of a type
T thermocouple is approximately 40 microvolts
per degree C difference in temperature
between the two junctions. The ±10 mV scale
will provide a range of +1000/40 = +250
this scale will not overrange as long as the
measuring junction is within 250
temperature). The resolution of the ±10 mV
range is 0.33 µV or 0.008
o
o
C because a
o
C (i.e.,
C of the panel
differential measurement is being made.
Parameter 3 is the analog input channel on
which to make the first, and in this case only,
measurement.
Parameter 4 is the code for the type of
thermocouple used. This information is located
on the Prompt Sheet, in the on-line help, or in
the description of Instruction 14 in Section 9.
The code for a type T (copper-constantan)
thermocouple is 1.
Parameter 5 is the Input Storage location in
which the reference temperature is stored.
Parameter 6 is the Input Storage location in
which to store the measurement (or the first
measurement; e.g., if there are 5 repetitions
and the first measurement is stored in location
3, the final measurement will be stored in
location 7). Parameters 7 and 8 are the
multiplier and offset. A multiplier of 1 and an
offset of 0 outputs the reading in degrees C. A
multiplier of 1.8 and an offset of 32 converts the
reading to degrees F.
In this example, the sensor is measured once a
minute, and the day, time, and average
temperature are output every hour. Once a day
the day, time, maximum and minimum
temperatures and the times they occur will be
output.
Final Storage data will be sent to Storage
Module. Remember, all on-line data output to a
peripheral device is accomplished with
Instruction 96 (Sections 4.1 and 12).
The first example described program entry one
keystroke at a time. This example does not
show the "A" key. Remember, "A" is used to
enter and/or advance (i.e., between each line in
the example below). This format is similar to
the format used in EDLOG.
It's a good idea to have both the manual and
the Prompt Sheet handy when going through
this example. Also look at the on-line help, key
, whenever “?” is displayed on the screen.
You can find the program instructions and
parameters on the Prompt Sheet and can read
their complete definitions in the manual.
To obtain daily output, the If Time instruction is
again used to set the Output Flag and is
followed by the Output Instructions to store time
and the daily maximum and minimum
temperatures and the time each occurs.
Any Program Control Instruction which is used
to set the Output Flag high will set it low if the
conditions are not met for setting it high.
Instruction 92 above sets the Output Flag high
every hour. The Output Instructions which
follow do not output every hour because they
are preceded by another Instruction 92 which
sets the Output Flag high at midnight (and sets
it low at any other time). This is a unique
feature of Flag 0. The Output Flag is
automatically set low at the start of each table
(Section 3.7).
OV5.3 EDITING AN EXISTING PROGRAM
When editing an existing program in the
CR23X, entering a new instruction inserts the
instruction; entering a new parameter replaces
the previous value.
To insert an instruction, enter the program table
and advance to the position where the
instruction is to be inserted (i.e., PXX in the
display) key in the instruction number, and then
key A. The new instruction will be inserted at
that point in the table, advance through and
enter the parameters. The instruction that was
at that point and all instructions following it will
be pushed down to follow the inserted
instruction.
OV-18
CR23X MICROLOGGER OVERVIEW
An instruction is deleted by advancing to the
instruction number (P in display) and keying #D
(Table 4.2-1).
SAMPLE PROGRAM 2
Instruction Parameter
(Loc:Entry)
(Par#:Entry) Description
1 Enter Program Table 1
01:60 60 second (1 minute) execution interval
# D
Key
until 01:P00 Erase previous Program before
is displayed continuing.
01:P17 Measure panel temperature
01:1 Store temp in Location 1
02:P14 Measure thermocouple temperature
(differential)
01:1 1 repetition
02:21 Range code (10 mV, 60 Hz Rejection)
03:5 Input channel of TC
04:1 TC type: copper-constantan
05:1 Reference temp is stored in Location 1
06:2 Store TC temp in Location 2
07:1 Multiplier of 1
08:0 No offset
03:P92 If Time instruction
01:0 0 minutes into the interval
02:60 60 minute interval
03:10 Set Output Flag 0
The CR23X is programmed to measure the thermocouple temperature every sixty seconds.
The If Time instruction sets the Output Flag at the beginning of every hour. Next, the Output
Instructions for time and average are added.
Instruction # Parameter
(Loc.:Entry)
(Par.#:Entry) Description
04:P77 Output Time instruction
01:110 Store Julian day, hour, and minute
To change the value entered for a parameter,
advance to the parameter and key in the
correct value then press A. Note that the new
value is not entered until A is keyed.
05:P71 Average instruction
01:1 one repetition
02:2 Location 2 - source of TC temps. to be
averaged
06:P92 If Time instruction
01:0 0 minutes into the interval
02:1440 1440 minute interval (24 hrs.)
03:10 Set Output Flag 0
07: P77 Output Time instruction
01:100 Store Day of Year
08: P73 Maximize instruction
01:1 One repetition
02:10 Output time of daily maximum in hours and minutes
03:2 Data source is Input Storage Location 2.
OV-19
CR23X MICROLOGGER OVERVIEW
09: P74 Minimize instruction
01:1 One repetition
02:10 Output the time of the daily minimum in hours
03:2 Data source is Input Storage Location 2.
The program to make the measurements and to send the desired data to Final Storage has
been entered. At this point, Instruction 96 is entered to enable data transfer from Final Storage
to Storage Module.
10:P96 Activate Serial Data Output.
1:71 Output Final Storage data to Storage Module.
The program is complete. (Here the example reverts back to the key by key format.)
Display Explanation
Key
5
∗
00:21:32 Enter
correctly.
A
05:0000 Advance to location for year.
1 9 9 6
A
05:0000 Enter and advance to location for Julian day.
1 9 7
A
05:0021 Enter and advance to location for hours and minutes (24 hr. time).
05:1324 Key in hrs.:min. (1:24 PM in this example).
and minutes
∗
5 Mode. Clock running but perhaps not set
OV-20
CR23X MICROLOGGER OVERVIEW
OV6. DATA RETRIEVAL OPTIONS
There are several options for data storage and
retrieval. These options are covered in detail in
Sections 2, 4, and 5. Figure OV6.1-1
summarizes the various possible methods.
Regardless of the method used, there are three
general approaches to retrieving data from a
datalogger.
1) On-line output of Final Storage data to a
peripheral storage device. On a regular
schedule, that storage device is either
"milked" of its data or is brought back to the
office/lab where the data is transferred to
the computer. In the latter case, a "fresh"
storage device is usually left in the field
when the full one is taken so that data
collection can continue uninterrupted.
2) Bring a storage device to the datalogger
and milk all the data that has accumulated
in Final Storage since the last visit.
TABLE OV6.1-1. Data Retrieval Methods and Related Instructions
Method Instruction/Mode Section in Manual
3) Retrieve the data over some form of
telecommunications link, whether it be RF,
telephone, cellular phone, short haul
modem, or satellite. This can be performed
under program control or by regularly
scheduled polling of the dataloggers.
Campbell Scientific's Datalogger Support
Software automates this process.
Regardless of which method is used, the
retrieval of data from the datalogger does NOT
erase those data from Final Storage. The data
remain in the ring memory until:
They are written over by new data (Section 2.1)
Memory is reallocated or the CR23X is reset
(Section 1.5)
Table OV6.1-1 lists the instructions used with
the various methods of data retrieval.
Storage Module Instruction 96 4.1, 12
Telecommunications Telecommunications
Commands 5
Instruction 97 12
Instruction 99 12
Printer or other Instruction 96 4.1, 12
Serial device Instruction 98 12
8
9
8
4.2
4.5
4.2
OV-21
CR23X MICROLOGGER OVERVIEW
CR23X
COMPUTER
RS-232
DSP4
HEADS UP
DISPLAY
SM192/716
STORAGE
MODULES
STORAGE
MODULE
OR CARD
BROUGHT
FROM THE
FIELD TO
THE
COMPUTER
SM192/716
STORAGE
MODULES
CSM1
CSM1
CS I/OPORT
CS I/O PORT
SC12 CABLES
MD9
MULTIDROP
INTERFACE
COAXIAL
CABLE
MD9
MULTIDROP
INTERFACE
SC12 CABLESC12 CABLE
SC532
RS-232
INTERFACE
COMPUTER
ASYNCHRONOUS SERIAL
COMMUNICATIONS PORT
RF95 RF
MODEM
RF100/RF200
TRANSCEIVER
W/ ANTENNA
& CABLE
RF100/RF200
TRANSCEIVER
W/ ANTENNA
& CABLE
RF232 RF
BASE
STATION
SC32A
RS-232
INTERFACE
INTERFACE
SRM-6A RAD
SHORTHAUL
MODEM
SRM-6A RAD
SHORTHAUL
MODEM
RS-232
CABLE
SC932
COM200 OR
VS1 PHONE
MODEM
PHONE
LINE
HAYES
COMPATIBLE
PHONE
MODEM
COM100
CELLULAR
PHONE
SATELLITE
GROUND
STATION
NOTES:1. ADDITIONAL METHODS OF DATA RETRIEVAL ARE:
A. SATELLITE TRANSMISSION
B. DIRECT DUMP TO PRINTER
C. VOICE PHONE MODEM TO VOICE PHONE OR PC WITH HAYES COMPATIBLE
PHONE MODEM
2. THE DSP4 HEADS UP DISPLAY ALLOWS THE USER TO VIEW DATA IN INPUT
STORAGE. ALSO BUFFERS FINAL STORAGE DATA AND WRITES IT TO PRINTER
OR STORAGE MODULE.
3. ALL CAMPBELL SCIENTIFIC RS-232 INTERFACE PERIPHERALS HAVE A FEMALE
25 PIN RS-232 CONNECTOR.
4. THE “COMPUTER RS-232” PORT HAS A FEMALE 9 PIN CONNECTOR.
FIGURE OV6.1-1. Data Retrieval Hardware Options
OV-22
CR23X MICROLOGGER OVERVIEW
OV7. SPECIFICATIONS
Electrical specifications are valid for -25° to 50°C range unless otherwise specified. To maintain electrical specifications, yearly recalibrations are recommended.
PROGRAM EXECUTION RATE
Program is synchronized with real-time up to 100 Hz.
Two fast (250 µs integration) single-ended measurements can write to final storage at 100 Hz. Burst
measurements are possible at rates up to 1.5 kHz over
short intervals.
CLOCK ACCURACY
±1 minute per month
ANALOG INPUTS
DESCRIPTION: 12 differential or 24 single-ended,
individually configured. Channel expansion
provided through AM416 Relay Multiplexers and
AM25T Thermocouple Multiplexers.
ACCURACY: ±0.025% of FSR;0° to 40°C
±0.05% of FSR;-25° to 50°C
±0.075% of FSR;-40° to 80°C (optional)
±5 µV offset voltage error is possible with SE
measurements.
RANGES AND RESOLUTION
InputResolution (µV) Accuracy (mV)
Range (mV) Diff.SE(-25° to 50°C)
±5000166333±5.00
±100033.366.6±1.00
±2006.6613.3±0.20
±501.673.33±0.05
±100.330.66±0.01
INPUT SAMPLE RATES: Includes the measurement
time and conversion to engineering units. Differential measurements incorporate two integrations with reversed input polarities to reduce
thermal offset and common mode errors. Fast
measurement integrates the signal for 250 µs;
slow measurement integrates for one power
line cycle (50 or 60 Hz).
Fast single-ended voltage:2.1 ms
Fast differential voltage:3.1 ms
Slow single-ended voltage (60 Hz):18.3 ms
Slow differential voltage (60 Hz):35.9 ms
Fast differential thermocouple:6.9 ms
INPUT REFERRED NOISE: Typical for ±10 mV Input
Range;digital resolution dominates for higher
ranges.
Fast differential0.60 µV rms
Slow differential (60 Hz)0.15 µV rms
Fast single-ended1.20 µV rms
Slow single-ended (60 Hz)0.30 µV rms
COMMON MODE RANGE: ±5 V.
DC COMMON MODE REJECTION:>100 dB.
NORMAL MODE REJECTION:70 dB (60 Hz with slow
diff.measurement).
SUSTAINED INPUT VOLTAGE WITHOUT DAMAGE:
±16 VDC max.
INPUT CURRENT:±2.5 nA typ., ±10 nA max.at 50°C.
INPUT RESISTANCE: 20 Gohms typical.
ANALOG OUTPUTS
DESCRIPTION: 4 switched, active only during
measurement one at a time;2 continuous.
RANGE: Programmable between ±5 V
RESOLUTION: 333 µV
ACCURACY: ±5 mV;±2.5 mV (0° to 40°C).
CURRENT SOURCING: 50 mA for switched;15 mA
for continuous.
CURRENT SINKING: 50 mA for switched, 5 mA for
continuous (15 mA for continuous with Boost
selected in P133).
FREQUENCY SWEEP FUNCTION: The switched
outputs provide a programmable swept frequency,
0 to 5 V square wave for exciting vibrating wire
transducers.
RESISTANCE MEASUREMENTS
MEASUREMENT TYPES: The CR23X provides ratio-
metric measurements of 4- and 6-wire full bridges,
and 2-, 3-, and 4-wire half bridges.Precise, dual
polarity excitation using any of the 4 switched
outputs eliminates DC errors. Conductivity
measurements use a dual polarity 0.75 ms excitation to minimize ionic polarization errors.
ACCURACY: ±0.02% of FSR (±0.015%, 0° to 40°C)
plus bridge resistor error.
PERIOD AVERAGING MEASUREMENTS
DESCRIPTION: The average period for a single
cycle is determined by measuring the duration
of a specified number of cycles. Any of the 24
SE analog inputs can be used;signal attenuation
and AC coupling is typically required.
INPUT FREQUENCY RANGE: Signal centered
around ground.
Max.InputMin. signal (Peak to Peak)
Frequency@ Max.Freq.
10 kHz2 mV
20 kHz5 mV
30 kHz10 mV
200 kHz500 mV
RESOLUTION:12 ns divided by the number of cycles
measured.
ACCURACY:±0.03% of reading.
PULSE COUNTERS
DESCRIPTION: Four 8-bit or two 16-bit inputs
selectable for switch closure, high frequency pulse,
or low-level AC. Counters read at 10 or 100 Hz.
MAXIMUM COUNT RATE: 2.5 kHz and 25 kHz, 8-bit
counter read at 10 Hz and 100 Hz, respectively;500 kHz, 16-bit counter.
SWITCH CLOSURE MODE
Minimum Switch Closed Time:5 ms.
Minimum Switch Open Time:6 ms.
Maximum Bounce Time:1 ms open without being
counted.
HIGH FREQUENCY PULSE MODE
Minimum Pulse Width: 1 µs.
Maximum Input Frequency: 500 kHz.
Voltage Thresholds: Count upon transition from
below 1.5 V to above 3.5 VDC. Larger transitions
required at high frequencies because of 0.5 µs
time constant filter.
Maximum Input Voltage: ±20 V.
LOW LEVEL AC MODE
Internal AC coupling removes DC offsets up to
±0.5 V .
Input Hysteresis: 15 mV.
Maximum AC Input Voltage: ±20 V.
Frequency RangeMin.sine wave rms
1.0 Hz to 1 kHz20 mV
0.5 Hz to 10 kHz200 mV
0.3 Hz to 16 kHz1000 mV
DIGITAL I/O PORTS
DESCRIPTION: 8 ports selectable as binary inputs or
control outputs. Ports C5-C8 capable of counting
switch closures and high frequency.
HIGH FREQUENCY MAX: 2.5 kHz
OUTPUT VOLTAGES (no load):high 5.0 V ±0.1 V;
low < 0.1 V.
OUTPUT RESISTANCE: 500 ohms.
INPUT STATE: high 3.0 to 5.5 V; low -0.5 to 0.8 V.
INPUT RESISTANCE: 100 kohms.
SDI-12 INTERFACE SUPPORT
DESCRIPTION: Digital I/O Ports C5-C8 support SDI-
12 asynchronous communication;up to 10 SDI-12
sensors can be connected to each port.
EMI and ESD PROTECTION
Encased in metal with gas discharge tubes on the
panel, the CR23X has EMI filtering and ESD protection
on all input and output connections.
CE COMPLIANCE
APPLICATION OF COUNCIL DIRECTIVE(S):
89/336/EEC as amended by 89/336/EEC and
93/68/EEC
STANDARD(S) TO WHICH CONFORMITY IS
DECLARED:
ENC55022-1:1995 and ENC50082-1: 1992
CPU AND INTERFACE
PROCESSORS:Hitachi 6303; Motorola 68HC708
supports communications.
MEMORY:1 M Flash stores 500K data values;
512K Flash stores OS and user programs with
128K battery-backed SRAM. Optional 4 M Flash
available.
DISPLAY: 24-character-by-2-line LCD.
SERIAL INTERFACES: Optically isolated RS-232
9-pin interface for computer or modem. CS 9-pin
I/O interface for peripherals such as card storage
module or modem.
BAUD RATES: Selectable at 300, 1200, 2400, 4800,
9600, 19.2K, 38.4K, and 76.8K. ASCII protocol
is one start bit, one stop bit, eight data bits, no
parity.
SYSTEM POWER REQUIREMENTS
VOLTAGE: 11 to 16 VDC.
TYPICAL CURRENT DRAIN: 2 mA quiescent with
display off (2.5 mA max), 7 mA quiescent with
display on, 45 mA during processing, and
70 mA during analog measurement.
INTERNAL BATTERIES: 7 Ahr alkaline or 7 Ahr
rechargeable base;low-profile base without bat-
teries optional. 1800 mAhr lithium battery for clock
and SRAM backup typically provides 10 years of
service.
EXTERNAL BATTERIES: Any 11 to 16 V battery
may be connected;reverse polarity protected.
PHYSICAL SPECIFICATIONS
SIZE: 9.5” x 7.0” x 3.8” (24.1 cm x 17.8 cm x 9.6 cm).
Terminal strips extend 0.4” (1.0 cm) and ter minal
strip cover extends 1.3”(3.3 cm) above the panel
surface.
WEIGHT: 3.6 lbs (1.6 kg) with low-profile base,
8.3 lbs (3.8 kg) with alkaline base,
10.7 lbs (4.8 kg) with rechargeable base.
WARRANTY
3 years against defects in materials and workmanship.
(as of 01/98)
OV-23
CR23X MICROLOGGER OVERVIEW
This is a blank page.
OV-24
SECTION 1. FUNCTIONAL MODES
1.1 DATALOGGER PROGRAMS - 1,
2, 3, AND 4 MODES
Data acquisition and processing functions are
controlled by user-entered instructions
contained in program tables. Programming can
be separated into 2 tables, each having its own
user-entered execution interval. A third table is
available for programming subroutines which
may be called by instructions in Tables 1 or 2 or
by special interrupts. The
1and
Modes are used to access Tables 1 and 2. The
3 Mode is used to access Subroutine
Table 3.
The
4 Mode Table is a table of values
used in the program that someone can change
while the rest of the program is protected.
These values may be used for sensor
calibrations or to select optional sensors. The
4 Table is only available when a special
program created by EDLOG is loaded in the
CR23X.
When a program table is first entered, the
display shows the mode (table) number on the
first line and 0000 on the second line. Keying
an "A" will advance the editor to the scan
interval. If there is an existing program in the
table, keying an instruction location number
prior to "A" will advance directly to the
instruction (e.g., 5 will advance to the fifth
instruction in the table).
1.1.1 SCAN (EXECUTION) INTERVAL
The scan interval is entered in units of seconds
as follows:
1/100 ....1 second, in multiples of 1/100 (.01)
1 ...........6553.5 seconds, in multiples of 1/10
(0.1)
Execution of the table is repeated at the rate
determined by this entry. The table will not be
executed if 0 is entered.
The sample rate for a CR23X measurement is
the rate at which the measurement instruction
can be executed (i.e., the measurement made,
scaled with the instruction's multiplier and
offset, and the result placed in Input Storage).
2
Additional processing requires extra time. The
throughput rate is the rate at which a
measurement can be made and the resulting
value stored in Final Storage. The maximum
throughput rate for fast single-ended
measurements, other than burst
measurements, is 600 measurements per
second (24 measurements repeated 25 times
per second with the settling time set at 100 µs
with Instruction P132).
If the specified execution interval for a table is
less than the time required to process that
table, the CR23X finishes processing the table
and waits for the next occurrence of the
execution interval before again initiating the
table (i.e., when the execution interval has
elapsed and the table is still executing, that
execution is skipped). Since no advantage is
gained in the rate of execution with this
situation, it should be avoided by specifying an
execution interval adequate for the table
processing time.
NOTE: Whenever the processing time of
the user's program exceeds a table's
execution interval, an error is logged in
memory. The number of overrun errors
can be displayed and reset in the
B
mode (Section 1.6) or using the
Telecommunications A command (Section
5.1). An overrun will also cause “
T
” to
o
appear in the lower right corner of the
display. “
T
” will appear on the first table
o
overruns and continue to be displayed until
table overruns stop and 0 or another
mode command is entered.
In some cases, the processing time may exceed
the execution interval only when the Output Flag is
set and extra time is consumed by final Output
Processing. This may be acceptable. For
example, suppose it is desired to sample some
phenomena every 0.1 seconds and output
processed data every 10 minutes. The processing
time of the table which does this is less than 0.1
seconds except when output occurs (every 10
minutes). With final output the processing time is
1 second. With the execution interval set at 0.1
seconds, and a one second lag between samples
once every 10 minutes, 9 measurements out of
5000 (.18%) are missed: an acceptable statistical
error for most populations.
1-1
SECTION 1. FUNCTIONAL MODES
1.1.2 SUBROUTINES
Table 3 is used to enter subroutines which may
be called with Program Control Instructions in
Tables 1 and 2 or other subroutines. The group
of instructions which form a subroutine must
begin with Instruction 85, Label Subroutine, and
end with Instruction 95, End (Section 12).
Subroutines 95, 96, 97, and 98 have the unique
capability of being executed when a port goes
high (ports 5, 6, 7, and 8 respectively). Any of
these subroutines will interrupt Tables 1 and 2
(Section 1.1.3) when the appropriate port goes
high. When the port goes high, the processor
awakes within a few microseconds. The port
triggers on the rising edge (i.e., when it goes
from low to high). If the port stays high, the
subroutine is not called again.
1.1.3 TABLE PRIORITY/INTERRUPTS
Table 1 execution has priority over Table 2. If
Table 2 is being executed when it is time to
execute Table 1, Table 2 will be interrupted.
After Table 1 processing is completed, Table 2
processing resumes at the interruption point. If
the execution interval of Table 2 coincides with
Table 1, Table 1 is executed first, then Table 2.
created using EDLOG which allows instruction
parameters to be assigned to the
In a network of datalogger stations, the
4 table.
4
table can be used to simplify site customization
and the procedure of information entry. Once a
generalized program is developed, application
specific details, e.g., sensor calibration, can be
entered without accessing the
2 program tables or the
1 and
3
subroutine table.
ASSIGNING PARAMETERS TO
4 -
EDLOG
The only way to implement the
4 mode is
through EDLOG. The datalogger program is
generated in EDLOG in the normal way.
To assign a parameter to a
4 location,
position the cursor on the desired parameter
and press the "@" key. EDLOG then prompts
for the location number in the
4 table to
be assigned to the associated parameter. After
a valid number is entered, EDLOG marks the
parameter with "@@nn" to the right of the
4
parameter description, where "nn" is the
location number.
Interrupts by Table 1 are not allowed in the
middle of an instruction or while output to Final
Storage is in process (flag 0 is set high). The
interrupt occurs as soon as the instruction is
completed or flag 0 is set low.
Special subroutines 95, 96, 97, and 98, initiated
by a port going high (Section 1.1.2), can
interrupt either Table 1 or 2 or can occur when
neither is being executed. These subroutines
can interrupt a table while the Output Flag is
set. When the port goes high during the
execution of a table, the instruction being
executed is completed before the subroutine is
run (i.e., as if the subroutine was called by the
next instruction). For more information, refer to
Section 12 (P85 Label Subroutine).
1.1.4
4 PARA METER ENTRY TABLE
The CR23X
4 mode is a table with up to
one hundred values. Each value corresponds
to an instruction parameter in the datalogger
program. When the datalogger compiles the
program, values in the
4 table are
transferred to the corresponding instruction
parameter. The datalogger program must be
Any program parameter or execution interval
can be marked for inclusion in the table, as
illustrated below.
4 location 0 is
assigned to the program table execution
interval, and locations 1 and 2 to the multiplier
and offset of the measurement instruction.
Note that a default execution interval of zero
means the program will not execute until an
alternative interval is entered in location 00 of
4 mode. A default multiplier and
the
offset of 1 and 0 means that the measurement
value is in units of millivolts. A different
1-2
SECTION 1. FUNCTIONAL MODES
4
multiplier and offset can be entered in
locations 1 and 2, respectively.
4 location can be used in only one
A
program parameter. For example,
4
locations 0, 1, and 2 used in the example
cannot be reused in another instruction in the
same program.
If the
4 feature is enabled in EDLOG
when printing a program to a printer or disk file,
the
4 list is printed at the end of the file.
Once the EDLOG created program has been
sent to the CR23X, it can be saved in the Flash
memory program storage area using the
D Mode (Section 1.8).
CHANGING VALUES IN
Enter the
4 Mode by keying " 4";
4 TABLE
"04:00" is then displayed. At this point it is
possible to jump to any valid
4 location by
keying the desired location number and
pressing the A key. For example, when the
display shows 04:00 and the desired location is
80, key in the number 80, press the A key and
the display will show "80:XXXXX." where
XXXXX. is the value stored in location 80.
Pressing the "A" key advances to the next
4 location, and the "B" key backs up to
the previous location. If a
4 location is not
assigned in the datalogger program, it can not
be displayed in the
To enter a value in a
4 mode.
4 location, advance
to the desired location, key in the number and
enter it by pressing the "A" key. The value is
not entered if the "A" key is not pressed.
Entering a new value causes the datalogger to
stop logging. Logging resumes when the
0
program is compiled. Upon compiling (
or 6), all current 4 values are
incorporated into the program. For this reason,
4
whenever changes are made in the
mode, make sure that all 4 values are
correct before exiting the
4 mode.
Removing or adding an instruction to a program
residing in the datalogger disables the
4
mode. An instruction parameter may be edited
without any adverse affect. If the
4 mode
is disabled, it may be reactivated by
downloading the program to the datalogger or, if
the program was saved to Flash storage,
retrieving the program from the stored program
area.
The
C mode (Section 1.7) may be used to
secure the datalogger program and the
mode entries. The lowest level of security
prevents access to the
1, 2, and
3 modes. Higher levels of security block
4.
The CR23X will not respond to the
command if any of the following conditions
exist.
•the program that was downloaded does not
contain any
4 assignments.
•a program that was downloaded has since
been hand edited.
•Security is blocking access to
4.
1.1.5 COMPILING A PROGRAM
When a program is first loaded, or if any
changes are made in the
1, 2,
3, 4, A, or C Modes, the
program must be compiled before it starts
running. The compile function checks for
programming errors and optimizes program
information for use during program execution. If
errors are detected, the appropriate error codes
are indicated on the display (Section 3.10). The
compile function is executed when the
6, or B Modes are entered and prior
to saving a program listing in the
D Mode.
The compile function is only executed after a
program change has been made and any
subsequent use of any of these modes will
return to the mode without recompiling.
When the
0 or B Mode is used to
compile, all output ports and flags are set low,
the timer is reset, and data values contained in
Input and Intermediate Storage are reset to
zero.
When
0 is used, one of the following
status lines will be displayed: Running Table 1,
Running Table 2, No Active Program, Running
Table 1, 2, Tables Not Running.
When the
6 Mode is used to compile data
values contained in Input Storage, the state of
flags, control ports, and the timer (Instruction
26) are unaltered. Compiling always zeros
Intermediate Storage.
4
0,
4
1-3
SECTION 1. FUNCTIONAL MODES
1.2 SETTING AND DISPLAYING THE
CLOCK - 5 MODE
The 5 Mode is used to display or set time.
When "∗5" is entered, time is displayed. It is
updated approximately once a second or longer
depending on the rate and degree of data
collection and processing taking place. The
sequence of time parameters displayed in the
5 Mode is given in Table 1.2-1.
To set the year, day, or hours and minutes,
enter the
the appropriate value. Key in the desired
number and enter the value by keying "A".
When a new value for hours and minutes is
entered, the seconds are set to zero and current
time is again displayed. To exit the
Mode, key "∗" and the mode you wish to enter.
When the time is changed, a partial recompile
is done automatically to synchronize the
program with real time.
Changing time affects the output and execution
intervals in which time is changed. Because
time can only be set with a 1 second resolution,
execution intervals of 1 second or less remain
constant. Averaged values will still be accurate,
though the interval may have a different number
of samples than normal. Totalized values will
reflect the different number of samples. The
pulse count instruction will use the previous
interval's value if an option has been selected to
discard odd intervals, otherwise it will use the
count accumulated in the interval.
KeyID:DATA
5
∗
A
A
A
A
5 Mode and advance to display
5
TABLE 1.2-1. Sequence of Time
5
Parameters in
∗
Mode
Display
Description
HH:MM:SSDisplay current time
YearDisplay/enter year
XXXX
Day of YearDisplay/enter day of
XXXXyear 1-365(366) or
D
orpress
and enter
MMDDas month and day,
XXXXsuch as 1012 for
October 12.
toggles back to Day
of Year.
TimeDisplay/enter
HHMMhours:minutes
SecondsDisplay/enter
SSseconds
1.3 DISPLAYING/ALTERING INPUT
MEMORY, FLAGS, AND PORTS -
6 MODE
The 6 Mode is used to display and/or
change Input Storage values and to toggle and
display user flags and ports. If the
is entered immediately following any changes in
program tables, the program will be compiled and
run.
NOTE: Input Storage data and the state of
flags, control ports, and the timer
(Instruction 26) are UNALTERED
whenever program tables are altered and
recompiled with the 6 Mode.
Compiling always zeros Intermediate
Storage.
TABLE 1.3-1. 6 Mode Commands
KeyAction
6
∗
A
Enter 6 mode
Advance to next input location or
enter new value
B
C
Back-up to previous location
Change value in first input location on
display (followed by keyed in value,
then "A")
D
1
0
#
Display/alter user flags 1 through 8
Display/alter user flags 11 through 18
Display/alter ports
Display current location and allow a
location number to be keyed in,
followed by "A" to jump to that
location
1.3.1 DISPLAYING AND ALTERING INPUT
STORAGE
When "∗6" is entered, the keyboard/display will
read "Mode 06 Enter Loc". One can advance to
view the value stored in input location 1 by
keying "A". To go directly to a specific location,
key in the location number before keying "A".
For example, to view the value contained in
Input Storage location 20, key in "*6 20 A". The
D
left portion of the display shows the location
number and the 9-character label assigned to
that location in the programming portion
(EDLOG) of Campbell Scientific’s PC208W
datalogger support software. If the value stored
in the location being monitored is the result of a
program instruction, the value on the display will
be the result of the most recent scan and will be
6 Mode
1-4
SECTION 1. FUNCTIONAL MODES
updated each time the instruction is executed.
When using the
6 Mode from a remote
terminal, a number (any number) must be sent
before the value shown will be updated.
Input locations can be used to store parameters
for use in computations. To store a value in a
location, or change the current value, key "C"
while monitoring the location, followed by the
desired number and "A".
If an algorithm requires parameters to be
manually modified during execution of the
Program without interruption of the Table
execution process, the
6 Mode can be
used. (If parameters will not need modification,
it is better to load them from the program using
Instruction 30.) If initial parameter values are
required to be in place before program execution
commences, use Instruction 91 at the beginning
of the program table to prevent the execution
until a flag is set (see the next section). Initial
parameter values can be entered into input
locations using the
6 Mode C command.
The flag can then be set to enable the table(s).
skipped. Flag 5 can be toggled from the
6 Mode, effectively starting and stopping
the execution of Table 2.
1.3.3 DISPLAYING AND TOGGLING PORTS
NOTE: The switched 12 V port is displayed
as “control port 9.” Other port options are not
available on the switched 12 volt channel.
The status of the CR23X ports can be displayed
by hitting "0" while looking at an input location
(e.g.,
6 A 0). Ports are displayed left
to right as SW12, C8, C7, ... , C1 (opposite to
the flags). A port configured as output can be
toggled by hitting its number while in the port
display mode. There is no effect on ports
configured as inputs.
On power up all ports are configured as inputs.
Instruction 20 is used to configure a port as an
output. Ports are also configured as outputs by
any program control commands which uses the
port as an output (pulse, set high, set low, toggle).
If the program is altered and compiled with
Mode, all values previously entered via 6
will be set to zero. To preserve 6 C entered
values, compile with
6 after changing the
program.
1.3.2 DISPLAYING AND TOGGLING USER
FLAGS
If D is keyed (for Flags 1 to 8), or 1 is keyed (for
Flags 11 to 18) while the CR23X is displaying a
location value, the current status of the user flags
will be displayed in the following format:
"0001.0010". The characters represent the flags,
the left-most digit is Flag 1 (or 11) and right most
is Flag 8 (or 18). A "0" indicates the flag is low
and a "1" indicates the flag is high. In the above
example, Flags 4 (or 14) and 7 (or 17) are set.
To toggle a flag, simply press the corresponding
number. To return to displaying the input
location, press "A".
Entering appropriate flag tests into the program
allows manual control of program execution.
For example, to manually start the execution of
Table 2: enter Instruction 91 as the first
instruction in Table 2. The first parameter is 25
(do if Flag 5 is low), the second parameter is 0,
go to end of program table. If Flag 5 is low, all
subsequent instructions in Table 2 will be
1.4 COMPILING AND LOGGING DATA -
0
C
0 MODE
When the 0 Mode is entered after
programming the CR23X, the program is
compiled and the display shows "Running
Table" followed by the active program table
numbers. The display is not updated after
entering
0.
NOTE: All output ports are set low, the
timer is reset, and data values in Input and
Intermediate Storage are RESET TO ZERO
whenever the program tables are altered
and the Program is recompiled with the
0 Mode. The same is true when the
programs are compiled with B or
D.
To minimize current drain, the CR23X should
be left in the
0 Mode when logging data,
and by turning off the display by pressing
1.5 MEMORY ALLOCATION -
1.5.1 INTERNAL MEMORY
When powered up, “Hello” is displayed while a
self check is performed. The total system
memory is then displayed in K bytes. The size
#
.
1-5
SECTION 1. FUNCTIONAL MODES
0
of memory can be displayed in the
mode. A “--“ after the number displayed means
that the memory test was aborted. The number
shown indicates how far the test progressed
before aborted.
Input Storage is used to store the results of
Input/Output and Processing Instructions. The
values stored in input locations may be
displayed using the
6 Mode (Section 1.3).
Intermediate Storage is a scratch pad for
Output Processing Instructions. It is used to
store the results of intermediate calculations
necessary for averages, standard deviations,
histograms, etc. Intermediate Storage is not
accessible by the user.
Final Storage holds stored data for a
permanent record. Output Instructions store
data in Final Storage when the Output Flag is
set (Section 3.7). The data in Final Storage can
be monitored using the
7 Mode (Section
2.3).
Each Input or Intermediate Storage location
requires 4 bytes of memory. Each Final
Storage location requires 2 bytes of memory.
Low resolution data points require 1 Final
Storage location and high resolution data points
require 2. Section 2 describes Final Storage
and data retrieval in detail.
Figure 1.5-1 lists the basic memory functions
and the amount of memory allotted to them.
1-6
SECTION 1. FUNCTIONAL MODES
Flash Memory
(EEPROM)
Total 512 Kbytes
Operating System
(128 Kbytes)
Active Program
(32 Kbytes Code)
Stored Programs
(32 Kbytes Code)
(32 Kbytes Labels)
Temporary Copy of
Current Progr am
Saved during
download if download
is aborted
(64 Kbytes)
Alphanumeric Labels
(32 Kbytes)
Unassigned
(192 Kbytes)
How it works:
Operatin g System
The
Flash Memory at the factory .
Memory
running for calculations, buffering data
and general operating tasks.
Any time a user load s a program into
the CR23X, th e program is compiled in
SRAM and stored in the
Program
powered off and then on, the Active
Program is loaded from Flash and run.
The Active Program is run in SRAM to
maximize speed. The program
accesses
Intermed iate Storage
into
the user.
The Active Program ca n be copied into
the
program "names" are available, the
number of programs stored is limited
by the available memory. Stored
programs can be ret rieved to beco me
the active program. While programs
are stored one at a time, all stored
programs are erased simultaneously.
That is bec ause the flash memory can
only be written to once before it must
be erased and can only be erased in 16
Kbytes blocks.
(Memory Areas separated by dashed
lines:
can be re-sized by the user.)
1 byte per character stored. 9 bytes
per input location label. All final
storage label characters plus 2 bytes
per table name (array ID name) and
field name.
is used while the CR23X is
areas. If th e CR23X is
Input Storage
Final Storage
Stored Programs
is loaded into
System
Active
and
and stores data
for later retrieval by
area. While 98
SRAM/FLASH
Total 1152 Kbytes
32K SRAM
System Memory
4096 Bytes
Active Program
Default
2048 Bytes
Input Storage
Default
112 Bytes
28 Locations
Intermediate Storage
Default
256 Bytes
64 Locations
96K SRAM
Final Storage 1 and 2
98,304 Bytes
49,154 Locations
1M FLASH
Final Storage 1 and 2
917,504 Bytes
458,752 Locations
or
4M FLASH
Final Storage 1 and 2
4,292,610 Bytes
2,146,305 Loca tions
Final Storage 1 Only
131,072 Bytes
65,536 Locations
Memory av a i l able only t o
system
Memory s hared between
Program, Input Storage,
and Intermediate Storage
Memory al locable t o Final
Storage 1 and 2 only
Memory av a i l able only t o
Final Storage area 1
FIGURE 1.5-1. CR23X Memory
1-7
SECTION 1. FUNCTIONAL MODES
1.5.2
A MODE
CAUTION: Reallocating memory will result
in all data being lost.
The A Mode is used to 1) determine the
number of locations allocated to Input Storage,
Intermediate Storage, Final Storage Area 2, Final
Storage Area 1, and Program Memory; 2)
repartition this memory; 3) check the number of
bytes remaining in Program memory; 4) erase Final
Storage; and 5) to completely reset the datalogger.
A second Final Storage area (Storage Area 2)
can be allocated in the
A Mode. The
default number of locations allocated for
Storage Area 2 is 0. Final Storage Area 1 is the
source from which memory is taken when Final
Storage Area 2 is increased. When Final
Storage Area 2 is reduced, Final Storage Area 1
memory is increased.
TABLE 1.5-2. Description of
KeyboardDisplay ID:
EntryData
A
∗
01: Input LocationsInput Storage Locations. Default 28, minimum of 1, maximum
Description of Data
XXXXof 7138. This value can be changed by keying in the desired
number.
A
02: Intermediate LocsIntermediate Storage Locations. Default 64, maximum of
XXXX7137. This value can be changed by keying in the desired
number. Enter 0 then recompile, and the CR23X will assignthe exact number needed. Entering 0 may also result in the
CR23X erasing all data whenever the program is changed and
compiled.
A
03: Final Storage 2Final Storage Area 2 Locations (CR23X-4M). Default 0,
XXXXXminimum of 0, maximum of 507,905 (2,080,769). Valid inputs
are 0…32,769 or 49,153 and 32,768*N, where N is an integer.
Changing this number automatically reallocates Final Storage
Area 1.
A
04: Final Storage 1Final Storage Area 1 Locations (CR23X-4M). Default 573,441
XXXXX(2,146,305), minimum of 65,536, maximum of 573,441 (2,146,305).
This number is automatically altered when the memory allocation for
Final Storage Area 2 is changed.
A
05: Alloc. Program Bytes Bytes allocated for user program. Default 2048, minimum
+XXXXX116, maximum 28,552. The number of bytes to assign to
program memory can be keyed in to change the size of
program memory. Changing the size of program memory
results in all data being erased. Enter 0 and the CR23X willassign the exact number needed above 116. Entering 0 will
also result in the CR23X erasing all data whenever the program
is changed and compiled. Key in 98765 to completely reset
datalogger.
When
A is entered, the first number
displayed is the number of memory locations
allocated to Input Storage. The "A" key is used
to advance through the next 6 windows. Table
A
1.5-2 describes what the values in the
Mode represent.
Memory allocation defaults at reset to the
values in Table 1.5-1.
The sizes of Input, Intermediate, Final Storage
Area 2, and Program Memory may be altered by
keying in the desired value and entering it by
keying "A".
The maximum size of Input and Intermediate
Storage and the minimum size of Final Storage
are determined by the memory installed (Table
1.5-1). A minimum 64 Input location and
65,536 Final Storage Area 1 locations will
ALWAYS be retained. The size of Intermediate
Storage may be reduced to 0.
A
∗
Mode Data
1-8
SECTION 1. FUNCTIONAL MODES
A
06: Prog. Bytes UnusedBytes free in program memory. The user cannot change
+XXXXXthis window. It is a function of window 5 and the program.
A
07: Prog. Bytes Available The user cannot change this window. It is a function of Window
+XXXXX5 and total available memory.
A
08: Label Bytes UsedThe user cannot change this window. It is a function of the
+XXXXXprogram.
A
09: Label Bytes FreeThe user cannot change this window. It is a function of Window
+XXXXX8 and the program.
Input Storage, Intermediate Storage, and Final
Storage are erased when memory is
repartitioned. This feature may be used to clear
memory without altering programming. The
number of locations does not actually need to
be changed; the same value can be keyed in
and entered.
If Intermediate Storage size is too small to
accommodate the programs or instructions
entered, the "E:04" ERROR CODE will be
displayed in the
0, 6, and
B
Modes. The user may remove this error code
by entering a larger value for Intermediate
Storage size. Intermediate Storage and
Program Memory can be automatically
allocated by entering 0 for their size. When
automatic allocation is used, all data are erased
any time the program is exchanged and
recompiled. Final Storage size is maximized by
limiting Intermediate Storage and Program
Memory to the minimum necessary. The size of
Final Storage and the rate at which data are
stored determines how long it will take for Final
Storage to fill, at which point new data will write
over old.
After repartitioning memory, the program must
be recompiled. Compiling erases Intermediate
Storage. Compiling with
Storage; compiling with
0 erases Input
6 leaves Input
Storage unaltered.
ENTERING 98765 for the number of bytes to
allocate for program memory COMPLETELY
RESETS THE CR23X. All memory is erased
including any stored programs and memory is
checked. Memory allocation returns to the
default. The reset operation requires
approximately 5 minutes for a CR23X. Memory
reset can be aborted by pressing any key on the
keypad, or raising the ring line high.
1.6 MEMORY TESTING AND SYSTEM
STATUS -
The B Mode is used to check the status of
the program’s operating system, memory, and
lithium battery. Table 1.6-1 describes what the
values seen in the
A signature is a number which is a function of
the data and the sequence of data in memory.
It is derived using an algorithm which assures a
99.998% probability that if either the data or its
sequence changes, the signature changes.
The algorithm used to calculate the signature is
described in Appendix C.
The signature of the program memory is used
to determine if the program tables have been
altered. The program signature is calculated
only at compile time. In the background FLASH
memory of the program is periodically checked
against RAM memory of the program. If a byte
is different, an E08 watchdog error is flagged.
During the self check on reset, the signature
computed for the OS is compared with a stored
signature to determine if a failure has occurred.
The operating system (OS) signature is
calculated in the background of 8 bytes per
second and is updated at least once every three
days. It is also done when memory is reset or a
new operating system is downloaded.
The contents of windows 6 and 7, Operating
System (OS) version and version revision, are
helpful in determining what OS is in the
datalogger. As different versions are released,
there may be operational differences. When
calling Campbell Scientific for datalogger
assistance, please have these numbers
available.
Window 13 is a real time display (updated every
0.1 seconds) of the “Program Time”, the time it
takes Table 1 to execute. The resolution is
0.407 µs, and the range is 6.826 seconds. To
read this time as part of a datalogger program,
see the description for Instruction P130.
B
B Mode represent.
1-9
SECTION 1. FUNCTIONAL MODES
TABLE 1.6-1. Description of
KeyboardDisplay ID:
EntryData
B
∗
01:Program memory Signature. The value is dependent upon the
+XXXXX programming entered and memory allotment. If the program has
A
02:Operating System (OS) Signature
+XXXXX
A
03:Memory Size, Kbytes (Flash + SRAM). "--" indicates that a full
XXXXXmemory reset was aborted.
A
04:Number of E08 occurrences (Key in 88 to reset)
XX
A
05:Number of table overrun occurrences (Key in 88 to reset)
XX
A
06:Operating System version number
+X.XXXX
A
07:Version revision number
XXXX.
A
08:Lithium battery voltage (measured daily)
+X.XXXX
A
09:Low 12 V battery detect counter (Key in 88 to reset)
XX
A
10:Extended memory error counter (Key in 88 to reset)
XX
A
11:Extended Memory time of erase, seconds. If >5 at room
+X.XXXXtemperat ure, flash memory may be wearing out. Contact CSI
A
12:Low 5 V counter (Key 88 to reset)
XX
A
13:Program Time (0.407 µsec resolution, range is 6.826 seconds,
+X.XXXXabove 6.826, time = 6.826 + displayed value)
A
14:Panel Temperature (updated at least every 1 to 2.8 minutes)
+X.XXXX
A
15:Coprocessor Revision
XX
A
16:Coprocessor Status
XX
A
17:CPLD Revision
XX
B Mode Data
Description of Data
not been previously compiled, it will be compiled and run.
for replacement information.
1-10
KeyboardDisplay ID:
EntryData
C
∗
01:Non-zero password blocks entry to 1, 2, 3,
XXXX
A
02:Non-zero password blocks 4, 5, and 6 except
XXXX
A
03:Non-zero password blocks 5, 6, 7, 8,
XXXX
KeyboardDisplay ID:
EntryData
C
∗
12:Enter password. If correct, security is temporarily unlocked
0000through that level.
A
01:Level to which security has been disabled.
XX0 -- Password 1 entered (everything unlocked)
TABLE 1.7-1.
∗
SECURITY DISABLED
Description
A, and D Modes, telecommunication S command.
for display.
9, B, and all telecommunications commands except
A, L, N, and E.
SECURITY ENABLED
Description
1 -- Password 2 entered
2 -- Password 3 entered
C
Mode Entries
SECTION 1. FUNCTIONAL MODES
1.7 C MODE -- SECURITY
The C Mode is used to block access to
the user's program information and certain
CR23X functions. There are 3 levels of
security, each with its own 4 digit password.
Setting a password to a non-zero value "locks"
the functions secured at that level. The
password must subsequently be entered to
temporarily unlock security through that level.
Passwords are part of the program. If security
is enabled in the active program, it is enabled
as soon as the program is run when the CR23X
is powered up.
When security is disabled,
directly to the window containing the first
password. A non-zero password must be
entered in order to advance to the next window.
Leaving a password 0, or entering 0 for the
password disables that and subsequent levels
of security.
Security may be temporarily disabled by
entering a password in the
using the telecommunications L command
(Section 5.1). The password entered
determines what operations are unlocked (e.g.,
entering password 2 unlocks the functions
secured by passwords 2 and 3). Password 1
C will advance
C Mode or
(everything unlocked) must be entered before
any passwords can be altered.
When security is temporarily disabled in the
C Mode, entering 0 will
automatically re-enable security to the level
determined by the passwords entered.
The telecommunications L command
temporarily changes the security level. After
hanging up, security is reset.
1.8 D MODE -- SAVE OR LOAD
PROGRAM
The D Mode is used to save or load
CR23X programs, to set the degree to which
memory is cleared on powerup, to set the
datalogger ID, to set communication to full or
half duplex, and to set the display’s contrast
level.
Programs (
A, C, and D Mode data) may
be stored to and from computers, internal flash
memory, and Storage Modules. Several
programs can be stored in the CR23X Flash
Memory and later recalled and run using the
D
Mode or Instruction 111.
1, 2, 3, 4,
1-11
SECTION 1. FUNCTIONAL MODES
D
PC208W automatically makes use of the
Mode to upload and download programs from a
computer. Appendix C gives some additional
information on Commands 1 and 2 that are used
for these operations.
When "∗D" is keyed in, the CR23X will display
"13: Enter Command". A command (Table 1.8-
1) is entered by keying the command number
and "A".
1.8.1 INTERNAL FLASH PROGRAM STORAGE
Several programs can be stored in the CR23X
Flash Memory and later recalled and run using
D Mode. The Flash Electrically
the
Erasable Programmable Read Only Memory is
non-volatile memory that can only be erased in
16K blocks. The CR23X has 512K of Flash
EEPROM memory, one 16K block is reserved
for storing extra programs.
TABLE 1.8-1.
D Mode Commands
CommandDescription
1Send (Print) ASCII Program
2Load ASCII Program,
0
Compile
2--Load ASCII Program,
6
Compile
(canceled by
D 1
0
mode)
6Store Program in Flash
7Load Program from Flash
7NSave/Load/Clear Program from
If the CR23X program has not been compiled
when the command to save a program is entered,
it will be compiled before the program is saved.
When a program is loaded, it is immediately
compiled and run. When a command is complete,
"13:0000" is displayed;
D must be entered
again before another command can be given.
If a program download is aborted, the CR23X will
reload the program in its flash into RAM, compile it,
and run it.
TABLE 1.8-2. Progr am Load Error Codes
E 94Program Storage Area full
E 95Program does not exist in flash
E 96Storage Module not connected or
wrong address
E 97Data not encountered within 30 sec.
E 98Uncorrectable errors detected
E 99Wrong type of file or Editor Error
When a program is loaded and compiled, it is
saved as the active program. The active
program will be automatically loaded and run
when the CR23X is powered up. Automatic
loading of the program can be aborted by
pressing any key while “Hello” is showing on the
CR23X display; the display will show “Program
Aborted.” (If a Storage Module with a program
8 is connected when the CR23X powers-up, the
Storage Module program 8 will be loaded into
the CR23X and become the active program.)
The active program can be stored in internal
D
flash memory program storage with
command 6 (Table 1.8-3). Programs can be
retrieved with
D command 7 (Table 1.8-4).
TABLE 1.8-3. Storing Program in
Internal Flash
Key entryDisplay
D
13: Enter Command
00
6
A
06: Program ID
00
You may now enter one of the following options:
xx
A
Save active program
as number xx, xx may
be 1-98.
A
B
Scroll forward and
backward through
saved program
numbers. The
numbers are displayed
in the order saved.
99
99
A
A
Clear all saved
programs.
0
A
Display number of
bytes free in saved
program area.
1-12
SECTION 1. FUNCTIONAL MODES
TABLE 1.8-4. Retrieving a Program from
Internal Flash
Key entryDisplay
D
13: Enter Command
00
7
A
07: Program ID
00
You may now enter one of the following options:
xx
A
Retrieve program number xx
(the most recent xx saved). To
have the program compile like
6 (no resetting of input
locations, flags, or ports) press
C (xx--) before A.
0
A
Erase active program (i.e., load a
blank program; memory allocation
and Final Storage are reset).
A
B
Scroll forward and
backward through saved
program numbers.
Scrolling through the program names begins
with the oldest program. "A" advances to the
next newer program, "B" backs up to the next
older program. While scrolling, at any time
typing in a number (xxA) will cause a save or a
retrieve operation.
Each program saved takes up the memory
required for the program + 6 bytes.
Flash memory can only be written to once
before being erased. Because it can only be
erased in 16K blocks, if one stored program is
to be erased, all must be erased. To allow
revising a program and storing it with the same
number (name) as an earlier version, the same
number can be used by more than one saved
program. When retrieving a program, the
programs are searched beginning with the last
program saved; the most recently saved version
will be retrieved. An older program with a
duplicate name cannot be retrieved. When the
flash program memory is full, all programs must
be erased before any more can be added (error
94 will be displayed).
1.8.2 PROGRAM TRANSFER WITH STORAGE
MODULE
Storage Modules can store up to eight separate
programs. The Storage Module and
Keyboard/Display or Modem/Terminal must both
be connected to the CR23X. After keying
D, the command 7N, is entered (N is the
Storage Module address 1-8, Section 4.4.1).
Address 1 will work with any Storage Module
address; the CR23X will search for the lowest
address Storage Module that is connected. The
command to save, load, or clear a program and
the program number (Table 1.8-5) is entered.
After the operation is finished "13:0000" is
displayed. Error 96 indicates that the Storage
Module is not connected or the wrong address
was given.
TABLE 1.8-5 Transferring a Program using a
Storage Module
Key entryDisplay
D
13: Enter Command
00
7
A
N
7N: Save, Load, Clr
00
(N is Storage Module address 1-8)
You may now enter one of the following options:
1
xSave Program x to Storage
Module (x = 1-8)
2
xLoad Program x from Storage
Module (x = 1-8)
3
xErase Program x in Storage
Module (x = 1-8)
The datalogger can be programmed on power-
up using a Storage Module. If a program is
stored as program number 8, and the Storage
Module is connected to the datalogger I/O at
power-up, program number 8 is automatically
loaded into the active program area of the
datalogger and run.
1.8.3 SET DATALOGGER ID
Command 8 is used to set the datalogger ID.
The ID can be moved to an input location with
Instruction 117 and can then be sampled as
part of the data.
TABLE 1.8-6 Setting Datalogger ID
Key EntryDisplay
D
13: Enter Command
00
8
A
08: Datalogger ID
0XXX
Where XXX are 0s or the current ID. You may
now key in the ID (1-12, 14-254).
1-13
SECTION 1. FUNCTIONAL MODES
1.8.4 FULL/HALF DUPLE X
The
D Mode can also be used to set
communications to full or half duplex. The default
is full duplex, which works best in most situations.
TABLE 1.8-7. Setting Duplex
Key entryDisplay
D
13: Enter Command
00
9
A
09: Comm Duplex
0x
If x=0 the CR23X is set for full duplex.
If x=1 the CR23X is set for half duplex.
You may now change the option:
0
A
1
A
Set full duplex
Set half duplex
1.8.5 SETTING POWERUP OPTIONS
Setting options for the Program on Powerup
allows the user to specify what information to
retain from when the datalogger was last on.
This allows Flag/Port status, the User Timer,
and the Input/Intermediate Storage to be
cleared or not cleared.
Table 1.8-8. Setting Powerup Options
Key entryDisplay
D
13: Enter Command
00
1 0
A
10: Power Up Option
0X
Where X is the powerup option currently
selected. You may now change the option:
0
A
Clears input locations, ports, flags,
user timer, and intermediate storage
locations.
1
A
Clears intermediate storage only
(leaves Input Storage, Flags/Ports, and
User Timer as is).
2
A
Doesn’t clear anything.
1.8.6 SETTING DISPLAY CONTRAST
The CR23X automatically adjusts the LCD
display contrast for temperature within two
seconds after power-up. If necessary, the user
can fine tune the default contrast in the
mode. The user entered adjustment is valid
only for the specific temperature range wherein
the adjustment was made. If the CR23X
temperature moves out of that range, the
default setting for the next range controls the
contrast. See “Telecommunications” R
command information on changing default
settings in each temperature range.
TABLE 1.8-9.
Key
Entry
1 1
A
A
DisplayComments
13: Enter Command
D
00
11: Program Stopped
11: Dsply Contrast
xxxx
11: D Dark C Light
xxxx
LOGSave setting,
0
xxxx is the
current setting.
Key in new
setting followed
by an A or . . .
Press A to
darken, B to
lighten
restart program
1.8.7 SET INITIAL BAUD / SET RS232 POWER
Table 1.8-11 shows the option codes available
for setting the initial baud rate. Setting the initial
baud rate forces the CR23X to try the selected
baud rate first when connecting with a device.
By indexing the option, the “Computer RS232”
port can be powered up. Power up of the
RS232 port puts 9 volts on pins 1 (DTR) and 8
(RTS), and 8 volts on pin 2 (TX).
D
1-14
SECTION 1. FUNCTIONAL MODES
TABLE 1.8-10. Set Initial Baud Rate / Set
RS232 Power
Key
EntryDisplay
D
∗
13:Enter Command
Comments
00
1 2 A
12: Connect Baud Rate
00
X C A
12: Connect Baud RateEnter Baud
0X--Rate Code X
(Table 1.8-11).
Index (--)
is optional.
TABLE 1.8-11. Baud Rate Codes
X = 0300 Baud
X = 11200 Baud
X = 42400 Baud
X = 54800 Baud
X = 29600 Baud
X = 619.2 K Baud
X = 738.4 K Baud
X = 376.8 K Baud
X-- = RS232 Power On
TABLE 1.8-12. Set Program Compile Option
Key
EntryDisplay
D
∗
13:Enter Command
Comments
00
1 3 A
13: Compile Option
00
1 A
13: Compile OptionSets Compile
6
01like
∗
TABLE 1.8-13. Compile Option Codes
0Compile like ∗ 0 (See Section 1.4)
1Compile like
∗
6 (See Section 1.3)
2Do not clear intermediate storage
1.8.8 SET PROGRAM COMPILE OPTION
Table 1.8-13 shows the option codes available
for setting the program compile option. This
setting will affect the program compile when the
program is downloaded from the PC or a
SM192/716 Storage Module. It also affects
compiling with
7
command. Keyboard or Remote Keyboard
compiling with
B and the arcane
6 and 0 is not
affected by this setting. If a .DLD file has this
setting, it will affect the compile operation
AFTER the .DLD file is downloaded.
D
1-15
SECTION 1. FUNCTIONAL MODES
This is a blank page.
1-16
SECTION 2. INTERNAL DATA STORAGE
2.1 FINAL STORAGE AREAS, OUTPUT
ARRAYS, AND MEMORY POINTERS
Final Storage is the memory where final
processed data are stored. Final Storage data
are transferred to your computer or external
storage peripheral.
The size of Final Storage is expressed in terms of
memory locations or bytes. A low resolution data
point (4 decimal characters) occupies one
memory location (2 bytes), whereas a high
resolution data point (5 decimal characters)
requires two memory locations (4 bytes). Table
1.5-1 shows the default allocation of memory
locations to Program, Input, Intermediate, and the
two Final Storage areas. The
used to reallocate memory or erase Final Storage
(Section 1.5).
The default size of Final Storage with standard
memory is 586,568 low resolution memory
locations.
Final Storage can be divided into two parts:
Final Storage Area 1 and Final Storage Area 2.
A Mode is
Final Storage Area 1 is the default storage area
and the only one used if the operator does not
specifically allocate memory to Area 2.
Two Final Storage Areas may be used to:
1. Output different data to different devices.
2. Separate archive data from real time display
data. In other words, you can record a short
time history of real time data and separately
record long term, archive data.
3. Record both high speed data (fast recording
interval) and slow data without having the
high speed data write over the slow data.
Each Final Storage Area can be represented as
ring memory (Figure 2.1-1) on which the newest
data are written over the oldest data.
The Data Storage Pointer (DSP) is used to
determine where to store each new data point in
the Final Storage area. The DSP advances to
the next available memory location after each
new data point is stored.
FIGURE 2.1-1. Ring Memory Representation of Final Data Storage
2-1
SECTION 2. INTERNAL DATA STORAGE
Output Processing Instructions store data into
Final Storage only when the Output Flag is set.
The string of data stored each time the Output
Flag is set is called an OUTPUT ARRAY. The
first data point in the output array is a 3 digit
OUTPUT ARRAY ID. This ID number is set in
one of two ways:
1. In the default condition, the ID consists of
the program table number and the
Instruction Location Number of the
instruction which set the Output Flag for
that particular array of data. For example,
the ID of 118 in Figure 2.1-2 indicates that
the 18th instruction in Table 1 set the
Output Flag.
2. The output array ID can be set by the user
with the second parameter of Instruction 80
(Section 11). The ID can be set to any
positive integer up to 511. This option
allows the user to make the output array ID
independent of the programming. The
program can be changed (instructions
added or deleted) without changing the
output array ID. This avoids confusion
during data reduction, especially on long
term projects where program changes or
updates are likely.
Data are stored in Final Storage before being
transmitted to an external device. There are 4
pointers for each Final Storage Area which are
used to keep track of data transmission. These
pointers are:
1. Display Pointer (DPTR)
2. Printer Pointer (PPTR)
3. Telecommunications (Modem) Pointer (MPTR)
4. Storage Module Pointer (SPTR)
The DPTR is used to recall data to the keyboard/
display. The positioning of this pointer and data
7
recall are controlled from the keyboard (
Mode).
The PPTR is used to control data transmission
to a printer or other serial device. Whenever
on-line printer transfer is activated (Instruction
96), data between the PPTR and DSP are
transmitted. The PPTR may also be positioned
via the keyboard for manually initiated data
8
transmission (
Mode).
The MPTR is used in transmitting data over a
telecommunications interface. When
telecommunications is first entered, the MPTR is
set to the same location as the DSP. Positioning
of the MPTR is then controlled by commands from
the external calling device (Section 5.1).
FIGURE 2.1-2. Output Array ID
NOTE: If Instruction 80 is used to
designate the active Final Storage Area and
parameter 2 is 0, the output array ID is
determined by the position of Instruction 80
or by the position of the instruction setting
the Output Flag, whichever occurs last.
A start-of-array marker ($ in Figure 2.1-1) is
written into Final Storage with the Output Array
ID. This marker is used as a reference point
from which to number the data points of the
output array. The start of array marker occupies
the same Final Storage location as the Array ID
and is transparent for all user operations.
The SPTR is used to control data transmission to a
Storage Module. When on-line transfer is activated
by Instruction 96, data is transmitted each time an
output array is stored in Final Storage IF THE
STORAGE MODULE IS CONNECTED TO THE
CR23X. If the Storage Module is not connected, the
CR23X does not transmit the data nor does it
advance the SPTR to the new DSP location. It
saves the data until the Storage Module is
connected. Then, during the next execution of
Instruction 96, the CR23X outputs all of the data
between the SPTR and the DSP and updates the
SPTR to the DSP location (Section 4.1)
The SPTR may also be positioned via the
keyboard for manually initiated data transfer to
8
the Storage Module (
Mode, Section 4.2).
NOTE: All memory pointers are set to the
DSP location when the datalogger compiles
a program. ALWAYS RETRIEVE
UNCOLLECTED DATA BEFORE MAKING
PROGRAM CHANGES.
2-2
SECTION 2. INTERNAL DATA STORAGE
2.2 DATA OUTPUT FORMAT AND
RANGE LIMITS
Data are stored internally in Campbell Scientific's
Binary Final Storage Format (Appendix C.2).
Data may be sent to Final Storage in either LOW
RESOLUTION or HIGH RESOLUTION format.
2.2.1 RESOLUTION AND RANGE LIMITS
Low resolution data is a 2 byte format with 4
significant digits and a maximum magnitude of
+6999. High resolution data is a 4 byte format
with 5 significant digits and a maximum possible
output value of +99999 (see Table 2.2-1 below).
TABLE 2.2-1. Resolution Range Limits of
CR23X Data
MinimumMaximum
ResolutionZero
Low0.000+0.001+6999.
High0.0000+ .00001+99999.
The resolution of the low resolution format is
reduced to 3 significant digits when the first (left
most) digit is 7 or greater. Thus, it may be
necessary to use high resolution output or an offset
to maintain the desired resolution of a measurement.
For example, if water level is to be measured and
output to the nearest 0.01 ft., the level must be less
than 70 ft. for low resolution output to display the
0.01 ft. increment. If the water level was expected
to range from 50 to 80 ft. the data could either be
output in high resolution or could be offset by 20 ft.
(transforming the range to 30 to 50 ft.).
Magnitude Magnitude
A precise calculation of the resolution of a
number may be determined by representing the
number as a mantissa between .5 and 1
multiplied by 2 raised to some integer power. The
resolution is the product of that power of 2 and
-24
. For example, representing 478 as .9336 ∗
2
9
, the resolution is 29 ∗ 2
2
-24
= 2
-15
= 0.0000305.
A description of Campbell Scientific's floating
point format may be found in the description of
the J and K Telecommunications Commands in
Appendix C.
2.3 DISPLAYING STORED DATA -
7
MODE
(Computer/terminal users refer to Section 5 for
instructions on entering the Remote Keyboard
State.)
Final Storage may be displayed by using the
7
Mode. Key
If you have allocated memory to Final Storage
Area 2, the display will show:
Mode 07: Storage Area
Select which Storage Area you wish to view:
00 or 01 = Final Storage Area 1
02 = Final Storage Area 2
If no memory has been allocated to Final
Storage Area 2, this first window will be
skipped.
00
7
.
2.2.2 INPUT AND INTERMEDIATE STORAGE
DATA FORMAT
While output data have the limits described
above, the computations performed in the
CR23X are done in floating point arithmetic. In
Input and Intermediate Storage, the numbers
are stored and processed in a binary format
with a 23 bit binary mantissa and a 6 bit binary
exponent. The largest and smallest numbers
that can be stored and processed are 9 x 10
and 1 x 10
-19
, respectively. The size of the
18
number determines the resolution of the
arithmetic. A rough approximation of the
resolution is that it is better than 1 in the
seventh digit. For example, the resolution of
97,386,924 is better than 10. The resolution of
0.0086731924 is better than 0.000000001.
The next window displays the current DSP
location. Pressing
A
advances you to the
Output array ID of the oldest Array in the
Storage Area. To locate a specific Output
Array, enter a location number that positions the
Display Pointer (DPTR) behind the desired data
and press the "A" key. If the location number
entered is in the middle of an Output Array, the
DPTR is automatically advanced to the first data
point of the next Output Array. Repeated use of
the "A" key advances through the Output Array.
Data and the alphanumeric label assigned by
EDLOG are displayed. The "B" key backs the
DPTR through memory.
The memory location of the data point is
displayed by pressing the "#" key. At this point,
another memory location may be entered,
followed by the "A" key to jump to the start of
2-3
SECTION 2. INTERNAL DATA STORAGE
the Output Array equal to or just ahead of the
location entered. Whenever a location number
is displayed by using the "#" key, the
corresponding data point can be displayed by
pressing the "C" key.
The same element in the next Output Array with
the same ID can be displayed by hitting
# A
The same element in the previous array can be
# B
displayed by hitting
(Array ID), then
array and
#
array.
0 A backs up to the start of the
# A
# B
backs up to the previous
. If the element is 1
advances to the next
current array.
7
The keyboard commands used in the
Mode are summarized in Table 2.3-1.
Advancing the DPTR past the Data Storage
Pointer (DSP) displays the oldest data point.
Upon entering the
7 Mode, the oldest
Output Array can be accessed by pressing the
"A" key.
TABLE 2.3-1.
7 Mode Command
Summary
KeyAction
A
B
.
#
Advance to next data point
Back-up to previous data point
Display location number of currently
displayed data point value
C
# A
Display value of current location
Advance to same element in next
Output Array with same ID
# B
Back-up to same element in
previous Output Array with same ID
# 0 A
Back-up to the start of the current
Final Data Storage Array
∗
Exit 7 Mode
2-4
SECTION 3. INSTRUCTION SET BASICS
The instructions used to program the CR23X are divided into four types: Input/Output (I/O), Processing,
Output Processing, and Program Control. I/O Instructions are used to make measurements and store
the readings in input locations or to initiate analog or digital port output. Processing Instructions perform
mathematical operations using data from Input Storage locations and place the results back into
specified Input Storage locations. Output Processing Instructions provide a method for generating time
or event dependent data summaries from processed sensor readings residing in specified Input Storage
locations. Program Control Instructions are used to direct program execution based on time and or
conditional tests on input data and to direct output to external devices.
Instructions are identified by a number. There are a fixed number of parameters associated with each
instruction to give the CR23X the information required to execute the instruction. The set of instructions
available in the CR23X is determined by the CR23X Operating System.
3.1 PARAMETER DATA TYPES
There are 3 different data types used for
Instruction parameters: Floating Point (FP), 4
digit integers (4), and 2 digit integers (2). The
parameter data type is identified in the listings
of the instruction parameters in Sections 9-12.
Different data types are used to allow the
CR23X to make the most efficient use of its
memory.
Floating Point parameters are used to enter
numeric constants for calibrations or
mathematical operations. While it is only
possible to enter 5 digits (magnitude +.00001 to
+99999.), the internal format has a much
greater range (1x10
2.2.1). Instruction 30 can be used to enter a
number in scientific notation into an input
location.
-19
to 9x1018, Section
3.2 REPETITIONS (Reps)
The repetitions parameter on many of the I/O,
Processing, and Output Processing Instructions
is used to repeat the instruction on a number of
sequential Input Channels or Input Storage
locations. For example, if you are making 4
differential voltage measurements on the same
voltage range, wire the inputs to sequential
channels and enter the Differential Voltage
Measurement Instruction once with 4 repetitions,
rather than entering 4 separate measurement
instructions. The instruction will make 4
measurements starting on the specified channel
number and continuing through the 3 succeeding
differential channels. The results will be stored
in the specified input location and the 3
succeeding input locations. Averages for all 4
measurements can be calculated by entering the
Average Instruction with 4 repetitions.
When several of the same type of
measurements will be made, but the
calibrations of the sensors are different, it
requires less time to make the measurements
using one measurement with repetitions and
then apply the calibrations with a scaling array
(Inst. 53) than it does to enter the instruction
several times in order to use a different
multiplier and offset. This is due to set up and
calibration time for each measurement
instruction. However, if time is not a constraint,
separate instructions may make the program
easier to follow.
3.3 ENTERING NEGATIVE NUMBERS
Before or after keying in a number, press C or
"-" to change the number's sign. On floating
point numbers a minus sign (-) will appear to
the left of the number. Excitation voltages in
millivolts for I/O Instructions are 4 digit integers;
when
appear to the right of the number indicating a
negative excitation. Even though this display is
the same as that indicating an indexed input
location, (Section 3.4) there is no indexing effect
on excitation voltage.
C
is keyed 2 minus signs (--) w ill
3.4 INDEXING INPUT LOCATIONS AND
CONTROL PORTS
When used within a loop, the parameters for
input locations and the commands to set,
toggle, or pulse a port can be Indexed to the
loop counter. The loop counter is added to the
indexed value to determine the actual Input
Location or Port the instruction acts on.
Normally the loop counter is incremented by 1
after each pass through the loop. Instruction
90, Step Loop Index, allows the increment step
3-1
SECTION 3. INSTRUCTION SET BASICS
to be changed. See Instructions 87 and 90,
Section 12, for more details.
To index an input location (4 digit integer) or set
port command (2 digit integer) parameter,
or "-" is pressed after keying the value but
before entering the parameter. Two minus
signs (--) will be displayed to the right of the
parameter.
3.5 VOLTAGE RANGE AND
OVERRANGE DETECTION
The voltage RANGE code parameter on
Input/Output Instructions is used to specify the
full scale range of the measurement and the
integration period for the measurement (Table
3.5-1).
The full scale range selected should be the
smallest that will accommodate the full scale
output of the sensor being measured. Using
the smallest possible range will result in the
best resolution for the measurement.
Four different integration sequences are
possible. The relative immunity of the
integration sequences to random noise is:
Slow 60 Hz rej. = Slow 50 Hz rej. > Fast 60 Hz
rej. = Fast 50 Hz rej. > 250 µs integ. The 60 Hz
rejection integration rejects noise from 60 Hz
AC line power. The 50 Hz rejection is for
countries whose electric utilities operate at 50
Hz (Section 13.1).
When a voltage input exceeds the range
programmed, the value which is stored is set to
the maximum negative number and displayed
as -99999 in high resolution or -6999 in low
resolution.
An input voltage greater than +8 volts on one of
the analog inputs will result in errors and
possible overranging on the other analog inputs.
C
Voltages greater than 16 volts may permanently
damage the CR23X.
3.6 OUTPUT PROCESSING
Most Output Processing Instructions have both
an Intermediate Data Processing operation and
a Final Data Processing operation. For
example, when the Average Instruction, 71, is
initiated, the intermediate processing operation
increments a sample count and adds each new
Input Storage value to a cumulative total
residing in Intermediate Storage. When the
Output Flag is set, the final processing
operation divides the cumulative total by the
number of samples to find the average. The
average is then stored in final storage and the
cumulative total and number of samples are set
to zero in Intermediate Storage.
Final Storage Area 1 (Sections 1.5, 2.1) is the
default destination of data output by Output
Processing Instructions. Instruction 80 may be
used to direct output to either Final Storage
Area 2 or to Input Storage.
Output Processing Instructions requiring
intermediate processing sample the specified
input location(s) each time the Output
Instruction is executed, NOT each time the
location value is updated by an I/O Instruction.
For example: Suppose a temperature
measurement is initiated by Table 1 which has
an execution interval of 1 second.
* Differential measurement, resolution for single-ended measurement is twice value shown.
**Autoranging may not adequately measure inputs with extremely noisy or rapidly changing signals.
Autoranging channels may occasionally measure on a higher range than is required.
3-2
SECTION 3. INSTRUCTION SET BASICS
The instructions to output the average
temperature every 10 minutes are in Table 2
which has an execution interval of 10 seconds.
The temperature will be measured 600 times in
the 10 minute period, but the average will be the
result of only 60 of those measurements
because the instruction to average is executed
only one tenth as often as the instruction to
make the measurement.
Intermediate Processing can be disabled by
setting Flag 9 which prevents Intermediate
Processing without actually skipping over the
Output Instruction.
All of the Output Processing Instructions store
processed data values when and only when the
Output Flag is set (Section 3.7.1). The Output
Flag (Flag 0) is set at desired intervals or in
response to certain conditions by using an
appropriate Program Control Instruction
(Section 12).
3.7 USE OF FLAGS: OUTPUT AND
PROGRAM CONTROL
There are 18 flags which may be used in
CR23X programs. Two of the flags are
dedicated to specific functions: Flag 0 causes
Output Processing Instructions to write to Final
Storage, and Flag 9 disables intermediate
processing. Flags 1-8 and 11-18 may be used
as desired in programming the CR23X. Flags 0
and 9 are automatically set low at the beginning
of each execution of the program table. Flags
1-8 and 11-18 remain unchanged until acted on
by a Program Control Instruction or until
manually toggled from the
TABLE 3.7-1. Flag Description
Flag 0-Output Flag
Flag 1 to 8-User Flags
Flag 11 to 18-User Flags
Flag 9-Intermediate Processing
Disable Flag
Flags are set with Program Control Instructions.
The Output Flag (Flag 0) and the Intermediate
Programming Disable Flag (Flag 9) will always
be set low if the set high condition fails. The
status of flags 1 through 8 and 11 through 18
does not change when a conditional test is
false.
6 Mode.
3.7.1 THE OUTPUT FLAG
A group of processed data values is placed in
Final Data Storage by Output Processing
Instructions when the Output Flag (Flag 0) is set
high. This group of data is called an Output
Array. The Output Flag is set using Program
Control Instructions according to time or event
dependent intervals specified by the user. The
Output Flag is set low at the beginning of each
execution of the program table.
Output is most often desired at fixed intervals;
this is accomplished with Instruction 92, If Time.
Output is usually desired on the even interval,
so Parameter 1, time into the interval, is 0. The
time interval (Parameter 2), in minutes, is how
often output will occur; i.e., the Output Interval.
The command code (Parameter 3) is 10,
causing Flag 0 to be set high. The time interval
is synchronized to 24 hour time; output will
occur on each integer multiple of the Output
Interval starting from midnight (0 minutes). If
the Output Interval is not an even divisor of
1440 minutes (24 hours), the last output interval
of the day will be less than the specified time
interval. Output will occur at midnight and will
resume synchronized to the new day.
Instruction 92 is followed in the program table
by the Output Instructions which define the
Output Array desired.
Each group of Output Processing Instructions
creating an Output Array is preceded by a
Program Control Instruction that sets the Output
Flag.
NOTE: If the Output Flag is already set high
and the test condition of a subsequent
Program Control Instruction acting on Flag
0 fails, the flag is set low. This eliminates
entering another instruction to specifically
reset the Output Flag before proceeding to
another group of Output Instructions with a
different output interval.
3.7.2 THE INTERMEDIATE PROCESSING
DISABLE FLAG
The Intermediate Processing Disable Flag (Flag
9) suspends intermediate processing when it is
set high. This flag is used to restrict sampling
for averages, totals, maxima, minima, etc., to
times when certain criteria are met. The flag is
automatically set low at the beginning of each
execution of the program table.
3-3
SECTION 3. INSTRUCTION SET BASICS
As an example, suppose it is desired to obtain a
wind speed rose incorporating only wind speeds
greater than or equal to 4.5 m/s. The wind
speed rose is computed using the Histogram
Instruction 75, and wind speed is stored in input
location 14, in m/s. Instruction 89 is placed just
before Instruction 75 and is used to set Flag 9
high if the wind speed is less than 4.5 m/s:
TABLE 3.7-2. Example of the Use of Flag 9
Inst.Param.
Loc.No.
EntryDescription
XP89If wind speed < 4.5 m/s
114Wind speed location
24Comparison: <
34.5Minimum wi nd
speed for histogram
419Set Flag 9 high
X+1P75Histogram
X+2P86Do
129Set Flag 9 Low
NOTE: Flag 9 is automatically reset the
same as Flag 0. If the intermediate
processing disable flag is already set high
and the test condition of a subsequent
Program Control Instruction acting on Flag
9 fails, the flag is set low. This feature
eliminates having to enter another
instruction to specifically reset Flag 9 before
proceeding to another group of test
conditions.
3.7.3 USER FLAGS
Flags 1 through 8 and 11 through 18 are not
dedicated to a specific purpose and are available
to the user for general programming needs. The
user flags can be manually toggled from the
keyboard in the
6 Mode (Section 1.3) or
through telecommunications with PC208W
datalogger support software. By inserting the flag
test (Instruction 91) at appropriate points in the
program, the user can use the
6 Mode to
manually direct program execution.
TABLE 3.8-1. Command Codes
0Go to end of program table
1-9, 79-99Call Subroutine 1-9, 79-99
3
1
10-19Set Flag 0-9 high
111-118 Set Flag 11-18 high
20-29Set Flag 0-9 low
211-218 Set Flag 11-18 low
30Then Do
31Exit loop if true
32Exit loop if false
41-48Set Port 1-8 high
49Set Switched 12 V high
51-58Set Port 1-8 low
59Set Switched 12 V low
61-68Toggle Port 1-8
71-78Pulse Port 1-8
1
95, 96, 97, and 98 are special subroutines
2
2
2
2
2
2
which can be called by Control ports 6, 7,
and 8 going high; see Instruction 85 for
details (Section 12).
2
The ports can be indexed to the loop
counter (Section 8.4).
3
If this command is executed while in a
subroutine, execution jumps directly to the
end of the table that called the subroutine.
3.8.1 IF THEN/ELSE COMPARISONS
Program Control Instructions can be used for If
then/else comparisons. When Command 30
(Then do) is used with Instructions 83 or 88-92,
the If Instruction is followed immediately by
instructions to execute if the comparison is true.
The Else Instruction (94) is optional and is
followed by the instructions to execute if the
comparison is false. The End Instruction (95)
ends the If then/else comparison and marks the
beginning of the instructions that are executed
regardless of the outcome of the comparison
(see Figure 3.8-1).
3.8 PROGRAM CONTROL LOGICAL
CONSTRUCTIONS
Most of the Program Control Instructions have a
command code parameter which is used to
specify the action to be taken if the condition
tested in the instruction is true. Table 3.8-1 lists
these codes.
3-4
FIGURE 3.8-1. If Then/Else
Execution Sequence
FIGURE 3.8-2. Logical AND Construction
If Then/Else comparisons may be nested to
form logical AND or OR branching. Figure 3.82 illustrates an AND construction. If conditions A
and B are true, the instructions included
between IF B and the first End Instruction will
be executed.
SECTION 3. INSTRUCTION SET BASICS
then used to compare the value in the location
with fixed values. When the value in the input
location is less than the fixed value specified in
Instruction 83, the command in that Instruction
83 is executed, and execution branches to the
END Instruction 95 which closes the case test
(see Instruction 93, Section 12).
3.8.2 NESTING
A branching or loop instruction which occurs
before a previous branch or loop has been
closed is nested. The maximum nesting level is
11 deep. Loop Instruction 87 and Begin Case
Instruction 93 both count as 1 level.
Instructions 83, 86, 88, 89, 91, and 92 each
count as one level when used with the
Command "30" which is the "Then Do"
command. Use of Else, Instruction 94, also
counts as one nesting level each time it is used.
For example, the AND construction above is
nested 2 deep while the OR construction is
nested 3 deep.
If either of the conditions is false, execution will
jump to the corresponding End Instruction,
skipping the instructions between.
A logical OR construction is also possible.
Figure 3.8-3 illustrates the instruction sequence
that will result in subroutine X being executed if
either A or B is true.
IF A (88-92 with command 30)
Call subroutine X (86, command=X)
ELSE (94)
IF B (88-92 with command 30)
Call subroutine X (86, command=X)
END B (95)
END A (95)
FIGURE 3.8-3. Logical OR Construction
NOTE: A logical OR can also be
constructed by setting a user flag if a
comparison is true. (The flag is cleared
before making comparisons.) After all
comparisons have been made, execute the
desired instructions if the flag is set.
Subroutine calls do not count as nesting with
the above instructions, though they have their
own nesting limit (maximum of 7, see
Instruction 85, Section 12). Branching and loop
nesting start at zero in each subroutine.
Any number of groups of nested instructions
may be used in any of the three Programming
Tables. The number of groups is only restricted
by the program memory available.
3.9 INSTRUCTION MEMORY AND
EXECUTION TIME
Each instruction requires program memory and
uses varying numbers of Input, Intermediate,
and Final Storage locations. Tables 3.9-1 to
3.9-4 list the memory used by each instruction
and the approximate time required to execute it.
When attempting to make a series of
measurements and calculations at a fast rate, it
is important to examine the time required for the
automatic calibration sequence and possibly
make use of the program controlled calibration,
Instruction 24. Section 13.9 describes the
calibration process.
The Begin Case Instruction 93 and If Case
Instruction 83 allow a series of tests on the
value in an input location. The case test is
started with Instruction 93 which specifies the
location to test. A series of Instruction 83s are
2R2R, 3R01,10,110.6+0.5R1.6+2.8R
75 HISTOGRAM1+bins∗RBINS*R240.7+1.7R0.8+(2.8+0.7*BIN)R
77 REAL TIME01 TO 440.12.2
78 RESOLUTION0030.40.4
79 SMPL ON MMRR70.20.7+0.3R
1
80 STORE AREA
0070.2 0.2
81 RAINFLOW HIST see
instruction42
82 STD. DEV.1+3RR70.8+1.0R3.3+7.0R
TABLE 3.9-4. Program Control Instruction Memory and Execution Times
MEMORY
INTER.PROG.
INSTRUCTIONLOC.BYTES EXECUTION TIME (ms)
83 IF CASE <F0100.23
85 LABEL SUBR.030.08
86 DO060.17
87 LOOP1100.16
88 IF X<=>Y0110.42
89 IF X<=>F0130.32
90 LOOP INDEX030.40
91 IF FLAG/PORT070.22
92 IF TIME1120.21
93 BEGIN CASE180.16
94 ELSE040.16
95 END040.22
96 SERIAL OUT03
There are four types of errors flagged by the
CR23X: Compile, Run Time, Editor, and
Mode. Compile errors are errors in programming
which are detected once the program is entered
and compiled for the first time (
B Mode entered). If a programming error is
detected during compilation, an E is displayed with
the 2 digit error code. The Instruction Location
Number of the Instruction which caused the error
is displayed to the right of the error code (e.g., E23
105; 105 indicates that the fifth instruction in Table
1 caused error 23). Error 22, missing END, will
indicate the location of the instruction which the
compiler cannot match with an END instruction.
Run time errors are detected while the program
is running. The number of the instruction being
executed at the time the error is detected is
displayed to the right of the error code (e.g.,
E09 06 indicates that an Instruction 6 in the
program is attempting to store data in input
locations beyond those allocated). Run time
errors 9 and 31 are the result of programming
errors. While E08 will display the number of the
instruction that was being executed when the
error occurred, it is unlikely that the instruction
has anything to do with the error.
If there is a run time error in a table with a fast
execution interval, the error may be written to
the display so frequently that it seems the
CR23X is not responding to the keyboard.
Once the program is stopped, normal function
will return. To stop the program some entry
must be changed which requires recompiling
(Section 1.1.4). For example, enter 0 for the
execution interval of Table 1 (i.e., enter
1 A 0 A as fast as possible). The
program can easily be stopped by pressing any
key while the CR23X is displaying “Hello” after
applying power (turn the CR23X off and then on
again). This delays program execution for
about two minutes, allowing the program to be
changed.
Error 8 is the result of a hardware and software
"watchdog" that checks the processor state,
software timers, and program related counters.
The watchdog will attempt to reset the
processor and program execution if it finds that
the processor has bombed or is neglecting
standard system updates, or if the counters are
out of allowable limits. Error code 08 is flagged
when the watchdog performs this reset. E08 is
0, 6, or
occasionally caused by voltage surges or
transients. Frequent repetitions of E08 are
D
indicative of a dead lithium battery, a hardware
problem, or a software bug. Check the lithium
battery voltage (
B). If the lithium battery
voltage is good (2.4 volts or higher), contact
Campbell Scientific for assistance as a
hardware or software bug is indicated. The
CR23X keeps track of the number of times (up
to 99) that E08 has occurred. The number can
be displayed and reset in the
B Mode
(Section 1.6) or with the Telecommunications A
command (Section 5.1).
Error 10 is displayed if the primary power drops
below 11 volts. When this happens, the CR23X
stops executing programs. The low voltage
counter (
B Window 9, Section 1.6) counts
the number of times the voltage drops below 11
volts and displays a double dash (--) if the
CR23X is currently in a low voltage shut down.
Low voltage shut down terminates when voltage
is raised above 11 volts.
Editor errors are detected as soon as an
incorrect value is entered and are displayed
immediately.
B Mode errors indicate
problems with saving or loading a program.
TABLE 3.10-1. Error Codes
CodeTypeDescription
03EditorProgram table full
04CompileIntermediate Storage full
05CompileStorage Area #2 not
allocated
08Run TimeCR23X reset by
watchdog timer
09Run TimeInsufficient Input Storage
10Run TimeLow battery voltage
11EditorAttempt to allocate more
Input or Intermediate
Storage than is available
12CompileDuplicate
4 ID
13Run TimeLow 5 V supply
20CompileSUBROUTINE encountered
before END of previous
subroutine
21CompileEND without IF, LOOP or
SUBROUTINE
22CompileMissing END
23CompileNonexistent
SUBROUTINE
24CompileELSE in SUBROUTINE
without IF
3-9
SECTION 3. INSTRUCTION SET BASICS
25CompileELSE without IF
26CompileEXIT LOOP without
LOOP
27CompileIF CASE without BEGIN
CASE
30CompileIF and/or LOOP nested
too deep
31Run TimeSUBROUTINES nested
too deep
32CompileInstruction 3 and interrupt
subroutine use same port
40EditorInstruction does not exist
41EditorIncorrect execution
External data storage devices are used to provide a data transfer medium that the user can
carry from the test site to the lab and to supplement the internal storage capacity of the CR23X,
allowing longer periods between visits to the site. The standard data storage peripheral for the
CR23X is the Storage Module (Section 4.4). Output to a printer or related device is also
possible (Section 4.3).
Data output to a peripheral device can take place ON-LINE (automatically, as part of the
CR23X’s routine operation) or it can be MANUALLY INITIATED. On-line data transfer is
accomplished with Instruction 96 (Section 4.1). Manual initiation is done in the
(Section 4.2).
The CR23X can output data to multiple peripherals. The CR23X activates the peripheral it
sends data to in one of two ways (Section 6.2):
1.A specific pin in the CS I/O connector is dedicated to that peripheral; when that pin goes
high, the peripheral is enabled. This is referred to as "PIN-ENABLED" or simply
"ENABLED".
2.The peripheral is synchronously addressed by the CR23X. This is referred to as
"ADDRESSED".
Modems are pin-enabled. Only one modem device may be connected to the CR23X at any one
time.
8
Mode
The SM192, SM716, and CSM1 Storage Modules are addressed. The CR23X can tell when the
addressed device is present. The CR23X will not send data meant for the Storage module if the
Storage Module is not present (Section 4.4.2).
9
The
and to perform several functions, including review of data, battery test, review of Storage Module
status, etc.
Cassette tape data storage is not supported by the CR23X.
Mode (Section 4.5) allows the user to communicate directly with the Storage Module
4.1 ON-LINE DATA TRANSFER INSTRUCTION 96
All on-line data output to a peripheral device is
accomplished with Instruction 96. (Instruction
96 can also be used to transfer data from one
Final Storage Area to the other, Section 8.8,
12). This instruction must be included in the
datalogger program for on-line data transfer to
take place. Instruction 96 should follow the
Output Processing Instructions, but only needs
to be included once in the program table unless
both Final Storage areas are in use. The
suggested programming sequence is:
1. Set the Output Flag.
2. If both Final Storage Areas are in use or if
you wish to set the Output Array ID, enter
Instruction 80 (Section 11).
3. Enter the appropriate Output Processing
Instructions.
4. Enter Instruction 96 to enable the on-line
transfer of Final Storage data to the
specified device. If outputting to more than
one device, Instruction 96 must be entered
separately for each device.
5. Repeat steps 2 through 4 if you wish to
output data to the other Final Storage Area
and the peripheral.
4-1
SECTION 4. EXTERNAL STORAGE PERIPHERALS
Instruction 96 has a single parameter which
specifies the peripheral to send output to. Table
4.1-1 lists the output device codes.
TABLE 4.1-1. Output Device and
Baud Rate Codes
CodeBaud Rate
0300
11200
29600
376800
42400
54800
619200
738400
PARAM.DATA
NUMBERTYPEDESCRIPTION
01:2Option Device
ADDRESSED PRINT DEVICE, y = Baud code
1y= Printable ASCII
2y= Comma Separated ASCII
3y= Binary Final Storage Format
7N = Storage Module N (N=1-8; Section 4.4.2)
(Stored in Binary Format)
7N-- = Output File Mark to Storage Module N
SERIAL PRINTER, COMPUTER, OR
PIN-ENABLED PRINT DEVICE, y = Baud code
(SDE pulled high)
4y = Printable ASCII (CS I/O)
4y--= Printable ASCII (RS-232)
5y = Comma Separated ASCII (CS I/O)
5y--= Comma Separated ASCII (RS-232)
6y = Binary Final Storage Format (CS I/O)
6y--= Binary Final Storage Format (RS-232)
TRANSFER DATA TO OTHER FINAL
STORAGE AREA
80 = New data only
81 = All data
The source of data for Instruction 96 is the
currently active Final Storage Area as set by
Instruction 80 (the default is Final Storage Area 1
at the beginning of each program table execution).
If the CR23X is using a port (CS I/O or RS-232)
for other I/O tasks when Instruction 96 is
executed, the output request is put in a queue
and program execution continues. As the port
becomes available, each device in the queue
gets its turn.
An output request is not put in the queue if the
same device is already in the queue. The data
contained in the queue (and which determine a
unique entry) are the device, baud rate (if
applicable), and the Final Storage Area.
When an entry reaches the top of the queue, the
CR23X sends all data accumulated since the last
transfer to the device up to the location of the
DSP at the time the device became active.
Printer output can be either pin-enabled or
addressed. However, there is not a pin
specifically dedicated to print enable. When a
pin-enabled print output is specified, the SDE
line, which is normally used in the addressing
sequence, is used as a print enable. This
allows some compatibility with the CR21, 21X,
and CR7 dataloggers which have a Print Enable
line. The pin-enabled print option will result in
garbage being sent to the print peripheral if an
addressed device is also connected to the
CR23X (i.e., SM192 or SM716 etc.). The
SDC99 Synchronous Device Interface can
convert a print device to an Addressed
peripheral (Section 6.2).
The STORAGE MODULE address is important
only when using more than one Storage
Module. The universal address that will find the
Storage Module with lowest number address is
"1". If a Storage Module is not connected, the
CR23X will not advance the SPTR (Section 2.1)
and the Storage Module drops out of the queue
until the next time Instruction 96 is executed.
Section 4.4 contains specifics on the Storage
Modules.
4-2
SECTION 4. EXTERNAL STORAGE PERIPHERALS
8
TABLE 4.2-1.
Mode Entries
Display ID:
KeyDATA
∗
8Mode 08: Storage AreaKey 1 or 2 for Storage Area. (This window is skipped if no memory
Description
00has been allocated to Final Storage Area 2.)
A
01: Device CodeKey in Output Device Option. See Table 4.1-1.
XX
A
02: Start LocationStart of dump location. Initially the SPTR or PPTR location; a
XXXXXdifferent location may be entered if desired.
A
03: End LocationEnd of dump location. Initially the DSP location; a different location
XXXXXmay be keyed in if desired.
A
04: Number Starts Ready to dump. To initiate dump, key any number, then A. While
00dumping, "04 activated; key aborts" and the location number will be
displayed. “Output complete” will be displayed when the dump is
complete. (Any key aborts transmission after completion of the
current data block.)
4.2 MANUALLY INITIATED DATA
OUTPUT - 8 MODE
Data transfer to a peripheral device can be
manually initiated in the
8 Mode allows the user to retrieve a
specific block of data, on demand, regardless of
whether or not the CR23X is programmed for
on-line data output.
If external storage peripherals are not left online, the maximum time between collecting data
must be calculated to ensure that data in Final
Storage are not lost due to write-over. To
calculate this time it is necessary to know: (1)
the size of Final Storage, (2) the number of
Output Arrays being generated, (3) the number
of low and/or high resolution data points per
Output Array, and (4) the rate at which Output
Arrays are placed into Final Storage. When
calculating the number of data points per
Output Array, remember to add 1 data point per
array for the Output Array ID.
For example, assume that 586,568 locations are
assigned to Final Storage (
that 1 Output Array, containing the Array ID (1
memory location), 9 low resolution data points (9
memory locations) and 5 high resolution data
points (10 memory locations), is stored each
hour. In addition, an Output Array with the Array
ID and 5 high resolution data points (11 memory
locations) is stored daily. This is a total of 491
memory locations per day ((20 x 24) + 11).
586,568 divided by 491 = 1194 days. Therefore,
the CR23X would have to be visited every 1194
days to retrieve data, because write-over would
8 Mode. The
A Mode), and
begin on the 1195th day. The site should be
visited more frequently than this for routine
maintenance. Thus data storage capacity would
not be a factor in determining how frequently to
visit the site.
The output device codes used with the
Mode are the same as those used with
Instruction 96 (Table 4.1-1), with the exception
of the option to transfer data from one Final
Storage area to the other (80, 81). Table 4.2-1
lists the keystrokes required to initiate a
data dump.
4.3 PRINTER OUTPUT FORMATS
Printer output can be sent in binary Final Storage
Format (Appendix C.2), Printable ASCII, or
Comma Separated ASCII. These ASCII formats
may also be used when data from the Storage
Modules or Telecommunications are stored on
disk with Campbell Scientific's PC208W software.
4.3.1 PRINTABLE ASCII FORMAT
In the Printable ASCII format, each data point is
preceded by a 2 digit data point ID and a (+) or
(−) sign. The ID and fixed spacing of the data
points make particular points easy to find on a
printed output. This format requires 10 bytes
per data point to store on disk.
Figure 4.3-1 shows both high and low resolution
data points in a 12 data point Output Array. The
example data contains Day, Hour-Minute, and
Seconds in the 2nd - 4th data points.
REMEMBER! You must specifically program
8
8
4-3
SECTION 4. EXTERNAL STORAGE PERIPHERALS
the CR23X to output the date and time values.
The Output Array ID, Day, and Time are always
4 character numbers, even when high resolution
output is specified. The seconds resolution is
0.1 seconds.
Each full line of data contains 8 data points (79
characters including spaces), plus a carriage
return (CR) and line feed (LF). If the last data
point in a full line is high resolution, it is followed
immediately with a CR and LF. If it is low
resolution, the line is terminated with a space,
CR and LF. Lines of data containing less than 8
data points are terminated similarly after the last
data point.
4.3.2 COMMA SEPARATED ASCII
Comma Separated ASCII strips all IDs, leading
zeros, unnecessary decimal points and trailing
zeros, and plus signs. Data points are separated
by commas. Arrays are separated by Carriage
Return Line Feed. Comma Separated ASCII
requires approximately 6 bytes per data point.
Example:
The Storage Module stores data in battery
backed RAM. Backup is provided by an internal
lithium battery. The RAM is internal on the
SM192/716 and on a PCMCIA card in the CSM1.
Operating power is supplied by the CR23X over
pin 1 of the CS I/O port. Whenever power is
applied to the CS I/O port (after having been off),
the Storage Module places a File Mark in the
data (if a File Mark is not the last data point
already in storage).
The File Mark separates data. For example, if
you retrieve data from one CR23X, disconnect
the Storage Module and connect it to a second
CR23X, a File Mark is automatically placed in
the data. This mark follows the data from the
first CR23X but precedes the data from the
second.
The SM192 has 192K bytes of RAM storage; the
SM716 has 716K bytes. Both can be configured
as either ring or fill and stop memory. The size of
memory in the CSM1 depends on the PC Card
used. The CSM1 is always fill and stop.
4-4
FIGURE 4.3-1. Example of CR23X Printable ASCII Output Format
SECTION 4. EXTERNAL STORAGE PERIPHERALS
4.4.1 STORAGE MODULE ADDRESSING
The CSM1 does not support individual addresses.
Use address "1" when sending data to the CSM1.
The SM192/716 Storage Modules can have
individual addresses. Different addresses allow 1)
up to 8 Storage Modules to be connected to the
CR23X during on-line output, 2) different data to be
output to different Modules, and 3) transfer of data
from a Module that is left with the CR23X to a
Module that is hand carried to the site for data
transfer (
9 Mode).
Storage Modules are assigned addresses (1-8) either
through the
9
Mode or with the PC208W
software. The default address when the Storage
Module is reset is "1". Unless you are using one of the
features which require different addresses, you need
not assign any other address.
Address 1 is also a universal address when
sending data or commands to a storage module
8
with Instruction 96,
address 1 is entered in the
, or
9
Mode
9
. When
(default) or in the device code (71, Table 4.2-1)
for Instruction 96 or the
8 Mode, The
CR23X searches for the Storage Module with
the lowest address that is not full (fill and stop
configuration only) and addresses it. In other
words, if a single Storage Module is connected,
and it is not full, address 1 will address that
Storage Module regardless of the address that
is assigned to the Module.
Address 1 would be used with Instruction 96 if
several Storage Modules with different
addresses were connected to the CR23X and
were to be filled sequentially. The Storage
modules would be configured as fill and stop.
When the lowest addressed Module was full
data would be written to the next lowest
addressed Module, etc.
4.4.2 STORAGE MODULE USE WITH
INSTRUCTION 96
When output to the Storage Module is enabled
with Instruction 96, the Storage Module(s) may
be either left with the CR23X for on-line data
transfer and periodically exchanged, or brought
to the site for data transfer.
USE OF STORAGE MODULE TO PICK UP
DATA
The CR23X is capable of recognizing whether or
not the Storage Module is connected. Each time
Instruction 96 is executed and there is data to
output, the CR23X checks for the presence of a
Storage Module. If one is not present, the
CR23X does not attempt to output data.
Instead, the CR23X saves the data and
continues its other operations without advancing
the Storage Module Pointer (SPTR, Section 2.1).
When the user finally does connect the Storage
Module to the CR23X, two things happen:
1. Immediately upon connection, a File Mark is
placed in the Storage Module Memory
following the last data stored (if a File Mark
wasn't the last data point already in storage).
2. During the next execution of Instruction 96,
the CR23X recognizes that the Storage
Module (SM) is present and outputs all data
between the SPTR and the DSP location.
The File Mark allows the operator to distinguish
blocks of data from different dataloggers or
from different visits to the field.
To be certain that the Storage Module has been
connected to the CR23X during an execution of
P96, the user can:
•Leave the Storage Module connected for a time
period longer than an execution interval or
•Use the SC90 9-Pin Serial Line Monitor. The
SC90 contains an LED which lights up during
data transmission. The user connects the SM
to the CR23X with the SC90 on the line and
waits for the LED to light. When the light goes
off, data transfer is complete and the SM can
be disconnected from the CR23X.
4.4.3
8 DUMP TO STORAGE MODULE
In addition to the on-line data output procedures
described above, output to the Storage Module
can be manually initiated in the
8 Mode.
The procedure for setting up and transferring
data is as follows:
1. Connect the Storage Module to the CR23X
using the SC12 cable.
4-5
SECTION 4. EXTERNAL STORAGE PERIPHERALS
2. Key in the appropriate commands as listed
in Table 4.2-1.
4.5
9
MODE -- SM192/716
STORAGE MODULE COMMANDS
The CSM1 does not support the
Commands.
9
The
Mode is used to issue commands to
the SM192/716 Storage Module, from the CR23X.
These commands are like
Modes for the
Storage Module and in some cases are directly
analogous to the CR23X
Modes. Command 7
enters a mode used to review stored data, and 8 is
used to transfer data between two Storage
Modules connected to the CR23X. The operations
with the Storage Module are not directly analogous
as may be seen in Table 4.5-1 which lists the
TABLE 4.5-1.
COMMANDDISPLAYDESCRIPTION
101: 0000RESET, enter 248 to erase all data and programs. While erasing,
01: XXdisplayed (6 for SM192, 22 SM716).
303: 01INSERT FILE MARK, 1 indicates that the mark was inserted, 0
404: XXDISPLAY/SET MEMORY CONFIGURATION enter the
5DISPLAY STATUS (A to advance to each window)
01: ABCDWindow 1:
ABStorage pointer location (chip no.)
CDTotal good RAM chips (1-22)
02: ABCDWindow 2:
ABDisplay pointer location (chip no.)
CUnloaded Batt. Chk. 0=low, 1=OK
DNo. of Programs stored (Max=8)
03: A0CDWindow 3:
AErrors logged (up to 9)
0Not Used
CMemory Config. (0=ring, 1=fill&stop)
DMemory Status (0=not full, 1=full)
04: XXXXXPROM signature (0 if bad PROM)
606: 0XBATTERY CHECK UNDER LOAD (0=low, 1=OK)
707: 00DISPLAY DATA, Select the Storage Module Area with these codes:
9
Mode
the SM checks memory. The number of good chips is then
that it was not.
appropriate code to change configuration 0=ring, 1=fill & stop
commands (e.g., when reviewing data, #A
advances to the start of the next Output Array
rather than to the same element in the next array
with the same ID).
9
When
is keyed, the CR23X responds: 09:01
1 is the default address for the Storage Module
(Section 4.4.1). If you have more than 1
Storage Module connected, enter the address
of the desired Storage Module. Address 1 will
always work if only one Module is connected.
Key A and the CR23X responds: 9N:00
Where N is the address which was entered.
You may now enter any of the commands in
Table 4.5-1 (key in the command number and
enter with A). Most commands have at least one
response. Advance through the responses and
return to the
9
Commands for Storage Module
9
command state by keying A.
0Dump pointer to SRP
1File 1, current file
2File 2, previous to file 1
3File 3, previous to file 2
4File 4, previous to file 3
5File 5, previous to file 4
7Display pointer to SRP
9Oldest data to SRP
1-5will loop within file boundaries, 0,7,9 allow display to
cross boundaries
4-6
SECTION 4. EXTERNAL STORAGE PERIPHERALS
07:XXXXXXSM location at end of area selected. Key A to advance to first
data. If another location is keyed in SM will jump to 1st start of
array following that location.
Review data with:
AAdvance and display next data point
BBack-up one data point
#Display location, C to return to data
#A Advance to next start of Array
#B Back-up to start of Array
9
#D Return to
command mode
8DUMP TO ANOTHER STORAGE MODULE
08:00Select Area as in 7 above
01:XXXXXXFirst Loc. in area selected/Enter Loc. to start dump
02:XXXXXXFinal Loc. in area selected/Enter Loc. to end dump
03:XXEnter destination SM address
9DISPLAY ADDRESSES OF CONNECTED SM
XXXXXXXX1 = occupied, 0 = unoccupied
87654321(Addresses 8-1 from left to right)
10CHANGE ADDRESS
10:0XX is current address, enter address to change to (1-8)
4-7
SECTION 4. EXTERNAL STORAGE PERIPHERALS
This is a blank page.
4-8
SECTION 5. TELECOMMUNICATIONS
Campbell Scientific has developed a software package which automates data retrieval and facilitates the
programming of Campbell Scientific dataloggers and the handling of data files. This package, PC208W,
has been designed to meet most needs in datalogger support and telecommunications. Therefore,
information in this section is not necessary for most datalogger applications.
Telecommunications is used to retrieve data from Final Storage directly to a computer/terminal and to
program the CR23X. Any user communication with the CR23X that makes use of a computer or
terminal is done through Telecommunications.
Telecommunications can take place over a variety of links including:
• SC32A and ribbon cable/SC929 cable
• Telephone
• Cellular phone
• Radio frequency
• Short haul modem and twisted pair wire
• Multi-drop interface and coax cable
This section does not cover the technical interface details for any of these links. Those details are
covered in Section 6 and in the individual manuals for the devices.
Data retrieval can take place in either BINARY or ASCII. The BINARY format is 5 times more compact
than ASCII. The shorter transmission times for binary result in lower long distance costs if the link is
telephone and lower power consumption with an RF link. On "noisy" links shorter blocks of data are
more likely to get through without interruption.
For more efficient data transfer, binary data retrieval makes use of a signature for error detection. The
signature algorithm assures a 99.998% probability that if either the data or its sequence changes, the
signature changes. Campbell Scientific’s PC208W Datalogger Support Software uses the binary format
for data transfer.
This section does not furnish sufficient detail to write telecommunications software. Appendix C contains
some details of binary data transfer and Campbell Scientific’s binary data format. The emphasis of this
section is on the commands that a person would use when manually (i.e., keyed in by hand)
interrogating or programming the CR23X via a computer/terminal. These commands and the responses
to them are sent in the American Standard Code for Information Interchange (ASCII).
The telecommunications commands allow the user to perform several operations including:
• trouble shoot a problematic communications link
• check the datalogger’s status
• monitor data in Input Storage and review data in Final Storage
• retrieve Final Storage data in either ASCII or BINARY
• open communications with the Storage Module
• remote keyboard programming
The Remote Keyboard State (Section 5.2) allows the user with a computer/terminal to use the same
commands as on the CR23X keypad.
5.1 TELECOMMUNICATIONS
COMMANDS
When a modem/terminal rings the CR23X, the
CR23X should answer almost immediately.
Several carriage returns (CR) must be sent to
the CR23X to allow it to set its baud rate to that
of the modem/terminal (300, 1200, 2400, 4800,
9600, 19.2K, 38.4K, or 76.8K). Once the baud
rate is set, the CR23X will send back the
prompt, "∗∗∗∗", signaling that it is ready to receive a
command.
5-1
SECTION 5. TELECOMMUNICATIONS
GENERAL RULES governing the
telecommunications commands are as follows:
1. ∗∗∗∗ from datalogger means "ready for
command".
2. All commands are of the form: [no.]letter,
where the number may or may not be
optional.
3. Valid characters are the numbers 0-9, the
capital letters A-U, the colon (:), and the
carriage return (CR).
4. An illegal character increments a counter
and zeros the command buffer, returning a
∗∗∗∗.
5. CR to datalogger means "execute".
6. A carriage return followed immediately by a
line feed character (CRLF) from datalogger
means "executing command".
7. ANY character besides a CR sent to the
datalogger with a legal command in its buffer
causes the datalogger to abort the command
sequence with CRLF∗∗∗∗ and to zero the
command buffer.
8. All commands return a response code,
usually at least a checksum.
9. The checksum includes all characters sent by
the datalogger since the last ∗∗∗∗, including the
echoed command sequence, excluding only
the checksum itself. The checksum is
formed by summing the ASCII values, without
parity, of the transmitted characters. The
largest possible checksum value is 8191.
Each time 8191 is exceeded, the CR23X
starts the count over; e.g., if the sum of the
ASCII values is 8192, the checksum is 0.
10. Commands that return Campbell Scientific
binary format data (i.e., F and K
commands) return a signature (see
Appendix C.3).
The CR23X sends ASCII data with 8 bits, no
parity, one start bit, and one stop bit.
After the CR23X answers a ring, or completes a
command, it waits about 40 seconds (127
seconds in the Remote Keyboard State) for a
valid character to arrive. It "hangs up" if it does
not receive a valid character in this time interval.
Some modems are quite noisy when not on line;
it is possible for valid characters to appear in
the noise pattern. To insure that this situation
does not keep the CR23X in
telecommunications, the CR23X counts all the
invalid characters it receives from the time it
answers a ring, and terminates communication
after receiving 150 invalid characters.
The CR23X continues to execute its
measurement and processing tasks while
servicing the telecommunication requests. If
the processing overhead is large (short
Execution Interval), the processing tasks will
slow the telecommunication functions. In a
worst case situation, the CR23X interrupts the
processing tasks to transmit a data point every
0.1 second.
The best way to become familiar with the
Telecommunication Commands is to try them
from a terminal connected to the CR23X via the
SC32A (Section 6.7.1) or other interface.
Commands used to interrogate the CR23X in
the Telecommunications Mode are described in
the following Table.
5-2
SECTION 5. TELECOMMUNICATIONS
TABLE 5.1-1. Telecommunications Commands
CommandDescription
[F.S. Area]ASELECT AREA/STATUS - If 1 or 2 does not precede the A to select
the Final Storage Area, the CR23X will default to the Area last used
(initially this is Area 1). All subsequent commands other than A will
address the area selected. Datalogger returns Reference, the DSP
location; the number of Filled Final Storage locations; Version of
datalogger; Final Storage Area; Location of MPTR (the location
number may be 1 to 7 characters long); Errors #1, #2, #3, and #4
where #1 is the number of E08's, #2 is the number of overrun errors,
#3 is the number of times the program stopped due to low voltage,
and #4 is the number of times the 5 V supply dropped below 5V (all
are cleared by entering 8888A; #2 is also cleared at time of program
compilation); size of total Memory in CR23X in Kbytes; the lithium
Battery voltage; and Checksum. All in the following format:
R+xxxxx. F+xxxxx. Vxx Axx L+xxxxxxx. Exx xx xx xx Mxxxx B+x. xxxx Cxxxx
If data is stored while in telecommunications, the A command must
be issued to update the Reference to the new DSP.
[no. of arrays]BBACK-UP - MPTR is backed-up the specified number of Output
Arrays (no number defaults to 1) and advanced to the nearest start
of array. CR23X sends the Area, MPTR Location, and Checksum:
Ax L+xxxxxxx Cxxxx
[YR:DAY:HR:MM:SS]CRESET/SEND TIME - If time is entered the time is reset. If only 2
colons are in the time string, HR:MM:SS is assumed; 3 colons
means DAY:HR:MM:SS. If only the C is entered, time is unaltered.
CR23X returns year, Julian day, hr:min:sec, and Checksum:
Yxx Dxxxx Txx:xx:xx Cxxxx
[no. of arrays]DASCII DUMP - If necessary, the MPTR is advanced to the beginning
of the next array. CR23X sends the number of arrays specified (no
number defaults to 1) or the number of arrays between MPTR and
Reference, whichever is smaller, CRLF, FSA, Location, Checksum.
EEnd call. Datalogger sends CRLF only.
[no. of loc.]FBINARY DUMP - Used by CSI software for data retrieval. See
Appendix C.
[F.S. loc. no.]GMOVE MPTR - MPTR is moved to specified Final Storage location.
The location number must be entered. CR23X sends Area,
Location, and Checksum:
Ax L+xxxxxxx Cxxxx
7H or 2718HREMOTE KEYBOARD - CR23X sends the prompt ">" and is ready
to execute standard keyboard commands (Section OV3). Aborted
by pressing any key (except *, D , #) on local keypad.
5-3
SECTION 5. TELECOMMUNICATIONS
[loc. no.]IDisplay/change value at Input Storage location. CR23X sends the
value stored at the location. A new value and CR may then be sent.
CR23X sends checksum. If no new value is sent (CR only), the
location value will remain the same.
3142JTOGGLE FLAGS AND SET UP FOR K COMMAND - Used i n the
Monitor Mode and with the Heads Up Display. See Appendix C for
details.
2413JSET UP FOR K COMMAND - Used in the Monitor Mode and with the
Heads Up Display. Similar to the 3142J command but does not
toggle flags and ports. See Appendix C for details. (Available first in
CR23X OS Version 1.7; also indicated by “V4” returned to the A
command, see above.)
KCURRENT INFORMATION - In response to the K command, the
CR23X sends datalogger time, user flag status, the data at the input
locations requested in the J command, and Final Storage Data if
requested by the J command. Used in the Monitor Mode and with
Heads Up Display. See Appendix C for details.
[Password]LUnlocks security (if enabled) to the level determined by the
password entered (See * C Mode, Section 1.7). CR23X sends
security level (0-3) and checksum:
Sxx Cxxxx
[X]MConnect to Storage Module with address 'X' and enter the Storage
Module's Telecommunications Mode (see Storage Module manual). The
Storage Module can also be accessed through the * 9 Commands while in
the Remote Keyboard Mode (Section 4.5 and the Storage Module
manual).
1NConnect phone modem to RF modem at phone to RF base station.
PCommand to set 9.8304 MHz crystal coefficients. Coefficients are
set at the factory and normally should not be altered. Displays:
E clock Hz - 2.4576 MHz
to give better resolution. Also, gets rid of out of bounds check that
used to load default back in. If not set, P27 and other timing
instructions will have problems.
19287P will display the 2 coefficient numbers for you (e.g. 0.8944
.8133). If the 2 numbers are -99999, the datalogger needs to be
calibrated.
19287:1600P will calibrate it for you if your crystal is exactly 2.4576
MHz E Clock. This temporary fix will improve the performance of a
datalogger that failed the 19287P test.
5-4
RCommand to set the display’s contrast dependence on temperature.
Typing R alone will display the current settings to you (## ## ## ##
SECTION 5. TELECOMMUNICATIONS
## ## ## ##). Typing 8 numbers, separated by colons, followed by
an R, will reset the default settings. Example:
140:110:90:65:50:45:34:30R <crlf>
The setting of the eight contrast temperature bins is initially done at
Campbell Scientific. Below are the contrast settings of one type of
LCD screen for temperatures from <-15 to >+50 °C. A user can also
adjust the value of the current bin by entering the * D mode while in
Remote Keyboard Mode. The minimum contrast setting is 0. The
maximum setting is 255.
Contrast Setting
140< -15
110-10 to -15
90-5 to -10
65-5 to +5
50+5 to +30
45+30 to +40
35+40 to +50
30> +50
SReturns Mode A Memory Allocation registers (first group of 01: to 09:)
and Mode B Status/On-board Firmware registers (second group of 01:
to 17:)
TSDM-SIO4 talk through command
Address: Port T
Address = 0..15
Port = 0..4
nnnnUReturns V[value] C[checksum] where nnnn refers to an input
location, port, or flag, V is the value at the input location, port or flag,
and C is the checksum. For nnnn = 90ff, then nnnn refers to flag ff.
For nnnn = 91pp, then nnnn refers to port pp. For nnnn<9000, then
nnnn refers to input location nnnn.
Temperature °°°°C
Examples (xxxx is checksum, true or high for flags is non-zero, false
or low is zero):
2U<CR> returns
V+73.650 Cxxxx. (input location 2 equals 73.650)
9003U<CR> returns
V+1.0000 Cxxxx (flag 3 is high).
9107U<CR> returns
V+0.0000 Cxxxx (port 7 is low)
nnnn:[value]:[checksum]ULoads the input location, port, or flag referred to by nnnn with value if
the checksum is correct. nnnn refers to input location, flag, or port
as above. The datalogger returns the same as the nnnnU
command.
9003:1:xxxxU<CR> returns
V1.0000 Cxxxx (sets flag 3 high)
9105:0:xxxxU<CR> returns
V0.0000 Cxxxx (sets port 5 low)
5.2 REMOTE PROGRAMMING OF THE
CR23X
Remote programming of the CR23X can be
accomplished with the PC208W software or
directly through the Remote Keyboard State.
The PC208W Datalogger Support Software was
developed by Campbell Scientific for use with
IBM or compatible PC's. Datalogger programs
are developed on the computer using the
program editor (Edlog in PC208W or the
separate Short Cut program generator) and
downloaded to the datalogger using PC208W’s
Connect screen.
Alternatively, a terminal session can be opened
using any terminal program (e.g., Microsoft’s
Hyperterminal) and connecting via serial cable to
the CR23X. PC208W’s Connect screen also
offers such a Terminal window. The CR23X can
be placed in the Remote Keyboard State by
sending either "7H" or "2718H" and a carriage
return (CR). The CR23X responds by sending a
CR, line feed (LF), and the prompt '>'. The
CR23X is then ready to receive the standard
keyboard commands; it recognizes all the
standard CR23X keyboard characters plus
several additional characters, including the
decimal point, the minus sign, and Enter (CR)
(Section OV3.2).
Remember that entering * 0 will compile and
run the CR23X program if program changes
have been made.
The 7H Command is generally used with a
terminal for direct entry since H makes use of a
destructive backspace and does not send
control Q between each entry. The 2718H
Command functions the same as it does for
other Campbell Scientific dataloggers (deleting
an entry causes the entire entry to be sent,
"control Q" is sent after each user entry).
It is important to remember that the Remote
Keyboard State is still within
Telecommunications. Entering * 0 exits the
Remote Keyboard State and returns the
datalogger to the Telecommunications
Command State, awaiting another command.
The user can step back and forth between the
Telecommunications Command State and the
Remote Keyboard State.
NOTE: Entering * 0 returns the CR23X to
the telecommunications command state.
TelecommunicationsRemote
CommandKeyboard
StateState
5-6
7H (or 2718H)
∗ 0
SECTION 6. 9-PIN SERIAL INPUT/OUTPUT
CS I/O
COMPUTER
RS232
(OPTICALLY ISOLATED)
External communication peripherals normally connect to the CR23X through two 9-pin subminiature D-type
socket connectors located on the front panel (Figure 6.1-1). An optically isolated RS-232 port is provided for
direct connection to RS-232 devices such as a PC. Optical isolation provides immunity from ground loop
problems that can degrade single-ended measurement accuracy in systems with multiple ground
connections. The CS I/O interface utilizes (0 - 5) V signal levels and is to be used to connect to Campbell
Scientific communications peripherals. Either 9-pin interface can be used for telecommunications, however,
only one of these two interfaces can be active at once. The first 9-pin interface to receive a RING becomes
the active interface until a telecommunications sequence is terminated. When either port is active, "Busy with
COM" will show on the CR23X display. If "Busy with COM" is displayed after disconnecting the
telecommunications device, pressing any key will activate the key pad after a 2 to 3 second delay.
NOTE: Serial communications is not reliable over cable greater than 50 feet in length.
6.1 COMPUTER RS-232 9-PIN
DESCRIPTION
Direct connection of the CR23X to a PC is most
conveniently done through the "Computer
RS232" port (Figure 6.2-1). Table 6.1-1 gives a
brief description of each "Computer RS232" pin.
The Computer RS-232 port is a DCE device
when connected to a PC with a serial cable. It
also doubles as a DTE device when connected
to a modem device through a null-modem
cable.
ABR = Abbreviation for the function name
PIN = Pin number
O= Signal Out of the CR23X to a RS-232
device
I= Signal Into the CR23X from a RS-232
device
The CR23X is supplied with a six foot 9 pin to 9
pin serial cable and a 9 to 25 pin adapter to
facilitate connection to a PC RS-232 port.
Pin 5
Pin 9
FIGURE 6.1-1. Serial Communication
Interfaces
6.2 CS I/O 9-PIN DESCRIPTION
All Campbell Scientific communication
peripherals connect to the CR23X through the
9-pin subminiature D-type socket connector
located on the front of the Wiring Panel labeled
“CS I/O” (Figure 6.1-1). Table 6.2-1 gives a
brief description of each pin.
Pin 1
Pin 6
PINABR
1DTROdata terminal ready
2TXOasynchronous transmit
3RXIasynchronous receive
4not used
5GNDisolated ground
6not used
7CTSIclear to send
8RTSOrequest to send
9RINGIring
I/ODescription
6-1
SECTION 6. 9-PIN SERIAL INPUT/OUTPUT
TABLE 6.2-1. Pin Description
ABR =Abbreviation for the function name.
PIN=Pin number.
O=Signal Out of the CR10X to a peripheral.
I=Signal Into the CR10X from a peripheral.
PINABR
15 VO5V: Sources 5 VDC, used to power peripherals.
2SGSignal Ground: Provides a power return for pin 1 (5V), and is used as a
3RINGIRing: Raised by a peripheral to put the CR10X in the telecommunications mode.
4RXDIReceive Data: Serial data transmitted by a peripheral are received on pin 4.
5MEOModem Enable: Raised when the CR10X determines that a modem raised the
6SDEOSynchronous Device Enable: Used to address Synchronous Devices (SDs), and
7CLK/HS I/OClock/Handshake: Used with the SDE and TXD lines to address and transfer
8+12 VDC
9TXDOTransmit Data: Serial data are transmitted from the CR10X to peripherals on pin
I/ODescription
reference for voltage levels.
ring line.
can be used as an enable line for printers.
data to SDs. When not used as a clock, pin 7 can be used as a handshake line
(during printer output, high enables, low disables).
9; logic low marking (0V) logic high spacing (5V) standard asynchronous ASCII, 8
data bits, no parity, 1 start bit, 1 stop bit, 300, 1200, 9600, 76,800 baud (user
selectable).
6-2
(ME)
MODEM
(COM200
RF95
SC32A)
FIGURE 6.2-1. Hardware Enabled and Synchronously Addressed Peripherals
SECTION 6. 9-PIN SERIAL INPUT/OUTPUT
6.2.1 ENABLING AND ADDRESSING
PERIPHERALS
While several peripherals may be connected in
parallel to the CS I/O port, the CR23X has only
one transmit line (pin 9) and one receive line (pin
4, Table 6.2-1). The CR23X selects a peripheral
in one of two ways: 1) A specific pin is dedicated
to that peripheral and the peripheral is enabled
when the pin goes high; we will call this pinenabled or simply enabled. 2) The peripheral is
addressed; the address is sent on pin 9, each bit
being synchronously clocked using pin 7. Pin 6
is set high while addressing.
6.2.1.1 PIN-ENABLED PERIPHERALS
Modem Enable (pin 5) is dedicated to a specific
device. Synchronous Device Enable (pin 6) can
either be used as a Print Enable or it can be
used to address Synchronous Devices (Section
6.2.5).
Modem Enable (ME), pin 5, is raised to enable
a modem that has raised the ring line.
Modem/terminal peripherals include Campbell
Scientific phone modems and computers or
terminals using the SC32A or SC929 interface.
The CR23X interprets a ring interrupt (Section
6.2.2) to come from a modem if the device
raises the CR23X's Ring line, and holds it high
until the CR23X raises the ME line. Only one
modem/ terminal may be connected to the
CR23X.
Print Peripherals are defined as peripherals
which have an asynchronous serial
communications port used to RECEIVE data
transferred by the CR23X. In most cases the
print peripheral is a printer, but could also be an
on-line computer or other device.
Synchronous Device Enable (SDE), pin 6, may be
used to enable a print peripheral only when no
other addressable peripherals are connected to
the CS I/O connector. Use of the SDE line as an
enable line maintains CR23X compatibility with
printer-type peripherals which require a line to be
held high (Data Terminal Ready) in order to
receive data.
If output to both a print peripheral and an
addressable peripheral is necessary the SDC99
Synchronous Device Interface is required. With
the SDC99 the print peripheral functions as an
addressable peripheral. If the SDC99 is not
used, the print peripheral receives the address
and data sent to the addressed peripheral.
Synchronous addressing appears as garbage
characters on a print peripheral.
6.2.1.2 ADDRESSED PERIPHERALS
The CR23X has the ability to address
Synchronous Devices (SDs). SDs differ from
enabled peripherals in that they are not enabled
solely by a hardware line (Section 6.2.1.1); an SD
is enabled by an address synchronously clocked
from the CR23X (Section 6.2.5).
Up to 16 SDs may be addressed by the CR23X.
Unlike an enabled peripheral, the CR23X
establishes communication with an addressed
peripheral before data are transferred. During
data transfer an addressed peripheral uses pin
7 as a handshake line with the CR23X.
Synchronously addressed peripherals include
Storage Modules, SDC99 Synchronous Device
Interface (SDC99), and RF95 RF Modem when
configured as a synchronous device. The SDC99
interface is used to address peripherals which are
normally modem enabled (Figure 6.2-1).
6.2.2 RING INTERRUPTS
There are two peripherals that can raise the
CR23X's ring line; modems and the RF Modem
configured for synchronous device for
communication (RF-SDC). The RF-SDC is
used when the CR23X is installed at a
telephone to RF base station.
When the Ring line is raised, the processor is
interrupted, and the CR23X determines which
peripheral raised the Ring line through a process
of elimination (Figure 6.2-3). The CR23X raises
the CLK/HS line forcing all SDs to drop the ring
line. If the ring line is still high the peripheral is a
modem, and the ME line is raised. If the ring line
is low the CR23X addresses the Keyboard
Display and RF-SDC to determine which device
to service. (Section 6.2.5)
After the CR23X has determined which
peripheral raised the Ring line, the hierarchy is
as follows:
A modem which raises the Ring line will interrupt
and gain control of the CR23X. A ring from a
modem aborts data transfer to pin-enabled and
addressed peripherals.
6-3
SECTION 6. 9-PIN SERIAL INPUT/OUTPUT
FIGURE 6.2-3. Servicing of Ring Interrupts
6.2.4 MODEM/TERMINAL PERIPHERALS
The CR23X considers any device with an
asynchronous serial communications port which
raises the Ring line (and holds it high until the
ME line is raised) to be a modem peripheral.
Modem/terminals include Campbell Scientific
phone modems, and most computers,
terminals, and modems using the SC32A
Optically Isolated RS-232 Interface, the SC932
RS-232 DCE Interface, or the SC929 cable.
When a modem raises the Ring line, the CR23X
responds by raising the ME line. The CR23X
must then receive carriage returns spaced at
least 50 ms apart until it can establish baud rate.
When the baud rate has been set, the CR23X
sends a carriage return, line feed, "∗".
The ME line is held high until the CR23X receives
an "E" to exit telecommunications. The ME is
also lowered if a character is not received after 40
seconds in the Telecommunications Command
State (2 minutes in the Remote Keyboard State).
Some modems are quite noisy when not on line; it
is possible for valid characters to appear in the
noise pattern. For this reason, the CR23X counts
all the invalid characters it receives from the time
it answers a ring, and terminates communication
(lowers the ME line and returns to the
Mode) after receiving 150 invalid characters.
6.2.5 SYNCHRONOUS DEVICE
COMMUNICATION
Synchronous Devices (SDs) differ from enabled
peripherals (Section 6.2.1) in that they are not
enabled solely by a hardware line. An SD is
enabled by an address synchronously clocked
from the CR23X. Up to 16 SDs may be
addressed by the CR23X, requiring only three
pins of the 9-pin connector.
Synchronous Device Communication (SDC)
discussed here is for those peripherals which
connect to the 9-pin serial port. This should not
be confused with Synchronous Device for
Measurement (SDM) peripherals connected to
control ports 1, 2, and 3. (Although the
communication protocol for SDMs is very
similar, their addressing is independent of SDC
addresses and they do not have a ring line.)
SD STATES
The CR23X and the SDs use a combination of
the Ring, Clock Handshake (CLK/HS) and
Synchronous Device Enable (SDE) lines to
establish communication. The CR23X can put
the SDs into one of six states.
STATE 1, the SD Reset State
The CR23X forces the SDs to the reset/request
state by lowering the SDE and CLK/HS lines.
The SD cannot drive the CLK/HS or RXD lines
in State 1, however, it can raise the Ring line if
service is needed. The SD can never pull the
Ring low if a Modem/Terminal is holding it high.
Data on TXD is ignored by the SD.
STATE 2, the SD Addressing State
The CR23X places the SDs in the addressing
state by raising CLK/HS followed by or
simultaneously raising SDE (Figure 6.2-4). TXD
must be low while SDE and CLK/HS are
changing to the high state.
State 2 requires all SDs to drop the Ring line
and prepare for addressing. The CR23X then
synchronously clocks 8 bits onto TXD using
CLK/HS as a clock. The least significant bit is
transmitted first and is always logic high. Each
bit transmitted is stable on the rising edge of
CLK/HS. The SDs shift in bits from TXD on the
rising edge of CLK/HS provided by the CR23X.
0
The CR23X can only address one device per
State 2 cycle. More than one SD may respond
6-4
SECTION 6. 9-PIN SERIAL INPUT/OUTPUT
to the address, however. State 2 ends when
the 8th bit is received by the SD.
SDs implemented with shift registers decode
the 4 most significant bits (bits 4, 5, 6, and 7) for
an address. Bit 0 is always logic high. Bits 1, 2,
and 3 are optional function selectors or
commands. Addresses established to date are
shown in Table 6.2-2 and are decoded with
respect to the TXD line.
STATE 3, the SD Active State
The SD addressed by State 2, enters State 3.
All other SDs enter State 4. An active SD
returns to State 1 by resetting itself, or by the
CR23X forcing it to reset.
Active SDs have different acknowledgment and
communication protocols. Once addressed, the
SD is free to use the CLK/HS, TXD, and RXD
lines according to its protocol with the CR23X.
The CR23X may also pulse the SDE line after
addressing, as long as the CLK/HS and SDE
are not low at the same time.
STATE 4, the SD Inactive State
The SDs not addressed by State 2 enter State
4, if not able to reset themselves (e.g., SM192
Storage Module). Inactive SDs ignore data on
the TXD line and are not allowed to use the
CLK/HS or RXD lines. Inactive SDs may raise
the Ring line to request service.
STATE 5
State 5 is a branch from State 1 when the SDE
line is high and the CLK/HS line is low. The
SDs must drop the Ring line in this state. This
state is not used by SDs. The CR23X must
force the SDs back to the reset state from State
5 before addressing SDs.
STATE 6
State 6 is a branch from State 1, like State 5,
except the SDE line is low and the CLK/HS line
is high. The SDs must drop the Ring line in this
state.
6.2.6 MODEM/TERMINAL AND COMPUTER
REQUIREMENTS
The CR23X considers any device with an
asynchronous serial communications port which
raises the Ring line (and holds it high until the
ME line is raised) to be a modem peripheral.
Modems include Campbell Scientific phone
modems, and most computers, terminals, and
modems using the SC32A Optically Isolated
RS-232 Interface.
FIGURE 6.2-4. Addressing Sequence for the RF Modem
6-5
SECTION 6. 9-PIN SERIAL INPUT/OUTPUT
6.2.6.1 SC32A INTERFACE TO COMPUTER
Most computers require the SC32A Optically
Isolated RS-232 Interface to communicate to the
CS I/O port. (Direct connection to the CR23X is
allowed through the “Computer RS-232” port.)
The SC32A can pass data up to 19.2 K baud.
The SC32A raises the CR23X's ring line when it
receives characters from a modem, and converts
the CR23X's logic levels (0 V logic low, 5V logic
high) to RS-232 logic levels.
The SC32A 25-pin port is configured as Data
Communications Equipment (DCE) (see Table
6.2-3) for direct connection to Data Terminal
Equipment (DTE), which includes most PCs
and printers.
When the SC32A receives a character from the
terminal/computer (pin 2), 5 V is applied to the
datalogger Ring line (pin 3) for one second or
until the Modem Enable line (ME) goes high.
The CR23X waits approximately 40 seconds to
receive carriage returns, which it uses to
establish baud rate. After the baud rate has
been set the CR23X transmits a carriage return,
line feed, "∗", and enters the Telecommunications Command State (Section 5). If the
carriage returns are not received within the 40
seconds, the CR23X "hangs up".
TABLE 6.2-3. SC32A Pin Description
PIN =Pin number
O=Signal Out of the SC32A to a peripheral
I=Signal Into the SC32A from peripheral
25-PIN FEMALE PORT:
NOTE: The SC32A has a jumper, which
when used, passes data only when the ME
line is high and the SDE line is low. The
function of the jumper is to block data sent
to SDs from being received by a
computer/terminal used to initiate data
transfer. Synchronous data will appear as
garbage characters on a computer/terminal.
6.2.6.2 SC932 INTERFACE TO MODEMS
Most modems have an RS-232 port configured as
DCE. For connection of the CS I/O port to DCE
devices such as modems and some computers,
the SC932 9-pin to RS-232 DCE Interface should
be used. The SC932 supports baud rates up to
19.2 K. Faster baud rates may be possible,
depending on the device being interfaced.
6.2.6.3 COMPUTER/TERMINAL
REQUIREMENTS
Computer/terminal peripherals are usually
configured as Data Terminal Equipment (DTE).
Pins 4 and 20 are used as handshake lines,
which are set high when the serial port is
enabled. Power for the SC32A RS-232 section
is taken from these pins. For equipment
configured as DTE (see Table 6.2-4) a direct
ribbon cable connects the computer/terminal to
the SC32A. Clear to Send (CTS) pin 5, Data
Set Ready (DSR) pin 6, and Data Carrier Detect
(DCD) pin 8 are held high by the SC32A (when
the RS-232 section is powered) which should
satisfy hardware handshake requirements of
the computer/terminal.
Table 6.2-4 lists the most common RS-232
configuration for Data Terminal Equipment.
SECTION 6. 9-PIN SERIAL INPUT/OUTPUT
TABLE 6.2-4. DTE Pin Configuration
PIN =25-pin connector number
ABR =Abbreviation for the function name
O=Signal Out of terminal to another device
I=Signal Into terminal from another device
PINABR
2TDOTransmitted Data: Data
3RDIReceived Data: Data is
4RTSORequest to Send: The
5CTSIClear to Send: The
20DTROData Terminal Ready:
6DSRIData Set Ready: The
8DCDIData Carrier Detect: The
22RIIRing Indicator: The
7SGSignal Ground: Voltages
I/OFUNCTION
is transmitted from the
terminal on this line.
received by the terminal
on this line.
terminal raises this line
to ask a receiving device
if the terminal can
transmit data.
receiving device raises
this line to let the
terminal know that the
receiving device is ready
to accept data.
The terminal raises this
line to tell the modem to
connect itself to the
telephone line.
modem raises this line to
tell the terminal that the
modem is connected to
the phone line.
modem raises this line to
tell the terminal that the
modem is receiving a
valid carrier signal from
the phone line.
modem raises this line to
tell the terminal that the
phone is ringing.
are measured relative to
this point.
6.2.6.3 COMMUNICATION
PROTOCOL/TROUBLE SHOOTING
The ASCII standard defines an alphabet
consisting of 128 different characters where
each character corresponds to a number, letter,
symbol, or control code.
An ASCII character is a binary digital code
composed of a combination of seven "bits", each
bit having a binary state of 1 (one) or 0 (zero).
For example, the binary equivalent for the ASCII
character "1" is 0110001 (decimal 49).
ASCII characters are transmitted one bit at a
time, starting with the 1st (least significant) bit.
During data transmission the marking condition
is used to denote the binary state 1, and the
spacing condition for the binary state 0. The
signal is considered marking when the voltage
is more negative than minus three volts with
respect to ground, and spacing when the
voltage is more positive than plus three volts.
Most computers use 8-bits (1 byte) for data
communications. The 8th bit is sometimes
used for a type of error checking called paritychecking. Even parity binary characters have
an even number of 1's, odd-parity characters
have an odd number of 1's. When parity
checking is used, the 8th bit is set to either a 1
or a 0 to make the parity of the character
correct. The CR23X ignores the 8th bit of a
character that is receives, and transmits the 8th
bit as a binary 0. This method is generally
described as "no parity".
To separate ASCII characters, a Start bit is sent
before the 1st bit and a Stop bit is sent after the
8th bit. The start bit is always a space, and the
stop bit is always a mark. Between characters
the signal is in the marking condition.
Figure 6.2-5 shows how the ASCII character "1"
is transmitted. When transmitted by the CR23X
using the SC32A RS-232 interface spacing and
marking voltages are positive and negative, as
shown. Signal voltages at the CS I/O port are
5V in the spacing condition, and 0V in the
marking condition.
6-7
SECTION 6. 9-PIN SERIAL INPUT/OUTPUT
FIGURE 6.2-5. Transmitting the ASCII Character 1
BAUD RATE
BAUD RATE is the number of bits transmitted
per second. The CR23X can communicate at
300, 1200, 4800, 9600, 19200, 38400, and
76800 baud. In the Telecommunications State,
the CR23X will set its baud rate to match the
baud rate of the computer/terminal. Some baud
rates, particularly those above 9600, may not be
supported by all CSI communications
equipment.
Typically the baud rate of the modem/computer/
terminal is set either with dip switches, or
programmed from the keyboard. The instrument's
instruction manual should explain how to set it.
DUPLEX
Full duplex means that two devices can
communicate in both directions simultaneously.
Half duplex means that the two devices must send
and receive alternately. Full duplex should always
be specified when communicating with Campbell
Scientific peripherals and modems. However,
communication between some Campbell Scientific
modems (such as the RF95 RF modem) is carried
out in a half duplex fashion. This can affect the
way commands should be sent to and received
from such a modem, especially when implemented
by computer software.
To overcome the limitations of half duplex,
some communications links expect a terminal
sending data to also write the data to the
screen. This saves the remote device having to
echo that data back. If, when communicating
with a Campbell Scientific device, characters
are displayed twice (in pairs), it is likely that the
terminal is set to half duplex rather than the
correct setting of full duplex.
IF NOTHING HAPPENS
If the CR23X is connected to the SC32A RS-
232 interface and a modem/terminal, and an "∗"
is not received after sending carriage returns:
1. Verify that the CR23X has power AT THE
12V AND GROUND INPUTS, and that the
cables connecting the devices are securely
connected.
2. Verify that the port of the modem/terminal is
an asynchronous serial communications
port configured as DTE (see Table 6.2-4).
The most common problems occur when
the user tries to use a parallel port, or
doesn't know the port assignments, i.e.
COM1 or COM2. IBM, and most
compatibles come with a Diagnostic disk
which can be used to identify ports, and
their assignments. If the serial port is
standard equipment, then the operators
manual should give you this information.
3. Verify that there is 5 volts between the
CR23X 5V and G terminals. Call Campbell
Scientific technical support if the voltage is
less than 4.8 volts.
Some serial ports, e.g., the Super Serial Card
for Apple computers, can be configured as DTE
or DCE with a jumper block. Pin functions must
match Table 6.2-4.
If you are using a computer to communicate
with the datalogger, communication software
must be used to enable the serial port and to
make the computer function as a terminal. The
port should be enabled for 300, 1200, or 9600
baud, 8 data bits, 1 stop bit, and no parity.
Campbell Scientific's PC208W provides this
function.
If you are not sure that your computer/terminal
is sending or receiving characters, there is a
simple way to verify it. Make sure that the
duplex is set to full. Next, take a paper clip and
connect one end to pin 2, and the other end to
pin 3 of the serial port. Each character typed on
the keyboard will be displayed only if
transmitted from the terminal on pin 2, and
received on pin 3 (if duplex is set to half, the
character will be displayed once if it is not
transmitted, or twice if it is transmitted).
6-8
SECTION 6. 9-PIN SERIAL INPUT/OUTPUT
IF GARBAGE APPEARS
If garbage characters appear on the display,
check that the baud rate is supported by the
CR23X. If the baud rate is correct, verify that
the computer/terminal is set for 8 data bits, and
no parity. Garbage will appear if 7 data bits and
no parity are used. If the computer/terminal is
set to 8 data bits and even or odd parity,
communication cannot be established.
6.3 USE OF INSTRUCTION 96
Instruction 96 is used for on-line data transfer to
peripherals (Section 4.1). Each peripheral
connected to the CR23X requires an Instruction
96 with the appropriate parameter. If the CR23X
is already communicating on the 9-pin connector
when Instruction 96 is executed, the instruction
puts the output request in a "queue" and program
execution continues. As the 9-pin connector
becomes available, each device in the queue will
get its turn until the queue is empty.
TABLE 6.3-1. CS I/O Pin Description
ABR =Abbreviation for the function name.
PIN=Pin number.
O=Signal Out of the CR23X to a
peripheral.
I=Signal Into the CR23X from a
peripheral.
PINABR
15 VO5V: Sources 5 VDC, used
2SGSignal Ground: Provides
3RINGIRing: Raised by a
4RXDIReceive Data: Serial
5MEOModem Enable: Raised
I/ODescription
to power peripherals.
a power return for pin 1
(5V), and is used as a
reference for voltage
levels.
peripheral to put the
CR23X in the
telecommunications
mode.
data transmitted by a
peripheral are received
on pin 4.
when the CR23X
determines that a
modem raised the ring
line.
Instruction 96 is aborted if a modem raises the Ring
line. Data transfer to an addressed peripheral is
aborted if the ring line is raised by an RF Modem
configured as a synchronous device. Transfer of
data is not resumed until the next time Instruction
96 is executed and the datalogger has exited
telecommunications.
The
8 Mode is used to manually initiate
data transfer from Final Storage to a peripheral.
An abort flag is set if any key on the CR23X or
terminal is pressed during the transfer. Data
transfer is stopped and the memory location
8
displayed when the flag is set. During
data transfer the abort flag is checked as
follows:
1. Comma separated ASCII - after every 32
characters.
2. Printable ASCII - after every line.
3. Binary - after every 256 Final Storage locations.
PINABR
I/ODescription
6SDEOSynchronous Device
Enable: Used to
address Synchronous
Devices (SDs), and can
be used as an enable
line for printers.
7CLK/HS I/OClock/Handshake: Used
with the SDE and TXD
lines to address and
transfer data to SDs.
When not used as a clock,
pin 7 can be used as a
handshake line (during
printer output, high
enables, low disables).
812 VO12 V: Sources 12 VDC,
used to power 12 VDC
peripherals.
9TXDOTransmit Data: Serial
data are transmitted
from the CR23X to
peripherals on pin 9;
logic low marking (0V)
logic high spacing (5V)
standard asynchronous
ASCII, 8 data bits, no
parity, 1 start bit, 1 stop
bit, 300, 1200, 9600,
76,800 baud (user
selectable).
6-9
SECTION 6. 9-PIN SERIAL INPUT/OUTPUT
This is a blank page.
6-10
SECTION 7. MEASUREMENT PROGRAMMING EXAMPLES
This section gives some examples of Input Programming for common sensors used with the CR23X.
These examples detail only the connections, Input, Program Control, and Processing Instructions
necessary to perform measurements and store the data in engineering units in Input Storage. Output
Processing Instructions are omitted. It is left for the user to program the necessary instructions to obtain
the final data in the form desired. NO OUTPUT TO FINAL STORAGE WILL TAKE PLACE WITHOUT
ADDITIONAL PROGRAMMING.
The examples given in this section would likely be only fragments of larger programs. In general, the
examples are written with the measurements made by the lowest numbered channels, the
instructions at the beginning of the program table, and low number Input Storage locations used to
store the data. It is unlikely that an application and CR23X configuration exactly duplicates that
assumed in an example. THESE EXAMPLES ARE NOT MEANT TO BE USED VERBATIM;
SENSOR CALIBRATION AND INPUT LOCATIONS SELECTED MUST BE ADJUSTED FOR THE
ACTUAL CIRCUMSTANCES. UNLESS OTHERWISE NOTED, ALL EXCITATION CHANNELS ARE
SWITCHED ANALOG OUTPUT.
7.1 SINGLE-ENDED VOLTAGE/
SWITCHED 12 V TERMINAL - CS500
The CS500 is a modified Vaisala 50Y Humitter
temperature and relative humidity sensor. It
has high level linear output of 0 to 1 V for the
temperature range of -40° to +60°C and relative
humidity of 0 to 100%. It is measured with
Instruction 1 (Volts SE). The multiplier for
temperature is found with the following
relationship [60°C - (-40°C)] / [1000 mV - 0 mV]
= 0.1°C/mV. The offset is -40°C. The multiplier
for relative humidity is [100 % - 0 %] / [1000 mV
- 0 mV] = 0.1 %/mV and the offset is 0 %. The
CS500 is powered by the CR23X’s 12 V battery
and draws <2 mA of current while on. Battery
power can be conserved by turning the CS500
on just prior to making the measurement and
turning it off after the measurement is
completed. This is done with the Switched 12 V
terminal on the CR23X wiring panel.
CONNECTIONS
The CS500 output is measured using two
single-ended voltage measurements on analog
inputs 5 and 6. Single-ended analog inputs are
labeled in blue on the CR23X wiring panel. A
wiring diagram on connections between the
CR23X and the CS500 is given in Figure 7.1-1.
CAUTION: The Switched 12 V Control
terminal will be permanently damaged if 12
V is applied to it. Do not connect 12 V to
the Switched 12 V Control terminal.
PROGRAM
;Turn CS500 on.
;
01:Do (P86)
1: 49Set Switched 12 V High
;Allow CS500 to warm up and stabilize on
;the Temperature and Relative Humidity.
;
02:Excitation with Delay (P22)
1:3Ex Channel
2:0Delay W/Ex (units = 0.01 sec)
3: 10Delay After Ex (units = 0.01 sec)
4:0mV Excitation
Rejection Range
3:6SE Channel
4:2Loc [ RH_pct ]
5:.1Mult
6:0Offset
CR23X
SE 5
SE 6
SWITCHED 12V
G
;Turn CS500 off.
;
05:Do (P86)
1: 59Set Switched 12 V Low
INPUT LOCATIONS
1 Temp_C
2 RH_pct
Temperature (Black)
Relative Humidity (Brown)
12 V (Red)
Power Ground (Green)
Shield (Clear)
FIGURE 7.1-1. Wiring Diagram for CS500
CS500
CR23X
FIGURE 7.1-2. Typical Connection for Active Sensor with External Battery
7-2
SECTION 7. MEASUREMENT PROGRAMMING EXAMPLES
7.2 DIFFERENTIAL VOLTAGE
MEASUREMENT
Some sensors either contain or require active
signal conditioning circuitry to provide an easily
measured analog voltage output. Generally, the
output is referenced to the sensor ground. The
associated current drain usually requires a
power source external to the CR23X. A typical
connection scheme where AC power is not
available and both the CR23X and sensor are
powered by an external battery is shown in
Figure 7.2-1. Since a single-ended
measurement is referenced to the CR23X
ground, any voltage difference between the
sensor ground and CR23X ground becomes a
measurement error. A differential measurement
avoids this error by measuring the signal
between the 2 leads without reference to ground.
This example analyzes the potential error on a
differential CO
CO
The wire used to supply power from the external
battery is 18 AWG with an average resistance of
6.5 ohms/1000 ft. The power leads to the CR23X
and LI-6262 are 2 ft and 10 ft, respectively.
Typical current drain for the LI-6262 is 1000 mA.
When making measurements, the CR23X draws
about 35 mA. Since voltage is equal to current
multiplied by resistance (V=IR), ground voltages
at the LI-6262 and the CR23X relative to battery
ground are:
Ground at the LI-6262 is 0.065 V higher than ground
at the CR23X. The LI-6262 can be programmed to
output a linear voltage (0 to 100 mV) that is
proportional to differential CO
scale, or 1 µmol/mol/mV. If the output is measured
with a single-ended voltage measurement, it is
0.065 V or 65 µmol/mol high. If this offset remained
constant, it could be corrected in programming.
However, it is better to use a differential voltage
measurement which does not rely on the current
drain remaining constant. The program that follows
illustrates the use of Instruction 2 to make the
measurement. A multiplier of 1 is used to convert
the millivolt output into µmol/mol.
O analyzer, model LI-6262.
2/H2
1A ∗ 6.5 ohms/1000 ft ∗ 10 ft = +0.065 V
0.035A ∗ 6.5 ohms/1000 ft ∗ 2 ft = +0.0005 V
measurement using a LI-COR
2
LI-6262 ground =
CR23X ground =
, 100 µmol/mol full
2
PROGRAM
01:Volt (Diff) (P2)
1:1Reps
2: 23±200 mV 60 Hz Rejection
Range
3:1DIFF Channel
4:1Loc [ umol_mol ]
5:1Mult
6:0Offset
7.3 THERMOCOUPLE TEMPERATURES
USING CR23X REFERENCE
The use of the built in CR23X thermocouple
reference thermistor is described in the
introductory programming example (Section
OV4).
7.4 THERMOCOUPLE TEMPERATURES
USING AN EXTERNAL REFERENCE
JUNCTION
When a number of thermocouple measurements
are made at some distance from the CR23X, it is
often better to use a reference junction box
located at the site rather than using the CR23X
panel for the reference junction. This reduces
the required length of expensive thermocouple
wire as regular copper wire can be used
between the junction box (J-box) and CR23X. In
addition, if the temperature gradient between the
J-box and the thermocouple measurement
junction is smaller than the gradient between the
CR23X and the measurement junction,
thermocouple accuracy is improved. In the
following example, an external reference
junction is used on 5 thermocouple
measurements. A Campbell Scientific 107
Temperature Probe is used to measure the
reference temperature. The connection scheme
is shown in Figure 7.4-1.
CR23X
FIGURE 7.4-1. Thermocouples with External
Reference Junction
7-3
SECTION 7. MEASUREMENT PROGRAMMING EXAMPLES
The temperature of the 107 Probe is stored in
input location 1 and the thermocouple
temperatures in Locations 2-6.
Range
3:1DIFF Channel
4:1Type T (Copper-Constantan)
5:1Ref Temp (Deg. C) Loc [
REF_TEMP ]
6:2Loc [ TC_1 ]
7:1.0Mult
8:0.0Offset
7.5 107 TEMPERATURE PROBE
Instruction 11 is designed to excite and measure
the Campbell Scientific 107 Thermistor Probe
(or the thermistor portion of the 207 temperature
and relative humidity probe) and convert the
measurement into temperature (
example, temperatures are obtained from three
107 probes. The measurements are made on
single-ended channels 1-3, and the
temperatures are stored in input locations 1-3.
o
C). In this
7.6 ANEMOMETER WITH
PHOTOCHOPPER OUTPUT
An anemometer with a photochopper transducer
produces a pulsed output which is monitored
with the Pulse Count Instruction, configured for
High Frequency Pulses. The anemometer used
in this example is the R.M. Young Model No.
12102D Cup Anemometer which has a 10
window chopper wheel. The photochopper
circuitry is powered from the CR23X 12V supply.
Supplemental charging, AC or solar, should be
used with the CR23X. If a charging source is not
practical, back-up batteries should be used to
compensate for the increased current drain.
Wind speed is desired in meters per second.
There is a pulse each time a window in the
chopper wheel, which revolves with the cups,
allows light to pass from the source to the
photoreceptor. Because there are 10 windows
in the chopper wheel, there are 10 pulses per
revolution. Thus, 1 rpm is equal to 10 pulses
per 60 seconds (1 minute) or 6 rpm = 1 pulse
per second. The manufacturer's calibration for
relating wind speed to rpm is:
Wind speed (m/s) =
0.01632 m/s/rpm x rpm + 0.2 m/s
Pulse count instruction has the option of
converting counts to frequency in Hz
(counts/second). The multiplier and offset to
convert Hz to meters per second are:
m/s =
0.01632 m/s/rpm x 6 rpm/Hz x XHz + 0.2 m/s
CONNECTIONS
The black leads from the probes go to excitation
channel 1, the purple and clear leads go to a
channel, and the red leads go to single- ended
channels 1, 2, and 3 (high and low sides of
differential channel 1 and high side of 2).
A tipping bucket rain gauge is measured with
the Pulse Count Instruction configured for Switch
Closure. Counts from long intervals will be used
(an option in Parameter 3), as the final output
desired is total rainfall (obtained with Instruction
72, Totalize). If counts from long intervals were
discarded, less rainfall would be recorded than
was actually measured by the gauge (assuming
there were counts in the long intervals). Output
is desired in millimeters of precipitation. The
gauge is calibrated for a 0.01 inch tip; a
multiplier of 0.254 is used.
CR23X
FIGURE 7.7-1. Wiring Diagram for Rain
Gauge with Long Leads
In a long cable there is appreciable capacitance
between the lines, which is discharged across
the switch when it closes. In addition to
shortening switch life, a transient may be
induced in other wires, packaged with the rain
gauge leads, each time the switch closes. The
100 ohm resistor protects the switch from arcing
and the associated transient from occurring, and
should be included any time leads longer than
100 feet are used with a switch closure.
Instruction 9 is the best choice for accuracy
where a 100 ohm Platinum Resistance
Thermometer (PRT) is separated from other
bridge completion resistors by a lead length
having more than a few thousandths of an ohm
resistance. In this example, it is desired to
measure a temperature in the range of -10 to
o
C. The length of the cable from the CR23X
40
to the PRT is 500 feet.
CR23X
FIGURE 7.8-1. Wiring Diagram for PRT in 4
Wire Half Bridge
Figure 7.8-1 diagrams the circuit used to
measure the PRT. The 10 kohm resistor allows
the use of a high excitation voltage and a low
input range. This insures that noise in the
excitation does not have an effect on signal
noise. Because the fixed resistor (R
PRT (R
) have approximately the same
s
resistance, the differential measurement of the
voltage drop across the PRT can be made on
the same range as the differential measurement
of the voltage drop across R
. The use of the
f
same range eliminates any range translation
error that might arise from the 0.01% tolerance
of the range translation resistors in the CR23X.
If the voltage drop across the PRT (V
on the 50mV range, self heating of the PRT
o
should be less than 0.001
C in still air. The
resolution of the measurement is increased as
the excitation voltage (V
) is increased as long
x
as the Input Range is not exceeded. The
voltage drop across the PRT is equal to V
multiplied by the ratio of Rs to the total
resistance, and is greatest when R
=115.54 ohms at 40oC). To find the
(R
s
maximum excitation voltage that can be used,
we assume V
equal to 50mV and use Ohm's
2
Law to solve for the resulting current, I.
) and the
f
) is kept
2
is greatest
s
x
7-5
SECTION 7. MEASUREMENT PROGRAMMING EXAMPLES
I = 50mV/Rs = 50mV/115. 54 ohms = 0.433mA
Next solve for V
:
x
V
= I(R1+Rs+Rf) = 4.42V
x
If the actual resistances were the nominal
values, the CR23X would not overrange with V
= 4.4V. To allow for the tolerances in the actual
resistances, it is decided to set V
equal to 4.2
x
volts (e.g., if the 10 kohms resistor is 5% low,
/(R1+Rs+Rf)=115.54/9715.54, and Vx must be
R
s
4.204V to keep V
less than 50mV).
s
The result of Instruction 9 when the first
differential measurement (V
the 5V range is equivalent to R
16 computes the temperature (
) is not made on
1
. Instruction
s/Rf
o
C) for a DIN
43760 standard PRT from the ratio of the PRT
o
resistance to its resistance at 0
Thus, a multiplier of R
f/R0
9 to obtain the desired intermediate, R
C (Rs/R0).
is used in Instruction
s/R0
(=Rs/Rf x Rf/Ro). If Rs and R0 were each
exactly 100 ohms, the multiplier would be 1.
However, neither resistance is likely to be exact.
The correct multiplier is found by connecting the
PRT to the CR23X and entering Instruction 9
with a multiplier of 1. The PRT is then placed in
o
an ice bath (0
bridge measurement is read using the
C; Rs=R0), and the result of the
6
Mode. The reading is Rs/Rf, which is equal to
since Rs=Ro. The correct value of the
R
o/Rf
multiplier, R
, is the reciprocal of this
f/R0
reading. The initial reading assumed for this
example was 0.9890. The correct multiplier is:
The temperature measurement requirements in
this example are the same as in Section 7.9. In
this case, a three wire half bridge, Instruction 7,
is used to measure the resistance of the PRT.
The diagram of the PRT circuit is shown in
Figure 7.9-1.
CR23X
The fixed 100 ohm resistor must be thermally
stable. Its precision is not important because
the exact resistance is incorporated, along with
that of the PRT, into the calibrated multiplier.
o
The 10 ppm/
C temperature coefficient of the
fixed resistor will limit the error due to its change
in resistance with temperature to less than
o
C over the -10 to 40oC temperature range.
0.15
Because the measurement is ratiometric (R
s/Rf
the properties of the 10 kohm resistor do not
affect the result.
A terminal input module (Model 4WPB100) can
be used to complete the circuit shown in Figure
7.8-1.
7-6
FIGURE 7.9-1. 3 Wire Half Bridge Used to
Measure 100 ohm PRT
As in the example in Section 7.8, the excitation
),
voltage is calculated to be the maximum
possible, yet allow the +50mV measurement
range. The 10 kohm resistor has a tolerance of
±1%; thus, the lowest resistance to expect from
it is 9.9 kohms. We calculate the maximum
excitation voltage (V
) to keep the voltage drop
x
across the PRT less than 50mV:
0.050V > V
115.54/(9900+115.54); Vx < 4.33V
x
The excitation voltage used is 4.3V.
SECTION 7. MEASUREMENT PROGRAMMING EXAMPLES
The multiplier used in Instruction 7 is determined
in the same manner as in Section 7.8. In this
example, the multiplier (R
) is assumed to be
f/R0
100.93.
The 3 wire half bridge compensates for lead wire
resistance by assuming that the resistance of
wire A is the same as the resistance of wire B.
The maximum difference expected in wire
resistance is 2%, but is more likely to be on the
order of 1%. The resistance of R
with Instruction 7, is actually R
calculated
s
plus the
s
difference in resistance of wires A and B. The
average resistance of 22 AWG wire is 16.5
ohms per 1000 feet, which would give each 500
foot lead wire a nominal resistance of 8.3 ohms.
Two percent of 8.3 ohms is 0.17 ohms.
Assuming that the greater resistance is in wire B,
the resistance measured for the PRT (R
=
0
100 ohms) in the ice bath would be 100.17
o
ohms, and the resistance at 40
115.71. The measured ratio R
C would be
is 1.1551;
s/R0
the actual ratio is 115.54/100 = 1.1554. The
temperature computed by Instruction 16 from
o
the measured ratio would be about 0.1
C lower
than the actual temperature of the PRT. This
source of error does not exist in the example in
Section 7.8, where a 4 wire half bridge is used to
measure PRT resistance.
This example describes obtaining the
temperature from a 100 ohm PRT in a 4 wire
full bridge (Instruction 6). The temperature
being measured is in a constant temperature
bath and is to be used as the input for a control
algorithm. The PRT in this case does not
adhere to the DIN standard (alpha = 0.00385)
used in the temperature calculating Instruction
16. Alpha is defined as (R
and R0 are the resistances of the PRT at
R
100
o
C and 0oC, respectively. In this PRT,
100
alpha is equal to 0.00392.
CR23X
100/R0
-1)/100, where
The advantages of the 3 wire half bridge are that
it only requires 3 lead wires going to the sensor
and takes 2 single- ended input channels,
whereas the 4 wire half bridge requires 4 wires
and 2 differential channels.
A terminal input module (Model 3WHB10K) can
be used to complete the circuit in Figure 7.9-1. It
uses a ±0.01% ±8 ppm precision resistor.
PROGRAM
1: 3W Half Bridge (P7)
1:1Reps
2:2250 mV, 60 Hz Reject, Slow
Range
3:1SE Channel
4:1Excite all reps w/Exchan 1
5:4300mV Excitation
6:1Loc [ Rs_Ro ]
7:100.93Mult
8:0.0Offset
FIGURE 7.10-1. Full Bridge Schematic for
100 ohm PRT
The result (X) given by Instruction 6 is 1000
(where Vs is the measured bridge output
V
s/Vx
voltage, and V
is the excitation voltage) which
x
is:
X = 1000 (R
The resistance of the PRT (R
/(Rs+R1)-R3/(R2+R3))
s
) is calculated
s
with the Bridge Transform Instruction 59:
= R1 X'/(1-X')
R
s
Where
X' = X/1000 + R
Thus, to obtain the value R
o
C) for the temperature calculating Instruction
0
/(R2+R3)
3
, (R0 = Rs @
s/R0
16, the multiplier and offset used in Instruction 6
are 0.001 and R
multiplier used in Instruction 59 to obtain R
/(R2+R3), respectively. The
3
s/R0
is R1/R0 (5000/100 = 50).
7-7
SECTION 7. MEASUREMENT PROGRAMMING EXAMPLES
It is desired to control the temperature bath at
o
C with as little variation as possible. High
50
resolution is desired so the control algorithm will
be able to respond to minute changes in
temperature. The highest resolution is obtained
when the temperature range results in an output
voltage (V
) range which fills the measurement
s
range selected in Instruction 6. The full bridge
configuration allows the bridge to be balanced
= 0V) at or near the control temperature.
(V
s
Thus, the output voltage can go both positive
and negative as the bath temperature changes,
allowing the full use of the measurement range.
The resistance of the PRT is approximately
o
119.7 ohms at 50
C. The 120 ohm fixed
resistor balances the bridge at approximately
o
C. The output voltage is:
51
V
= Vx [Rs/(Rs+R1) - R3/(R2+R3)]
s
[Rs/(Rs+5000) - 0.023438]
= V
x
The temperature range to be covered is 50
o
±10
C. At 40oC Rs is approximately 115.8
ohms, or:
= -802.24x10-6 V
V
s
x
PROGRAM
1: Full Bridge (P6)
1:1Reps
2:2110 mV, 60 Hz Reject, Slow
Range
3:3DIFF Channel
4:1Excite all reps w/Exchan 1
5:5000mV Excitation
6:1Loc [ Rs_Ro ]
7:.001Mult
8:.02344 Offset
2: BR Transform Rf[X/(1-X)] (P59)
1:1Reps
2:1Loc [ Rs_Ro ]
3:50Multiplier (Rf)
3: Temperature RTD (P16)
1:1Reps
2:1R/R0 Loc [ Rs_Ro ]
3:2Loc [ TEMP_degC ]
4:.98214 Mult
5:0.0Offset
7.11 PRESSURE TRANSDUCER - 4
WIRE FULL BRIDGE
even with an excitation voltage (Vx) equal to
5000mV, V
scale (40
can be measured on the ±10mV
s
o
C = 115.8 Ω = -4.01mV, 60oC = 123.6
Ω = 3.428mV). There is a change of
o
approximately 4mV from the output at 40
o
the output at 51
C, or 364µV/oC. With a
C to
resolution of 0.33µV on the ±10mV range, this
means that the temperature resolution is
o
0.0009
The ±5 ppm per
C.
o
C temperature coefficient of
the fixed resistors was chosen so that their
±0.01% accuracy tolerance would hold over the
desired temperature range.
The relationship between temperature and PRT
resistance is a slightly nonlinear one. Instruction
16 computes this relationship for a DIN standard
PRT where the nominal temperature coefficient
o
is 0.00385/
C. The change in nonlinearity of a
PRT with the temperature coefficient of
o
0.00392/
C is minute compared with the slope
change. Entering a slope correction factor of
0.00385/0.00392 = 0.98214 as the multiplier in
Instruction 16 results in a calculated
temperature which is well within the accuracy
specifications of the PRT.
This example describes a measurement made
with a Druck PDCR 10/D depth measurement
pressure transducer. The pressure transducer
was ordered with passive temperature
compensation for use with positive or negative
excitation and has a range of 5 psi or about 3.5
meters of water. The transducer is used to
measure the depth of water in a stilling well.
Instruction 6, 4 Wire Full Bridge, is used to
measure the pressure transducer. The high
output of the semiconductor strain gauge
necessitates the use of the ±50mV input range.
The sensor is calibrated by connecting it to the
CR23X and using Instruction 6 with a multiplier
of 1 and an offset of 0, noting the readings
6 Mode) with 10 cm of water above the
(
sensor and with 334.6 cm of water above the
sensor. The output of Instruction 6 is 1000 V
s/Vx
or millivolts per volt excitation. At 10 cm the
reading is 0.19963mV/V and at 334.6 cm the
reading is 6.6485mV/V. The multiplier to yield
output in cm is:
(334.6 - 10)/(6.6485-.19963) = 50.334 cm/mV/V
7-8
SECTION 7. MEASUREMENT PROGRAMMING EXAMPLES
The offset is determined after the pressure
transducer is installed in the stilling well. The
sensor is installed 65 cm below the water level
at the time of installation. The depth of water at
this time is determined to be 72.6 cm relative to
the desired reference. When programmed with
the multiplier determined above and an offset of
0, a reading of 65.12 is obtained. The offset for
the actual measurements is thus determined to
be 72.6 - 65.12 = 7.48 cm.
The lead length is approximately 10 feet, so
there is no appreciable error due to lead wire
resistance. Example 7.13 shows a means of
compensating for long lead lengths.
CR23X
one would encounter if the actual excitation
voltage was not measured and shows the use
of a 6 wire full bridge to measure a load cell on
a weighing lysimeter (a container buried in the
ground, filled with plants and soil, used for
measuring evapotranspiration).
The lysimeter is 2 meters in diameter and 1.5
meters deep. The total weight of the lysimeter
with its container is approximately 8000 kg. The
lysimeter has a mechanically adjustable
counterbalance, and changes in weight are
measured with a 250 pound (113.6 kg) capacity
Sensotec Model 41 tension/compression load
cell. The load cell has a 4:1 mechanical
advantage on the lysimeter (i.e., a change of 4
kg in the mass of the lysimeter will change the
force on the load cell by 1 kg-force or 980 N).
FIGURE 7.11-1. Wiring Diagram for Full
Bridge Pressure Transducer
PROGRAM
1: Full Bridge (P6)
1:1Reps
2:2250 mV, 60 Hz Reject, Slow
Range
3:1DIFF Channel
4:1Excite all reps w/Exchan 1
5:5000mV Excitation
6:1Loc [ WATER_cm ]
7:50.334Mult
8:7.48Offset
7.12 LYSIMETER - 6 WIRE FULL
BRIDGE
When a long cable is required between a load
cell and the CR23X, the resistance of the wire
can create a substantial error in the
measurement if the 4 wire full bridge
(Instruction 6) is used to excite and measure
the load cell. This error arises because the
excitation voltage is lower at the load cell than
at the CR23X due to voltage drop in the cable.
The 6 wire full bridge (Instruction 9) avoids this
problem by measuring the excitation voltage at
the load cell. This example shows the errors
FIGURE 7.12-1. Lysimeter Weighing
Mechanism
The surface area of the lysimeter is 3.1416 m
2
or 31,416 cm2, so 1 cm of rainfall or evaporation
results in a 31.416 kg change in mass. The load
cell can measure ±113.6 kg, a 227 kg range.
This represents a maximum change of 909 kg
(28 cm of water) in the lysimeter before the
counterbalance would have to be readjusted.
There is 1000 feet of 22 AWG cable between
the CR23X and the load cell. The output of the
load cell is directly proportional to the excitation
voltage. When Instruction 6 (4 wire half bridge)
is used, the assumption is that the voltage drop
in the connecting cable is negligible. The
average resistance of 22 AWG wire is 16.5
ohms per 1000 feet. Thus, the resistance in the
excitation lead going out to the load cell added
to that in the lead coming back to ground is 33
ohms. The resistance of the bridge in the load
cell is 350 ohms. The voltage drop across the
load cell is equal to the voltage at the CR23X
multiplied by the ratio of the load cell resistance,
, to the total resistance, RT, of the circuit. If
R
s
Instruction 6 were used to measure the load
7-9
SECTION 7. MEASUREMENT PROGRAMMING EXAMPLES
cell, the excitation voltage actually applied to
the load cell, V
V1 = V
would be:
1
Rs/RT = Vx 350/(350+33) = 0.91 V
x
x
Where Vx is the excitation voltage. This means
that the voltage output by the load cell would
only be 91% of that expected. If recording of
the lysimeter data was initiated with the load cell
output at 0 volts, and 100mm of
evapotranspiration had occurred, calculation of
the change with Instruction 6 would indicate that
only 91mm of water had been lost. Because the
error is a fixed percentage of the output, the
actual magnitude of the error increases with the
force applied to the load cell. If the resistance of
the wire was constant, one could correct for the
voltage drop with a fixed multiplier. However,
the resistance of copper changes 0.4% per
degree C change in temperature. Assume that
the cable between the load cell and the CR23X
o
lays on the soil surface and undergoes a 25
C
diurnal temperature fluctuation. If the resistance
is 33 ohms at the maximum temperature, then at
the minimum temperature, the resistance is:
(1-25x0.004)33 ohms = 29.7 ohms
The actual excitation voltage at the load cell is:
= 350/(350+29.7) Vx = .92 V
V
1
x
The excitation voltage has increased by 1%,
relative to the voltage applied at the CR23X. In
this case, where we were recording a 91mm
change in water content, there would be a 1mm
diurnal change in the recorded water content that
would actually be due to the change in
temperature. Instruction 9 solves this problem
by actually measuring the voltage drop across
the load cell bridge. The drawbacks to using
Instruction 9 are that it requires an extra
differential channel and the added expense of a
6 wire cable. In this case, the benefits are worth
the expense.
The load cell has a nominal full scale output of 3
millivolts per volt excitation. If the excitation is
3.3 volts, the full scale output is 9.9 millivolts;
thus, the ±10 millivolt range is selected. The
calibrated output of the load cell is 3.106mV/V1
at a load of 250 pounds. Output is desired in
millimeters of water with respect to a fixed point.
The calibration in mV/V1/mm is:
3.106mV/V
/250lb x 2.2lb/kg x
1
3.1416kg/mm/4 =
0.02147mV/V
/mm
1
The reciprocal of this gives the multiplier to
convert mV/V1 into millimeters. (The result of
Instruction 9 is the ratio of the output voltage to
the actual excitation voltage multiplied by 1000,
which is mV/V1):
1/0.02147mV/V
/mm = 46.583mm/mV/V
1
1
The output from the load cell is connected so
that the voltage increases as the mass of the
lysimeter increases. (If the actual mechanical
linkage was as diagrammed in Figure 7.12-1,
the output voltage would be positive when the
load cell was under tension.)
When the experiment is started, the water
content of the soil in the lysimeter is
approximately 25% on a volume basis. It is
decided to use this as the reference, (i.e., 0.25 x
1500mm = 375 mm). The experiment is started
at the beginning of what is expected to be a
period during which evapotranspiration exceeds
precipitation. Instruction 9 is programmed with
the correct multiplier and no offset. After
hooking everything up, the counterbalance is
adjusted so that the load cell is near the top of
its range; this will allow a longer period before
readjustment is necessary. The result of
Instruction 9 (monitored with the
6 Mode)
is 109. The offset needed to give the desired
initial value of 375mm is 266. However, it is
decided to add this offset in a separate
instruction so that the result of Instruction 9 can
be used as a ready reminder of the strain on the
load cell (range = ±140mm). When the strain on
the load cell nears its rated limits, the
counterbalance is readjusted and the offset
recalculated to provide a continuous record of
the water budget.
The program table has an execution interval of
10 seconds. The average value in millimeters
is output to Final Storage (not shown in Table)
every hour. The average is used, instead of a
sample, in order to cancel out the effects of
wind loading on the lysimeter.
7-10
SECTION 7. MEASUREMENT PROGRAMMING EXAMPLES
CR23X
FIGURE 7.12-2. 6 Wire Full Bridge
Connection for Load Cell
PROGRAM
1: Full Bridge w/mv Excit (P9)
1:1Reps
2:255000 mV, 60 Hz Reject,
Fast, Ex Range
3:2110 mV, 60 Hz Reject, Slow,
Br Range
4:1DIFF Channel
5:1Excite all reps w/Exchan 1
6:3300mV Excitation
7:1Loc [ RAW_MEAS ]
8:46.583Mult
9:0.0Offset
2: Z=X+F (P34)
1:1X Loc [ RAW_MEAS ]
2:266F
3:2Z Loc [ MEAS_OFFS ]
coefficients for a 5th order polynomial to convert
block resistance to water potential in bars.
There are two polynomials: one to optimize the
range from -0.1 to -2 bars, and one to cover the
range from -0.1 to -10 bars (the minus sign is
omitted in the output). The -0.1 to -2 bar
polynomial requires a multiplier of 1 in the
Bridge Transform Instruction (result in kohms)
and the -0.1 to -10 bar polynomial requires a
multiplier of 0.1 (result in 10,000s of ohms). The
multiplier is a scaling factor to maintain the
maximum number of significant digits in the
coefficients of the polynomial.
In this example, we wish to make
measurements on 6 gypsum blocks and output
the final data in bars. The soil where the
moisture measurements are to be made is quite
wet at the time the data logging is initiated, but
is expected to dry beyond the -2 bar limit of the
wet range polynomial. The dry range polynomial
is used, so a multiplier of 0.1 is entered in the
bridge transform instruction.
When the water potential is computed, it is
written over the resistance value. The potentials
are stored in input locations 1-6 where they may
be accessed for output to Final Storage. If it
was desired to retain the resistance values, the
potential measurements could be stored in
Locations 7-12 by changing Parameter 3 in
Instruction 55 to 7.
7.13 227 GYPSUM SOIL MOISTURE
BLOCK
Soil moisture is measured with a gypsum block
by relating the change in moisture to the change
in resistance of the block. An AC Half Bridge
(Instruction 5) is used to determine the
resistance of the gypsum block. Rapid reversal
of the excitation voltage inhibits polarization of
the sensor. Polarization creates an error in the
output so the fast integration time is used. The
output of Instruction 5 is the ratio of the output
voltage to the excitation voltage; this output is
converted to gypsum block resistance with
Instruction 59, Bridge Transform.
The Campbell Scientific 227 Soil Moisture Block
uses a Delmhorst gypsum block with a 1 kohm
bridge completion resistor (there are also series
capacitors to block DC current and degradation
due to electrolysis. Using data supplied by
Delmhorst, Campbell Scientific has computed
CR23X
FIGURE 7.13-1. 6 Gypsum Blocks
Connected to the CR23X
PROGRAM
1: AC Half Bridge (P5)
1:6Reps
2:141000 mV, Fast Range
3:1SE Channel
4:1Excite all reps w/Exchan 1
5:1000mV Excitation
6:1Loc [ Vs_Vx_1 ]
7:1.0Mult
8:0.0Offset
7-11
SECTION 7. MEASUREMENT PROGRAMMING EXAMPLES
2: BR Transform Rf[X/(1-X)] (P59)
1:6Reps
2:1Loc [ Vs_Vx_1 ]
3:.1Multiplier (Rf)
3: Polynomial (P55)
1:6Reps
2:1X Loc [ Vs_Vx_1 ]
3:1F(X) Loc [ Vs_Vx_1 ]
4:.15836 C0
5:6.1445C1
6:-8.4189C2
7:9.2493C3
8:-3.1685C4
9:.33392 C5
7.14 NONLINEAR THERMISTOR IN
HALF BRIDGE (CAMPBELL
SCIENTIFIC MODEL 101)
Instruction 11, 107 Thermistor Probe,
automatically calculates temperature by
transforming the millivolt reading with a 5th order
polynomial. Instruction 55, Polynomial, can be
used to calculate temperature of any nonlinear
thermistor, provided the correlation between
temperature and probe output is known, and an
appropriate polynomial fit has been determined.
In this example, the CR23X is used to measure
the temperature of 5 Campbell Scientific 101
Probes (used with the CR21). Instruction 4,
Excite, Delay, and Measure, is used because the
high source resistance of the probe requires a
long input settling time (see Section 13.3.1).
The signal voltage is then transformed to
temperature using the Polynomial Instruction.
The manual for the 101 Probe gives the
coefficients of the 5th order polynomial used to
convert the output in millivolts to temperature (E
denotes the power of 10 by which the mantissa
is multiplied):
The CR23X will only allow 5 significant digits to
the right or left of the decimal point to be entered
from the keyboard. The polynomial cannot be
applied exactly as given in the 101 manual. The
initial millivolt reading must be scaled if the
coefficients of the higher order terms are to be
entered with the maximum number of significant
digits. If 0.001 is used as a multiplier on the
millivolt output, the coefficients are divided by
0.001 raised to the appropriate power (i.e.,
C0=C0, C1=C1/0.001, C2=C2/.000001, etc.).
With this adjustment, the coefficients entered in
Parameters 4-9 of Instruction 55 become: