Windows System Software -- Consulting, Training, Development -- Unique Expertise, Guaranteed Results

Home NTDEV

Before Posting...

Please check out the Community Guidelines in the Announcements and Administration Category.

More Info on Driver Writing and Debugging


The free OSR Learning Library has more than 50 articles on a wide variety of topics about writing and debugging device drivers and Minifilters. From introductory level to advanced. All the articles have been recently reviewed and updated, and are written using the clear and definitive style you've come to expect from OSR over the years.


Check out The OSR Learning Library at: https://www.osr.com/osr-learning-library/


RawInput for Devices in RDS-based Session

Nathan_KiddNathan_Kidd Member - All Emails Posts: 34
edited February 12 in NTDEV

I've created a virtual HID device which works fine in a remote Console session when using RawInput APIs, but when using an RDS-based session (think RDP) GetRawInputDeviceList() never sees the device, or any device, ever. (Other APIs successfully interact with the device).

Does anyone have experience or ideas about RawInput in an RDS-based session?

Stepping on the kernel side I see win32kfull!NtUserGetRawInputDeviceList() iterates a global linked list which might explain why the API seems disabled (multiple sessions and a single global conflict architecturally), but is very unfortunate because increasingly I see software wants to use RawInput (e.g. Blender).

-Nathan

Comments

  • Nathan_KiddNathan_Kidd Member - All Emails Posts: 34

    Nobody's had a problem with RawInput not seeing devices?

  • Tim_RobertsTim_Roberts Member - All Emails Posts: 14,832

    You can understand the difficulties, right? Your raw device belongs to the host, not to any individual session. They all have to share access to the device through the very fat layer of abstraction, and that prevents a device from being available in "raw" mode to any single session. I guess I would expect the session-specific fake input device to be visible, however.

    Tim Roberts, [email protected]
    Software Wizard Emeritus

  • Nathan_KiddNathan_Kidd Member - All Emails Posts: 34

    You're right, of course, that it would be difficult to map any physically connected device into RDS sessions. I'm only considering devices that are already per-session (e.g. hung off a virtual USB hub) -- they don't show up with GetRawInputDeviceList(), but it seems RawInput could iterate a per-session list.

    I guess I was hoping to entice Doron into saying "Yeah, I wrote that subsystem back in the day and the PM at the time said" A) "we never will care about anything but Console", or B) "Wait till customers ask to bother with per-session devices" or C) ... :)

  • Doron_HolanDoron_Holan Member - All Emails Posts: 10,828
    Sorry, never dealt with rds. My involvement stopped at the raw input device layer and those fun abstractions above were mostly magic to me.
    d
Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. Sign in or register to get started.

Upcoming OSR Seminars
OSR has suspended in-person seminars due to the Covid-19 outbreak. But, don't miss your training! Attend via the internet instead!
Kernel Debugging 13-17 May 2024 Live, Online
Developing Minifilters 1-5 Apr 2024 Live, Online
Internals & Software Drivers 11-15 Mar 2024 Live, Online
Writing WDF Drivers 20-24 May 2024 Live, Online