Working with joystick/gamepad from service
I am trying to use a gamepad/joystick to control some hardware.
Industrial compurer (WinXP) runs all software as services so no login is required. The computer itself is hidden from an operator, actually.
I need exclusive access to the game controller to catch operators actions (buttons) and feed back system's status as force feedback effects.
The problem is that DirectInput requires HWND descriptor to work with gamepads (SetCooperativeLevel function). I obviously do not have a window for that.
Does anybody know how to work with USB-based HID from a service?