How develop an app that has access to the Sensors:
All information you need are in firmware. So unpack your firmware using Cygwin and kitchen:
- How to setting up Cygwin and kitchen:
http://www.mtkroms.com/2015/02/tutorial-to-set-up-cygwin-and-android.html - Then load the system.img from your firmware to the original_update folder
- Choose “1. Set up working folder from Rom” and follow introductions
Why we do that?
The idea was that the system apps also get access to the sensors. So now we search in the firmware for the systemapps.
The most interesting app is the EngineerMode.apk. You can find it at:
\cygwin\home\username\kitchen\WORKING_XXX\system\app\EngineerMode.apk
Now decompile the app using:
http://www.javadecompilers.com/apk
You get a zip Archive which contains the Sourcecode from the app. My first Test was to get access to the heartrate sensor. The *.java in the heartrate folder tell you how to do this