Campbell Scientific SDM-IO16 16-Channel Input/Output Expansion Module User Manual

Page 31

Advertising
background image

SDM-IO16 16 Channel Input/Output Expansion Module

;Measure the four frequencies and write to four input locations
;applying a scaling to m/s
5: SDM-IO16 (P188)
1: 00

SDM

Address

2: 40

Command Code Option

;read the freq of the signals on ports 1..4

3: 0

Ports

16-13

;port settings not used for 40

4: 0

Ports

12-9

5: 0

Ports

8-5

6: 0

Ports

4-1

7: 1

Return Code Loc [ ErrCount ] ;for return code

8: 2

First Loc [ Windspd_1 ]

;for first windspeed data

9: .05148 Mult

;Calibration to give m/s for A100L2

10: 0.0

Offset


;Measure the four pulses counts and write to four locations
;as equivalent rainfall in mm
6: SDM-IO16 (P188)
1: 00

SDM

Address

2: 18

Command

Code

Option

;Count the pulses on ports 5..8

3: 0

Ports

16-13

;port settings not used for 18

4: 0

Ports

12-9

5: 0

Ports

8-5

6: 0

Ports

4-1

7: 1

Return Code Loc [ ErrCount ] ;for return code

8: 6

First Loc [ Rain_1 ]

;for rain values

9: 0.2

Mult

;Typical calib for mm per tip

10: 0.0

Offset


;Example of output instructions
;Every hour
7: If time is (P92)
1: 0

Minutes (Seconds --) into a

2: 60

Interval (same units as above)

3: 10

Set Output Flag High (Flag 0)


;Fix the array ID to 100
8: Set Active Storage Area (P80)
1: 1

Final Storage Area 1

2: 100

Array

ID


;Store a time stamp first
9: Real Time (P77)
1: 1110

Year,Day,Hour/Minute (midnight = 0000)


;Store average windspeeds
10: Average (P71)
1: 4

Reps

2: 2

Loc [ Windspd_1 ]

25

Advertising