Home
last modified time | relevance | path

Searched refs:mSensors (Results 1 – 25 of 30) sorted by relevance

12

/frameworks/native/services/sensorservice/
DHidlSensorHalWrapper.cpp117 return mSensors->supportsPolling(); in supportsPolling()
121 return mSensors->supportsMessageQueues(); in supportsMessageQueues()
146 auto ret = mSensors->poll(count, in poll()
187 size_t availableEvents = mSensors->getEventQueue()->availableToRead(); in pollFmq()
201 availableEvents = mSensors->getEventQueue()->availableToRead(); in pollFmq()
211 if (mSensors->getEventQueue()->read(mEventBuffer.data(), eventsToRead)) { in pollFmq()
233 if (mSensors != nullptr) { in getSensorsList()
234 checkReturn(mSensors->getSensorsList([&](const auto& list) { in getSensorsList()
242 if (!mSensors->supportsMessageQueues()) { in getSensorsList()
243 checkReturn(mSensors->activate(list[i].sensorHandle, 0 /* enabled */)); in getSensorsList()
[all …]
DAidlSensorHalWrapper.cpp559 mSensors = nullptr; in connect()
563 if (mSensors != nullptr) { in connect()
564 AIBinder_unlinkToDeath(mSensors->asBinder().get(), mDeathRecipient.get(), this); in connect()
569 mSensors = ISensors::fromBinder(binder); in connect()
590 mSensors->initialize(mEventQueue->dupeDesc(), mWakeLockQueue->dupeDesc(), mCallback); in connect()
592 AIBinder_linkToDeath(mSensors->asBinder().get(), mDeathRecipient.get(), this); in connect()
598 return mSensors != nullptr; in connect()
661 if (mSensors != nullptr) { in getSensorsList()
663 mSensors->getSensorsList(&list); in getSensorsList()
675 if (mSensors == nullptr) return NO_INIT; in setOperationMode()
[all …]
DSensorService.cpp316 mSensors.forEachSensor( in onFirstRef()
413 if (mSensors.add(handle, s, isDebug, isVirtual)){ in registerSensor()
417 return mSensors.getNonSensor(); in registerSensor()
426 bool ret = mSensors.remove(handle); in unregisterDynamicSensorLocked()
510 } else if (!mSensors.hasAnySensor()) { in dump()
525 result.append(mSensors.dump().c_str()); in dump()
532 sp<SensorInterface> s = mSensors.getInterface(i.first); in dump()
623 if (!mSensors.hasAnySensor()) { in dumpProtoLocked()
639 mSensors.dump(&proto); in dumpProtoLocked()
650 sp<SensorInterface> s = mSensors.getInterface(i.first); in dumpProtoLocked()
[all …]
DAidlSensorHalWrapper.h79 std::shared_ptr<aidl::android::hardware::sensors::ISensors> mSensors;
/frameworks/base/services/core/java/com/android/server/biometrics/sensors/face/aidl/
DFaceProvider.java85 final SparseArray<Sensor> mSensors; // Map of sensors that this HAL supports field in FaceProvider
100 for (int i = 0; i < mSensors.size(); i++) { in onTaskStackChanged()
101 final BaseClientMonitor client = mSensors.valueAt(i).getScheduler() in onTaskStackChanged()
116 mSensors.valueAt(i).getScheduler().cancelAuthenticationOrDetection( in onTaskStackChanged()
130 mSensors = new SparseArray<>(); in FaceProvider()
158 mSensors.put(sensorId, sensor); in FaceProvider()
202 for (int i = 0; i < mSensors.size(); i++) { in getHalInstance()
203 final int sensorId = mSensors.keyAt(i); in getHalInstance()
213 if (!mSensors.contains(sensorId)) { in scheduleForSensor()
217 mSensors.get(sensorId).getScheduler().scheduleClientMonitor(client); in scheduleForSensor()
[all …]
/frameworks/base/services/core/java/com/android/server/biometrics/sensors/fingerprint/aidl/
DFingerprintProvider.java99 final SparseArray<Sensor> mSensors; // Map of sensors that this HAL supports field in FingerprintProvider
115 for (int i = 0; i < mSensors.size(); i++) { in onTaskStackChanged()
116 final BaseClientMonitor client = mSensors.valueAt(i).getScheduler() in onTaskStackChanged()
131 mSensors.valueAt(i).getScheduler().cancelAuthenticationOrDetection( in onTaskStackChanged()
148 mSensors = new SparseArray<>(); in FingerprintProvider()
189 mSensors.put(sensorId, sensor); in FingerprintProvider()
237 for (int i = 0; i < mSensors.size(); i++) { in getHalInstance()
238 final int sensorId = mSensors.keyAt(i); in getHalInstance()
248 if (!mSensors.contains(sensorId)) { in scheduleForSensor()
252 mSensors.get(sensorId).getScheduler().scheduleClientMonitor(client); in scheduleForSensor()
[all …]
/frameworks/base/core/java/android/hardware/input/
DInputDeviceSensorManager.java63 private final Map<Integer, List<Sensor>> mSensors = new HashMap<>(); field in InputDeviceSensorManager
111 if (!mSensors.containsKey(deviceId)) { in onInputDeviceAdded()
123 mSensors.remove(deviceId); in onInputDeviceRemoved()
130 mSensors.remove(deviceId); in onInputDeviceChanged()
151 mSensors.put(deviceId, sensors); in populateSensorsForInputDeviceLocked()
156 mSensors.clear(); in initializeSensors()
173 List<Sensor> sensors = mSensors.get(deviceId); in getInputDeviceSensorLocked()
258 private List<Sensor> mSensors = new ArrayList<Sensor>(); field in InputDeviceSensorManager.InputSensorEventListenerDelegate
273 return mSensors; in getSensors()
277 return mSensors.isEmpty(); in isEmpty()
[all …]
/frameworks/base/core/java/android/hardware/
DLegacySensorManager.java209 private int mSensors; field in LegacySensorManager.LegacyListener
214 mSensors = 0; in LegacyListener()
218 if ((mSensors & legacyType) != 0) { in registerSensor()
221 boolean alreadyHasOrientationSensor = hasOrientationSensor(mSensors); in registerSensor()
222 mSensors |= legacyType; in registerSensor()
230 if ((mSensors & legacyType) == 0) { in unregisterSensor()
233 mSensors &= ~legacyType; in unregisterSensor()
234 if (hasOrientationSensor(legacyType) && hasOrientationSensor(mSensors)) { in unregisterSensor()
241 return mSensors != 0; in hasSensors()
267 if ((mSensors & SensorManager.SENSOR_ORIENTATION_RAW) != 0) { in onSensorChanged()
[all …]
/frameworks/native/libs/input/
DInputDevice.cpp188 mSensors(other.mSensors), in InputDeviceInfo()
211 mSensors.clear(); in initialize()
240 if (mSensors.find(info.type) != mSensors.end()) { in addSensorInfo()
244 mSensors.insert_or_assign(info.type, info); in addSensorInfo()
270 infos.reserve(mSensors.size()); in getSensors()
271 for (const auto& [type, info] : mSensors) { in getSensors()
/frameworks/native/services/inputflinger/reader/mapper/
DSensorInputMapper.cpp72 auto it = mSensors.find(sensorType); in parseSensorConfiguration()
73 if (it == mSensors.end()) { in parseSensorConfiguration()
76 mSensors.emplace(sensorType, sensor); in parseSensorConfiguration()
85 for (const auto& [sensorType, sensor] : mSensors) { in populateDeviceInfo()
96 for (const auto& [sensorType, sensor] : mSensors) { in dump()
293 auto it = mSensors.find(sensorType); in setSensorEnabled()
294 if (it == mSensors.end()) { in setSensorEnabled()
307 for (const auto& [_, sensor] : mSensors) { in setSensorEnabled()
318 auto it = mSensors.find(sensorType); in flushSensor()
319 if (it == mSensors.end()) { in flushSensor()
[all …]
DSensorInputMapper.h118 std::unordered_map<InputDeviceSensorType, Sensor> mSensors; variable
/frameworks/base/services/tests/servicestests/src/com/android/server/biometrics/
DAuthSessionTest.java98 @NonNull private List<BiometricSensor> mSensors; field in AuthSessionTest
107 mSensors = new ArrayList<>(); in setUp()
117 final AuthSession session = createAuthSession(mSensors, in testNewAuthSession_eligibleSensorsSetToStateUnknown()
139 final AuthSession session = createAuthSession(mSensors, in testStartNewAuthSession()
145 assertEquals(mSensors.size(), session.mPreAuthInfo.eligibleSensors.size()); in testStartNewAuthSession()
201 final AuthSession session = createAuthSession(mSensors, in testCancelReducesAppetiteForCookies()
241 final int fingerprintSensorId = mSensors.stream() in testMultiAuth_fingerprintSensorStartsAfterUINotifies()
247 final AuthSession session = createAuthSession(mSensors, in testMultiAuth_fingerprintSensorStartsAfterUINotifies()
253 assertEquals(mSensors.size(), session.mPreAuthInfo.eligibleSensors.size()); in testMultiAuth_fingerprintSensorStartsAfterUINotifies()
292 final AuthSession session = createAuthSession(mSensors, in testOnDialogAnimatedInDoesNothingDuringInvalidState()
[all …]
/frameworks/hardware/interfaces/sensorservice/libsensorndkbridge/
DASensorManager.cpp102 mSensors = list; in getSensorList()
107 mSensorList.reset(new ASensorRef[mSensors.size()]); in getSensorList()
108 for (size_t i = 0; i < mSensors.size(); ++i) { in getSensorList()
110 reinterpret_cast<ASensorRef>(&mSensors[i]); in getSensorList()
118 return mSensors.size(); in getSensorList()
133 for (size_t i = 0; i < mSensors.size(); ++i) { in getDefaultSensor()
134 if (sensor == mSensors[i]) { in getDefaultSensor()
136 reinterpret_cast<ASensorRef>(&mSensors[i]); in getDefaultSensor()
DASensorManager.h70 android::hardware::hidl_vec<SensorInfo> mSensors; member
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/doze/
DDozeTriggersTest.java107 private FakeSensorManager mSensors; field in DozeTriggersTest
123 mSensors = spy(new FakeSensorManager(mContext)); in setupDozeTriggers()
124 mTapSensor = mSensors.getFakeTapSensor().getSensor(); in setupDozeTriggers()
127 new AsyncSensorManager(mSensors, new FakeThreadFactory(mExecutor), null); in setupDozeTriggers()
203 verify(mSensors).requestTriggerSensor(any(), eq(mTapSensor)); in testTransitionTo_disablesAndEnablesTouchSensors()
205 clearInvocations(mSensors); in testTransitionTo_disablesAndEnablesTouchSensors()
212 verify(mSensors).cancelTriggerSensor(any(), eq(mTapSensor)); in testTransitionTo_disablesAndEnablesTouchSensors()
214 clearInvocations(mSensors); in testTransitionTo_disablesAndEnablesTouchSensors()
218 verify(mSensors).requestTriggerSensor(any(), eq(mTapSensor)); in testTransitionTo_disablesAndEnablesTouchSensors()
226 verify(mSensors).requestTriggerSensor(any(), eq(mTapSensor)); in transitionToDockedAod_disablesTouchSensors()
[all …]
/frameworks/base/core/java/com/android/internal/os/
DSensorPowerCalculator.java30 private final SparseArray<Sensor> mSensors; field in SensorPowerCalculator
34 mSensors = new SparseArray<>(sensors.size()); in SensorPowerCalculator()
37 mSensors.put(sensor.getHandle(), sensor); in SensorPowerCalculator()
109 Sensor s = mSensors.get(sensorHandle); in calculatePowerMah()
/frameworks/native/libs/sensor/
DSensorManager.cpp143 mSensors.clear(); in sensorManagerDied()
177 mSensors = mSensorServer->getSensorList(mOpPackageName); in assertStateLocked()
178 size_t count = mSensors.size(); in assertStateLocked()
189 mSensorList[i] = mSensors.array() + i; in assertStateLocked()
203 return static_cast<ssize_t>(mSensors.size()); in getSensorList()
266 for (size_t i=0 ; i<mSensors.size() ; i++) { in getDefaultSensor()
/frameworks/base/packages/SystemUI/tests/utils/src/com/android/systemui/util/sensors/
DFakeSensorManager.java60 private final FakeGenericSensor[] mSensors; field in FakeSensorManager
71 mSensors = new FakeGenericSensor[]{ in FakeSensorManager()
109 .stream(mSensors) in getFullSensorList()
122 for (FakeGenericSensor s : mSensors) { in unregisterListenerImpl()
135 for (FakeGenericSensor s : mSensors) { in registerListenerImpl()
/frameworks/base/services/core/java/com/android/server/biometrics/
DBiometricService.java113 final ArrayList<BiometricSensor> mSensors = new ArrayList<>(); field in BiometricService
499 for (BiometricSensor sensor : mSensors) {
515 for (BiometricSensor sensor : mSensors) {
604 for (BiometricSensor sensor : mSensors) {
642 for (BiometricSensor sensor : mSensors) {
648 mSensors.add(new BiometricSensor(getContext(), id, modality, strength, authenticator) {
682 InvalidationTracker.start(getContext(), mSensors, userId, fromSensorId, callback);
690 for (BiometricSensor sensor : mSensors) {
729 for (BiometricSensor sensor : mSensors) {
758 for (BiometricSensor sensor : mSensors) {
[all …]
DBiometricStrengthController.java86 for (BiometricSensor sensor : mService.mSensors) { in updateStrengths()
98 for (BiometricSensor sensor : mService.mSensors) { in revertStrengths()
DAuthSession.java134 private int[] mSensors; field in AuthSession
251 mSensors = new int[0]; in goToInitialState()
257 mSensors /* sensorIds */, in goToInitialState()
303 mSensors = new int[mPreAuthInfo.eligibleSensors.size()]; in onCookieReceived()
305 mSensors[i] = mPreAuthInfo.eligibleSensors.get(i).id; in onCookieReceived()
312 mSensors, in onCookieReceived()
436 mSensors = new int[0]; in onErrorReceived()
441 mSensors /* sensorIds */, in onErrorReceived()
/frameworks/base/packages/SystemUI/src/com/android/systemui/doze/
DDozeSensors.java516 @NonNull final Sensor[] mSensors; // index = posture, value = sensor field in DozeSensors.TriggerSensor
604 mSensors = sensors; in TriggerSensor()
623 || mSensors.length < 2 in setPosture()
624 || posture >= mSensors.length) { in setPosture()
628 Sensor oldSensor = mSensors[mPosture]; in setPosture()
629 Sensor newSensor = mSensors[posture]; in setPosture()
679 final Sensor sensor = mSensors[mPosture]; in updateListening()
715 .append(", mSensors=").append(Arrays.toString(mSensors)); in toString()
716 if (mSensors.length > 2) { in toString()
726 final Sensor sensor = mSensors[mPosture]; in onTrigger()
/frameworks/base/services/tests/servicestests/src/com/android/server/biometrics/sensors/face/aidl/
DFaceProviderTest.java107 mFaceProvider.mSensors.get(prop.commonProps.sensorId).getScheduler(); in halServiceDied_resetsAllSchedulers()
119 mFaceProvider.mSensors.get(prop.commonProps.sensorId).getScheduler(); in halServiceDied_resetsAllSchedulers()
132 mFaceProvider.mSensors.get(prop.commonProps.sensorId).getScheduler(); in halServiceDied_resetsAllSchedulers()
/frameworks/base/services/tests/servicestests/src/com/android/server/biometrics/sensors/fingerprint/aidl/
DFingerprintProviderTest.java123 mFingerprintProvider.mSensors.get(prop.commonProps.sensorId).getScheduler(); in halServiceDied_resetsAllSchedulers()
135 mFingerprintProvider.mSensors.get(prop.commonProps.sensorId).getScheduler(); in halServiceDied_resetsAllSchedulers()
148 mFingerprintProvider.mSensors.get(prop.commonProps.sensorId).getScheduler(); in halServiceDied_resetsAllSchedulers()
/frameworks/native/libs/sensor/include/sensor/
DSensorManager.h87 Vector<Sensor> mSensors; variable

12