Analytics Builder 10.14.0 | Using Analytics Builder for Cumulocity IoT | Details of Values and Blocks | Values as representations of continuous-time physical quantities | Input values at different times
 
Input values at different times
Consider two position sensors which give the position of two robot arms, and both are on-change sensors. If the two arms move together in unison in the same direction and speed, then the position sensors should update to new values at the same time such that they are a constant distance apart (or at least, close to a constant distance). If the Difference block has inputs connected to both sensors, then even if the robot arms move, the output of the Difference block should be approximately constant. Analytics Builder evaluates all values with the same timestamp, so even though there may be a small delay in receiving the values from the two sensors, provided they supply timestamps from the same clock (and the Ignore Timestamp parameter of the Measurement Input block is not set), then the Difference block will always generate a synchronized output, as shown in the table below:
Time
Position sensor 1
Position sensor 2
Output of the Difference block
00:00
4
14
10
00:01
6
16
10
00:02
9
19
10
By contrast, consider if the two robot arms do not move in unison - one moves, then another. The distance between the arms may vary as either arm moves. As the sensors are on-change inputs, there will only be a new value when the position changes. However, the absence of an input does not mean that the corresponding robot arm does not have a position. It has remained where it is (within error margins). For example:
Time
Position sensor 1
Position sensor 2
Output of the Difference block
00:00
9
19
10
00:01
11
19
8
00:02
13
19
6
00:05
13
18
5
00:06
13
17
4
00:07
13
15
2
The bold numbers indicate the effective value. The last value latches if it has not been replaced by a more up-to-date value.