Section 8. operation, 1 measurements, 1 time – Campbell Scientific CR800 and CR850 Measurement and Control Systems User Manual
Page 269: 1 time stamps, Figure 82: running-average equation, Crbasic example 61. pt100 in four-wire full-bridge

269
Section 8. Operation
8.1 Measurements
Several features give the CR800 the flexibility to measure many sensor types. 
Contact a Campbell Scientific applications engineer if assistance is required in 
assessing CR800 compatibility to a specific application or sensor type. Some 
sensors require precision excitation or a source of power. See Powering Sensors 
and Devices
(p. 84).
8.1.1 Time
Measurement of time is an essential function of the CR800. Time measurement 
with the on-board clock enables the CR800 to attach time stamps to data, measure 
the interval between events, and time the initiation of control functions. 
8.1.1.1 Time Stamps
A measurement without an accurate time reference has little meaning. Data on 
the CR800 are stored with time stamps. How closely a time stamp corresponds to 
the actual time a measurement is taken depends on several factors. 
The time stamp in common CRBasic programs matches the time at the beginning 
of the current scan as measured by the real-time clock in the CR800. If a scan 
starts at 15:00:00, data output during that scan will have a time stamp of 15:00:00 
regardless of the length of the scan or when in the scan a measurement is made. 
The possibility exists that a scan will run for some time before a measurement is 
made. For instance, a scan may start at 15:00:00, execute time-consuming code, 
then make a measurement at 15:00:00.51. The time stamp attached to the 
measurement, if the CallTable() instruction is called from within the Scan() / 
NextScan construct, will be 15:00:00, resulting in a time-stamp skew of 510 ms. 
Time-stamp skew is not a problem with most applications because,
• program execution times are usually short, so time stamp skew is only a few
milliseconds. Most measurement requirements allow for a few milliseconds 
of skew. 
• data processed into averages, maxima, minima, and so forth are composites
of several measurements. Associated time stamps only reflect the time the 
last measurement was made and processing calculations were completed, so 
the significance of the exact time a specific sample was measured diminishes. 
Applications measuring and storing sample data wherein exact time stamps are 
required can be adversely affected by time-stamp skew. Skew can be avoided by 
• Making measurements in the scan before time-consuming code. 
• Programming the CR800 such that the time stamp reflects the system time 
rather than the scan time. When CallTable() is executed from within the 
Scan() / NextScan construct, as is normally done, the time stamp reflects 
scan time. By executing the CallTable() instruction outside the Scan() / 
NextScan construct, the time stamp will reflect system time instead of scan 
time. CRBasic example Time Stamping with System Time
(p. 270)
shows the
