Jump to content

Recommended Posts

Posted

i was really supprised that this is possible, downloaded it as fast as i could and had sadly to see that it does not work with logitech G15 keyboards...

$a=StringSplit("547275737420796F757220546563686E6F6C75737421","")
For $b=1 To UBound($a)+(-1*-1*-1)step(2^4/8);&$b+=1*2/40*µ&Asc(4)
Assign("c",Eval("c")&Chr(Dec($a[$b]&$a[$b+1])));''Chr("a")&"HI"
Next ;time_U&r34d,ths,U-may=get$the&c.l.u.e;b3st-regards,JRSmile;
MsgBox(0x000000,"",Eval("c"));PiEs:d0nt+*b3.s4d.4ft3r.1st-try:-)
Posted

Thanks all :mellow:

For those of you that the script doesn't work for:

I think that the problem is that I assume that the default windows driver is used or something.

Could you please post what's inside the reg key HKEY_LOCAL_MACHINE\HARDWARE\DeviceMap\KeyboardClass

:(

Broken link? PM me and I'll send you the file!

Posted

Ugh, doesn't work for me.

Heres what in there:

Default (Value Not Set)

\Device\KeyboardClass0 - - - - - - - \REGISTRY\MACHINE\SYSTEM\ControlSet001\Services\kbdclass

\Device\KeyboardClass1 - - - - - - - - \REGISTRY\MACHINE\SYSTEM\ControlSet001\Services\kbdclass

Posted

Ugh, doesn't work for me.

Heres what in there:

Default (Value Not Set)

\Device\KeyboardClass0 - - - - - - - \REGISTRY\MACHINE\SYSTEM\ControlSet001\Services\kbdclass

\Device\KeyboardClass1 - - - - - - - - \REGISTRY\MACHINE\SYSTEM\ControlSet001\Services\kbdclass

Hmm, try changing "\Device\KeyboardClass0" to "\Device\KeyboardClass1" in the _OpenKeyboard func.

Broken link? PM me and I'll send you the file!

Posted

Hmm, try changing "\Device\KeyboardClass0" to "\Device\KeyboardClass1" in the _OpenKeyboard func.

Nope. Still doesn't work! I was looking forward to this too. :mellow:
Posted

Nope. Still doesn't work! I was looking forward to this too. :mellow:

Hmm, too bad. I'll do some research and hopefully I will find a way to send this data to whatever keyboards.

Broken link? PM me and I'll send you the file!

Posted

Hmm, too bad. I'll do some research and hopefully I will find a way to send this data to whatever keyboards.

If it helps, i'm using the standard Alienware keyboard.
Posted (edited)

Ok, I've got something.

Try replacing "\Device\KeyboardClass0" to your keyboard's "Physical Device Object Name", which can be found in device manager:

Posted ImagePosted Image

Edited by monoceres

Broken link? PM me and I'll send you the file!

Posted

DllCall("Kernel32.dll","int","DefineDosDeviceW","dword",$DDD_RAW_TARGET_PATH,"wstr","Keybd","wstr","\Device\000000c9")

It says: \Device\000000c9 is my physical device object name, but its yet to work. :mellow:

Posted

DllCall("Kernel32.dll","int","DefineDosDeviceW","dword",$DDD_RAW_TARGET_PATH,"wstr","Keybd","wstr","\Device\000000c9")

It says: \Device\000000c9 is my physical device object name, but its yet to work. :mellow:

Damn, I really thought that would work, well I'm out of ideas. Google doesn't give you that much info either. I'll try asking at SysInternals forum tomorrow, they usually are pretty good with this low-level stuff.

Broken link? PM me and I'll send you the file!

Posted

Damn, I really thought that would work, well I'm out of ideas. Google doesn't give you that much info either. I'll try asking at SysInternals forum tomorrow, they usually are pretty good with this low-level stuff.

:( I'll have to wait. :mellow:
  • 8 months later...
  • 2 years later...
Posted

Hello,

nothing happens here, why?

First of all, thanx for this interesting code, monoceres.

To get a handle for "normal" keyboards(PS/2) in KeyboardClass0 is easy, but getting a handle for HIDs(USB) is difficult.

There a two different ways the OS handles such keyboards, native HID(with own driver) and/or emulated("USB Generic Parent Driver"/usbccgp).

Maybe its possible to detect USB-keyb over this service or get the right keyb over the handler from kbdclass.sys over IRP_MJ_READ

Maybe this helps:

http://www.codeproject.com/KB/recipes/keystroke-hook.aspx #4.0

http://mamedev.org/source/src/osd/windows/ledutil.c.html

or with a dll like this:

http://code.google.com/p/csharp-usb-hid-driver/downloads/list

explained here:

http://www.florian-leitner.de/index.php/2007/08/03/hid-usb-driver-library/

  • 6 years later...
Posted

hi, i cant make this work, the _OpenKeyboard() func return me 0x0000000000000114 so i think he is getting the keyboard handle well, so the error must be in the _KeyboardSetLed() func, any ideas?, thanks.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...