BorlandTalk.com Forum Index BorlandTalk.com
Borland discussion newsgroups
 
Archives   FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Keypad Identification - HID?

 
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> C++ Builder (Compatibility with MFC)
View previous topic :: View next topic  
Author Message
Matt Muskovac
Guest





PostPosted: Sun Mar 26, 2006 3:03 am    Post subject: Keypad Identification - HID? Reply with quote



I have three identical standard USB numeric keypads connected to the
computer (call them 1,2,3). I need to know which keypad keystokes are coming
from. I realize that the user may need to correlate the keypads by pressing
a key on each keypad each time they run the application, this is acceptable.

Is the HID the best (easiest) way to do this?

Thanks in advance,
MattM
Back to top
Matt Muskovac
Guest





PostPosted: Tue Mar 28, 2006 9:03 am    Post subject: Re: Keypad Identification - HID? Reply with quote



After digging around the internet for many, many hours, I think I am now on
the right trail ... WinXP has a new "raw input" message.

Unfortunately, BCB6 doesn't have any direct support for this so I will need
to use Win API calls. I haven't written any code yet, but, it appears that
these are the functions needed to setup the input messages:

GetRawInputDeviceList, GetRawInputDeviceInfo, RegisterRawInputDevices

Then I will make an OnMessage handler and intercept the raw input messages
(WM_INPUT). GetRawInputData will help decode the message.

If anyone else wants more info on this, search for "WM_INPUT" on MSDN or
google: "rawmouse".

MattM

"Matt Muskovac" <mathyou (AT) aol (DOT) com> wrote in message
news:4425fa66 (AT) newsgroups (DOT) borland.com...
Quote:
I have three identical standard USB numeric keypads connected to the
computer (call them 1,2,3). I need to know which keypad keystokes are
coming from. I realize that the user may need to correlate the keypads by
pressing a key on each keypad each time they run the application, this is
acceptable.

Is the HID the best (easiest) way to do this?

Thanks in advance,
MattM
Back to top
Matt Muskovac
Guest





PostPosted: Tue Apr 11, 2006 7:03 am    Post subject: Re: Keypad Identification - HID? Reply with quote



I did get this working as described in the previous post. Borland does
provide an ApplicationEvents callback so I did not need to use the WinAPI
OnMessage.

"Matt Muskovac" <mathyou (AT) aol (DOT) com> wrote in message
news:4428f20d$1 (AT) newsgroups (DOT) borland.com...
Quote:
After digging around the internet for many, many hours, I think I am now
on the right trail ... WinXP has a new "raw input" message.

Unfortunately, BCB6 doesn't have any direct support for this so I will
need to use Win API calls. I haven't written any code yet, but, it appears
that these are the functions needed to setup the input messages:

GetRawInputDeviceList, GetRawInputDeviceInfo, RegisterRawInputDevices

Then I will make an OnMessage handler and intercept the raw input messages
(WM_INPUT). GetRawInputData will help decode the message.

If anyone else wants more info on this, search for "WM_INPUT" on MSDN or
google: "rawmouse".

MattM

"Matt Muskovac" <mathyou (AT) aol (DOT) com> wrote in message
news:4425fa66 (AT) newsgroups (DOT) borland.com...
I have three identical standard USB numeric keypads connected to the
computer (call them 1,2,3). I need to know which keypad keystokes are
coming from. I realize that the user may need to correlate the keypads by
pressing a key on each keypad each time they run the application, this is
acceptable.

Is the HID the best (easiest) way to do this?

Thanks in advance,
MattM


Back to top
Display posts from previous:   
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> C++ Builder (Compatibility with MFC) All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2006 phpBB Group
SEO toolkit © 2004-2006 webmedic.