]> git.donarmstrong.com Git - qmk_firmware.git/blob - keyboards/ergodox/readme.md
Merge pull request #1183 from Rovanion/real-master
[qmk_firmware.git] / keyboards / ergodox / readme.md
1 # The Easy Way
2
3 If you have an ErgoDox EZ, the absolute easiest way for you to customize your firmware is using the [graphical configurator](http://configure.ergodox-ez.com), which uses QMK under the hood.
4
5 If you can find firmware someone else has made that does what you want, that
6 is the easiest way to customize your ErgoDox.  It requires no programming
7 experience or the setup of a build environment.
8
9 Quickstart:
10
11   - Find and download an existing firmware
12     [from Other Firmware Options](#other-firmware-options)
13
14   - Then flash the firmware to your [ErgoDox Ez](#ergodox-ez)
15     or [ErgoDox Infinity](#ergodox-infinity)
16
17 # Customizing Keymaps
18
19 There are many existing keymaps in the "keymaps" directory.  If you just want
20 to use one of them, you don't need to modify keymaps and can just build and
21 flash the firmware as described below.  These directories each have a
22 "readme.md" file which describe them.
23
24 If none of the existing keymaps suit you, you can create your own custom
25 keymap.  This will require some experience with coding.  Follow these steps
26 to customize a keymap:
27
28   - Read the [qmk firmware README](https://github.com/qmk/qmk_firmware) from top to bottom.  Then come back here.  :)
29
30   - Clone the qmk_firmware repository
31
32   - Set up your build environment (see below).
33
34   - Make a new directory under "keymaps" to hold your customizations.
35
36   - Copy an existing keymap that is close to what you want, such as
37     "keymaps/default/keymap.c".
38
39   - Use an editor to modify the new "keymap.c".  See "Finding the keycodes you
40     need" below).  Try to edit the comments as well, so the "text graphics"
41     represent your layout correctly.
42
43   - Compile your new firmware (see below)
44
45   - Flash your firmware (see below)
46
47   - Test the changes.
48
49   - Submit your keymap as a pull request to the qmk_firmware repository so
50     others can use it.  You will want to add a "readme.md" that describes the
51     keymap.
52
53 # Build Dependencies
54
55 Before you can build, you will need the build dependencies.  There is a script
56 to try to do this for Linux:
57
58   - Run the `util/install_dependencies.sh` script as root.
59
60 For the Infinity, you need the chibios submodules to be checked out or you
61 will receive errors about the build process being unable to find the chibios
62 files.  Check them out with:
63
64   - Go to the top level repo directory and run: `git submodule update --init --recursive`
65
66 # Flashing Firmware
67
68 ## ErgoDox EZ
69
70 The Ez uses the [Teensy Loader](https://www.pjrc.com/teensy/loader.html).
71
72 Linux users need to modify udev rules as described on the [Teensy
73 Linux page].  Some distributions provide a binary, maybe called
74 `teensy-loader-cli`.
75
76 [Teensy Linux page]: https://www.pjrc.com/teensy/loader_linux.html
77
78 To flash the firmware:
79
80   - Build the firmware with `make keymapname`, for example `make default`
81
82   - This will result in a hex file called `ergodox_ez_keymapname.hex`, e.g.
83     `ergodox_ez_default.hex`
84
85   - Start the teensy loader.
86
87   - Load the .hex file into it.
88
89   - Press the Reset button by inserting a paperclip gently into the reset hole
90     in the top right corder.
91
92   - Click the button in the Teensy app to download the firmware.
93
94 To flash with ´teensy-loader-cli´:
95
96   - Build the firmware with `make keymapname`, for example `make default`
97
98   - Run ´<path/to/>teensy_loader_cli --mcu=atmega32u4 -w ergodox_ez_<keymap>.hex´
99
100   - Press the Reset button by inserting a paperclip gently into the reset hole
101     in the top right corder.
102
103 ## ErgoDox Infinity
104
105 The Infinity is two completely independent keyboards, and needs to be flashed
106 for the left and right halves seperately.  To flash them:
107
108   - Build the firmware with `make infinity-keymapname`
109
110   - Plug in the left hand keyboard only.
111
112   - Press the program button (back of keyboard, above thumb pad).
113
114   - Install the firmware with `sudo make infinity-keymapname-dfu-util`
115
116   - Build right hand firmware with `make infinity-keymapname MASTER=right`
117
118   - Plug in the right hand keyboard only.
119
120   - Press the program button (back of keyboard, above thumb pad).
121
122   - Install the firmware with `sudo make infinity-keymapname-dfu-util MASTER=right`
123
124 More information on the Infinity firmware is available in the [TMK/chibios for
125 Input Club Infinity Ergodox](https://github.com/fredizzimo/infinity_ergodox/blob/master/README.md)
126
127 ### Infinity Master/Two Halves
128
129 The Infinity is two completely independent keyboards, that can connect together.
130 You have a few options in how you flash the firmware:
131
132 - Flash the left half, rebuild the firmware with "MASTER=right" and then flash
133   the right half.  This allows you to plug in either half directly to the
134   computer and is what the above instructions do.
135
136 - Flash the left half, then flash the same firmware on the right.  This only
137   works when the left half is plugged directly to the computer and the keymap
138   is mirrored.  It saves the small extra step of rebuilding with
139   "MASTER=right".
140
141 - The same as the previous one but with "MASTER=right" when you build the
142   firmware, then flash the same firmware to both halves.  You just have to
143   directly connect the right half to the computer.
144
145 - For minor changes such as changing only the keymap without having updated
146   any part of the firmware code itself, you can program only the MASTER half.
147   It is safest to program both halves though.
148
149 # Contributing your keymap
150
151 The QMK firmware is open-source, so it would be wonderful to have your contribution! Within a very short time after launching we already amassed dozens of user-contributed keymaps, with all sorts of creative improvements and tweaks. This is very valuable for people who aren't comfortable coding, but do want to customize their ErgoDox. To make it easy for these people to use your layout, I recommend submitting your PR in the following format.
152
153 1. All work goes inside your keymap subdirectory (`keymaps/german` in this example).
154 2. `keymap.c` - this is your actual keymap file; please update the ASCII comments in the file so they correspond with what you did.
155 3. `readme.md` - a readme file, which GitHub would display by default when people go to your directory. Explain what's different about your keymap, what you tweaked or how it works. No specific format to follow, just communicate what you did. :)
156 4. Any graphics you wish to add. This is absolutely not a must. If you feel like it, you can use [Keyboard Layout Editor](http://keyboard-layout-editor.com) to make something and grab a screenshot, but it's really not a must. If you do have graphics, your readme can just embed the graphic as a link, just like I did with the default layout.
157
158 # Finding the keycodes you need
159
160 Let's say you want a certain key in your layout to send a colon; to figure out what keycode to use to make it do that, you're going to need `quantum/keymap_common.h`.
161
162 That file contains a big list of all of the special, fancy keys (like, being able to send % on its own and whatnot).
163
164 If you want to send a plain vanilla key, you can look up its code under `doc/keycode.txt`. That's where all the boring keys hang out.
165
166 # Other Firmware Options
167
168 There are external tools for customizing the layout, but those do not use
169 the featurs of this qmk firmware.  These sites include:
170
171   - The official [ErgoDox EZ configurator](http://configure.ergodox-ez.com)
172   - [Massdrop configurator](https://keyboard-configurator.massdrop.com/ext/ergodox) for EZ, works but not officially supported
173   - [Input Club configurator](https://input.club/configurator-ergodox) for Infinity, provides left and right files
174
175 You can also find an existing firmware that you like, for example from:
176
177   - [Dozens of community-contributed keymaps](http://qmk.fm/keyboards/ergodox/)