/base/sensors/miscdevice/frameworks/cj/src/ |
H A D | vibrator_ffi.cpp | 94 void FfiVibratorStartVibrationTime(RetVibrateTime effect, RetVibrateAttribute attribute, int32_t &code) in FfiVibratorStartVibrationTime() argument 97 std::string strType(effect.timeType); in FfiVibratorStartVibrationTime() 99 info.duration = effect.duration; in FfiVibratorStartVibrationTime() 106 void FfiVibratorStartVibrationPreset(RetVibratePreset effect, RetVibrateAttribute attribute, int32_t &code) in FfiVibratorStartVibrationPreset() argument 109 std::string strType(effect.presetType); in FfiVibratorStartVibrationPreset() 111 std::string strEffectId(effect.effectId); in FfiVibratorStartVibrationPreset() 113 info.count = effect.count; in FfiVibratorStartVibrationPreset() 114 info.intensity = effect.intensity; in FfiVibratorStartVibrationPreset() 121 void FfiVibratorStartVibrationFile(RetVibrateFromFile effect, RetVibrateAttribute attribute, int32_t &code) in FfiVibratorStartVibrationFile() argument 124 std::string strType(effect in FfiVibratorStartVibrationFile() [all...] |
H A D | vibrator_ffi.h | 54 RetVibrateTime effect, RetVibrateAttribute attribute, int32_t &code); 56 RetVibratePreset effect, RetVibrateAttribute attribute, int32_t &code); 58 RetVibrateFromFile effect, RetVibrateAttribute attribute, int32_t &code);
|
/base/powermgr/battery_manager/charger/src/ |
H A D | battery_led.cpp | 66 struct HdfLightEffect effect; in TurnOn() local 67 effect.lightColor.colorValue.rgbColor.r = static_cast<uint8_t>((color >> MOVE_RIGHT_16) & 0xFF); in TurnOn() 68 effect.lightColor.colorValue.rgbColor.g = static_cast<uint8_t>((color >> MOVE_RIGHT_8) & 0xFF); in TurnOn() 69 effect.lightColor.colorValue.rgbColor.b = static_cast<uint8_t>(color & 0xFF); in TurnOn() 72 int32_t ret = batteryLight_->TurnOnLight(HdfLightId::HDF_LIGHT_ID_BATTERY, effect); in TurnOn()
|
/base/sensors/miscdevice/services/miscdevice_service/hdi_connection/adapter/src/ |
H A D | compatible_connection.cpp | 34 {"haptic.default.effect", 804}, 42 {"haptic.effect.hard", 50}, 43 {"haptic.effect.soft", 30}, 44 {"haptic.effect.sharp", 20} 129 std::optional<HdfEffectInfo> CompatibleConnection::GetEffectInfo(const std::string &effect) in GetEffectInfo() argument 133 if (g_vibratorEffect.find(effect) == g_vibratorEffect.end()) { in GetEffectInfo() 134 MISC_HILOGI("Not support effect:%{public}s", effect.c_str()); in GetEffectInfo() 140 effectInfo.duration = g_vibratorEffect[effect]; in GetEffectInfo() 202 int32_t CompatibleConnection::StartByIntensity(const std::string &effect, int32_ argument [all...] |
H A D | hdi_light_connection.cpp | 88 HDI::Light::V1_0::HdfLightEffect effect; in TurnOn() local 89 effect.lightColor = lightColor; in TurnOn() 90 effect.flashEffect = flashEffect; in TurnOn() 92 int32_t ret = lightInterface_->TurnOnLight(lightId, effect); in TurnOn()
|
H A D | hdi_connection.cpp | 123 std::optional<HdfEffectInfo> HdiConnection::GetEffectInfo(const std::string &effect) in GetEffectInfo() argument 130 int32_t ret = vibratorInterface_->GetEffectInfo(effect, effectInfo); in GetEffectInfo() 284 int32_t HdiConnection::StartByIntensity(const std::string &effect, int32_t intensity) in StartByIntensity() argument 286 MISC_HILOGD("Time delay measurement:end time, effect:%{public}s, intensity:%{public}d", effect.c_str(), intensity); in StartByIntensity() 287 if (effect.empty()) { in StartByIntensity() 288 MISC_HILOGE("effect is null"); in StartByIntensity() 292 int32_t ret = vibratorInterface_->StartByIntensity(effect, intensity); in StartByIntensity()
|
/base/sensors/miscdevice/frameworks/native/common/include/ |
H A D | miscdevice_service_proxy.h | 31 virtual int32_t PlayVibratorEffect(int32_t vibratorId, const std::string &effect, 39 virtual int32_t IsSupportEffect(const std::string &effect, bool &state) override; 47 virtual int32_t PlayPrimitiveEffect(int32_t vibratorId, const std::string &effect, int32_t intensity,
|
H A D | i_miscdevice_service.h | 40 virtual int32_t PlayVibratorEffect(int32_t vibratorId, const std::string &effect, 48 virtual int32_t IsSupportEffect(const std::string &effect, bool &state) = 0; 56 virtual int32_t PlayPrimitiveEffect(int32_t vibratorId, const std::string &effect, int32_t intensity,
|
/base/sensors/miscdevice/services/miscdevice_service/hdi_connection/interface/src/ |
H A D | vibrator_hdi_connection.cpp | 113 std::optional<HdfEffectInfo> VibratorHdiConnection::GetEffectInfo(const std::string &effect) in GetEffectInfo() argument 122 std::optional<HdfEffectInfo> ret = iVibratorHdiConnection_->GetEffectInfo(effect); in GetEffectInfo() 176 int32_t VibratorHdiConnection::StartByIntensity(const std::string &effect, int32_t intensity) in StartByIntensity() argument 182 int32_t ret = iVibratorHdiConnection_->StartByIntensity(effect, intensity); in StartByIntensity()
|
/base/sensors/miscdevice/services/miscdevice_service/hdi_connection/adapter/include/ |
H A D | compatible_connection.h | 38 std::optional<HdfEffectInfo> GetEffectInfo(const std::string &effect) override;
45 int32_t StartByIntensity(const std::string &effect, int32_t intensity) override;
|
H A D | hdi_connection.h | 43 std::optional<HdfEffectInfo> GetEffectInfo(const std::string &effect) override;
51 int32_t StartByIntensity(const std::string &effect, int32_t intensity) override;
|
/base/sensors/miscdevice/services/miscdevice_service/hdi_connection/interface/include/ |
H A D | vibrator_hdi_connection.h | 37 std::optional<HdfEffectInfo> GetEffectInfo(const std::string &effect) override;
44 int32_t StartByIntensity(const std::string &effect, int32_t intensity) override;
|
H A D | i_vibrator_hdi_connection.h | 68 virtual std::optional<HdfEffectInfo> GetEffectInfo(const std::string &effect) = 0;
75 virtual int32_t StartByIntensity(const std::string &effect, int32_t intensity) = 0;
|
/base/sensors/miscdevice/services/miscdevice_service/src/ |
H A D | vibrator_thread.cpp | 49 MISC_HILOGE("Play effect vibration fail, package:%{public}s", info.packageName.c_str());
in Run() 62 MISC_HILOGE("Play custom vibration by composite effect fail, package:%{public}s", info.packageName.c_str());
in Run() 93 std::string effect = info.effect;
in PlayEffect() local 94 int32_t ret = VibratorDevice.StartByIntensity(effect, info.intensity);
in PlayEffect() 96 MISC_HILOGE("Vibrate effect %{public}s failed, ", effect.c_str());
in PlayEffect() 104 MISC_HILOGD("Stop effect:%{public}s, package:%{public}s", effect.c_str(), info.packageName.c_str());
in PlayEffect() 192 MISC_HILOGD("Stop composite effect par in PlayCompositeEffect() [all...] |
H A D | miscdevice_service_stub.cpp | 104 std::string effect; in PlayVibratorEffectStub() local 108 if ((!data.ReadInt32(vibratorId)) || (!data.ReadString(effect)) || in PlayVibratorEffectStub() 113 return PlayVibratorEffect(vibratorId, effect, count, usage, systemUsage); in PlayVibratorEffectStub() 139 std::string effect; in IsSupportEffectStub() local 140 if (!data.ReadString(effect)) { in IsSupportEffectStub() 141 MISC_HILOGE("Parcel read effect failed"); in IsSupportEffectStub() 145 int32_t ret = IsSupportEffect(effect, state); in IsSupportEffectStub() 147 MISC_HILOGE("Query support effect failed"); in IsSupportEffectStub() 410 std::string effect; in PlayPrimitiveEffectStub() local 415 if ((!data.ReadInt32(vibratorId)) || (!data.ReadString(effect)) || in PlayPrimitiveEffectStub() [all...] |
H A D | miscdevice_service.cpp | 372 int32_t MiscdeviceService::PlayVibratorEffect(int32_t vibratorId, const std::string &effect, in PlayVibratorEffect() argument 380 std::optional<HdfEffectInfo> effectInfo = vibratorHdiConnection_.GetEffectInfo(effect); in PlayVibratorEffect() 400 .effect = effect, in PlayVibratorEffect() 412 "vibratorId:%{public}d, duration:%{public}d, effect:%{public}s, count:%{public}d", curVibrateTime.c_str(), in PlayVibratorEffect() 413 info.packageName.c_str(), info.pid, info.usage, vibratorId, info.duration, info.effect.c_str(), info.count); in PlayVibratorEffect() 464 int32_t MiscdeviceService::IsSupportEffect(const std::string &effect, bool &state) in IsSupportEffect() argument 467 std::optional<HdfEffectInfo> effectInfo = vibratorHdiConnection_.GetEffectInfo(effect); in IsSupportEffect() 475 MISC_HILOGI("IsSupportEffect, currentTime:%{public}s, package:%{public}s, pid:%{public}d, effect:%{public}s," in IsSupportEffect() 476 "state:%{public}d", curVibrateTime.c_str(), packageName.c_str(), GetCallingPid(), effect in IsSupportEffect() 867 PlayPrimitiveEffect(int32_t vibratorId, const std::string &effect, int32_t intensity, int32_t usage, bool systemUsage, int32_t count) PlayPrimitiveEffect() argument [all...] |
H A D | miscdevice_dump.cpp | 156 dprintf(fd, "startTime:%s | uid:%d | pid:%d | packageName:%s | effect:%s | count:%d | usage:%s\n", in DumpMiscdeviceRecord() 158 info.effect.c_str(), info.count, GetUsageName(info.usage).c_str()); in DumpMiscdeviceRecord()
|
/base/sensors/miscdevice/frameworks/native/vibrator/include/ |
H A D | vibrator_service_client.h | 58 int32_t Vibrate(int32_t vibratorId, const std::string &effect, int32_t loopCount, int32_t usage, bool systemUsage); 66 int32_t IsSupportEffect(const std::string &effect, bool &state); 75 int32_t PlayPrimitiveEffect(int32_t vibratorId, const std::string &effect, int32_t intensity, int32_t usage,
|
/base/sensors/miscdevice/frameworks/native/vibrator/src/ |
H A D | vibrator_service_client.cpp | 156 int32_t VibratorServiceClient::Vibrate(int32_t vibratorId, const std::string &effect, in Vibrate() argument 159 MISC_HILOGD("Vibrate begin, effect:%{public}s, loopCount:%{public}d, usage:%{public}d", in Vibrate() 160 effect.c_str(), loopCount, usage); in Vibrate() 171 ret = miscdeviceProxy_->PlayVibratorEffect(vibratorId, effect, loopCount, usage, systemUsage); in Vibrate() 176 MISC_HILOGE("Vibrate effect failed, ret:%{public}d, effect:%{public}s, loopCount:%{public}d, usage:%{public}d", in Vibrate() 177 ret, effect.c_str(), loopCount, usage); in Vibrate() 270 int32_t VibratorServiceClient::IsSupportEffect(const std::string &effect, bool &state) in IsSupportEffect() argument 272 MISC_HILOGD("IsSupportEffect begin, effect:%{public}s", effect in IsSupportEffect() 534 PlayPrimitiveEffect(int32_t vibratorId, const std::string &effect, int32_t intensity, int32_t usage, bool systemUsage, int32_t count) PlayPrimitiveEffect() argument [all...] |
/base/sensors/miscdevice/services/miscdevice_service/include/ |
H A D | miscdevice_service.h | 67 virtual int32_t PlayVibratorEffect(int32_t vibratorId, const std::string &effect, 75 virtual int32_t IsSupportEffect(const std::string &effect, bool &state) override; 83 virtual int32_t PlayPrimitiveEffect(int32_t vibratorId, const std::string &effect, int32_t intensity,
|
/base/sensors/miscdevice/frameworks/native/common/src/ |
H A D | miscdevice_service_proxy.cpp | 105 int32_t MiscdeviceServiceProxy::PlayVibratorEffect(int32_t vibratorId, const std::string &effect, in PlayVibratorEffect() argument 117 if (!data.WriteString(effect)) { in PlayVibratorEffect() 118 MISC_HILOGE("WriteString effect failed"); in PlayVibratorEffect() 180 int32_t MiscdeviceServiceProxy::IsSupportEffect(const std::string &effect, bool &state) in IsSupportEffect() argument 187 if (!data.WriteString(effect)) { in IsSupportEffect() 188 MISC_HILOGE("WriteString effect failed"); in IsSupportEffect() 460 int32_t MiscdeviceServiceProxy::PlayPrimitiveEffect(int32_t vibratorId, const std::string &effect, int32_t intensity, in PlayPrimitiveEffect() argument 472 if (!data.WriteString(effect)) { in PlayPrimitiveEffect() 473 MISC_HILOGE("WriteString effect failed"); in PlayPrimitiveEffect()
|
/base/sensors/miscdevice/utils/common/include/ |
H A D | vibrator_infos.h | 32 const std::string VIBRATE_CUSTOM_COMPOSITE_EFFECT = "custom.composite.effect";
129 std::string effect;
member
|