mirror of
https://gitlab.freedesktop.org/monado/monado.git
synced 2025-01-04 06:06:17 +00:00
d/qwerty: Implement haptic output
This commit is contained in:
parent
4ea696bfdd
commit
8b81afeb59
|
@ -116,7 +116,16 @@ qwerty_update_inputs(struct xrt_device *xd)
|
|||
static void
|
||||
qwerty_set_output(struct xrt_device *xd, enum xrt_output_name name, union xrt_output_value *value)
|
||||
{
|
||||
return;
|
||||
struct qwerty_device *qd = qwerty_device(xd);
|
||||
float frequency = value->vibration.frequency;
|
||||
float amplitude = value->vibration.amplitude;
|
||||
time_duration_ns duration = value->vibration.duration;
|
||||
if (amplitude || duration || frequency) {
|
||||
QWERTY_INFO(qd,
|
||||
"[%s] Haptic output: \n"
|
||||
"\tfrequency=%.2f amplitude=%.2f duration=%ld",
|
||||
xd->str, frequency, amplitude, duration);
|
||||
}
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
Loading…
Reference in a new issue