Generic HID

Questions and comments specific to a particular plugin should go here.

Generic HID

Postby Bartman » Mon Oct 29, 2007 2:09 pm

This is a topic for questions concerning the HID plugin.

Notes:
The HID plugin does not allow to open mouse or keyboard devices. Those are opened exlusivly by Windows.
If you don't get any events from the plug in try the raw data option (requieres disabling enduring events).
Some devices show up as multiple HID entries. Try all of them.

If you don't get any events even with the raw data option you might wanna try SimpleHIDWrite.exe which belongs to IO Warrior SDK. If you don't get any input there your device will probably not work with generic HID communication and requieres a specif plugin.
Bartman
Plugin Developer
 
Posts: 881
Joined: Sun Feb 12, 2006 9:03 am

Basic instructions?

Postby specter333 » Fri Dec 28, 2007 4:54 am

It looks like I'm the only person having trouble with the HID plugin, just figures.

Anyway, I need some simple instructions as how things in EG function. As for the HID plugin I have a few questions.

Why does it log some events and not others, ie it logs the middle mouse button but no others. Doesn't log any keyboard keys, even the media keys which I would like to assign functions.

I have two Gyration Rf receivers attached to this computer (different frequencies) but it sees ten. Of those ten only one records any events from only one of my remotes and then only 3 of the buttons. I know they are all sending a signal because the indicator on the receiver flashes.

Why does it see the Gyration receivers but not anything like the wired mouse and keyboard or my USB bar code reader?

I'm sure there are logical explanations for all of these things but I'm not very computer knowledgeable so in light of not having an instruction manual can someone please explain some of the basic such as these?

I'll proceed one plugin at a time. When I get this one doing what I want then I'll move on to another one that's over my head.

Thanks for any help or advice you can give.
Rich
specter333
Experienced User
 
Posts: 95
Joined: Thu Dec 27, 2007 12:26 am

Re: HID plugin

Postby Bartman » Fri Dec 28, 2007 8:43 am

The HID plugin cannot use keyboard and mouse HID devices as these are exlusivly used by the OS. DirectInput would be te way to go.
The USB Bar Code Reader is probably not an HID device.
Bartman
Plugin Developer
 
Posts: 881
Joined: Sun Feb 12, 2006 9:03 am

Re: HID plugin

Postby specter333 » Sat Dec 29, 2007 5:55 am

Ok, thanks. That makes sense and clears some things up.

I've toyed with all the other plug ins so I have a better idea of what they do and hopefully keep me from asking obvious questions again.

Now I'd like to ask some questions about my specific setup. I have two Gyration Media Center RF remote controls, I don't see a model number on either one so I'll try to attach photos. I don't have the software that came with them or Windows Media Center for that matter so most of the functions I can't use. But they do both operate as a mouse, they are easy to use and it's very handy when doing media applications and other things at the same time, or having to navigate media errors and functions that normal remotes won't do.

So obviously what I would like to do is assign functions to the unused buttons just as if they were IR remotes. The problem as a said before is only the buttons that I can already use are being logged as events. EG isn't seeing the others.

Some of the plugins, HID, Bluetooth, see 10 Gyration receivers attached to my computer although I only have 2. I've gone through all of them and only one picks up any more buttons and that's only a couple from one of the remotes. Can anyone explain either of these things?

I'm guessing the issue is I don't have a plugin capable of detecting the other buttons. Is there an RF plugin that might work? Is this a feasible use of EG or am I wasting my time?

By the way, It probably sounds like I'm complaining here and that's not the case at all. I have downloaded and tried a lot of other software over the last few months just trying to get my IR remotes doing what I want. When I found EG everything just fell into place and I had both of them going in no time. The idea of being able to use the Gyration remotes didn't even occur to me until after I saw what EG was capable of doing. The process you came up with to be able to use any event to trigger any event is just brilliant. Every other software I've tested focussed on one type of event triggering one other.

I can't wait until the help files are available so I can learn to use the software better. I've been coming up with a lot of ideas that are still beyond my computer knowledge, but maybe someday...

Thanks again for all your help and the work you've put into EG.
Rich
Attachments
gyroremotes.jpg
specter333
Experienced User
 
