Home
last modified time | relevance | path

Searched refs:SensorMode (Results 1 – 9 of 9) sorted by relevance

/system/chre/core/
Dsensor_type.cc23 const char *getSensorModeName(SensorMode sensorMode) { in getSensorModeName()
25 case SensorMode::Off: in getSensorModeName()
27 case SensorMode::ActiveOneShot: in getSensorModeName()
29 case SensorMode::PassiveOneShot: in getSensorModeName()
31 case SensorMode::ActiveContinuous: in getSensorModeName()
33 case SensorMode::PassiveContinuous: in getSensorModeName()
41 SensorMode getSensorModeFromEnum(enum chreSensorConfigureMode enumSensorMode) { in getSensorModeFromEnum()
44 return SensorMode::Off; in getSensorModeFromEnum()
46 return SensorMode::ActiveContinuous; in getSensorModeFromEnum()
48 return SensorMode::ActiveOneShot; in getSensorModeFromEnum()
[all …]
Dsensor_request.cc41 : SensorRequest(SensorMode::Off, Nanoseconds(CHRE_SENSOR_INTERVAL_DEFAULT), in SensorRequest()
44 SensorRequest::SensorRequest(SensorMode mode, Nanoseconds interval, in SensorRequest()
48 SensorRequest::SensorRequest(uint32_t instanceId, SensorMode mode, in SensorRequest()
78 if (request.mMode != SensorMode::Off) { in mergeWith()
110 SensorMode maximalSensorMode = SensorMode::Off; in mergeWith()
111 if (mMode == SensorMode::ActiveContinuous || in mergeWith()
112 request.mMode == SensorMode::ActiveContinuous) { in mergeWith()
113 maximalSensorMode = SensorMode::ActiveContinuous; in mergeWith()
114 } else if (mMode == SensorMode::ActiveOneShot || in mergeWith()
115 request.mMode == SensorMode::ActiveOneShot) { in mergeWith()
[all …]
Dsensor_request_manager.cc34 bool isRequestOff = sensorRequest.getMode() == SensorMode::Off; in isSensorRequestValid()
69 sensor->getMaximalRequest().getMode() != SensorMode::Off) { in updateLastEvent()
189 if (request.getMode() == SensorMode::Off) { in setSensorRequest()
866 bool enable = (request.getMode() != SensorMode::Off); in configurePlatformSensor()
887 if (request.getMode() == SensorMode::Off) { in configurePlatformSensor()
/system/chre/core/tests/
Dsensor_request_test.cc23 using chre::SensorMode;
30 EXPECT_EQ(request.getMode(), SensorMode::Off); in TEST()
34 SensorRequest activeContinuous(SensorMode::ActiveContinuous, Nanoseconds(0), in TEST()
36 SensorRequest activeOneShot(SensorMode::ActiveOneShot, Nanoseconds(0), in TEST()
43 EXPECT_EQ(mergedRequest.getMode(), SensorMode::ActiveContinuous); in TEST()
47 SensorRequest activeOneShot(SensorMode::ActiveOneShot, Nanoseconds(0), in TEST()
49 SensorRequest passiveContinuous(SensorMode::PassiveContinuous, Nanoseconds(0), in TEST()
56 EXPECT_EQ(mergedRequest.getMode(), SensorMode::ActiveOneShot); in TEST()
60 SensorRequest passiveContinuous(SensorMode::PassiveContinuous, Nanoseconds(0), in TEST()
62 SensorRequest passiveOneShot(SensorMode::PassiveOneShot, Nanoseconds(0), in TEST()
[all …]
/system/chre/core/include/chre/core/
Dsensor_type.h91 enum class SensorMode { enum
105 const char *getSensorModeName(SensorMode sensorMode);
111 constexpr bool sensorModeIsActive(SensorMode sensorMode) { in sensorModeIsActive()
112 return (sensorMode == SensorMode::ActiveContinuous || in sensorModeIsActive()
113 sensorMode == SensorMode::ActiveOneShot); in sensorModeIsActive()
120 constexpr bool sensorModeIsPassive(SensorMode sensorMode) { in sensorModeIsPassive()
121 return (sensorMode == SensorMode::PassiveContinuous || in sensorModeIsPassive()
122 sensorMode == SensorMode::PassiveOneShot); in sensorModeIsPassive()
128 constexpr bool sensorModeIsContinuous(SensorMode sensorMode) { in sensorModeIsContinuous()
129 return (sensorMode == SensorMode::ActiveContinuous || in sensorModeIsContinuous()
[all …]
Dsensor_request.h54 SensorRequest(SensorMode mode, Nanoseconds interval, Nanoseconds latency);
67 SensorRequest(uint32_t instanceId, SensorMode mode, Nanoseconds interval,
123 SensorMode getMode() const { in getMode()
163 SensorMode mMode;
Dsensor_request_manager.h306 uint32_t sensorHandleIn, SensorMode modeIn, in SensorRequestLog()
320 SensorMode mode;
/system/chre/platform/shared/
Dchre_api_sensor.cc27 using chre::SensorMode;
96 SensorMode sensorMode = getSensorModeFromEnum(mode); in chreSensorConfigure()
/system/chre/platform/slpi/see/
Dplatform_sensor_manager.cc721 .enable = (request.getMode() != SensorMode::Off), in configureSensor()