2022-06-14 10:39 AM
Hello,
We have been working with the LIS3DH Accelerometer on an Android 11 based device. We have Integrated the corresponding Kernel drivers and the STM Android Sensor IIO HAL.
As per our understanding our Android device should be able to read values from the accelerometer and rotate the screen accordingly, but this feature is not working as expected.
When enabling the debug output of the Android WindowOrientationListener I saw that the code always returns a “proposedRotation=-1�? identifier, and when doing some research, I noted that this might be caused when the accelerometer has not been calibrated.
I reviewed the STM Android Sensor IIO HAL, and I noted that there is a calibration_daemon which depends on a calibration tool.
Could you please explain me if this calibration tool is an external APK? And provide information about how could I enable and run the calibration_daemon?
Any guidance will be highly appreciated,
Thanks, and best regards,
Esteban V.
2022-06-17 9:02 AM
Hi Esteban @EVazq.1 ,
Since this is a specific question about Android drivers, I suggest you to directly rise an issue on Github, so that it will be handled directly by Android ST experts.
--> https://github.com/STMicroelectronics/STMems_Android_Sensor_HAL_IIO
-Eleon
2022-09-06 9:39 AM
Hello Eleon,
Thank you for the suggestion, I opened the following “issue�? on GitHub, but I have not received response yet.
https://github.com/STMicroelectronics/STMems_Android_Sensor_HAL_IIO/issues/13
Could you please let me know if I correctly posted the issue?
Thanks, and best regards,
Esteban V.
2024-10-10 9:44 PM
The issue you're facing with the accelerometer not rotating the screen may be due to a lack of calibration. The calibration_daemon in the STM Android Sensor IIO HAL requires a calibration tool, which is usually an external APK. This tool runs calibration routines to ensure the sensor works correctly. To solve this, you'll need to find and install the correct calibration APK from STM. Once installed, the calibration_daemon will run automatically to calibrate the sensor. Ensure the daemon is active and check system logs to confirm the calibration is applied. This should fix the rotation problem.
2025-05-16 8:33 AM - edited 2025-05-20 11:07 AM
Hi Esteban,
The calibration_daemon you're referring to usually depends on a proprietary calibration tool, which in some cases might be an external APK file provided by the hardware vendor. If it’s not pre-installed, you might need to request it directly from STMicroelectronics or your board supplier.
To enable and run the calibration_daemon, make sure the required sensor permissions and services are correctly configured in your device’s firmware. Also, verify that the daemon is triggered at boot or manually initiated via shell with proper permissions.
By the way, if you're working with APK files and mobile tools in general, you might also want to check out this apk for creative video editing and animation it’s pretty handy for visual projects.
Hope this helps!