I have Asus M51Sn notebook, running Windows 7 (but also Linux, but this question is just about Windows). As you can see in the following image, it has five completely useless keys at the top of the keyboard. I want to remap such keys to useful things.

In this laptop, I have to use Fn+F5 and Fn+F6 to change the brightness, and Fn+F10, Fn+F11 and Fn+F12 to mute or change the volume. These actions are VERY cumbersome, as they need two hands to be pressed and I need to look at the keyboard to find where is the correct key. What I want is to remap the useless keys at the top (as seen in the previous picture) to change brightness and volume.

As I said, I need a solution for Windows 7 (I've already remapped the keys on my Linux system).

I have installed a program from Asus called ATK Hotkey, which is responsible for showing OSD messages about brightness/volume changes. However, this program is very bad, as it runs completely hidden from the user and has NO configuration at all. Not even configuration files, it has just a few EXE and DLL files, nothing more. It is so bad that the "open browser" key on my keyboard always launch Internet Explorer, even if it is not my default browser. If needed, I will happily uninstall this program if I find something better. (remapping keys to useful actions is much more important than OSD messages)

Things I've already tried

Uninstalling ATK Hotkey

Without ATK Hotkey, I can still change the brightness (as it is probably handled by BIOS), but Fn+F* keys don't change the volume anymore.

SharpKeys 3.0

SharpKeys 3.0 couldn't read any of the special keys on my laptop. My bet is that they aren't actual key presses, but instead ACPI events. Thus, I need a way to map some ACPI events to useful actions.

@Revolter: related, but not duplicate. A standard keyboard will send keypresses for those extra keys. This Asus laptop, on the other hand, seems to send ACPI events that can't be easily customized.
–
Denilson SáJan 8 '12 at 23:13

This program gives you ability to define own actions for additional buttons of Asus notebooks.

That's all I needed! What's more: the source-code is included! (too bad I don't have Visual Studio).

However, the program from the first post has a silly GUI mistake, which was later fixed by another user and then released as AsusNbKeysCtr-1.3fix.zip (but without source-code).

Using that program (the fixed version), I was able to remap the extra laptop keys to Volume Up, Volume Down and Volume Mute keystrokes, which are directly recognized by Windows. That's great, and solves half of my problem!

The other half, however, involves changing the monitor brightness. Unfortunately, there is no easy solution for that, and I need a command-line program to increase and decrease the brightness.

Saw your comment on another answer I left for setting brightness so I modded the app I wrote for that question a bit and came up with a tray app which you can use to control brightness (same restrictions apply as per the comments in the other thread).

This version of the app is pretty poor at the moment. Some seriously bad code at the moment but it seems to work for me anyway. Currently the hotkey is hardcoded as CTRL + ALT + UP / DOWN but as you'll see there's a dialog available to set up the hotkeys yourself. Doesn't work at the moment but I'll get around to fixing it at some point.

Thank you! But hey, no need for fancy dialogs! If you can make it so I can call it as brightener +1 for increasing (or -1 for decreasing), that's enough! A simple command-line interface is perfect for my need (because I already have other program to map a key to a command).
–
Denilson SáJan 25 '11 at 1:05

Design wise it wouldn't work too well. Incrementing by 1% at a time will mean that you'll open and close a console app 100 times to go from one end of the spectrum to another. A tray app with hotkeys is probably the best way to do this. Unless you can argue against it.
–
CiaranJan 25 '11 at 21:32

Well, since I'm used to Unix/Linux background, console apps are quite natural for me. However, on Windows they tend to popup the command prompt window, as you mentioned. So... maybe the GUI program, when called with some command-line parameters, could change the brightness and quit, without even opening any window. Well, that's just an idea. Gotta try your program later, when I reboot back into Windows.
–
Denilson SáJan 31 '11 at 4:14

Okay, I've finally tested it. It works, thank you! But it has only 4 brightness levels (which, on my monitor, are "dark" and 3 levels of "very bright"), while I know my monitor has around 10~15 brightness levels (and I usually toggle between the 3 lowest levels). So... it would be better if it didn't skip levels when changing the brightness.
–
Denilson SáFeb 13 '11 at 0:44

Probably a little bit late to answer, but after following link after link I found a version of DMedia that replaces the normal one and dispatches general keyboard key events for media playback. I know the question was about other buttons, but the fact that the media keys launched a random app each time (and that in Windows 8 it brings WMP to the foreground) bothered me.

Just download the rar file, stop the DMedia.exe process, go to your ATK Media installation folder, rename the original DMedia.exe just in case and then put the downloaded DMedia.exe in the same folder. Execute it to make it work (and normally it should launch at boot).