Add support for variable sampling period

The new sensor HAL version introduced
variable sampling periods for sensors.
Our host side does not support this. This
change latches values for CONTINUOUS_MODE
sensors and repeats them at the requested
rate.

Bug: 159469598
Test: atest android.hardware.cts.SensorBatchingTests
Change-Id: I0487f148fccab1066df253f66110a7e2539c82f2
Merged-In: I0487f148fccab1066df253f66110a7e2539c82f2
3 files changed