You are going to have more than 2 samples in 5 minutes. Make the sample size sufficiently large to account for the maximum number of samples you get in 5 minutes. There is a buffer fill ratio attribute of the sensor you can check. You want this to be close to 1 (100%) but never actually reaching 1.

So I’d have to set sampling_size to 15, when I assume the car is capable of going 180km/h?
That would be 180 / 60 * 5 = 15. Unfortunately I don’t get fractions of kilometers reported.

edit: is there another way to calculate such delta values?