Example Programs; Adding Cdms With Cpiaddmodule - Campbell CDM-A100 Series Instruction Manual

Table of Contents

Advertisement

Appendix B. Example Programs
B.1 Adding CDMs with CPIAddModule()
CRBasic Example B-1. Adding CDMs with CPIAddModule()
'This program sets CPI Addresses and Device Names on CDM-A100s with serial numbers
'1234, 1235, and 1236 and makes a single-ended measurement on each unit's SE 1 channel.
'Declare Variables and Units
Public
SEVolt1
Public
SEVolt2
Public
SEVolt3
'Main Program
BeginProg
CPIAddModule
(CDM_A108,1234,"A",4)
CPIAddModule
(CDM_A108,1235,"12345",5)
CPIAddModule
(CDM_A116,1236,"CDM_A108 in Pump House",6)
'Main Scan
Scan(5,Sec,3,0)
'Generic Single Ended Voltage measurement 'SEVolt' on CDM-A108 with CPI address 1
CDM_VoltSe(CDM_A108,4,SEVolt1,1,mV5000,1,True,500,60,1,0)
CDM_VoltSe(CDM_A108,5,SEVolt2,1,mV5000,1,True,500,60,1,0)
CDM_VoltSe(CDM_A116,6,SEVolt3,1,mV5000,1,True,500,60,1,0)
'Call Data Tables and Store Data
CallTable
Table1
NextScan
EndProg
The following program sets CPI Addresses and Device Names on CDM-A100s
with serial numbers 1234, 1235, and 1236 and makes a single-ended
measurement on each unit's SE 1 channel. With slight modifications, this
program can be used with the CR800-series, CR1000, and CR3000
dataloggers.
B-1

Advertisement

Table of Contents
loading

This manual is also suitable for:

Cdm-a108Cdm-a116

Table of Contents