Posts: 95
Joined: Thu Dec 27, 2007 12:26 am

Re: HID plugin

Postby Bartman » Sat Dec 29, 2007 11:54 am

You can try the "raw data as event name" option and see if any button gives an event.
My Logitech Keyboard also shows up as multiple devices and with one part I only get events with this option. This generate events like "HID.0123456789ABCDEF" on every change (even releasing buttons) and does not allow enduring events but it is the only way to get some devices working.
Does the remote come with a driver or software? It is possible that the software intercepts key presses and hides them from regular applications.
Bartman
Plugin Developer
 
Posts: 881
Joined: Sun Feb 12, 2006 9:03 am

Re: HID plugin

Postby Bitmonster » Sat Dec 29, 2007 12:56 pm

Please post software-related questions in the forum - PMs will only be answered, if really private, thanks!
User avatar
Bitmonster
Site Admin
 
Posts: 2239
Joined: Mon Feb 06, 2006 10:28 pm

Re: HID plugin

Postby specter333 » Wed Jan 02, 2008 1:23 pm

Thanks for your replies. The raw data option doesn't seem to make a difference. The link looks like it's may have the info I need. I'll read through it thoroughly when I get a chance. Thank you both for the help.

For now I'm putting this on hold while I deal with a more pressing issue in the Event Sender/Receiver section.
specter333
Experienced User
 
Posts: 95
Joined: Thu Dec 27, 2007 12:26 am

Re: HID plugin

Postby level20peon » Sat Feb 16, 2008 11:44 am

@specter333: Just ask if you have questions left with the Gyration Remote. I tried to write the HowTo as clearly as possible in the MediaPortal Forum but maybe I missed something :wink:.


@all: I have a question about the HID plugin. Since nobody seems to be able to solve this problem I am having with the Joystick plugin I consider using the HID plugin instead.

The problem is, I am trying to emulate the keyboard arrows using my GamePads Cursor Pad. The Keyboard arrows should be emulated as "pressed" as long as I hold down a direction on my GamePads Cursor Pad (ie: if I press "UP" on the GamePad, the keyboard {UP} should be repeated constantly until I release the GamePad button).

This works fine with the Joystick plugin. I use this script for the "UP" key:

Code: Select all
<?xml version="1.0" encoding="UTF-8" ?>
<EventGhost Version="1262">
    <Macro Name="{UP}" id="13" Expanded="True">
        <Event Name="Joystick.Up">
        </Event>
        <Action>
            Window.SendKeys(u'{Up}', False)
        </Action>
        <Action>
            EventGhost.AutoRepeat(0.40000000000000002, 0.0, 0.0, 0.0)
        </Action>
    </Macro>
</EventGhost>



However it doesn't work using the HID plugin. There are TWO events triggered, one for "UP button pressed" and one for "UP button released", since it registers the position of the CursorPad as X- / Y-Axis values. "UP button pressed" is "HID.Value.15 0" and "UP button released" is "HID.Value.15 127" which is the center of the Axis.
The logical thing to to would be:

1. Trigger Keyboard Button {UP} on event "HID.Value.15 0"
2. Repeat Keyboard Button {UP} continously until 3.
3. Stop continuation on event "HID.Value.15 127"

Basically an easy thing to do. The problem however is that "HID.Value.15 127" becomes "HID.Value.15" when dragged into the right side (into a script) out of the log. "HID.Value.15 0" also becomes "HID.Value.15". This makes it impossible to distinguish when to start and when to stop the button emulation. Manually renaming the "HID.Value.15" to "HID.Value.15 127" for example doesn't work either... nothing is triggered anymore at all.


Any hints ??

-level20peon
User avatar
level20peon
 
Posts: 24
Joined: Sun Dec 02, 2007 2:58 pm

Re: HID plugin

Postby Bartman » Sat Feb 16, 2008 7:36 pm

I have not imlemented enduring events for values. This only works for buttons.
Since an axis always as a value the plugin would always have to send an enduring event which is not quite logical either.
Bartman
Plugin Developer
 
Posts: 881
Joined: Sun Feb 12, 2006 9:03 am

Re: HID plugin

Postby level20peon » Sat Feb 16, 2008 8:49 pm

I don't fully get you.

