wish: additional sensor types

latcc

Banned
These types are only available from Android 2.3 and above.
However you can use them with PhoneSensors by passing the type value (as listed here: Sensor | Android Developers).
Erel

On the page you mention is the sensor type: TYPE_PRESSURE

Is this actually available or just a 'wish list' type function?

Are such sensors part of Android devices? I know we have a magnetic compass sensor and an orientation sensor. What else is there?
 

vinicio

Member
Licensed User
Longtime User
Sensors Type_linear_acceleration

I hope someone can help me,

I can not use the virtual sensor TYPE_LINEAR_ACCELERATION. I tried with PhoneSensors but the type is not implemented.

Using the API level 17 and the app should be operated only on the Samsung S4 (which supports the sensor)

Vinicio
 

galeforce9

Member
Licensed User
Longtime User
  1. Hello,

    I'm also trying to implement TYPE_LINEAR_ACCELERATION. I can initialize this by using sensor 10 as Erel points out above. What I'm not clear on is how I then capture the event. For the other supported sensor types I would use

    sub ACCEL_Sensorchanged

    Which works fine.I have tried

    Sub LINEARACCEL_Sensorchanged

    but this sub does not get triggered. I know I can use Sensor_SensorChanged to capture all sensor events but I need to capture this event separately or if not have a way to detect which sensor has triggered the generic event. One other point, if I add linear_acceleration to the Sensor App found here on the forum it only displays one value but I know it should be displaying all three values.

    Thank you

    Ian
 
Top