]> git.gir.st - tmk_keyboard.git/blame_incremental - converter/m0110_usb/README.md
Fix keymaps in README.(M0110)
[tmk_keyboard.git] / converter / m0110_usb / README.md
... / ...
CommitLineData
1M0110/M0110A to USB keyboard converter
2======================================
3This firmware converts the protocol of Apple Macintosh keyboard M0110/M0110A into USB.
4Target board of this project is [PJRC Teensy](http://www.pjrc.com/teensy/), though,
5you can use other board with USB AVR like `ATmega32U4` and `AT90USB`.
6
7![M0110](https://raw.github.com/tmk/tmk_keyboard/master/converter/m0110_usb/doc/m0110.jpg)
8
9- M0110A support was contributed by [skagon@github](https://github.com/skagon).
10- M0120 also is supported. keys(+ * / and ,) on M0120 are recognized as cursor keys.
11
12
13
14Connection
15----------
16You need 4P4C plug and cable to connect Teensy or other AVR dev board into the keyboard.
17Teensy port `PF0` is assigned for `CLOCK` line and `PF1` for `DATA` by default,
18you can change pin configuration with editing *config.h*.
19
20You can find 4P4C plugs on telephone handset cable. Note that it is *crossover* connection
21while Macintosh keyboard cable is *straight*.
22
23[![Conection](https://raw.github.com/tmk/tmk_keyboard/master/converter/m0110_usb/doc/teensy.jpg)]
24
25In this pic:
26
271. `GND`(Black)
282. `CLOCK`(Red)
293. `DATA`(Green)
304. `+5V`(Yellow)
31
32Note that wire colors may vary in your cable.
33
34
35### Pinout
36- <http://pinouts.ru/Inputs/MacKeyboard_pinout.shtml>
37- <http://en.wikipedia.org/wiki/Modular_connector#4P4C>
38
39![Jack fig](http://www.kbdbabel.org/conn/kbd_connector_macplus.png)
40
41
42### Pull-up Registor
43You may need pull-up registors on signal lines(`CLOCK`, `DATA`) in particular
44when you have long or coiled cable. 1k-10k Ohm will be OK for this purpose.
45In some cases MCU can't read signal from keyboard correctly without pull-up resistors.
46
47
48
49Building Frimware
50-----------------
51To compile firmware you need AVR GCC. You can use [WinAVR](http://winavr.sourceforge.net/) on Windows.
52You can edit *Makefile* and *config.h* to change compile options and pin configuration.
53
54 $ git clone git://github.com/tmk/tmk_keyboard.git (or download source)
55 $ cd m0110_usb
56 $ make
57
58and program your Teensy with [PJRC Teensy loader](http://www.pjrc.com/teensy/loader.html).
59
60
61
62Keymap
63------
64You can change keymaps by editing *keymap.c*.
65
66### M0110 & M0120
67#### *Default*
68 ,---------------------------------------------------------. ,---------------.
69 | `| 1| 2| 3| 4| 5| 6| 7| 8| 9| 0| -| =|Backs| |Ctl| -|Lft|Rgt|
70 |---------------------------------------------------------| |---------------|
71 |Tab | Q| W| E| R| T| Y| U| I| O| P| [| ]| \| | 7| 8| 9| Up|
72 |---------------------------------------------------------| |---------------|
73 |Fn0 | A| S| D| F| G| H| J| K| L| ;| '|Return| | 4| 5| 6| Dn|
74 |---------------------------------------------------------| |---------------|
75 |Shift | Z| X| C| V| B| N| M| ,| ,| /|Shift | | 1| 2| 3| |
76 `---------------------------------------------------------' |-----------|Ent|
77 |Alt|Gui | Space |Ctl |Alt| | 0| .| |
78 `-----------------------------------------------' `---------------'
79#### *HHKB/WASD Layer(WASD/IJKL)*
80 ,---------------------------------------------------------. ,---------------.
81 |Esc| F1| F2| F3| F4| F5| F6| F7| F8| F9|F10|F11|F12|Delet| |Nlk| -|Lft|Rgt|
82 |---------------------------------------------------------| |---------------|
83 |Caps |Hom| Up|PgU| | | |PgU| Up|Hom|Psc|Slk|Pau|Ins| | 7| 8| 9| Up|
84 |---------------------------------------------------------| |---------------|
85 |Fn0 |Lef|Dow|Rig| | | |Lef|Dow|Rig| | |Return| | 4| 5| 6| Dn|
86 |---------------------------------------------------------| |---------------|
87 |Shift |End| |PgD| | | |PgD| |End| |Shift | | 1| 2| 3| |
88 `---------------------------------------------------------' |-----------|Ent|
89 |Alt|Gui | Space |Ctl |Alt| | 0| .| |
90 `-----------------------------------------------' `---------------'
91
92### M0110A
93#### *Default*
94 ,---------------------------------------------------------. ,---------------.
95 | `| 1| 2| 3| 4| 5| 6| 7| 8| 9| 0| -| =|Backs| |Ctl| =| /| *|
96 |---------------------------------------------------------| |---------------|
97 |Tab | Q| W| E| R| T| Y| U| I| O| P| [| ]| | | 7| 8| 9| -|
98 |-----------------------------------------------------' | |---------------|
99 |Fn0 | A| S| D| F| G| H| J| K| L| ;| '|Return| | 4| 5| 6| +|
100 |---------------------------------------------------------| |---------------|
101 |Shift | Z| X| C| V| B| N| M| ,| ,| /|Shft| Up| | 1| 2| 3| |
102 |---------------------------------------------------------| |-----------|Ent|
103 |Alt |Gui | Space | \|Lft|Rgt| Dn| | 0| .| |
104 `---------------------------------------------------------' `---------------'
105#### *Cursor Layer(WASD/IJKL)*
106 ,---------------------------------------------------------. ,---------------.
107 |Esc| F1| F2| F3| F4| F5| F6| F7| F8| F9|F10|F11|F12|Delet| |Nlk| =| /| *|
108 |---------------------------------------------------------| |---------------|
109 |Caps |Hom| Up|PgU| | | |PgU| Up|Hom|Psc|Slk|Pau| | | 7| 8| 9| -|
110 |-----------------------------------------------------' | |---------------|
111 |Fn0 |Lef|Dow|Rig| | | |Lef|Dow|Rig| | |Return| | 4| 5| 6| +|
112 |---------------------------------------------------------| |---------------|
113 |Shift |End| |PgD| | | |PgD| |End| |Shif|PgU| | 1| 2| 3| |
114 |---------------------------------------------------------| |-----------|Ent|
115 |Alt |Gui | Space |Ins|Hom|End|PgD| | 0| .| |
116 `---------------------------------------------------------' `---------------'
117
118
119
120Debug
121-----
122You can use [PJRC HID listen](http://www.pjrc.com/teensy/hid_listen.html) to see debug output.
123
124The converter has some functions for debug, press `<magickey>+H` simultaneously to get help.
125These function is totally undocumented, tentative, inconsistent and buggy.
126
127magickey: Shift+Option+Command(Shift+Alt+Gui or Shift+Alt+Control)
Imprint / Impressum