/external/robolectric/v1/src/test/java/com/xtremelabs/robolectric/shadows/ |
SensorManagerTest.java | 7 import android.hardware.SensorManager; 21 private SensorManager sensorManager; 26 sensorManager = (SensorManager) Robolectric.application.getSystemService(Context.SENSOR_SERVICE); 27 shadow = shadowOf(sensorManager); 32 sensorManager = null; 45 Sensor sensor = sensorManager.getDefaultSensor(SensorManager.SENSOR_ACCELEROMETER); 46 sensorManager.registerListener(listener, sensor, SensorManager.SENSOR_DELAY_NORMAL) [all...] |
/cts/tests/sensor/src/android/hardware/cts/helpers/sensoroperations/ |
TestSensorOperation.java | 77 void execute(TestSensorManager sensorManager, TestSensorEventListener listener) 237 public void execute(TestSensorManager sensorManager, TestSensorEventListener listener) 240 CountDownLatch latch = sensorManager.registerListener(listener, eventCount); 243 sensorManager.unregisterListener(); 265 public void execute(TestSensorManager sensorManager, TestSensorEventListener listener) 268 sensorManager.registerListener(listener); 272 CountDownLatch flushLatch1 = sensorManager.requestFlush(); 301 CountDownLatch flushLatch2 = sensorManager.requestFlush(); 320 CountDownLatch flushLatch3 = sensorManager.requestFlush(); 333 sensorManager.unregisterListener() [all...] |
/frameworks/base/packages/SystemUI/src/com/android/systemui/doze/ |
DozeFactory.java | 22 import android.hardware.SensorManager; 38 SensorManager sensorManager = context.getSystemService(SensorManager.class); 52 createDozeTriggers(context, sensorManager, host, config, params, handler, wakeLock, 60 private DozeTriggers createDozeTriggers(Context context, SensorManager sensorManager, 65 sensorManager, handler, wakeLock, allowPulseTriggers);
|
/frameworks/base/core/java/com/android/internal/os/ |
SensorPowerCalculator.java | 19 import android.hardware.SensorManager; 29 public SensorPowerCalculator(PowerProfile profile, SensorManager sensorManager) { 30 mSensors = sensorManager.getSensorList(Sensor.TYPE_ALL);
|
/external/webrtc/webrtc/examples/androidapp/src/org/appspot/apprtc/ |
AppRTCProximitySensor.java | 20 import android.hardware.SensorManager; 42 private final SensorManager sensorManager; 55 sensorManager = ((SensorManager) context.getSystemService( 70 sensorManager.registerListener( 71 this, proximitySensor, SensorManager.SENSOR_DELAY_NORMAL); 82 sensorManager.unregisterListener(this, proximitySensor); 95 if (accuracy == SensorManager.SENSOR_STATUS_UNRELIABLE) { 135 proximitySensor = sensorManager.getDefaultSensor(Sensor.TYPE_PROXIMITY) [all...] |
/frameworks/base/core/jni/ |
android_hardware_SensorManager.cpp | 16 #define LOG_TAG "SensorManager" 30 #include <sensor/SensorManager.h> 150 return (jlong) &SensorManager::getInstanceForPackage(String16(opPackageNameUtf.c_str())); 199 nativeGetSensorAtIndex(JNIEnv *env, jclass clazz, jlong sensorManager, jobject sensor, jint index) 201 SensorManager* mgr = reinterpret_cast<SensorManager*>(sensorManager); 213 nativeGetDynamicSensors(JNIEnv *env, jclass clazz, jlong sensorManager, jobject sensorList) { 215 SensorManager* mgr = reinterpret_cast<SensorManager*>(sensorManager) [all...] |
/packages/apps/Camera2/src/com/android/camera/hardware/ |
HeadingSensor.java | 24 import android.hardware.SensorManager; 39 private final SensorManager mSensorManager; 55 * @param sensorManager A {#link android.hardware.SensorManager} that 58 public HeadingSensor(SensorManager sensorManager) { 59 mSensorManager = sensorManager; 82 SensorManager.SENSOR_DELAY_NORMAL); 86 SensorManager.SENSOR_DELAY_NORMAL); 120 SensorManager.getRotationMatrix(mRotationMatrix, null, mGData, mMData) [all...] |
/packages/apps/DevCamera/src/com/android/devcamera/ |
GyroOperations.java | 21 import android.hardware.SensorManager; 32 private SensorManager mSensorManager; 45 public GyroOperations(SensorManager sensorManager) { 46 mSensorManager = sensorManager; 50 mSensorManager.registerListener(mSensorEventListener, mSensorManager.getDefaultSensor(Sensor.TYPE_GYROSCOPE), SensorManager.SENSOR_DELAY_FASTEST);
|
/frameworks/native/libs/sensor/ |
SensorManager.cpp | 19 #include <sensor/SensorManager.h> 41 Mutex SensorManager::sLock; 42 std::map<String16, SensorManager*> SensorManager::sPackageInstances; 44 SensorManager& SensorManager::getInstanceForPackage(const String16& packageName) { 48 SensorManager* sensorManager; 52 sensorManager = iterator->second; 78 sensorManager = new SensorManager(opPackageName) [all...] |
/cts/tests/sensor/src/android/hardware/cts/helpers/ |
TestSensorEnvironment.java | 21 import android.hardware.SensorManager; 285 if (mSamplingPeriodUs == SensorManager.SENSOR_DELAY_FASTEST) { 304 && mSamplingPeriodUs != SensorManager.SENSOR_DELAY_FASTEST; 310 * The flags SensorManager.SENSOR_DELAY_[GAME|UI|NORMAL] are not supported since the CDD does 383 SensorManager sensorManager = 384 (SensorManager) context.getSystemService(Context.SENSOR_SERVICE); 385 if (sensorManager == null) { 389 Sensor sensor = sensorManager.getDefaultSensor(sensorType); 445 * {@link SensorManager#SENSOR_DELAY_GAME}, {@link SensorManager#SENSOR_DELAY_UI}, o [all...] |
/cts/apps/CtsVerifier/src/com/android/cts/verifier/sensors/sixdof/Activities/ |
StartActivity.java | 27 import android.hardware.SensorManager; 61 SensorManager sensorManager = (SensorManager) getSystemService(Context.SENSOR_SERVICE); 62 if (sensorManager.getDefaultSensor(Sensor.TYPE_POSE_6DOF) == null) {
|
/cts/tools/cts-device-info/src/com/android/cts/deviceinfo/ |
SensorDeviceInfo.java | 20 import android.hardware.SensorManager; 58 SensorManager sensorManager = (SensorManager) 60 List<Sensor> sensors = sensorManager.getSensorList(Sensor.TYPE_ALL);
|
/packages/apps/Settings/src/com/android/settings/gestures/ |
DoubleTwistPreferenceController.java | 22 import android.hardware.SensorManager; 92 final SensorManager sensorManager = 93 (SensorManager) mContext.getSystemService(Context.SENSOR_SERVICE); 94 for (Sensor s : sensorManager.getSensorList(Sensor.TYPE_ALL)) {
|
/external/webrtc/webrtc/modules/audio_processing/test/android/apmtest/jni/ |
main.c | 47 ASensorManager* sensorManager; 244 engine.sensorManager = ASensorManager_getInstance(); 245 engine.accelerometerSensor = ASensorManager_getDefaultSensor(engine.sensorManager, 247 engine.sensorEventQueue = ASensorManager_createEventQueue(engine.sensorManager,
|
/frameworks/base/services/core/java/com/android/server/ |
GestureLauncherService.java | 30 import android.hardware.SensorManager; 174 SensorManager sensorManager = (SensorManager) mContext.getSystemService( 176 sensorManager.unregisterListener(mGestureListener); 189 SensorManager sensorManager = (SensorManager) mContext.getSystemService( 197 mCameraLaunchSensor = sensorManager.getDefaultSensor( 206 mRegistered = sensorManager.registerListener(mGestureListener [all...] |
/developers/build/prebuilts/gradle/BatchStepSensor/Application/src/main/java/com/example/android/batchstepsensor/ |
BatchStepSensorFragment.java | 24 import android.hardware.SensorManager; 254 SensorManager sensorManager = 255 (SensorManager) getActivity().getSystemService(Activity.SENSOR_SERVICE); 257 Sensor sensor = sensorManager.getDefaultSensor(sensorType); 261 final boolean batchMode = sensorManager.registerListener( 262 mListener, sensor, SensorManager.SENSOR_DELAY_NORMAL, maxdelay); 290 SensorManager sensorManager = 291 (SensorManager) getActivity().getSystemService(Activity.SENSOR_SERVICE) [all...] |
/developers/samples/android/sensors/BatchStepSensor/Application/src/main/java/com/example/android/batchstepsensor/ |
BatchStepSensorFragment.java | 24 import android.hardware.SensorManager; 254 SensorManager sensorManager = 255 (SensorManager) getActivity().getSystemService(Activity.SENSOR_SERVICE); 257 Sensor sensor = sensorManager.getDefaultSensor(sensorType); 261 final boolean batchMode = sensorManager.registerListener( 262 mListener, sensor, SensorManager.SENSOR_DELAY_NORMAL, maxdelay); 290 SensorManager sensorManager = 291 (SensorManager) getActivity().getSystemService(Activity.SENSOR_SERVICE) [all...] |
/development/samples/browseable/BatchStepSensor/src/com.example.android.batchstepsensor/ |
BatchStepSensorFragment.java | 24 import android.hardware.SensorManager; 254 SensorManager sensorManager = 255 (SensorManager) getActivity().getSystemService(Activity.SENSOR_SERVICE); 257 Sensor sensor = sensorManager.getDefaultSensor(sensorType); 261 final boolean batchMode = sensorManager.registerListener( 262 mListener, sensor, SensorManager.SENSOR_DELAY_NORMAL, maxdelay); 290 SensorManager sensorManager = 291 (SensorManager) getActivity().getSystemService(Activity.SENSOR_SERVICE) [all...] |
/frameworks/base/services/core/java/com/android/server/power/ |
WirelessChargerDetector.java | 22 import android.hardware.SensorManager; 98 private static final double MIN_GRAVITY = SensorManager.GRAVITY_EARTH - 1.0f; 99 private static final double MAX_GRAVITY = SensorManager.GRAVITY_EARTH + 1.0f; 103 private final SensorManager mSensorManager; 145 public WirelessChargerDetector(SensorManager sensorManager, 147 mSensorManager = sensorManager; 151 mGravitySensor = sensorManager.getDefaultSensor(Sensor.TYPE_GRAVITY);
|
/developers/build/prebuilts/gradle/RuntimePermissionsWear/Wearable/src/main/java/com/example/android/wearable/runtimepermissions/ |
MainWearActivity.java | 23 import android.hardware.SensorManager; 148 SensorManager sensorManager = (SensorManager) getSystemService(SENSOR_SERVICE); 149 List<Sensor> sensorList = sensorManager.getSensorList(Sensor.TYPE_ALL); 336 SensorManager sensorManager = (SensorManager) getSystemService(SENSOR_SERVICE); 337 List<Sensor> sensorList = sensorManager.getSensorList(Sensor.TYPE_ALL);
|
IncomingRequestWearService.java | 23 import android.hardware.SensorManager; 119 SensorManager sensorManager = (SensorManager) getSystemService(SENSOR_SERVICE); 120 List<Sensor> sensorList = sensorManager.getSensorList(Sensor.TYPE_ALL);
|
/developers/samples/android/wearable/wear/RuntimePermissionsWear/Wearable/src/main/java/com/example/android/wearable/runtimepermissions/ |
MainWearActivity.java | 23 import android.hardware.SensorManager; 148 SensorManager sensorManager = (SensorManager) getSystemService(SENSOR_SERVICE); 149 List<Sensor> sensorList = sensorManager.getSensorList(Sensor.TYPE_ALL); 336 SensorManager sensorManager = (SensorManager) getSystemService(SENSOR_SERVICE); 337 List<Sensor> sensorList = sensorManager.getSensorList(Sensor.TYPE_ALL);
|
IncomingRequestWearService.java | 23 import android.hardware.SensorManager; 119 SensorManager sensorManager = (SensorManager) getSystemService(SENSOR_SERVICE); 120 List<Sensor> sensorList = sensorManager.getSensorList(Sensor.TYPE_ALL);
|
/development/samples/browseable/RuntimePermissionsWear/Wearable/src/com.example.android.wearable.runtimepermissions/ |
MainWearActivity.java | 23 import android.hardware.SensorManager; 148 SensorManager sensorManager = (SensorManager) getSystemService(SENSOR_SERVICE); 149 List<Sensor> sensorList = sensorManager.getSensorList(Sensor.TYPE_ALL); 336 SensorManager sensorManager = (SensorManager) getSystemService(SENSOR_SERVICE); 337 List<Sensor> sensorList = sensorManager.getSensorList(Sensor.TYPE_ALL);
|
IncomingRequestWearService.java | 23 import android.hardware.SensorManager; 119 SensorManager sensorManager = (SensorManager) getSystemService(SENSOR_SERVICE); 120 List<Sensor> sensorList = sensorManager.getSensorList(Sensor.TYPE_ALL);
|