Makefile redo & other features (#395)
* .build containment implemented * no destructive variable setting - builds in either folder * make from 3 places * cleans before each build * make from root with keyboard=keyboard, keymap=keymap * make from keyboard/keyboard with keymap=keymap * make from keymaps/keymap * only implemented on planck * adds color diag to avr-gcc * makefiles for all plancks, clean-up * quick build-all makefile for plancks * reformatting of make output (colors) * color toggle, tmk path corrections * correct if statement for color * move config.h to main makefile, updates preonic, atomic * format update, all keyboards targets * makefile optional for build all target, alps and arrow_pad updated * alps updated * make planck default, trying out travis recipe for all-keyboards * all-keymaps target, different travis recipe * updates alps64 * updates keyboards to new format * updates clue* projects * all projects updated, specialise EZ .hex, let .hex through * updates travis * automatically find root, keyboard, keymap * silent echo, cleaned-up mass make output * updates all keyboards' .hex files except EZ * Rename Bantam44.c to bantam44.c * Rename Bantam44.h to bantam44.h * nananana * adds six key keyboard * does same to ez as rest * updates send_string example * brings ergodox_ez up to date * updates template/new project script * adds sixkeyboard * adds readme for sixkeyboard * adds sixkeyboard to travis * filenames, gitignore mess * define clock prescaler stuff manually * make quick, size test example * documentation and dfu-no-build
This commit is contained in:
		
							parent
							
								
									a5d638ad30
								
							
						
					
					
						commit
						d9e4dad0a8
					
				
					 317 changed files with 135651 additions and 67504 deletions
				
			
		| 
						 | 
				
			
			@ -1,141 +1,60 @@
 | 
			
		|||
GH60 keyboard firmware
 | 
			
		||||
======================
 | 
			
		||||
DIY compact keyboard designed and run by komar007 and Geekhack community.
 | 
			
		||||
 | 
			
		||||
- Both Rev.A and Rev.B PCB are supported by one firmware binary(issue #64)
 | 
			
		||||
 | 
			
		||||
## GH60 Resources
 | 
			
		||||
- [KOMAR's project page](http://blog.komar.be/projects/gh60-programmable-keyboard/)
 | 
			
		||||
- [Prototyping](http://geekhack.org/index.php?topic=34959.0)
 | 
			
		||||
- [Rev.A PCB test](http://geekhack.org/index.php?topic=37570.0)
 | 
			
		||||
- [Rev.B PCB test](http://geekhack.org/index.php?topic=50685.0)
 | 
			
		||||
- [Group buy](http://geekhack.org/index.php?topic=41464.0)
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
## Build
 | 
			
		||||
Move to this directory then just run `make` like:
 | 
			
		||||
 | 
			
		||||
    $ make
 | 
			
		||||
 | 
			
		||||
Use `make -f Makefile.pjrc` if you want to use PJRC stack but I find no reason to do so now.
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
## Keymap
 | 
			
		||||
Several version of keymap are available in advance but you are recommended to define your favorite layout yourself. To define your own keymap create file named `<name>.c` in the keymaps folder, and see keymap document(you can find in top README.md) and existent keymap files.
 | 
			
		||||
 | 
			
		||||
To build firmware binary hex file with a certain keymap just do `make` with `KEYMAP` option like:
 | 
			
		||||
 | 
			
		||||
    $ make KEYMAP=[poker|poker_set|poker_bit|plain|hasu|spacefn|hhkb|<name>]
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
### 1  Poker
 | 
			
		||||
[poker.c](keymaps/poker.c) emulates original Poker layers
 | 
			
		||||
while both [poker_bit.c](keymaps/poker_bit.c) and [poker_set.c](keymaps/poker_set.c) implement the same layout in different ways and they fix a minor issue of original Poker and enhance arrow keys.
 | 
			
		||||
 | 
			
		||||
    Fn + Esc = `
 | 
			
		||||
    Fn + {left, down, up, right}  = {home, pgdown, pgup, end}
 | 
			
		||||
 | 
			
		||||
#### 1.0 Default layer
 | 
			
		||||
    ,-----------------------------------------------------------.
 | 
			
		||||
    |  `|  1|  2|  3|  4|  5|  6|  7|  8|  9|  0|  -|  =|Backsp |
 | 
			
		||||
    |-----------------------------------------------------------|
 | 
			
		||||
    |Tab  |  Q|  W|  E|  R|  T|  Y|  U|  I|  O|  P|  [|  ]|    \|
 | 
			
		||||
    |-----------------------------------------------------------|
 | 
			
		||||
    |Caps  |  A|  S|  D|  F|  G|  H|  J|  K|  L|  ;|  '|Return  |
 | 
			
		||||
    |-----------------------------------------------------------|
 | 
			
		||||
    |Shift   |  Z|  X|  C|  V|  B|  N|  M|  ,|  .|  /|Shift     |
 | 
			
		||||
    |-----------------------------------------------------------|
 | 
			
		||||
    |Ctrl|Gui |Alt |      Space             |Fn  |Gui |App |Ctrl|
 | 
			
		||||
    `-----------------------------------------------------------'
 | 
			
		||||
#### 1.1 Poker Fn layer
 | 
			
		||||
    ,-----------------------------------------------------------.
 | 
			
		||||
    |Esc| F1| F2| F3| F4| F5| F6| F7| F8| F9|F10|F11|F12|       |
 | 
			
		||||
    |-----------------------------------------------------------|
 | 
			
		||||
    |     |FnQ| Up|   |   |   |   |   |   |Cal|   |Hom|Ins|     |
 | 
			
		||||
    |-----------------------------------------------------------|
 | 
			
		||||
    |      |Lef|Dow|Rig|   |   |Psc|Slk|Pau|   |Tsk|End|        |
 | 
			
		||||
    |-----------------------------------------------------------|
 | 
			
		||||
    |        |Del|   |Web|Mut|VoU|VoD|   |PgU|PgD|Del|   Up     |
 | 
			
		||||
    |-----------------------------------------------------------|
 | 
			
		||||
    |    |    |    |         FnS            |Fn  |Left|Down|Righ|
 | 
			
		||||
    `-----------------------------------------------------------'
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
### 2. Plain
 | 
			
		||||
Without any Fn layer this will be useful if you want to use key remapping tool like AHK on host.
 | 
			
		||||
See [plain.c](keymaps/plain.c) for detail.
 | 
			
		||||
 | 
			
		||||
#### 1.0 Plain Default layer
 | 
			
		||||
    ,-----------------------------------------------------------.
 | 
			
		||||
    |Esc|  1|  2|  3|  4|  5|  6|  7|  8|  9|  0|  -|  =|Backsp |
 | 
			
		||||
    |-----------------------------------------------------------|
 | 
			
		||||
    |Tab  |  Q|  W|  E|  R|  T|  Y|  U|  I|  O|  P|  [|  ]|    \|
 | 
			
		||||
    |-----------------------------------------------------------|
 | 
			
		||||
    |Caps  |  A|  S|  D|  F|  G|  H|  J|  K|  L|  ;|  '|Return  |
 | 
			
		||||
    |-----------------------------------------------------------|
 | 
			
		||||
    |Shift   |  Z|  X|  C|  V|  B|  N|  M|  ,|  .|  /|Shift     |
 | 
			
		||||
    |-----------------------------------------------------------|
 | 
			
		||||
    |Ctrl|Gui |Alt |      Space             |Alt |Gui |App |Ctrl|
 | 
			
		||||
    `-----------------------------------------------------------'
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
### 3. Hasu
 | 
			
		||||
This is my favorite keymap with HHKB Fn, Vi cursor and Mousekey layer. See [hasu.c](keymaps/hasu.c) for detail.
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
### 4. SpaceFN
 | 
			
		||||
This layout proposed by spiceBar uses space bar to change layer with using Dual role key technique. See [spacefn.c](keymaps/spacefn.c) and [SpaceFN discussion](http://geekhack.org/index.php?topic=51069.0).
 | 
			
		||||
 | 
			
		||||
#### 4.0 Default layer
 | 
			
		||||
    ,-----------------------------------------------------------.
 | 
			
		||||
    |Esc|  1|  2|  3|  4|  5|  6|  7|  8|  9|  0|  -|  =|Backsp |
 | 
			
		||||
    |-----------------------------------------------------------|
 | 
			
		||||
    |Tab  |  Q|  W|  E|  R|  T|  Y|  U|  I|  O|  P|  [|  ]|    \|
 | 
			
		||||
    |-----------------------------------------------------------|
 | 
			
		||||
    |Caps  |  A|  S|  D|  F|  G|  H|  J|  K|  L|  ;|  '|Return  |
 | 
			
		||||
    |-----------------------------------------------------------|
 | 
			
		||||
    |Shift   |  Z|  X|  C|  V|  B|  N|  M|  ,|  .|  /|Shift     |
 | 
			
		||||
    |-----------------------------------------------------------|
 | 
			
		||||
    |Ctrl|Gui |Alt |      Space/Fn          |Alt |Gui |App |Ctrl|
 | 
			
		||||
    `-----------------------------------------------------------'
 | 
			
		||||
#### 4.1 SpaceFN layer
 | 
			
		||||
    ,-----------------------------------------------------------.
 | 
			
		||||
    |`  | F1| F2| F3| F4| F5| F6| F7| F8| F9|F10|F11|F12|Delete |
 | 
			
		||||
    |-----------------------------------------------------------|
 | 
			
		||||
    |     |   |   |   |   |   |   |Hom|Up |End|Psc|Slk|Pau|Ins  |
 | 
			
		||||
    |-----------------------------------------------------------|
 | 
			
		||||
    |      |   |   |   |   |   |PgU|Lef|Dow|Rig|   |   |        |
 | 
			
		||||
    |-----------------------------------------------------------|
 | 
			
		||||
    |        |   |   |   |   |Spc|PgD|`  |~  |   |   |          |
 | 
			
		||||
    |-----------------------------------------------------------|
 | 
			
		||||
    |    |    |    |            Fn          |    |    |    |    |
 | 
			
		||||
    `-----------------------------------------------------------'
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
### 5. HHKB
 | 
			
		||||
[hhkb.c](keymaps/hhkb.c) emulates original HHKB layers.
 | 
			
		||||
#### 5.0: Default layer
 | 
			
		||||
    ,-----------------------------------------------------------.
 | 
			
		||||
    |Esc|  1|  2|  3|  4|  5|  6|  7|  8|  9|  0|  -|  =|  \|  `|
 | 
			
		||||
    |-----------------------------------------------------------|
 | 
			
		||||
    |Tab  |  Q|  W|  E|  R|  T|  Y|  U|  I|  O|  P|  [|  ]|Bspc |
 | 
			
		||||
    |-----------------------------------------------------------|
 | 
			
		||||
    |Ctrl  |  A|  S|  D|  F|  G|  H|  J|  K|  L|Fn3|  '|Return  |
 | 
			
		||||
    |-----------------------------------------------------------|
 | 
			
		||||
    |Shift   |  Z|  X|  C|  V|  B|  N|  M|  ,|  .|  /|Shift |Fn |
 | 
			
		||||
    |-----------------------------------------------------------|
 | 
			
		||||
    |    |Gui |Alt |      Space             |    |Alt |Gui |    |
 | 
			
		||||
    `-----------------------------------------------------------'
 | 
			
		||||
#### 5.1: HHKB Fn layer
 | 
			
		||||
    ,-----------------------------------------------------------.
 | 
			
		||||
    |Pwr| F1| F2| F3| F4| F5| F6| F7| F8| F9|F10|F11|F12|Ins|Del|
 | 
			
		||||
    |-----------------------------------------------------------|
 | 
			
		||||
    |Caps |   |   |   |   |   |   |   |Psc|Slk|Pus|Up |   |     |
 | 
			
		||||
    |-----------------------------------------------------------|
 | 
			
		||||
    |      |VoD|VoU|Mut|Ejc|   |  *|  /|Hom|PgU|Lef|Rig|Enter   |
 | 
			
		||||
    |-----------------------------------------------------------|
 | 
			
		||||
    |        |   |   |   |   |   |  +|  -|End|PgD|Dow|      |   |
 | 
			
		||||
    |-----------------------------------------------------------|
 | 
			
		||||
    |    |    |    |                        |    |    |    |    |
 | 
			
		||||
    `-----------------------------------------------------------'
 | 
			
		||||
 | 
			
		||||
## gh60 Rev C keyboard firmware
 | 
			
		||||
 | 
			
		||||

 | 
			
		||||
 | 
			
		||||
    /* Column pin configuration
 | 
			
		||||
    * col: 0   1   2   3   4   5   6   7   8   9   10  11  12  13
 | 
			
		||||
    * pin: F0  F1  E6  C7  C6  B6  D4  B1  B7  B5  B4  D7  D6  B3  (Rev.C)
 | 
			
		||||
    */
 | 
			
		||||
     
 | 
			
		||||
    /* Row pin configuration
 | 
			
		||||
    * row: 0   1   2   3   4
 | 
			
		||||
    * pin: D0  D1  D2  D3  D5
 | 
			
		||||
    */
 | 
			
		||||
     
 | 
			
		||||
    GPIO pads
 | 
			
		||||
    0 F7 WASD LEDs
 | 
			
		||||
    1 F6 ESC LED
 | 
			
		||||
    2 F5 FN LED
 | 
			
		||||
    3 F4 POKER Arrow LEDs
 | 
			
		||||
     
 | 
			
		||||
    B2 Capslock LED
 | 
			
		||||
    B0 not connected
 | 
			
		||||
	
 | 
			
		||||
Functions to controls LED clusters
 | 
			
		||||
	
 | 
			
		||||
    gh60_caps_led_on()
 | 
			
		||||
    gh60_poker_leds_on()
 | 
			
		||||
    gh60_fn_led_on()
 | 
			
		||||
    gh60_esc_led_on()
 | 
			
		||||
    gh60_wasd_leds_on()
 | 
			
		||||
    
 | 
			
		||||
    gh60_caps_led_off()
 | 
			
		||||
    gh60_poker_leds_off()
 | 
			
		||||
    gh60_fn_led_off()
 | 
			
		||||
    gh60_esc_led_off()
 | 
			
		||||
    gh60_wasd_leds_off()
 | 
			
		||||
	
 | 
			
		||||
======================
 | 
			
		||||
 | 
			
		||||
## Quantum MK Firmware
 | 
			
		||||
 | 
			
		||||
For the full Quantum feature list, see [the parent README.md](/README.md).
 | 
			
		||||
 | 
			
		||||
## Building
 | 
			
		||||
 | 
			
		||||
Download or clone the whole firmware and navigate to the keyboard/gh60_rev_c folder. Once your dev env is setup, you'll be able to type `make` to generate your .hex - you can then use the Teensy Loader to program your .hex file. 
 | 
			
		||||
 | 
			
		||||
Depending on which keymap you would like to use, you will have to compile slightly differently.
 | 
			
		||||
 | 
			
		||||
### Default
 | 
			
		||||
To build with the default keymap, simply run `make`.
 | 
			
		||||
 | 
			
		||||
### Other Keymaps
 | 
			
		||||
Several version of keymap are available in advance but you are recommended to define your favorite layout yourself. To define your own keymap create file named `<name>.c` in the keymaps folder, and see keymap document (you can find in top README.md) and existent keymap files.
 | 
			
		||||
 | 
			
		||||
To build the firmware binary hex file with a keymap just do `make` with `KEYMAP` option like:
 | 
			
		||||
```
 | 
			
		||||
$ make KEYMAP=[default|jack|<name>]
 | 
			
		||||
```
 | 
			
		||||
Keymaps follow the format **__\<name\>.c__** and are stored in the `keymaps` folder.
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue