5 sdm-a04 analog output multiplexer to strip chart – Campbell Scientific CR23X Micrologger User Manual
Page 336

TD ADDENDUM—SECTION 8. PROCESSING AND PROGRAM CONTROL EXAMPLES
AD-8-6
8.5 SDM-A04 ANALOG OUTPUT
MULTIPLEXER TO STRIP CHART
This example illustrates the use of the SDM-
A04 4 Channel Analog Output Multiplexer to
output 4 analog voltages to strip chart.
While of questionable value because of current
requirements and strip chart reliability, some
archaic regulations require strip chart backup on
weather data. The SDM-A04 may be used with
the CR10 to provide analog outputs to strip charts.
The output values in this example are wind speed,
wind direction, air temperature, and solar radiation.
Instruction 103 is used to activate the SDM-
A04. The 4 millivolt values to output must be
stored in adjacent Input Storage locations, the
first of which is referenced in Instruction 103.
The following program measures the sensors
every 5 seconds. The readings are moved to
another 4 locations and scaled to a 0 to 1000
millivolt output for the SDM-A04. Wind direction
is changed from a 0-360 degree input to output
representing 0 to 540 degrees. This conversion
is done in a subroutine which is described in the
next example.
The example also includes instructions to
output wind vector and average temperature
and solar radiation every hour.
Input Location Labels:
1:WS
2: WD_360
3:TEMP_F
4:Solar_Rad
5:WS_output
6:WD540_out
7:TEMP_out
8:SR_out
10:WD_540
*
1
Table 1 Programs
01:
5
Sec. Execution Interval
01:
P3
Pulse
01:
1
Rep
02:
1
Pulse Input Chan
03:
22
Switch closure; Output Hz.
04:
1
Loc [:WS ]
05:
1.789
Mult
06:
1
Offset
02:
P4
Excite,Delay,Volt(SE)
01:
1
Rep
02:
14
250 mV fast Range
03:
1
IN Chan
04:
1
Excite all reps w/EXchan 1
05:
5
Delay (units .01sec)
06: 1000
mV Excitation
07:
2
Loc [:WD_360 ]
08:
.7273
Mult
09:
0
Offset
03:
P11
Temp 107 Probe
01:
1
Rep
02:
2
IN Chan
03:
2
Excite all reps w/EXchan 2
04:
3
Loc [:Temp_F ]
05:
1.8
Mult
06:
32
Offset
04:
P1
Volt (SE)
01:
1
Rep
02:
2
7.5 mV slow Range
03:
3
IN Chan
04:
4
Loc [:Solar_Rad]
05:
.14493 Mult
06:
0
Offset
05:
P54
Block Move
01:
4
No. of Values
02:
1
First Source Loc WS
03:
1
Source Step
04:
5
First Destination Loc
[:WS_output]
05:
1
Destination Step
06:
P86
Do
01:
1
Call Subroutine 1
07:
P53
Scaling Array (A*loc +B)
01:
5
Start Loc [:WS_output]
02:
10
A1 Scale WS, 0-100 MPH
= 0-1000 MV
03:
0
B1
04:
1.8519
A2 Scale WD, 0-540 DEG
= 0-1000 MV
05:
0
B2
06:
5.7143
A3 Scale TEMP, -25 - 100
F = 0-1000 MV
07:
25
B3
08: 1000
A4 Scale RADIATION, 0-
1KW/M^2 = 0-1000 MV
09:
0
B4
08:
P103
SDM-A04
01:
4
Reps
02:
30
Address
03:
5
Loc WS_output
09:
P84
Data Table
01:
0
Seconds into interval
02: 3600
Seconds interval
03:
0
Records (0=auto; -=redirect)