There ARE two different "events" shown in the log "HID.Value.15 127" and "HID.Value.15 0". So these are the only values for "UP" in digital mode (you could also call them UP=1 and UP=0 if you like). So there is no necessity for monitoring the values from 0-256 the whole time (analogue mode) but just for the "0", "127" and "256" value for X- and Y-axis which represent "Center", "Left", "Right", "Up", "Down". Since the difference is already in the logs I don't understand why the possibility to "press 'UP' ON X=0 UNTIL X=127" cannot be implemented.


-level20peon
Attachments
EG2.gif
EG2.gif (11.66 KiB) Viewed 54666 times
User avatar
level20peon
 
Posts: 24
Joined: Sun Dec 02, 2007 2:58 pm

Re: HID plugin

Postby Bartman » Sun Feb 17, 2008 3:57 pm

There a too types of events in EventGhost.
One is the simple event, and the other one is the so called enduring events which starts at a time and lasts for example for the time a button is pressed.
To use auto repeat a plugin has to generate enduring events.

The HID.Value events are normally for analogue values only. For example from a analogue stick of a game pad.

Enduring events would not really fit the nature of a analogue value. Especially since most pads have multiple analogue values.
No solution but a glimpse at the internals.
Bartman
Plugin Developer
 
Posts: 881
Joined: Sun Feb 12, 2006 9:03 am

Re: HID plugin

Postby level20peon » Sun Feb 17, 2008 4:06 pm

OK thanks, I will have to wait until the Joystick plugin issue is fixed then.


-level20peon
User avatar
level20peon
 
Posts: 24
Joined: Sun Dec 02, 2007 2:58 pm

Re: HID plugin

Postby specter333 » Sun Feb 24, 2008 5:56 am

level20peon wrote:@specter333: Just ask if you have questions left with the Gyration Remote. I tried to write the HowTo as clearly as possible in the MediaPortal Forum but maybe I missed something :wink:.



Hi level20peon, thanks for your reply. I finally got back to this project a couple of days ago and your post got me going nicely thank you. Couple of differences between my results and yours though.

The “Live TV”, “Guide” and “More” buttons are mappable one mine.

And down at the bottom, the “Setup” and “Input” buttons are mappable but the “Connect” button is not.

Also, in the number pad the “Star” and “Pound” buttons are not.

By the way, those are all mappable with the USB-UIRT, not through the RF receiver.


With the smaller remote in my pictures I finally realized that it is being recognized as a generic HID device and not one of the Gyration devices. All the buttons on top, that aren’t recognized by windows already, as well as the two unnamed buttons on the right side are mappable. I haven’t tried the two buttons on the left side since that would mess up my connection with the receiver but I would bet they are mappable too.

I’m running XP Pro service pack 1 and the USB-UIRT as well as two different Gyration RF receiver, one for the Media Center Remote and keyboard and one for the other remote, keyboard and mouse.

I’d be interested in finding out why our setups don’t match and if maybe there’s something we can do to make all the buttons mappable.

Thanks again for your help. Rich
specter333
Experienced User
 
Posts: 95
Joined: Thu Dec 27, 2007 12:26 am

Re: HID plugin

Postby level20peon » Sun Feb 24, 2008 9:18 am

specter333 wrote:The “Live TV”, “Guide” and “More” buttons are mappable one mine.


On mine, too... the results in post #4 just were "first trys", the picture in post#5 is more accurate. Note: the "not mappable" hasn't got to do anything with EventGhost primarily but with the OS support. So if there is a button marked as "Not mappable" it doesn't trigger an action inside the OS with its native drivers if you DON'T use EventGhost.

"Not mappable at all" INCLUDES EventGhost.

The story I told over in the MediaPortal Forum deals with driver issues and being able to use the remote with MediaPortals HID remote plugin. So its not an EventGhost ONLY story :wink:


specter333 wrote:And down at the bottom, the “Setup” and “Input” buttons are mappable but the “Connect” button is not.

Also, in the number pad the “Star” and “Pound” buttons are not.


"Setup" and "Input" are not mappable at all in my case (even using EventGhost)... no idea why. The "Connect" button is internally mapped to connect to the USB Dongle... I don't think it is mappable, no matter what.

