Campbell Hausfeld SDM-CD16AC Network Card User Manual


 
SDM-CD16AC 16 Channel AC/DC Controller
'Dimension Variables
Public src(32)
Dim i, count, mask(16)
'Program
BeginProg
for i=1 to 16
mask(i) = 2^(i-1)
next i
Scan(20,msec,2,0)
count = count + 1
for i=1 to 32
src(i) = count AND mask(((i-1) MOD 16) +1)
next i
SDMCD16AC(src(),2,1)
NextScan
EndProg
8.2 Edlog Example
The example is written for the CR10(X) Measurement and Control Module.
The program concepts presented are the same for the CR23X, 21X, and CR7
dataloggers with minor program code changes.
In this example, the SDM-CD16AC is used to control the temperature between
23° and 28°C in each of 5 greenhouses. In each green house the SDM-
CD16AC controls a heating unit, a refrigerating unit, and an air mixing fan
according to the following conditions.
Heating unit: Activate when temperature < 23.5°C. Deactivate when
temperature > 25.5°C
Cooling unit: Activate when temperature > 27.5°C. Deactivate when
temperature < 24.5°C
Mixing fan: Activate whenever the heating or cooling units are activated.
Activate for 5 minutes out of every 15 minutes.
The program assumes the temperature measurements have been made, and the
average temperature for each greenhouse is computed and residing in Input
Locations 1 through 5.
11