Lines Matching +full:pen +full:- +full:up
1 // SPDX-License-Identifier: GPL-2.0-or-later
15 #include "hid-ids.h"
26 * mode tries to be HID-compatible (not very successfully), but cripples the
30 * represents the correct resolution, but is possibly HID-incompatible (i.e.
48 0x09, 0x02, /* Usage (Pen), */
75 0x55, 0xFD, /* Unit Exponent (-3), */
99 0x09, 0x02, /* Usage (Pen), */
126 0x55, 0xFD, /* Unit Exponent (-3), */
150 0x09, 0x02, /* Usage (Pen), */
177 0x55, 0xFD, /* Unit Exponent (-3), */
203 0x09, 0x02, /* Usage (Pen), */
230 0x55, 0xFD, /* Unit Exponent (-3), */
254 0x09, 0x02, /* Usage (Pen), */
281 0x55, 0xFD, /* Unit Exponent (-3), */
307 0x15, 0xFF, /* Logical Minimum (-1), */
367 0x09, 0x02, /* Usage (Pen), */
394 0x55, 0xFD, /* Unit Exponent (-3), */
420 0x15, 0xFF, /* Logical Minimum (-1), */
478 0x09, 0x02, /* Usage (Pen), */
503 0x55, 0xFD, /* Unit Exponent (-3), */
525 0x55, 0xFE, /* Unit Exponent (-2), */
527 0x35, 0x97, /* Physical Minimum (-105), */
529 0x15, 0x97, /* Logical Minimum (-105), */
549 0x15, 0xFF, /* Logical Minimum (-1), */
605 switch (hdev->product) { in waltop_report_fixup()
655 /* If this is a pen input report */ in waltop_raw_event()
656 if (report->type == HID_INPUT_REPORT && report->id == 16 && size >= 8) { in waltop_raw_event()
670 /* If this is a pen input report of Sirius Battery Free Tablet */ in waltop_raw_event()
671 if (hdev->product == USB_DEVICE_ID_WALTOP_SIRIUS_BATTERY_FREE_TABLET && in waltop_raw_event()
672 report->type == HID_INPUT_REPORT && in waltop_raw_event()
673 report->id == 16 && in waltop_raw_event()
680 * reported values up to 60 degrees, as expected by userspace. in waltop_raw_event()
689 s8 sign_x = tilt_x >= 0 ? 1 : -1; in waltop_raw_event()
690 s8 sign_y = tilt_y >= 0 ? 1 : -1; in waltop_raw_event()
700 sign_y *= -1; in waltop_raw_event()
703 * This effectively clamps reported tilt to 60 degrees - the in waltop_raw_event()
706 if (tilt_x > ARRAY_SIZE(tilt_to_radians) - 1) in waltop_raw_event()
707 tilt_x = ARRAY_SIZE(tilt_to_radians) - 1; in waltop_raw_event()
708 if (tilt_y > ARRAY_SIZE(tilt_to_radians) - 1) in waltop_raw_event()
709 tilt_y = ARRAY_SIZE(tilt_to_radians) - 1; in waltop_raw_event()