This example shows a simple way to calculate the difference between an incoming value, and the previously received value (for integers).