Campbell Scientific AM16/32B AM16/32B Relay Multiplexer - Page 26
CR5000 and CR3000 Programming
View all Campbell Scientific AM16/32B manuals
Add to My Manuals
Save this manual to your list of manuals |
Page 26 highlights
AM16/32B Relay Multiplexer PulsePort (5,10000) 'Clock Mux CS616 (Period(I),3,1,6,3,1.0,0) 'measure 3ea CS616 probes I=I+3 NextSubScan ' For I=1 to 48 'convert CS616 period to Volumetric Water Content VWC(I)=a0 + a1*Period(I) + a2*Period(I)^2 Next ' PortSet (4,0) 'Set Mux Reset line Low flag(1)= low EndIf ' CallTable Dat30min 'Call Output Tables NextScan EndProg 5.1.2 CR5000 and CR3000 Programming Although the following example is a CR5000 program, a similar program can be used for the CR3000. This CR5000 program uses the AM16/32B to measure 16 100 ohm Platinum Resistance Thermometers connected in the 4x16 configuration. The program also measures 6 copper constantan thermocouples. CR5000 C1 C2 IX1 IXR 7H 7L AM16/32B Control/Common Sensor Terminals Reset Odd H Clock Odd L COM Odd H Even H COM Odd L Even L COM Even H COM Even L PRT(4 Wires) Excitation Excitation Return Sense wire excitation side Sense wire return side 'CR5000 Example Program to measure 16 100 ohm Platinum Resistance Thermometers 'connected to an AM16/32B multiplexer used in the 4x16 configuration. The program also 'measures 6 copper constantan thermocouples. 'The Thermocouples are connected to differential channels 1-6. 'Declare Variables: Public TRef, TCTemp(6), PRTResist(16), PRTTemp(16) Dim I 'Counter for setting Array element to correct value for mux measurement 'Declare Output Table for 15 minute averages: DataTable (Avg15Min,1,-1) DataInterval (0,5,Min,10) Average (1,TRef,IEEE4,0) Average (6,TCTemp(),IEEE4,0) Average (16,PRTTemp(),IEEE4,0) EndTable BeginProg Scan (60,Sec,3,0) PanelTemp (TRef,250) TCDiff (TCTemp(),6,mV20C ,1,TypeT,TRef,True ,0,250,1.0,0) Portset (1 ,1) 'Set C1 high to Enable Multiplexer I=0 SubScan(0,sec,16) 'Pulse C2 (Set High, Delay, Set Low) to clock multiplexer Portset (2,1 ) Delay (0,20,mSec) Portset (2,0) 16