Simple Android Sensors HAL for Android integration without any algorithm.
This repository provides a simple Android Sensors HAL for integrating InvenSense chips inside Android system. It doesn't provides any calibration or fusion algorithms inside.
Beware that this integration is not compliant with Android CDD because of the lack of calibration algorithms for gyroscope and magnetometer.
The sensors/
folder contains the Android Simple Sensors HAL 1.0.
The subhalv2_1/
folder contains an Android SubHal v2.1 wrapper loading the Sensors HAL 1.0 for implementing SubHal v2.1 interface.
Sensors HAL 1.0 integration, compatible with all Android <= 13:
# InvenSense Sensors HAL
PRODUCT_PACKAGES += \
sensors.invensense \
[email protected] \
[email protected]
PRODUCT_PROPERTY_OVERRIDES += ro.hardware.sensors=invensense
Sensors Multi-HAL 2.1 integration, compatible with Android 11, 12, 13:
# InvenSense Sensors HAL
PRODUCT_PACKAGES += \
sensors.invensense \
[email protected] \
[email protected]
PRODUCT_PROPERTY_OVERRIDES += ro.hardware.sensors=invensense
PRODUCT_COPY_FILES += \
$(LOCAL_PATH)/subhalv2_1/hals.conf:$(TARGET_COPY_OUT_VENDOR)/etc/sensors/hals.conf
Sensors Multi-HAL AIDL integration, compatible with Android >= 13:
# InvenSense Sensors HAL
PRODUCT_PACKAGES += \
sensors.invensense \
[email protected] \
android.hardware.sensors-service.multihal
PRODUCT_PROPERTY_OVERRIDES += ro.hardware.sensors=invensense
PRODUCT_COPY_FILES += \
$(LOCAL_PATH)/subhalv2_1/hals.conf:$(TARGET_COPY_OUT_VENDOR)/etc/sensors/hals.conf