The "Star" and "Pound" buttons aren't mappable as well as the keypad. I think this is because the whole keypad isn't connected as HID-Device but as a sepparate device (I don't know enough about this to tell the exact name).


specter333 wrote:By the way, those are all mappable with the USB-UIRT, not through the RF receiver.


What do you mean ? When I tried to add the USB-UIRT Plugin it told me that no drivers where found. Are you talking about mapping them with a sepparate page on the remote using IR-signals and an IR-Receiver attached to your PC ?


specter333 wrote:With the smaller remote in my pictures I finally realized that it is being recognized as a generic HID device and not one of the Gyration devices. All the buttons on top, that aren’t recognized by windows already, as well as the two unnamed buttons on the right side are mappable. I haven’t tried the two buttons on the left side since that would mess up my connection with the receiver but I would bet they are mappable too.

I’m running XP Pro service pack 1 and the USB-UIRT as well as two different Gyration RF receiver, one for the Media Center Remote and keyboard and one for the other remote, keyboard and mouse.

I’d be interested in finding out why our setups don’t match and if maybe there’s something we can do to make all the buttons mappable.


I just have the GYR3101US so I cannot tell anything about the other one at all 8)


-level20peon
User avatar
level20peon
 
Posts: 24
Joined: Sun Dec 02, 2007 2:58 pm

Re: HID plugin

Postby specter333 » Mon Feb 25, 2008 11:38 am

level20peon wrote:Note: the "not mappable" hasn't got to do anything with EventGhost primarily but with the OS support. So if there is a button marked as "Not mappable" it doesn't trigger an action inside the OS with its native drivers if you DON'T use EventGhost.

"Not mappable at all" INCLUDES EventGhost.


Sorry, I'm not certain I'm understanding this. I'm guessing there are three items were looking at here.

Not Mappable = Seen by EG as another device, such as the number keys.
Mappable = Seen only as event by EG that can be assigned to an action.
Not Seen = Not seen by EG or by OS.

Is that correct?


level20peon wrote:The "Connect" button is internally mapped to connect to the USB Dongle... I don't think it is mappable, no matter what.


That's right, I forgot what the button was for.

level20peon wrote:The "Star" and "Pound" buttons aren't mappable as well as the keypad. I think this is because the whole keypad isn't connected as HID-Device but as a sepparate device (I don't know enough about this to tell the exact name).


specter333 wrote:By the way, those are all mappable with the USB-UIRT, not through the RF receiver.


What do you mean ? When I tried to add the USB-UIRT Plugin it told me that no drivers where found. Are you talking about mapping them with a sepparate page on the remote using IR-signals and an IR-Receiver attached to your PC ?


What I mean is the remote transmits rf when using the PC mode and ir when using the TV, Aux and Sat modes (mostly). When in PC mode EG sees the number keys and transport keys as keystrokes, probably as a HID device.

When in any of the other modes everything including the number keys and transport keys are seen as USB-UIRT events. So there's a very limited number of keys that are usable in PC mode and those you wouldn't want to map but all they keys you mentioned plus a couple more on my remote a mappable in ir mode.

In PC mode the number keys are seen as number pad keys and in IR mode there seen as USB-UIRT events but the pound and star keys are not seen by EG at all.

I bet the DVD menu and Last keys are being intercepted by the OS and the connect key never makes it past the usb dongle.

It's a little confusing since EG sees different keys depending on which "Page" (I guess you would call it) of the remote your using. When I get some time I'll map out all for page keys and post the results.

I've been trying many different kinds of remote with EG to see which one is easiest to use and I keep coming back to these two. Having the gyroscopic mouse built in is just to handy. I usually end up using the little one because I can program buttons to do wheel up, wheel down, and center button function and I forget what I programed to what button on the bigger one.

I've just started experimenting with using a pocket pc as a remote using the webserver plugin. I made some webpages that look like remote buttons but with the names of the functions I'm using. It looks like it may work ok but I still like having the mouse control too.

Thanks again for you help. Rich
specter333
Experienced User
 
Posts: 95
Joined: Thu Dec 27, 2007 12:26 am

Next

Return to Plugin Support

Who is online

Users browsing this forum: enobhsiw and 4 guests

cron