WPF Crash on modern Touchscreen when EnablePointerSupport is enabled
Description
On a Surface Pro 9 my WPF app crashes when clicking anything.
This seems to be caused by enabling Switch.System.Windows.Input.Stylus.EnablePointerSupport
I have attached an example repo
This was recommend by CefSharp in there Example See here: https://github.com/cefsharp/CefSharp/blob/master/CefSharp.Wpf.Example/App.xaml.cs
> PresentationCore.dll!System.Windows.Input.StylusPointPropertyInfo.StylusPointPropertyInfo(System.Windows.Input.StylusPointProperty stylusPointProperty, int minimum, int maximum, System.Windows.Input.StylusPointPropertyUnit unit, float resolution) Zeile 70 C#
PresentationCore.dll!System.Windows.Input.StylusPointer.PointerStylusPointPropertyInfoHelper.CreatePropertyInfo(MS.Win32.Pointer.UnsafeNativeMethods.POINTER_DEVICE_PROPERTY prop) Zeile 47 C#
PresentationCore.dll!System.Windows.Input.StylusPointer.PointerTabletDeviceInfo.TryInitializeSupportedStylusPointProperties() Zeile 97 C#
PresentationCore.dll!System.Windows.Input.StylusPointer.PointerTabletDeviceInfo.TryInitialize() Zeile 38 C#
PresentationCore.dll!System.Windows.Input.StylusPointer.PointerTabletDeviceCollection.Refresh() Zeile 56 C#
PresentationCore.dll!System.Windows.Input.StylusPointer.PointerLogic.TabletDevices.get() Zeile 74 C#
PresentationCore.dll!System.Windows.Input.StylusPointer.PointerLogic.PostProcessInput(object sender, System.Windows.Input.ProcessInputEventArgs e) Zeile 205 C#
PresentationCore.dll!System.Windows.Input.InputManager.RaiseProcessInputEventHandlers(System.Tuple<System.Windows.Input.ProcessInputEventHandler, System.Delegate[]> postProcessInput, System.Windows.Input.ProcessInputEventArgs processInputEventArgs) Zeile 614 C#
PresentationCore.dll!System.Windows.Input.InputManager.ProcessStagingArea() Zeile 586 C#
PresentationCore.dll!System.Windows.Input.MouseDevice.ChangeMouseCapture(System.Windows.IInputElement mouseCapture, System.Windows.Input.IMouseInputProvider providerCapture, System.Windows.Input.CaptureMode captureMode, int timestamp) C#
PresentationCore.dll!System.Windows.Input.MouseDevice.Capture(System.Windows.IInputElement element, System.Windows.Input.CaptureMode captureMode) C#
PresentationFramework.dll!System.Windows.Controls.Primitives.ButtonBase.OnMouseLeftButtonDown(System.Windows.Input.MouseButtonEventArgs e) Unbekannt
PresentationCore.dll!System.Windows.RoutedEventArgs.InvokeHandler(System.Delegate handler, object target) Zeile 201 C#
PresentationCore.dll!System.Windows.EventRoute.InvokeHandlersImpl(object source, System.Windows.RoutedEventArgs args, bool reRaised) Zeile 124 C#
PresentationCore.dll!System.Windows.UIElement.ReRaiseEventAs(System.Windows.DependencyObject sender, System.Windows.RoutedEventArgs args, System.Windows.RoutedEvent newEvent) Zeile 6273 C#
PresentationCore.dll!System.Windows.RoutedEventArgs.InvokeHandler(System.Delegate handler, object target) Zeile 201 C#
PresentationCore.dll!System.Windows.EventRoute.InvokeHandlersImpl(object source, System.Windows.RoutedEventArgs args, bool reRaised) Zeile 124 C#
PresentationCore.dll!System.Windows.UIElement.RaiseEventImpl(System.Windows.DependencyObject sender, System.Windows.RoutedEventArgs args) Zeile 6298 C#
PresentationCore.dll!System.Windows.UIElement.RaiseTrustedEvent(System.Windows.RoutedEventArgs args) Zeile 2710 C#
PresentationCore.dll!System.Windows.Input.InputManager.ProcessStagingArea() Zeile 546 C#
PresentationCore.dll!System.Windows.Input.InputProviderSite.ReportInput(System.Windows.Input.InputReport inputReport) Zeile 52 C#
PresentationCore.dll!System.Windows.Interop.HwndMouseInputProvider.ReportInput(nint hwnd, System.Windows.Input.InputMode mode, int timestamp, System.Windows.Input.RawMouseActions actions, int x, int y, int wheel) Zeile 797 C#
PresentationCore.dll!System.Windows.Interop.HwndMouseInputProvider.FilterMessage(nint hwnd, MS.Internal.Interop.WindowMessage msg, nint wParam, nint lParam, ref bool handled) Zeile 343 C#
PresentationCore.dll!System.Windows.Interop.HwndSource.InputFilterMessage(nint hwnd, int msg, nint wParam, nint lParam, ref bool handled) Zeile 1140 C#
WindowsBase.dll!MS.Win32.HwndWrapper.WndProc(nint hwnd, int msg, nint wParam, nint lParam, ref bool handled) Unbekannt
WindowsBase.dll!System.Windows.Threading.ExceptionWrapper.InternalRealCall(System.Delegate callback, object args, int numArgs) Unbekannt
WindowsBase.dll!System.Windows.Threading.ExceptionWrapper.TryCatchWhen(object source, System.Delegate callback, object args, int numArgs, System.Delegate catchHandler) Unbekannt
WindowsBase.dll!System.Windows.Threading.Dispatcher.LegacyInvokeImpl(System.Windows.Threading.DispatcherPriority priority, System.TimeSpan timeout, System.Delegate method, object args, int numArgs) Unbekannt
WindowsBase.dll!MS.Win32.HwndSubclass.SubclassWndProc(nint hwnd, int msg, nint wParam, nint lParam) Unbekannt
[Übergang von Nativ zu Verwaltet]
[Übergang von Verwaltet zu Nativ]
WindowsBase.dll!System.Windows.Threading.Dispatcher.PushFrameImpl(System.Windows.Threading.DispatcherFrame frame) Unbekannt
PresentationFramework.dll!System.Windows.Application.RunDispatcher(object ignore) Unbekannt
PresentationFramework.dll!System.Windows.Application.RunInternal(System.Windows.Window window) Unbekannt
PointerErrorWpfApp.dll!PointerErrorWpfApp.App.Main() Unbekannt
Reproduction Steps
https://github.com/dos-ise/SurfaceStylusError/tree/master
Expected behavior
Should not crash
Actual behavior
Crashes immediately
Regression?
Can also be reproduced in net4.8
Known Workarounds
No response
Impact
No response
Configuration
No response
Other information
No response
The logic Min is greater than the logic.Max property. This common HID descriptor error occurs on devices. But Surface Pro 9...
Reference: https://github.com/dotnet/wpf/issues/7069#issuecomment-1807554225
Seems to be reproducable with the Surface Pro 9 as mentioned in the following comment.
https://github.com/dotnet/wpf/issues/7069#issuecomment-1729199468
@dos-ise I do not think the HID descriptor be error in Surface Pro 9.
@lindexi What is the common denominator then? I have 5 factory new Surface Pro 9 here and this can be reproduced on each of them.
Works fine on older Surfaces like Surface 7
@dos-ise Just like
05 0D 09 04 A1 01 85 10 09 54 15 00 25 0A 35 00
45 00 65 00 55 00 75 08 95 01 81 02 09 22 A1 02
09 51 81 02 09 42 25 01 45 01 75 01 81 02 95 07
81 03 05 01 09 30 26 FF 0F 46 96 14 65 11 55 0E
75 10 95 01 81 02 09 31 46 94 0B 81 02 C1 00 05
0D 09 22 A1 02 09 51 25 0A 45 00 75 08 81 02 09
42 25 01 45 01 65 00 55 00 75 01 81 02 95 07 81
03 05 01 09 30 26 FF 0F 46 96 14 65 11 55 0E 75
10 95 01 81 02 09 31 46 94 0B 81 02 C1 00 05 0D
09 22 A1 02 09 51 25 0A 45 00 75 08 81 02 09 42
25 01 45 01 65 00 55 00 75 01 81 02 95 07 81 03
05 01 09 30 26 FF 0F 46 96 14 65 11 55 0E 75 10
95 01 81 02 09 31 46 94 0B 81 02 C1 00 05 0D 09
22 A1 02 09 51 25 0A 45 00 75 08 81 02 09 42 25
01 45 01 65 00 55 00 75 01 81 02 95 07 81 03 05
01 09 30 26 FF 0F 46 96 14 65 11 55 0E 75 10 95
01 81 02 09 31 46 94 0B 81 02 C1 00 05 0D 09 22
A1 02 09 51 25 0A 45 00 75 08 81 02 09 42 25 01
45 01 65 00 55 00 75 01 81 02 95 07 81 03 05 01
09 30 26 FF 0F 46 96 14 65 11 55 0E 75 10 95 01
81 02 09 31 46 94 0B 81 02 C1 00 05 0D 09 22 A1
02 09 51 25 0A 45 00 75 08 81 02 09 42 25 01 45
01 65 00 55 00 75 01 81 02 95 07 81 03 05 01 09
30 26 FF 0F 46 96 14 65 11 55 0E 75 10 95 01 81
02 09 31 46 94 0B 81 02 C1 00 05 0D 09 22 A1 02
09 51 25 0A 45 00 75 08 81 02 09 42 25 01 45 01
65 00 55 00 75 01 81 02 95 07 81 03 05 01 09 30
26 FF 0F 46 96 14 65 11 55 0E 75 10 95 01 81 02
09 31 46 94 0B 81 02 C1 00 05 0D 09 22 A1 02 09
51 25 0A 45 00 75 08 81 02 09 42 25 01 45 01 65
00 55 00 75 01 81 02 95 07 81 03 05 01 09 30 26
FF 0F 46 96 14 65 11 55 0E 75 10 95 01 81 02 09
31 46 94 0B 81 02 C1 00 05 0D 09 22 A1 02 09 51
25 0A 45 00 75 08 81 02 09 42 25 01 45 01 65 00
55 00 75 01 81 02 95 07 81 03 05 01 09 30 26 FF
0F 46 96 14 65 11 55 0E 75 10 95 01 81 02 09 31
46 94 0B 81 02 C1 00 05 0D 09 22 A1 02 09 51 25
0A 45 00 75 08 81 02 09 42 25 01 45 01 65 00 55
00 75 01 81 02 95 07 81 03 05 01 09 30 26 FF 0F
46 96 14 65 11 55 0E 75 10 95 01 81 02 09 31 46
94 0B 81 02 C1 00 05 0D 09 56 26 FF FF 46 FF FF
66 01 10 55 0C 81 02 85 08 09 55 25 0A 75 08 B1
02 25 01 45 01 65 00 55 00 75 01 96 F8 07 B1 03
85 44 06 00 FF 09 C5 25 FF 46 FF FF 66 01 10 55
0C 75 08 96 00 01 B1 02 C1 00
The message above means:
0x05, 0x0D, // Usage Page (Digitizer)
0x09, 0x04, // Usage (Touch Screen)
0xA1, 0x01, // Collection (Application)
0x85, 0x10, // Report ID (16)
0x09, 0x54, // Usage (0x54)
0x15, 0x00, // Logical Minimum (0)
0x25, 0x0A, // Logical Maximum (10)
0x35, 0x00, // Physical Minimum (0)
0x45, 0x00, // Physical Maximum (0)
0x65, 0x00, // Unit (None)
0x55, 0x00, // Unit Exponent (0)
0x75, 0x08, // Report Size (8)
0x95, 0x01, // Report Count (1)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x09, 0x22, // Usage (Finger)
0xA1, 0x02, // Collection (Logical)
0x09, 0x51, // Usage (0x51)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x09, 0x42, // Usage (Tip Switch)
0x25, 0x01, // Logical Maximum (1)
0x45, 0x01, // Physical Maximum (1)
0x75, 0x01, // Report Size (1)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x95, 0x07, // Report Count (7)
0x81, 0x03, // Input (Const,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x05, 0x01, // Usage Page (Generic Desktop Ctrls)
0x09, 0x30, // Usage (X)
0x26, 0xFF, 0x0F, // Logical Maximum (4095)
0x46, 0x96, 0x14, // Physical Maximum (5270)
0x65, 0x11, // Unit (System: SI Linear, Length: Centimeter)
0x55, 0x0E, // Unit Exponent (-2)
0x75, 0x10, // Report Size (16)
0x95, 0x01, // Report Count (1)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x09, 0x31, // Usage (Y)
0x46, 0x94, 0x0B, // Physical Maximum (2964)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0xC1, 0x00, // End Collection
0x05, 0x0D, // Usage Page (Digitizer)
0x09, 0x22, // Usage (Finger)
0xA1, 0x02, // Collection (Logical)
0x09, 0x51, // Usage (0x51)
0x25, 0x0A, // Logical Maximum (10)
0x45, 0x00, // Physical Maximum (0)
0x75, 0x08, // Report Size (8)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x09, 0x42, // Usage (Tip Switch)
0x25, 0x01, // Logical Maximum (1)
0x45, 0x01, // Physical Maximum (1)
0x65, 0x00, // Unit (None)
0x55, 0x00, // Unit Exponent (0)
0x75, 0x01, // Report Size (1)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x95, 0x07, // Report Count (7)
0x81, 0x03, // Input (Const,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x05, 0x01, // Usage Page (Generic Desktop Ctrls)
0x09, 0x30, // Usage (X)
0x26, 0xFF, 0x0F, // Logical Maximum (4095)
0x46, 0x96, 0x14, // Physical Maximum (5270)
0x65, 0x11, // Unit (System: SI Linear, Length: Centimeter)
0x55, 0x0E, // Unit Exponent (-2)
0x75, 0x10, // Report Size (16)
0x95, 0x01, // Report Count (1)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x09, 0x31, // Usage (Y)
0x46, 0x94, 0x0B, // Physical Maximum (2964)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0xC1, 0x00, // End Collection
0x05, 0x0D, // Usage Page (Digitizer)
0x09, 0x22, // Usage (Finger)
0xA1, 0x02, // Collection (Logical)
0x09, 0x51, // Usage (0x51)
0x25, 0x0A, // Logical Maximum (10)
0x45, 0x00, // Physical Maximum (0)
0x75, 0x08, // Report Size (8)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x09, 0x42, // Usage (Tip Switch)
0x25, 0x01, // Logical Maximum (1)
0x45, 0x01, // Physical Maximum (1)
0x65, 0x00, // Unit (None)
0x55, 0x00, // Unit Exponent (0)
0x75, 0x01, // Report Size (1)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x95, 0x07, // Report Count (7)
0x81, 0x03, // Input (Const,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x05, 0x01, // Usage Page (Generic Desktop Ctrls)
0x09, 0x30, // Usage (X)
0x26, 0xFF, 0x0F, // Logical Maximum (4095)
0x46, 0x96, 0x14, // Physical Maximum (5270)
0x65, 0x11, // Unit (System: SI Linear, Length: Centimeter)
0x55, 0x0E, // Unit Exponent (-2)
0x75, 0x10, // Report Size (16)
0x95, 0x01, // Report Count (1)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x09, 0x31, // Usage (Y)
0x46, 0x94, 0x0B, // Physical Maximum (2964)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0xC1, 0x00, // End Collection
0x05, 0x0D, // Usage Page (Digitizer)
0x09, 0x22, // Usage (Finger)
0xA1, 0x02, // Collection (Logical)
0x09, 0x51, // Usage (0x51)
0x25, 0x0A, // Logical Maximum (10)
0x45, 0x00, // Physical Maximum (0)
0x75, 0x08, // Report Size (8)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x09, 0x42, // Usage (Tip Switch)
0x25, 0x01, // Logical Maximum (1)
0x45, 0x01, // Physical Maximum (1)
0x65, 0x00, // Unit (None)
0x55, 0x00, // Unit Exponent (0)
0x75, 0x01, // Report Size (1)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x95, 0x07, // Report Count (7)
0x81, 0x03, // Input (Const,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x05, 0x01, // Usage Page (Generic Desktop Ctrls)
0x09, 0x30, // Usage (X)
0x26, 0xFF, 0x0F, // Logical Maximum (4095)
0x46, 0x96, 0x14, // Physical Maximum (5270)
0x65, 0x11, // Unit (System: SI Linear, Length: Centimeter)
0x55, 0x0E, // Unit Exponent (-2)
0x75, 0x10, // Report Size (16)
0x95, 0x01, // Report Count (1)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x09, 0x31, // Usage (Y)
0x46, 0x94, 0x0B, // Physical Maximum (2964)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0xC1, 0x00, // End Collection
0x05, 0x0D, // Usage Page (Digitizer)
0x09, 0x22, // Usage (Finger)
0xA1, 0x02, // Collection (Logical)
0x09, 0x51, // Usage (0x51)
0x25, 0x0A, // Logical Maximum (10)
0x45, 0x00, // Physical Maximum (0)
0x75, 0x08, // Report Size (8)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x09, 0x42, // Usage (Tip Switch)
0x25, 0x01, // Logical Maximum (1)
0x45, 0x01, // Physical Maximum (1)
0x65, 0x00, // Unit (None)
0x55, 0x00, // Unit Exponent (0)
0x75, 0x01, // Report Size (1)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x95, 0x07, // Report Count (7)
0x81, 0x03, // Input (Const,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x05, 0x01, // Usage Page (Generic Desktop Ctrls)
0x09, 0x30, // Usage (X)
0x26, 0xFF, 0x0F, // Logical Maximum (4095)
0x46, 0x96, 0x14, // Physical Maximum (5270)
0x65, 0x11, // Unit (System: SI Linear, Length: Centimeter)
0x55, 0x0E, // Unit Exponent (-2)
0x75, 0x10, // Report Size (16)
0x95, 0x01, // Report Count (1)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x09, 0x31, // Usage (Y)
0x46, 0x94, 0x0B, // Physical Maximum (2964)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0xC1, 0x00, // End Collection
0x05, 0x0D, // Usage Page (Digitizer)
0x09, 0x22, // Usage (Finger)
0xA1, 0x02, // Collection (Logical)
0x09, 0x51, // Usage (0x51)
0x25, 0x0A, // Logical Maximum (10)
0x45, 0x00, // Physical Maximum (0)
0x75, 0x08, // Report Size (8)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x09, 0x42, // Usage (Tip Switch)
0x25, 0x01, // Logical Maximum (1)
0x45, 0x01, // Physical Maximum (1)
0x65, 0x00, // Unit (None)
0x55, 0x00, // Unit Exponent (0)
0x75, 0x01, // Report Size (1)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x95, 0x07, // Report Count (7)
0x81, 0x03, // Input (Const,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x05, 0x01, // Usage Page (Generic Desktop Ctrls)
0x09, 0x30, // Usage (X)
0x26, 0xFF, 0x0F, // Logical Maximum (4095)
0x46, 0x96, 0x14, // Physical Maximum (5270)
0x65, 0x11, // Unit (System: SI Linear, Length: Centimeter)
0x55, 0x0E, // Unit Exponent (-2)
0x75, 0x10, // Report Size (16)
0x95, 0x01, // Report Count (1)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x09, 0x31, // Usage (Y)
0x46, 0x94, 0x0B, // Physical Maximum (2964)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0xC1, 0x00, // End Collection
0x05, 0x0D, // Usage Page (Digitizer)
0x09, 0x22, // Usage (Finger)
0xA1, 0x02, // Collection (Logical)
0x09, 0x51, // Usage (0x51)
0x25, 0x0A, // Logical Maximum (10)
0x45, 0x00, // Physical Maximum (0)
0x75, 0x08, // Report Size (8)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x09, 0x42, // Usage (Tip Switch)
0x25, 0x01, // Logical Maximum (1)
0x45, 0x01, // Physical Maximum (1)
0x65, 0x00, // Unit (None)
0x55, 0x00, // Unit Exponent (0)
0x75, 0x01, // Report Size (1)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x95, 0x07, // Report Count (7)
0x81, 0x03, // Input (Const,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x05, 0x01, // Usage Page (Generic Desktop Ctrls)
0x09, 0x30, // Usage (X)
0x26, 0xFF, 0x0F, // Logical Maximum (4095)
0x46, 0x96, 0x14, // Physical Maximum (5270)
0x65, 0x11, // Unit (System: SI Linear, Length: Centimeter)
0x55, 0x0E, // Unit Exponent (-2)
0x75, 0x10, // Report Size (16)
0x95, 0x01, // Report Count (1)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x09, 0x31, // Usage (Y)
0x46, 0x94, 0x0B, // Physical Maximum (2964)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0xC1, 0x00, // End Collection
0x05, 0x0D, // Usage Page (Digitizer)
0x09, 0x22, // Usage (Finger)
0xA1, 0x02, // Collection (Logical)
0x09, 0x51, // Usage (0x51)
0x25, 0x0A, // Logical Maximum (10)
0x45, 0x00, // Physical Maximum (0)
0x75, 0x08, // Report Size (8)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x09, 0x42, // Usage (Tip Switch)
0x25, 0x01, // Logical Maximum (1)
0x45, 0x01, // Physical Maximum (1)
0x65, 0x00, // Unit (None)
0x55, 0x00, // Unit Exponent (0)
0x75, 0x01, // Report Size (1)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x95, 0x07, // Report Count (7)
0x81, 0x03, // Input (Const,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x05, 0x01, // Usage Page (Generic Desktop Ctrls)
0x09, 0x30, // Usage (X)
0x26, 0xFF, 0x0F, // Logical Maximum (4095)
0x46, 0x96, 0x14, // Physical Maximum (5270)
0x65, 0x11, // Unit (System: SI Linear, Length: Centimeter)
0x55, 0x0E, // Unit Exponent (-2)
0x75, 0x10, // Report Size (16)
0x95, 0x01, // Report Count (1)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x09, 0x31, // Usage (Y)
0x46, 0x94, 0x0B, // Physical Maximum (2964)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0xC1, 0x00, // End Collection
0x05, 0x0D, // Usage Page (Digitizer)
0x09, 0x22, // Usage (Finger)
0xA1, 0x02, // Collection (Logical)
0x09, 0x51, // Usage (0x51)
0x25, 0x0A, // Logical Maximum (10)
0x45, 0x00, // Physical Maximum (0)
0x75, 0x08, // Report Size (8)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x09, 0x42, // Usage (Tip Switch)
0x25, 0x01, // Logical Maximum (1)
0x45, 0x01, // Physical Maximum (1)
0x65, 0x00, // Unit (None)
0x55, 0x00, // Unit Exponent (0)
0x75, 0x01, // Report Size (1)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x95, 0x07, // Report Count (7)
0x81, 0x03, // Input (Const,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x05, 0x01, // Usage Page (Generic Desktop Ctrls)
0x09, 0x30, // Usage (X)
0x26, 0xFF, 0x0F, // Logical Maximum (4095)
0x46, 0x96, 0x14, // Physical Maximum (5270)
0x65, 0x11, // Unit (System: SI Linear, Length: Centimeter)
0x55, 0x0E, // Unit Exponent (-2)
0x75, 0x10, // Report Size (16)
0x95, 0x01, // Report Count (1)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x09, 0x31, // Usage (Y)
0x46, 0x94, 0x0B, // Physical Maximum (2964)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0xC1, 0x00, // End Collection
0x05, 0x0D, // Usage Page (Digitizer)
0x09, 0x22, // Usage (Finger)
0xA1, 0x02, // Collection (Logical)
0x09, 0x51, // Usage (0x51)
0x25, 0x0A, // Logical Maximum (10)
0x45, 0x00, // Physical Maximum (0)
0x75, 0x08, // Report Size (8)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x09, 0x42, // Usage (Tip Switch)
0x25, 0x01, // Logical Maximum (1)
0x45, 0x01, // Physical Maximum (1)
0x65, 0x00, // Unit (None)
0x55, 0x00, // Unit Exponent (0)
0x75, 0x01, // Report Size (1)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x95, 0x07, // Report Count (7)
0x81, 0x03, // Input (Const,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x05, 0x01, // Usage Page (Generic Desktop Ctrls)
0x09, 0x30, // Usage (X)
0x26, 0xFF, 0x0F, // Logical Maximum (4095)
0x46, 0x96, 0x14, // Physical Maximum (5270)
0x65, 0x11, // Unit (System: SI Linear, Length: Centimeter)
0x55, 0x0E, // Unit Exponent (-2)
0x75, 0x10, // Report Size (16)
0x95, 0x01, // Report Count (1)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x09, 0x31, // Usage (Y)
0x46, 0x94, 0x0B, // Physical Maximum (2964)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0xC1, 0x00, // End Collection
0x05, 0x0D, // Usage Page (Digitizer)
0x09, 0x56, // Usage (0x56)
0x26, 0xFF, 0xFF, // Logical Maximum (-1)
0x46, 0xFF, 0xFF, // Physical Maximum (-1)
0x66, 0x01, 0x10, // Unit (System: SI Linear, Time: Seconds)
0x55, 0x0C, // Unit Exponent (-4)
0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position)
0x85, 0x08, // Report ID (8)
0x09, 0x55, // Usage (0x55)
0x25, 0x0A, // Logical Maximum (10)
0x75, 0x08, // Report Size (8)
0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile)
0x25, 0x01, // Logical Maximum (1)
0x45, 0x01, // Physical Maximum (1)
0x65, 0x00, // Unit (None)
0x55, 0x00, // Unit Exponent (0)
0x75, 0x01, // Report Size (1)
0x96, 0xF8, 0x07, // Report Count (2040)
0xB1, 0x03, // Feature (Const,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile)
0x85, 0x44, // Report ID (68)
0x06, 0x00, 0xFF, // Usage Page (Vendor Defined 0xFF00)
0x09, 0xC5, // Usage (0xC5)
0x25, 0xFF, // Logical Maximum (-1)
0x46, 0xFF, 0xFF, // Physical Maximum (-1)
0x66, 0x01, 0x10, // Unit (System: SI Linear, Time: Seconds)
0x55, 0x0C, // Unit Exponent (-4)
0x75, 0x08, // Report Size (8)
0x96, 0x00, 0x01, // Report Count (256)
0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile)
0xC1, 0x00, // End Collection
// 714 bytes
And you can use https://github.com/todbot/win-hid-dump tool to dump the HID Descriptor in your devices.
win hid dump crashed immediately on the surface
Seems to be a known issue
https://github.com/todbot/win-hid-dump/issues/2
I noticed the same issue on Surface 5, any update?
@nkolarevic Could you dump HID descriptor?
@nkolarevic Could you dump HID descriptor?
05 01 09 02 A1 01 85 02 09 01 A1 00 05 09 19 01 29 10 15 00 25 01 35 00 45 01 65 00 55 00 75 01 95 10 81 02 05 01 09 30 26 FF 07 45 00 75 0C 95 01 81 06 09 31 81 06 09 38 25 7F 75 08 81 06 05 0C 0A 38 02 81 06 C1 00 C1 00
06 0F FF 09 50 A1 01 85 1F 09 60 15 00 25 FF 35 00 45 00 65 00 55 00 75 08 95 3C 81 02 85 21 09 66 17 00 00 00 80 27 FF FF FF 7F 75 20 95 01 81 02 09 67 81 02 09 68 81 02 09 69 81 02 15 00 25 01 45 01 75 01 96 60 01 81 03 85 22 09 72 17 00 00 00 80 27 FF FF FF 7F 45 00 75 20 95 01 81 02 09 73 81 02 09 74 81 02 09 75 81 02 15 00 25 01 45 01 75 01 96 60 01 81 03 85 1F 09 61 25 FF 45 00 75 08 95 3C 91 02 85 22 09 7A 17 00 00 00 80 27 FF FF FF 7F 75 20 95 01 B1 02 09 7B B1 02 09 7C B1 02 09 7D B1 02 85 23 09 86 B1 02 09 87 B1 02 09 88 B1 02 09 89 B1 02 C1 00
06 FF FF 09 01 A1 01 85 5C 09 05 15 00 25 00 35 00 45 00 65 00 55 00 75 20 95 01 B1 02 09 06 B1 02 09 07 75 10 B1 02 09 08 B1 02 09 09 B1 02 09 0A B1 02 09 0B B1 02 09 0C B1 02 09 0D 75 20 B1 02 09 0F 75 10 B1 02 09 0F B1 02 09 10 B1 02 09 11 B1 02 09 12 B1 02 09 13 B1 02 09 14 B1 02 09 15 B1 02 09 16 B1 02 09 17 95 14 B1 03 C1 00
06 0B FF 09 0B A1 01 85 2E 09 2E 15 00 25 FF 35 00 45 00 65 00 55 00 75 08 95 0F 81 02 25 01 45 01 75 01 96 80 E9 81 03 85 2F 09 2F 25 FF 45 00 75 08 95 1F 81 02 25 01 45 01 75 01 96 00 E9 81 03 85 30 09 30 25 FF 45 00 75 08 95 3E 81 02 25 01 45 01 75 01 96 08 E8 81 03 85 31 09 31 25 FF 45 00 75 08 95 FE 81 02 25 01 45 01 75 01 96 08 E2 81 03 85 32 09 32 25 FF 45 00 75 08 96 FE 01 81 02 25 01 45 01 75 01 96 08 DA 81 03 85 33 09 33 25 FF 45 00 75 08 96 FE 03 81 02 25 01 45 01 75 01 96 08 CA 81 03 85 34 09 34 25 FF 45 00 75 08 96 FE 07 81 02 25 01 45 01 75 01 96 08 AA 81 03 85 35 09 35 25 FF 45 00 75 08 96 FE 0F 81 02 25 01 45 01 75 01 96 08 6A 81 03 85 36 09 36 25 FF 45 00 75 08 96 FE 0D 81 02 25 01 45 01 75 01 96 08 7A 81 03 85 37 09 37 25 FF 45 00 75 08 96 3F 1D 81 02 85 48 09 48 95 02 B1 02 25 01 45 01 75 01 96 E0 0F B1 03 85 29 09 29 25 FF 45 00 75 08 95 0F B1 02 25 01 45 01 75 01 96 78 0F B1 03 85 2A 09 2A 25 FF 45 00 75 08 95 1F B1 02 25 01 45 01 75 01 96 F8 0E B1 03 85 2B 09 2B 25 FF 45 00 75 08 95 3E B1 02 25 01 45 01 75 01 96 00 0E B1 03 85 2C 09 2C 25 FF 45 00 75 08 95 FE B1 02 25 01 45 01 75 01 96 00 08 B1 03 85 2D 09 2D 25 FF 45 00 75 08 96 FE 01 B1 02 C1 00
05 01 09 0D A1 01 85 01 09 0D A1 02 05 07 09 E3 15 00 25 01 35 00 45 01 65 00 55 00 75 01 95 01 81 02 C1 00 05 01 09 0D A1 02 09 81 81 02 C1 00 09 0D A1 02 05 0C 09 E9 81 02 C1 00 05 01 09 0D A1 02 05 0C 09 EA 81 02 C1 00 05 01 09 0D A1 02 09 CA 81 02 95 03 81 03 C1 00 09 0D A1 02 09 CB 95 01 B1 02 C1 00 09 0D A1 02 09 CB B1 02 C1 00 09 0D A1 02 09 CB B1 02 C1 00 09 0D A1 02 09 CB B1 02 C1 00 09 0D A1 02 09 CB B1 02 95 03 B1 03 C1 00 C1 00
06 00 FF 09 01 A1 01 85 10 15 00 25 01 35 00 45 01 65 00 55 00 75 01 95 30 81 03 91 03 C1 00
0x05, 0x01, // Usage Page (Generic Desktop Ctrls) 0x09, 0x02, // Usage (Mouse) 0xA1, 0x01, // Collection (Application) 0x85, 0x02, // Report ID (2) 0x09, 0x01, // Usage (Pointer) 0xA1, 0x00, // Collection (Physical) 0x05, 0x09, // Usage Page (Button) 0x19, 0x01, // Usage Minimum (0x01) 0x29, 0x10, // Usage Maximum (0x10) 0x15, 0x00, // Logical Minimum (0) 0x25, 0x01, // Logical Maximum (1) 0x35, 0x00, // Physical Minimum (0) 0x45, 0x01, // Physical Maximum (1) 0x65, 0x00, // Unit (None) 0x55, 0x00, // Unit Exponent (0) 0x75, 0x01, // Report Size (1) 0x95, 0x10, // Report Count (16) 0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0x05, 0x01, // Usage Page (Generic Desktop Ctrls) 0x09, 0x30, // Usage (X) 0x26, 0xFF, 0x07, // Logical Maximum (2047) 0x45, 0x00, // Physical Maximum (0) 0x75, 0x0C, // Report Size (12) 0x95, 0x01, // Report Count (1) 0x81, 0x06, // Input (Data,Var,Rel,No Wrap,Linear,Preferred State,No Null Position) 0x09, 0x31, // Usage (Y) 0x81, 0x06, // Input (Data,Var,Rel,No Wrap,Linear,Preferred State,No Null Position) 0x09, 0x38, // Usage (Wheel) 0x25, 0x7F, // Logical Maximum (127) 0x75, 0x08, // Report Size (8) 0x81, 0x06, // Input (Data,Var,Rel,No Wrap,Linear,Preferred State,No Null Position) 0x05, 0x0C, // Usage Page (Consumer) 0x0A, 0x38, 0x02, // Usage (AC Pan) 0x81, 0x06, // Input (Data,Var,Rel,No Wrap,Linear,Preferred State,No Null Position) 0xC1, 0x00, // End Collection 0xC1, 0x00, // End Collection 0x06, 0x0F, 0xFF, // Usage Page (Vendor Defined 0xFF0F) 0x09, 0x50, // Usage (0x50) 0xA1, 0x01, // Collection (Application) 0x85, 0x1F, // Report ID (31) 0x09, 0x60, // Usage (0x60) 0x15, 0x00, // Logical Minimum (0) 0x25, 0xFF, // Logical Maximum (-1) 0x35, 0x00, // Physical Minimum (0) 0x45, 0x00, // Physical Maximum (0) 0x65, 0x00, // Unit (None) 0x55, 0x00, // Unit Exponent (0) 0x75, 0x08, // Report Size (8) 0x95, 0x3C, // Report Count (60) 0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0x85, 0x21, // Report ID (33) 0x09, 0x66, // Usage (0x66) 0x17, 0x00, 0x00, 0x00, 0x80, // Logical Minimum (-2147483649) 0x27, 0xFF, 0xFF, 0xFF, 0x7F, // Logical Maximum (2147483646) 0x75, 0x20, // Report Size (32) 0x95, 0x01, // Report Count (1) 0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0x09, 0x67, // Usage (0x67) 0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0x09, 0x68, // Usage (0x68) 0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0x09, 0x69, // Usage (0x69) 0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0x15, 0x00, // Logical Minimum (0) 0x25, 0x01, // Logical Maximum (1) 0x45, 0x01, // Physical Maximum (1) 0x75, 0x01, // Report Size (1) 0x96, 0x60, 0x01, // Report Count (352) 0x81, 0x03, // Input (Const,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0x85, 0x22, // Report ID (34) 0x09, 0x72, // Usage (0x72) 0x17, 0x00, 0x00, 0x00, 0x80, // Logical Minimum (-2147483649) 0x27, 0xFF, 0xFF, 0xFF, 0x7F, // Logical Maximum (2147483646) 0x45, 0x00, // Physical Maximum (0) 0x75, 0x20, // Report Size (32) 0x95, 0x01, // Report Count (1) 0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0x09, 0x73, // Usage (0x73) 0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0x09, 0x74, // Usage (0x74) 0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0x09, 0x75, // Usage (0x75) 0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0x15, 0x00, // Logical Minimum (0) 0x25, 0x01, // Logical Maximum (1) 0x45, 0x01, // Physical Maximum (1) 0x75, 0x01, // Report Size (1) 0x96, 0x60, 0x01, // Report Count (352) 0x81, 0x03, // Input (Const,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0x85, 0x1F, // Report ID (31) 0x09, 0x61, // Usage (0x61) 0x25, 0xFF, // Logical Maximum (-1) 0x45, 0x00, // Physical Maximum (0) 0x75, 0x08, // Report Size (8) 0x95, 0x3C, // Report Count (60) 0x91, 0x02, // Output (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x85, 0x22, // Report ID (34) 0x09, 0x7A, // Usage (0x7A) 0x17, 0x00, 0x00, 0x00, 0x80, // Logical Minimum (-2147483649) 0x27, 0xFF, 0xFF, 0xFF, 0x7F, // Logical Maximum (2147483646) 0x75, 0x20, // Report Size (32) 0x95, 0x01, // Report Count (1) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x09, 0x7B, // Usage (0x7B) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x09, 0x7C, // Usage (0x7C) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x09, 0x7D, // Usage (0x7D) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x85, 0x23, // Report ID (35) 0x09, 0x86, // Usage (0x86) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x09, 0x87, // Usage (0x87) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x09, 0x88, // Usage (0x88) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x09, 0x89, // Usage (0x89) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0xC1, 0x00, // End Collection 0x06, 0xFF, 0xFF, // Usage Page (Vendor Defined 0xFFFF) 0x09, 0x01, // Usage (0x01) 0xA1, 0x01, // Collection (Application) 0x85, 0x5C, // Report ID (92) 0x09, 0x05, // Usage (0x05) 0x15, 0x00, // Logical Minimum (0) 0x25, 0x00, // Logical Maximum (0) 0x35, 0x00, // Physical Minimum (0) 0x45, 0x00, // Physical Maximum (0) 0x65, 0x00, // Unit (None) 0x55, 0x00, // Unit Exponent (0) 0x75, 0x20, // Report Size (32) 0x95, 0x01, // Report Count (1) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x09, 0x06, // Usage (0x06) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x09, 0x07, // Usage (0x07) 0x75, 0x10, // Report Size (16) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x09, 0x08, // Usage (0x08) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x09, 0x09, // Usage (0x09) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x09, 0x0A, // Usage (0x0A) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x09, 0x0B, // Usage (0x0B) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x09, 0x0C, // Usage (0x0C) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x09, 0x0D, // Usage (0x0D) 0x75, 0x20, // Report Size (32) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x09, 0x0F, // Usage (0x0F) 0x75, 0x10, // Report Size (16) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x09, 0x0F, // Usage (0x0F) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x09, 0x10, // Usage (0x10) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x09, 0x11, // Usage (0x11) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x09, 0x12, // Usage (0x12) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x09, 0x13, // Usage (0x13) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x09, 0x14, // Usage (0x14) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x09, 0x15, // Usage (0x15) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x09, 0x16, // Usage (0x16) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x09, 0x17, // Usage (0x17) 0x95, 0x14, // Report Count (20) 0xB1, 0x03, // Feature (Const,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0xC1, 0x00, // End Collection 0x06, 0x0B, 0xFF, // Usage Page (Vendor Defined 0xFF0B) 0x09, 0x0B, // Usage (0x0B) 0xA1, 0x01, // Collection (Application) 0x85, 0x2E, // Report ID (46) 0x09, 0x2E, // Usage (0x2E) 0x15, 0x00, // Logical Minimum (0) 0x25, 0xFF, // Logical Maximum (-1) 0x35, 0x00, // Physical Minimum (0) 0x45, 0x00, // Physical Maximum (0) 0x65, 0x00, // Unit (None) 0x55, 0x00, // Unit Exponent (0) 0x75, 0x08, // Report Size (8) 0x95, 0x0F, // Report Count (15) 0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0x25, 0x01, // Logical Maximum (1) 0x45, 0x01, // Physical Maximum (1) 0x75, 0x01, // Report Size (1) 0x96, 0x80, 0xE9, // Report Count (-5760) 0x81, 0x03, // Input (Const,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0x85, 0x2F, // Report ID (47) 0x09, 0x2F, // Usage (0x2F) 0x25, 0xFF, // Logical Maximum (-1) 0x45, 0x00, // Physical Maximum (0) 0x75, 0x08, // Report Size (8) 0x95, 0x1F, // Report Count (31) 0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0x25, 0x01, // Logical Maximum (1) 0x45, 0x01, // Physical Maximum (1) 0x75, 0x01, // Report Size (1) 0x96, 0x00, 0xE9, // Report Count (-5888) 0x81, 0x03, // Input (Const,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0x85, 0x30, // Report ID (48) 0x09, 0x30, // Usage (0x30) 0x25, 0xFF, // Logical Maximum (-1) 0x45, 0x00, // Physical Maximum (0) 0x75, 0x08, // Report Size (8) 0x95, 0x3E, // Report Count (62) 0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0x25, 0x01, // Logical Maximum (1) 0x45, 0x01, // Physical Maximum (1) 0x75, 0x01, // Report Size (1) 0x96, 0x08, 0xE8, // Report Count (-6136) 0x81, 0x03, // Input (Const,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0x85, 0x31, // Report ID (49) 0x09, 0x31, // Usage (0x31) 0x25, 0xFF, // Logical Maximum (-1) 0x45, 0x00, // Physical Maximum (0) 0x75, 0x08, // Report Size (8) 0x95, 0xFE, // Report Count (-2) 0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0x25, 0x01, // Logical Maximum (1) 0x45, 0x01, // Physical Maximum (1) 0x75, 0x01, // Report Size (1) 0x96, 0x08, 0xE2, // Report Count (-7672) 0x81, 0x03, // Input (Const,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0x85, 0x32, // Report ID (50) 0x09, 0x32, // Usage (0x32) 0x25, 0xFF, // Logical Maximum (-1) 0x45, 0x00, // Physical Maximum (0) 0x75, 0x08, // Report Size (8) 0x96, 0xFE, 0x01, // Report Count (510) 0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0x25, 0x01, // Logical Maximum (1) 0x45, 0x01, // Physical Maximum (1) 0x75, 0x01, // Report Size (1) 0x96, 0x08, 0xDA, // Report Count (-9720) 0x81, 0x03, // Input (Const,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0x85, 0x33, // Report ID (51) 0x09, 0x33, // Usage (0x33) 0x25, 0xFF, // Logical Maximum (-1) 0x45, 0x00, // Physical Maximum (0) 0x75, 0x08, // Report Size (8) 0x96, 0xFE, 0x03, // Report Count (1022) 0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0x25, 0x01, // Logical Maximum (1) 0x45, 0x01, // Physical Maximum (1) 0x75, 0x01, // Report Size (1) 0x96, 0x08, 0xCA, // Report Count (-13816) 0x81, 0x03, // Input (Const,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0x85, 0x34, // Report ID (52) 0x09, 0x34, // Usage (0x34) 0x25, 0xFF, // Logical Maximum (-1) 0x45, 0x00, // Physical Maximum (0) 0x75, 0x08, // Report Size (8) 0x96, 0xFE, 0x07, // Report Count (2046) 0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0x25, 0x01, // Logical Maximum (1) 0x45, 0x01, // Physical Maximum (1) 0x75, 0x01, // Report Size (1) 0x96, 0x08, 0xAA, // Report Count (-22008) 0x81, 0x03, // Input (Const,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0x85, 0x35, // Report ID (53) 0x09, 0x35, // Usage (0x35) 0x25, 0xFF, // Logical Maximum (-1) 0x45, 0x00, // Physical Maximum (0) 0x75, 0x08, // Report Size (8) 0x96, 0xFE, 0x0F, // Report Count (4094) 0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0x25, 0x01, // Logical Maximum (1) 0x45, 0x01, // Physical Maximum (1) 0x75, 0x01, // Report Size (1) 0x96, 0x08, 0x6A, // Report Count (27144) 0x81, 0x03, // Input (Const,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0x85, 0x36, // Report ID (54) 0x09, 0x36, // Usage (0x36) 0x25, 0xFF, // Logical Maximum (-1) 0x45, 0x00, // Physical Maximum (0) 0x75, 0x08, // Report Size (8) 0x96, 0xFE, 0x0D, // Report Count (3582) 0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0x25, 0x01, // Logical Maximum (1) 0x45, 0x01, // Physical Maximum (1) 0x75, 0x01, // Report Size (1) 0x96, 0x08, 0x7A, // Report Count (31240) 0x81, 0x03, // Input (Const,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0x85, 0x37, // Report ID (55) 0x09, 0x37, // Usage (0x37) 0x25, 0xFF, // Logical Maximum (-1) 0x45, 0x00, // Physical Maximum (0) 0x75, 0x08, // Report Size (8) 0x96, 0x3F, 0x1D, // Report Count (7487) 0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0x85, 0x48, // Report ID (72) 0x09, 0x48, // Usage (0x48) 0x95, 0x02, // Report Count (2) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x25, 0x01, // Logical Maximum (1) 0x45, 0x01, // Physical Maximum (1) 0x75, 0x01, // Report Size (1) 0x96, 0xE0, 0x0F, // Report Count (4064) 0xB1, 0x03, // Feature (Const,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x85, 0x29, // Report ID (41) 0x09, 0x29, // Usage (0x29) 0x25, 0xFF, // Logical Maximum (-1) 0x45, 0x00, // Physical Maximum (0) 0x75, 0x08, // Report Size (8) 0x95, 0x0F, // Report Count (15) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x25, 0x01, // Logical Maximum (1) 0x45, 0x01, // Physical Maximum (1) 0x75, 0x01, // Report Size (1) 0x96, 0x78, 0x0F, // Report Count (3960) 0xB1, 0x03, // Feature (Const,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x85, 0x2A, // Report ID (42) 0x09, 0x2A, // Usage (0x2A) 0x25, 0xFF, // Logical Maximum (-1) 0x45, 0x00, // Physical Maximum (0) 0x75, 0x08, // Report Size (8) 0x95, 0x1F, // Report Count (31) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x25, 0x01, // Logical Maximum (1) 0x45, 0x01, // Physical Maximum (1) 0x75, 0x01, // Report Size (1) 0x96, 0xF8, 0x0E, // Report Count (3832) 0xB1, 0x03, // Feature (Const,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x85, 0x2B, // Report ID (43) 0x09, 0x2B, // Usage (0x2B) 0x25, 0xFF, // Logical Maximum (-1) 0x45, 0x00, // Physical Maximum (0) 0x75, 0x08, // Report Size (8) 0x95, 0x3E, // Report Count (62) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x25, 0x01, // Logical Maximum (1) 0x45, 0x01, // Physical Maximum (1) 0x75, 0x01, // Report Size (1) 0x96, 0x00, 0x0E, // Report Count (3584) 0xB1, 0x03, // Feature (Const,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x85, 0x2C, // Report ID (44) 0x09, 0x2C, // Usage (0x2C) 0x25, 0xFF, // Logical Maximum (-1) 0x45, 0x00, // Physical Maximum (0) 0x75, 0x08, // Report Size (8) 0x95, 0xFE, // Report Count (-2) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x25, 0x01, // Logical Maximum (1) 0x45, 0x01, // Physical Maximum (1) 0x75, 0x01, // Report Size (1) 0x96, 0x00, 0x08, // Report Count (2048) 0xB1, 0x03, // Feature (Const,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x85, 0x2D, // Report ID (45) 0x09, 0x2D, // Usage (0x2D) 0x25, 0xFF, // Logical Maximum (-1) 0x45, 0x00, // Physical Maximum (0) 0x75, 0x08, // Report Size (8) 0x96, 0xFE, 0x01, // Report Count (510) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0xC1, 0x00, // End Collection 0x05, 0x01, // Usage Page (Generic Desktop Ctrls) 0x09, 0x0D, // Usage (0x0D) 0xA1, 0x01, // Collection (Application) 0x85, 0x01, // Report ID (1) 0x09, 0x0D, // Usage (0x0D) 0xA1, 0x02, // Collection (Logical) 0x05, 0x07, // Usage Page (Kbrd/Keypad) 0x09, 0xE3, // Usage (0xE3) 0x15, 0x00, // Logical Minimum (0) 0x25, 0x01, // Logical Maximum (1) 0x35, 0x00, // Physical Minimum (0) 0x45, 0x01, // Physical Maximum (1) 0x65, 0x00, // Unit (None) 0x55, 0x00, // Unit Exponent (0) 0x75, 0x01, // Report Size (1) 0x95, 0x01, // Report Count (1) 0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0xC1, 0x00, // End Collection 0x05, 0x01, // Usage Page (Generic Desktop Ctrls) 0x09, 0x0D, // Usage (0x0D) 0xA1, 0x02, // Collection (Logical) 0x09, 0x81, // Usage (Sys Power Down) 0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0xC1, 0x00, // End Collection 0x09, 0x0D, // Usage (0x0D) 0xA1, 0x02, // Collection (Logical) 0x05, 0x0C, // Usage Page (Consumer) 0x09, 0xE9, // Usage (Volume Increment) 0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0xC1, 0x00, // End Collection 0x05, 0x01, // Usage Page (Generic Desktop Ctrls) 0x09, 0x0D, // Usage (0x0D) 0xA1, 0x02, // Collection (Logical) 0x05, 0x0C, // Usage Page (Consumer) 0x09, 0xEA, // Usage (Volume Decrement) 0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0xC1, 0x00, // End Collection 0x05, 0x01, // Usage Page (Generic Desktop Ctrls) 0x09, 0x0D, // Usage (0x0D) 0xA1, 0x02, // Collection (Logical) 0x09, 0xCA, // Usage (0xCA) 0x81, 0x02, // Input (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0x95, 0x03, // Report Count (3) 0x81, 0x03, // Input (Const,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0xC1, 0x00, // End Collection 0x09, 0x0D, // Usage (0x0D) 0xA1, 0x02, // Collection (Logical) 0x09, 0xCB, // Usage (0xCB) 0x95, 0x01, // Report Count (1) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0xC1, 0x00, // End Collection 0x09, 0x0D, // Usage (0x0D) 0xA1, 0x02, // Collection (Logical) 0x09, 0xCB, // Usage (0xCB) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0xC1, 0x00, // End Collection 0x09, 0x0D, // Usage (0x0D) 0xA1, 0x02, // Collection (Logical) 0x09, 0xCB, // Usage (0xCB) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0xC1, 0x00, // End Collection 0x09, 0x0D, // Usage (0x0D) 0xA1, 0x02, // Collection (Logical) 0x09, 0xCB, // Usage (0xCB) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0xC1, 0x00, // End Collection 0x09, 0x0D, // Usage (0x0D) 0xA1, 0x02, // Collection (Logical) 0x09, 0xCB, // Usage (0xCB) 0xB1, 0x02, // Feature (Data,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0x95, 0x03, // Report Count (3) 0xB1, 0x03, // Feature (Const,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0xC1, 0x00, // End Collection 0xC1, 0x00, // End Collection 0x06, 0x00, 0xFF, // Usage Page (Vendor Defined 0xFF00) 0x09, 0x01, // Usage (0x01) 0xA1, 0x01, // Collection (Application) 0x85, 0x10, // Report ID (16) 0x15, 0x00, // Logical Minimum (0) 0x25, 0x01, // Logical Maximum (1) 0x35, 0x00, // Physical Minimum (0) 0x45, 0x01, // Physical Maximum (1) 0x65, 0x00, // Unit (None) 0x55, 0x00, // Unit Exponent (0) 0x75, 0x01, // Report Size (1) 0x95, 0x30, // Report Count (48) 0x81, 0x03, // Input (Const,Var,Abs,No Wrap,Linear,Preferred State,No Null Position) 0x91, 0x03, // Output (Const,Var,Abs,No Wrap,Linear,Preferred State,No Null Position,Non-volatile) 0xC1, 0x00, // End Collection
// 947 bytes
@nkolarevic Thank you. And I find some Logical Maximum be 0 or -1, but I'm not sure there's a problem with that.
And the code below defined the Logical Maximum (-1) is less than Logical Minimum (0).
0x06, 0x0B, 0xFF, // Usage Page (Vendor Defined 0xFF0B)
0x09, 0x0B, // Usage (0x0B)
0xA1, 0x01, // Collection (Application)
0x85, 0x2E, // Report ID (46)
0x09, 0x2E, // Usage (0x2E)
0x15, 0x00, // Logical Minimum (0)
0x25, 0xFF, // Logical Maximum (-1)
0x35, 0x00, // Physical Minimum (0)
0x45, 0x00, // Physical Maximum (0)
I saw @lindexi posted this to the MVP mailing list before the holidays. Is this WPF-specific, an issue in underlying .NET, or something deeper? If it's a .NET-wide issue, we can get more attention by getting it over to the broader .NET team.
Thanks @Psychlist1972, this is connected with WPF. On Surface machines reading info about devices don't work fine, At https://github.com/dotnet/wpf/blob/dba1a21a8d5bb2662d4dd7d3796d92b1691a16fb/src/Microsoft.DotNet.Wpf/src/PresentationCore/System/Windows/Input/Stylus/Pointer/PointerStylusPointPropertyInfoHelper.cs#L63 get wrong data , Logical Maximum less than Minimum.
@Psychlist1972 Thank you. And as the email says, may I know if the definition or behavior of the Surface device is as expected, or in other words, is the judgment in WPF too strict?
@lindexi I don't know enough about this standard to be able to say.
The comments about WPF getting the wrong data make me think this is lower level than WPF, but @nkolarevic said it's WPF for sure, so I'll defer.
@Psychlist1972 Thank you. The logic of judgment in WPF may be applicable to outdated touch standard formats and may not necessarily be suitable for modern devices. If modern devices consider this format to be reasonable, it is reasonable for WPF to follow the format updates as well.
I've asked a friend internally if they know who should look at this. If they find someone appropriate, you'll likely see a reply here.
Thank you for your help. @Psychlist1972
Also have a user with this issue on Surface Pro 9 with EnablePointerSupport on (haven't tried with it off yet). Has anyone figured out yet if this is due to an incorrect value in the HID descriptor or if it is WPF being too strict? They reported the following exception:
System.ArgumentException: '{0}' must be greater than or equal to '{1}'. (Parameter 'maximum') at System.Windows.Input.StylusPointPropertyInfo..ctor(StylusPointProperty stylusPointProperty, Int32 minimum, Int32 maximum, StylusPointPropertyUnit unit, Single resolution) at System.Windows.Input.StylusPointer.PointerStylusPointPropertyInfoHelper.CreatePropertyInfo(POINTER_DEVICE_PROPERTY prop) at System.Windows.Input.StylusPointer.PointerTabletDeviceInfo.TryInitializeSupportedStylusPointProperties() at System.Windows.Input.StylusPointer.PointerTabletDeviceInfo.TryInitialize() at System.Windows.Input.StylusPointer.PointerTabletDeviceCollection.Refresh() at System.Windows.Input.StylusPointer.PointerLogic.HandleMessage(WindowMessage msg, IntPtr wParam, IntPtr lParam) at System.Windows.SystemResources.InvalidateTabletDevices(WindowMessage msg, IntPtr wParam, IntPtr lParam) at System.Windows.SystemResources.SystemThemeFilterMessage(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled) at MS.Win32.HwndWrapper.WndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled) at MS.Win32.HwndSubclass.DispatcherCallbackOperation(Object o) at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs) at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler) at System.Windows.Threading.Dispatcher.LegacyInvokeImpl(DispatcherPriority priority, TimeSpan timeout, Delegate method, Object args, Int32 numArgs) at MS.Win32.HwndSubclass.SubclassWndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam)
@aquinn39 Yes, some friends reported the same problem. But I'm not sure if this is Surface Pro problem or WPF
Was any work done on this for .NET 10?
In addition to Surface Pro, I've also seen it on the following Surface devices + a few Dell and Acer laptops:
Surface Go 2 Microsoft Corporation (SKU: Surface_Go_2_1901)
Surface Go 2 Microsoft Corporation (SKU: Surface_Go_2_1926)
Surface Go 2 Microsoft Corporation (SKU: Surface_Go_2_1927)
Surface Go 3 Microsoft Corporation (SKU: Surface_Go_3_1901)
Surface Go 3 Microsoft Corporation (SKU: Surface_Go_3_1926)
Surface Go 3 Microsoft Corporation (SKU: Surface_Go_3_2022)
Surface Go 4 Microsoft Corporation (SKU: Surface_Go_4_2067)
Surface Go Microsoft Corporation (SKU: Surface_Go_1824_Commercial)
Surface Go Microsoft Corporation (SKU: Surface_Go_1824_Consumer)
Latitude 7340 Dell Inc. (SKU: 0C09)
Latitude 9330 Dell Inc. (SKU: 0B8C)
ST-OPS-I5-VPC-G12 Speechi (SKU: ??)
Switch SW312-31 Acer
From what I can tell, it doesn't happen on all above devices. I have several Surface Go 3 and 4 which never see this bug. But for the devices where it happen, it's 100% all the time (i.e. our app is completely unusable).
For all customers which had this problem, if I give them a version where EnablePointerSupport is off, everything works fine.
Stack Traces There are several versions of this bug with slightly different stack traces or even exceptions but they all share the fact that it's happening in System.Windows.Input during touch processing:
Index was out of range. Must be non-negative and less than the size of the collection. (Parameter 'index')
at System.ThrowHelper.ThrowArgumentOutOfRange_IndexMustBeLessException()
at System.Windows.Input.TouchDevice.Capture(IInputElement element, CaptureMode captureMode)
at System.Windows.Input.TouchDevice.PromoteMainToManipulation(UIElement manipulatableElement, TouchEventArgs touchEventArgs)
at System.Windows.Input.InputManager.RaiseProcessInputEventHandlers(Tuple`2 postProcessInput, ProcessInputEventArgs processInputEventArgs)
at System.Windows.Input.InputManager.ProcessStagingArea()
at System.Windows.Input.TouchDevice.ReportUp()
at System.Windows.Input.StylusPointer.PointerLogic.PromoteMainToTouch(ProcessInputEventArgs e, StylusEventArgs stylusEventArgs)
at System.Windows.Input.InputManager.RaiseProcessInputEventHandlers(Tuple`2 postProcessInput, ProcessInputEventArgs processInputEventArgs)
at System.Windows.Input.InputManager.ProcessStagingArea()
at System.Windows.Interop.HwndPointerInputProvider.ProcessMessage(UInt32 pointerId, RawStylusActions action, Int32 timestamp)
at System.Windows.Interop.HwndPointerInputProvider.System.Windows.Interop.IStylusInputProvider.FilterMessage(IntPtr hwnd, WindowMessage msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
at System.Windows.Interop.HwndSource.InputFilterMessage(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
at MS.Win32.HwndSubclass.DispatcherCallbackOperation(Object o)
at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)
at System.Windows.Threading.Dispatcher.LegacyInvokeImpl(DispatcherPriority priority, TimeSpan timeout, Delegate method, Object args, Int32 numArgs)
at MS.Win32.HwndSubclass.SubclassWndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam)
at MS.Win32.UnsafeNativeMethods.DispatchMessage(MSG& msg)
at System.Windows.Threading.Dispatcher.PushFrameImpl(DispatcherFrame frame)
at System.Windows.Application.RunDispatcher(Object ignore)
at System.Windows.Application.RunInternal(Window window)
at MyApp.Main()
Resolution must be at least 0.0f. (Parameter 'resolution')
at System.Windows.Input.StylusPointPropertyInfo..ctor(StylusPointProperty stylusPointProperty, Int32 minimum, Int32 maximum, StylusPointPropertyUnit unit, Single resolution)
at System.Windows.Input.StylusPointer.PointerStylusPointPropertyInfoHelper.CreatePropertyInfo(POINTER_DEVICE_PROPERTY prop)
at System.Windows.Input.StylusPointer.PointerTabletDeviceInfo.TryInitializeSupportedStylusPointProperties()
at System.Windows.Input.StylusPointer.PointerTabletDeviceInfo.TryInitialize()
at System.Windows.Input.StylusPointer.PointerTabletDeviceCollection.Refresh()
at System.Windows.SystemResources.SystemThemeFilterMessage(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)
Index was out of range. Must be non-negative and less than the size of the collection. (Parameter 'index')
at System.ThrowHelper.ThrowArgumentOutOfRange_IndexMustBeLessException()
at System.Collections.Generic.List`1.get_Item(Int32 index)
at System.Windows.Input.TouchDevice.OnHitTestInvalidatedAsync(Object sender, EventArgs e)
at System.Windows.Input.InputManager.HitTestInvalidatedAsyncCallback(Object arg)
at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)
@isak1080
Was any work done on this for .NET 10?
Sorry, not any work done for .NET 10.
Resolution must be at least 0.0f. (Parameter 'resolution')
This exception is very interesting. It is very likely caused by the hardware device reporting incorrect data.