Closed nicolaerosia closed 5 years ago
Likely doesn't matter, but you don't really need to read the temperature constantly. In the ms5525 airspeed driver (nearly identical to this) I only update the temperature every 10th cycle.
@dagar that is correct, see my PR description "The previous logic was flawed, since we were using a fixed callback timer, we were sampling the temperature, waiting half a period (much more than the required delay), then sample the pressure. ** the idea is to align this driver with the one on NuttX so we can merge it later on (they do multiple pressure samples with each temperature sample - we can do that too but I did not want the changes to be so intrusive) "
You might also find this interesting: http://www.freesteel.co.uk/wpblog/2014/11/26/ms5611-altitude-sensor-very-sensitive-to-own-working-temperature/
Highlights:
timespec_inc
can be factored out into a header so multiple drivers can use it.@mcharleb @julianoes @LorenzMeier please review