Archive for the ‘Hardware’ Category

Microsoft Keyboard Remapping/Hack

If found this perfect comment on how to remap the keys on a Microsoft keyboard which was posted in a comment by Martin Hennings on this blog:

The comment is:

I’m using a natural ergonomic 4000 right now and loving it!

Now I got the taste of hacking, so I’d like to give away a few neat tricks.

The types in the commands.xml as in
have these meanings:

0 disabled
1 wParam follows
5 KeySeq follows
6 Activator follows
… what …
<C104 Type="2" lParam="0x05" />
<C401 Type="3" wParam="0x00002" />
<C104 Type="4" wParam="0x2" lParam="0x01711" />
<C1003 Type="7" Subtype="0" />
<C1003 Type="7" Subtype="3" wParam="0x01672" />
<C1003 Type="7" Subtype="4" wParam="0x2" lParam="0x01672" />
… ever … ;)
maybe I'll figure them out, too, some time…

As for the wParam, please note the command to registry hacks in the next post…

These are the keycodes I have figured out so far:
(german keyboard layout “qwertz”)

back C100
forward C101
zoom up C319
zoom down C320
function keys with F-Lock off: (with F-Lock on they serve as regular F-keys)
F1 C302
F2 C203
F3 C204
F4 C307
F5 C308
F6 C309
F7 C900
F8 C901
F9 C902
who knows F10? "spell check"?
F11 C311
F12 C310
not sure:
search C104 or C315
home C106
The ones I haven't figured out yet: (most of them are probably not even on the natural ergonomic 4000)
?? <C103 Type="5" KeySeq="escape" />
?? <C300 Type="5" KeySeq="enter" />
?? <C1101 Type="6" Activator="HorizontalScroll" />
?? <C1003 Type="7" Subtype="0" />
?? <C204 Type="5" KeySeq="ctrl y" />
?? <C105 Type="6" Activator="AOLBrowserFavorites" />
and some more…
These are really strange:
<Send1 Type="1" wParam="0x07E95" />
<Send2 Type="1" wParam="0x07E96" />
<ForwardMail1 Type="1" wParam="0x07E86" />
<ForwardMail2 Type="1" wParam="0x07E8D" />
<ForwardMail3 Type="1" wParam="0x07E8E" />
What are they for?

me using XP Pro I changed the commands.xml a bit, like for notepad:

<Application UniqueName="Notepad_WinXP" AppName="Notepad">
<C315 Type="1" wParam="0x10015" />
<C307 Type="1" wParam="0x10001" />
<C308 Type="1" wParam="0x10002" />
<C309 Type="5" KeySeq="alt F4" />
<C311 Type="1" wParam="0x10003" />
<C310 Type="1" wParam="0x10006" />
<C204 Type="5" KeySeq="ctrl z" />
<C401 Type="0" />
<C100 Type="5" KeySeq="pageup" />
<C101 Type="5" KeySeq="pagedown" />
<C319 Type="6" Activator="ScrollUp" />
<C320 Type="6" Activator="ScrollDown" />

This means back and forward keys toggle PageUp and PageDown, while the zoom button scrolls.

As for what the

<C307 Type="1" wParam="0x17c25" />

do, I’m still not sure. They toggle some internal commands within the programs, but until now I couldn’t change them so they’d so anything useful. Better stick to the keyboard shortcuts, I guess.

some important KeySeq-codes:

alt ctrl shift uparrow downarrow leftarrow rightarrow pageup pagedown backspace space add subtract + - escape break home end |

The pipe sign “|” lets you specify keystroke series like pressing “alt f” and then “s” for “file” – “save” by notating: “alt f | s”. To do a ‘copy all’ per “ctrl a” “ctrl c” you need to write “ctrl a | ctrl c”. Although it seems that itype.exe accepts a max. of three piped commands.
At least this didn’t work out in firefox: “ctrl l | ctrl c | ctrl t | ctrl v | enter” for ‘duplicate tab’. 😦
“alt home” works, at least.

So far for now, have fun hacking!

btw, please excuse my english, as I am from Germany…


NVidia Vista Drivers are Still Awful

I just installed version 15.00 of the nForce4 Nvidia drivers, and it seems that they have caused my onboard network adapters to go crazy. In other words, my something is seriously wrong.

I am getting error messages like “Ping: transmit failed, error code 1232” from the command prompt and messages like “Windows tried a repair but a problem still exists. The network adapter does not have a valid IP configuration.” When I edit my manual IPv4 settings, it seems like it will not save my IP address sometimes (and other times it will).

Suffice to say, if you are having these problems, I feel your pain. The best way I found to fix it is to go to the Device Manager and uninstall the network adapters, without checked the “Uninstall Driver” box. The network adapter will immediate reinstall itself, and most of the time my network worked (temporarily) after that. I have heard reports that going into sleep mode will break the network. In my case, changing to a manual IP address will _sometimes_ break the network again. Sometimes unplugging the cable and plugging it back in will fix this.

I know, I should have a better fix than this, but it just seems so random. I haven’t been able to track down a repeatable pattern. This all worked flawlessly before the driver update, so I would suggest waiting until a newer release.


I have some new (albiet incomplete) information on when my manual IP address configuration is not saved.

It seems like the reason it forgets my IP address has something to do with the fact that I set both adapters to use the same IP address. The reason for this is that I only have one hooked up at a time and it saves me from adding extra port forwarding rules to the router. The “Are you sure you want to use this IP address” dialog will pop up once and only once. I will never see it again afterward using that IP address, but if I set both adapters to a different IP then I will get the dialog once again. It seems like it is at that point that the second adapter I added the IP address to will not save its information, and that IP address is forever “broken” in that I can no longer use it. If I switch to a different IP address then I have connectivity again until I use it with both adapters (remember, only one is plugged in), at which point I get the dialog and that address becomes unusable.

Somewhere Vista or the nVidia drivers are remembering these IP addresses, and not working correctly when I try to use them.

To show you the craziness, here is a screenshot of my current network details (that are working, since I’m able to make this post):


Now observe the properties for this network adapter:


Notice the two blank entries?  This time, at least I have a default gateway.  That’s missing sometimes, too.