Home
last modified time | relevance | path

Searched refs:propertyValue (Results 1 – 8 of 8) sorted by relevance

/packages/services/Car/car-lib/src/android/car/hardware/
DCarSensorManager.java454 CarPropertyValue propertyValue = mCarPropertyMgr.getProperty(type, 0); in getLatestSensorEvent() local
455 return createCarSensorEvent(propertyValue); in getLatestSensorEvent()
458 private CarSensorEvent createCarSensorEvent(CarPropertyValue propertyValue) { in createCarSensorEvent() argument
460 switch (propertyValue.getPropertyId() & VehiclePropertyType.MASK) { in createCarSensorEvent()
462 event = new CarSensorEvent(propertyValue.getPropertyId(), in createCarSensorEvent()
463 propertyValue.getTimestamp(), 1, 0, 0); in createCarSensorEvent()
464 event.floatValues[0] = (float) propertyValue.getValue(); in createCarSensorEvent()
467 event = new CarSensorEvent(propertyValue.getPropertyId(), in createCarSensorEvent()
468 propertyValue.getTimestamp(), 0, 1, 0); in createCarSensorEvent()
469 event.intValues[0] = (int) propertyValue.getValue(); in createCarSensorEvent()
[all …]
/packages/services/Car/tests/vehiclehal_test/src/com/android/car/vehiclehal/test/
DCarPropertyTest.java252 CarPropertyValue<Object[]> propertyValue = propertyManager.getProperty(Object[].class, in testMixedTypeProperty() local
254 assertArrayEquals(DEFAULT_VALUE, propertyValue.getValue()); in testMixedTypeProperty()
368 for (CarPropertyValue propertyValue : expectedEvents) { in injectEventFromVehicleSide()
372 if (propertyValue.getValue() instanceof Integer) { in injectEventFromVehicleSide()
374 values[0] = propertyValue.getPropertyId(); in injectEventFromVehicleSide()
375 values[1] = propertyValue.getValue(); in injectEventFromVehicleSide()
376 values[2] = propertyValue.getTimestamp() + SystemClock.elapsedRealtimeNanos(); in injectEventFromVehicleSide()
377 } else if (propertyValue.getValue() instanceof Float) { in injectEventFromVehicleSide()
378 values[0] = propertyValue.getPropertyId(); in injectEventFromVehicleSide()
379 values[1] = propertyValue.getTimestamp() + SystemClock.elapsedRealtimeNanos(); in injectEventFromVehicleSide()
[all …]
/packages/services/Car/service/src/com/android/car/
DCarDrivingStateService.java477 CarPropertyValue propertyValue = mPropertyService.getPropertySafe( in updateVehiclePropertiesIfNeededLocked() local
480 if (propertyValue != null) { in updateVehiclePropertiesIfNeededLocked()
481 mLastGear = (Integer) propertyValue.getValue(); in updateVehiclePropertiesIfNeededLocked()
482 mLastGearTimestamp = propertyValue.getTimestamp(); in updateVehiclePropertiesIfNeededLocked()
490 CarPropertyValue propertyValue = mPropertyService.getPropertySafe( in updateVehiclePropertiesIfNeededLocked() local
493 if (propertyValue != null) { in updateVehiclePropertiesIfNeededLocked()
494 mLastParkingBrakeState = (boolean) propertyValue.getValue(); in updateVehiclePropertiesIfNeededLocked()
495 mLastParkingBrakeTimestamp = propertyValue.getTimestamp(); in updateVehiclePropertiesIfNeededLocked()
503 CarPropertyValue propertyValue = mPropertyService.getPropertySafe( in updateVehiclePropertiesIfNeededLocked() local
506 if (propertyValue != null) { in updateVehiclePropertiesIfNeededLocked()
[all …]
DCarNightService.java173 CarPropertyValue propertyValue = mCarPropertyService.getPropertySafe( in init() local
175 if (propertyValue != null && propertyValue.getTimestamp() != 0) { in init()
176 mLastSensorEventTime = propertyValue.getTimestamp(); in init()
177 setNightModeLocked((Boolean) propertyValue.getValue()); in init()
/packages/services/Car/tests/EmbeddedKitchenSinkApp/src/com/google/android/car/kitchensink/sensor/
DSensorsTestFragment.java273 CarPropertyValue propertyValue = mValueMap.get(propertyId); in formSummary() local
277 if (propertyValue != null) { in formSummary()
278 Long[] wheelTickData = (Long[]) propertyValue.getValue(); in formSummary()
280 getTimestamp(propertyValue), in formSummary()
288 getTimestamp(propertyValue), in formSummary()
300 resourceId, getTimestamp(propertyValue), in formSummary()
301 getStringOfPropertyValue(propertyValue))); in formSummary()
/packages/services/Car/car-lib/src/android/car/hardware/property/
DCarPropertyManager.java636 private <T> T handleNullAndPropertyStatus(CarPropertyValue<T> propertyValue, int areaId, in handleNullAndPropertyStatus() argument
639 if (propertyValue == null) { in handleNullAndPropertyStatus()
645 return propertyValue.getStatus() == CarPropertyValue.STATUS_AVAILABLE in handleNullAndPropertyStatus()
646 ? propertyValue.getValue() : defaultValue; in handleNullAndPropertyStatus()
650 switch (propertyValue.getStatus()) { in handleNullAndPropertyStatus()
652 throw new CarInternalErrorException(propertyValue.getPropertyId(), areaId); in handleNullAndPropertyStatus()
654 throw new PropertyNotAvailableException(propertyValue.getPropertyId(), areaId); in handleNullAndPropertyStatus()
656 return propertyValue.getValue(); in handleNullAndPropertyStatus()
/packages/apps/Settings/tests/robotests/src/com/android/settings/development/
DBluetoothMaxConnectedAudioDevicesPreferenceControllerTest.java124 final String propertyValue = mListValues[i].toString(); in updateState_NumberOfDevicesUpdated_shouldSetPreference() local
125 SystemProperties.set(MAX_CONNECTED_AUDIO_DEVICES_PROPERTY, propertyValue); in updateState_NumberOfDevicesUpdated_shouldSetPreference()
133 .isEqualTo(propertyValue); in updateState_NumberOfDevicesUpdated_shouldSetPreference()
/packages/apps/Car/Hvac/src/com/android/car/hvac/
DHvacController.java237 public static <E> E getValue(CarPropertyValue propertyValue) { in getValue() argument
238 return (E) propertyValue.getValue(); in getValue()
241 public static boolean isAvailable(CarPropertyValue propertyValue) { in isAvailable() argument
242 return propertyValue.getStatus() == CarPropertyValue.STATUS_AVAILABLE; in isAvailable()