Sdmspeed (bitperiod) – Campbell Scientific CR9000X Measurement and Control System User Manual
Page 256

Section 7. Measurement Instructions
7-32
Parameter
& Data Type
Enter
SDMSW8A PARAMETERS
Dest
Variable or
Array
The variable in which to store the results of the SDM-SW8A measurement. The variable
array for this parameter must be dimensioned to the number of Reps.
Reps
Constant
The number of channels that will be read on the SDM-SW8A. If (StartChan +Reps –1) is
greater than 8, measurement will continue on the next sequential SDM-SW8A. In this
instance, the addresses of the SDM devices must be consecutive.
SDMAddress
Constant
The address of the first SDM-SW8A with which to communicate. Valid SDM addresses
are 0 through 15. If the SDMTrigger instruction is used in the program, address 15 should
not be used. If the Reps parameter used more channels than are available on the first SDM-
SW8A, the datalogger will increment the SDM address for each subsequent device that it
communicates with.
FunctOp
The FunctOp is used to determine the result that will be returned by the SDM-SW8A.
Constant
Numeric
Code
Function
0
Returns the state of the signal at the time the instruction is executed. A zero (0)
is stored for low and a one (1) is stored for high.
1
Returns the duty cycle of the signal. The result is the percentage of time the
signal is high during the scan interval.
2
Returns a count of the number of positive transitions of the signal.
3
Returns a value indicating the condition of the module:
positive integer:
ROM and RAM are good
negative value:
RAM is bad
Zero:
ROM is bad
SDMSpeed (BitPeriod)
Changes the rate period that the CR9000X uses to clock the SDM data.
Slowing down the clock rate may be necessary when long cables lengths are
used to connect the CR9000X and SDM devices.
Parameter
& Data Type
Enter
SDMSPEED PARAMETER
BitPeriod
Constant or
variable
The default bit period is 28.8 microseconds if the SDMSpeed instruction is not in the program.
If 0 is used for the argument the bit period will be 3.2 microseconds, the minimum allowable.
Maximum bit period is 800 microseconds.
Resolution is 3.2 microseconds.
The bit rate in the SDMSpeed instruction is calculated as:
bit_rate (microseconds)=INT((k*10)/32)*Resolution
where k is the value entered in BitPeriod. The datalogger will round down to the next faster
bit rate.