Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Using an Apple Magic keyboard #64

Closed
RobThree opened this issue Jan 4, 2018 · 9 comments
Closed

Using an Apple Magic keyboard #64

RobThree opened this issue Jan 4, 2018 · 9 comments

Comments

@RobThree
Copy link

RobThree commented Jan 4, 2018

Leaving this here as documentation (since I couldn't edit the/a Wiki): I'm using an Apple Magic Keyboard (with numpad) and these are my mappings:

Screenshot

And this is the registry data:

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Keyboard Layout]
"Scancode Map"=hex:00,00,00,00,00,00,00,00,0c,00,00,00,37,e0,64,00,46,00,65,00,\
  20,e0,67,00,6a,e0,68,00,2e,e0,69,00,30,e0,6a,00,45,00,45,e0,5b,e0,38,00,38,\
  00,5b,e0,5c,e0,38,e0,38,e0,5c,e0,00,00,00,00

Save the above in a .reg file (e.g. "apple_keyboard.reg" for example), double-click the file, allow it to be imported. Log off and back on (works on my Win10 machine, you may need to reboot) and you're set!

This maps:

F13 -> PrtScr
F14 -> Scroll Lock
F15 -> Sorry, can't map to break
F16 -> (Un)Mute
F17 -> Web: Back
F18 -> Volume Down
F19 -> Volume Up
Clear -> NumLock
Left Option -> Left Windows
Left Command -> Left Alt
Right Option -> Right Windows
Right Command -> Right Alt

Unfortunately the key (between F12 and F13) and the fn button cannot be mapped (the latter I'd love to map to insert.

I use the above settings with Tray Status Pro to show the numlock and caps-lock states (can also do scroll-lock but I don't use it anyway) and only seldomly miss my HP Keyboard that I've used for over two decades. I use(d) shift + delete and shift + insert as ctrl + c / ctrl + v (copy/paste) alternative a lot since I can more easily find those keys blindly. Also being a programmer I miss the (ctrl + ) break key combo. Also the menu key is missing on the Apple Magic Keyboard so I didn't map it (maybe possible to use F17 for; but haven't figured out the codes (yet)). But that's about it. The rest works as expected.

I hope this information is useful to anyone. @randyrants : Thanks for the great tool 👍 Please consider opening the Wiki? 😘

@randyrants
Copy link
Owner

Just flipped it on, I think - plz let me know if it's not active.

@RobThree
Copy link
Author

I see a wiki but no way to edit / add.

@randyrants
Copy link
Owner

Should be enabled now!

@RobThree
Copy link
Author

@psyanite
Copy link

psyanite commented Jan 28, 2019

@RobThree, thank you so much 🙏
I'd really like to be able to map the eject key to delete, it can be done in https://github.com/samartzidis/WinAppleKey, perhaps it could be done in SharpKeys?

@nwittwer
Copy link

If anyone's using the Magic Keyboard without the numpad, this combo works quite nicely:

image

NOTE: I personally don't use the right command or option keys, so I haven't mapped them here.

@kevinjohncutler
Copy link

@RobThree, thank you so much 🙏
I'd really like to be able to map the eject key to delete, it can be done in https://github.com/samartzidis/WinAppleKey, perhaps it could be done in SharpKeys?

Did you figure out how to do that? I don't even know what code the eject key has. It does not come up with "type key" dialogue.

@verityj
Copy link

verityj commented Nov 2, 2023

@kevinjohncutler

I don't even know what code the eject key has.

https://verityj.github.io/2023/06/17/eject.html HID key is 0xC000000b8. References included. I don't know how to create a proper scancode map for Windows for it, though.

@RobThree
Copy link
Author

RobThree commented Apr 15, 2024

For future reference: since I got myself a macropad (which... isn't... bad), the swapped win/alt keys in SharpKeys which were then swapped back by MagicKeyboard (don't know or remember why I did that in the first place...) caused some confusion when configuring key combo's that used ALT in the (very spartan) macropad config utility.

So the registry key is now:

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Keyboard Layout]
"Scancode Map"=hex:00,00,00,00,00,00,00,00,05,00,00,00,20,e0,67,00,6a,e0,68,00,\
  2e,e0,69,00,30,e0,6a,00,00,00,00,00

And the settings are now as follows:

image

I know, I'm quite sure this is not very interesting for anyone, but still... you never know.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants