diff options
| author | Fred Sundvik <fsundvik@gmail.com> | 2016-07-09 00:41:15 +0300 |
|---|---|---|
| committer | Fred Sundvik <fsundvik@gmail.com> | 2016-07-29 20:48:20 +0300 |
| commit | e01b4c3fd9a7b66276ffd22dcac25d569d7bb7ff (patch) | |
| tree | bb5dcd6b71353aebfd93da01d740b527c4cdca82 | |
| parent | b0376687f4cc2dc0b5ffd89f3bcb33c873b1f4d3 (diff) | |
| download | qmk_firmware-e01b4c3fd9a7b66276ffd22dcac25d569d7bb7ff.tar.gz qmk_firmware-e01b4c3fd9a7b66276ffd22dcac25d569d7bb7ff.zip | |
Most ergodox keymaps compiles on Infinity
There are linker errors due to missing led funcitonality though
| -rw-r--r-- | keyboards/ergodox/drivers/gdisp/IS31FL3731C/board_IS31FL3731C.h (renamed from keyboards/ergodox/infinity/drivers/gdisp/IS31FL3731C/board_IS31FL3731C.h) | 0 | ||||
| -rw-r--r-- | keyboards/ergodox/drivers/gdisp/IS31FL3731C/driver.mk (renamed from keyboards/ergodox/infinity/drivers/gdisp/IS31FL3731C/driver.mk) | 0 | ||||
| -rw-r--r-- | keyboards/ergodox/drivers/gdisp/IS31FL3731C/gdisp_IS31FL3731C.c (renamed from keyboards/ergodox/infinity/drivers/gdisp/IS31FL3731C/gdisp_IS31FL3731C.c) | 0 | ||||
| -rw-r--r-- | keyboards/ergodox/drivers/gdisp/IS31FL3731C/gdisp_lld_config.h (renamed from keyboards/ergodox/infinity/drivers/gdisp/IS31FL3731C/gdisp_lld_config.h) | 0 | ||||
| -rw-r--r-- | keyboards/ergodox/drivers/gdisp/emulator_lcd/driver.mk (renamed from keyboards/ergodox/infinity/drivers/gdisp/emulator_lcd/driver.mk) | 0 | ||||
| -rw-r--r-- | keyboards/ergodox/drivers/gdisp/emulator_lcd/emulator_lcd.c (renamed from keyboards/ergodox/infinity/drivers/gdisp/emulator_lcd/emulator_lcd.c) | 0 | ||||
| -rw-r--r-- | keyboards/ergodox/drivers/gdisp/emulator_led/driver.mk (renamed from keyboards/ergodox/infinity/drivers/gdisp/emulator_led/driver.mk) | 0 | ||||
| -rw-r--r-- | keyboards/ergodox/drivers/gdisp/emulator_led/emulator_led.c (renamed from keyboards/ergodox/infinity/drivers/gdisp/emulator_led/emulator_led.c) | 0 | ||||
| -rw-r--r-- | keyboards/ergodox/drivers/gdisp/st7565ergodox/board_ST7565.h (renamed from keyboards/ergodox/infinity/drivers/gdisp/st7565ergodox/board_ST7565.h) | 0 | ||||
| -rw-r--r-- | keyboards/ergodox/drivers/gdisp/st7565ergodox/driver.mk (renamed from keyboards/ergodox/infinity/drivers/gdisp/st7565ergodox/driver.mk) | 0 | ||||
| -rw-r--r-- | keyboards/ergodox/drivers/gdisp/st7565ergodox/gdisp_lld_ST7565.c (renamed from keyboards/ergodox/infinity/drivers/gdisp/st7565ergodox/gdisp_lld_ST7565.c) | 0 | ||||
| -rw-r--r-- | keyboards/ergodox/drivers/gdisp/st7565ergodox/gdisp_lld_config.h (renamed from keyboards/ergodox/infinity/drivers/gdisp/st7565ergodox/gdisp_lld_config.h) | 0 | ||||
| -rw-r--r-- | keyboards/ergodox/drivers/gdisp/st7565ergodox/st7565.h (renamed from keyboards/ergodox/infinity/drivers/gdisp/st7565ergodox/st7565.h) | 0 | ||||
| -rw-r--r-- | keyboards/ergodox/ergodox.c | 8 | ||||
| -rw-r--r-- | keyboards/ergodox/ergodox.h | 1 | ||||
| -rw-r--r-- | keyboards/ergodox/infinity/Makefile | 4 | ||||
| -rw-r--r-- | keyboards/ergodox/infinity/infinity.c | 21 | ||||
| -rw-r--r-- | keyboards/ergodox/infinity/infinity.h | 36 | ||||
| -rw-r--r-- | keyboards/ergodox/infinity/matrix.c | 3 | ||||
| -rw-r--r-- | quantum/quantum.h | 1 | ||||
| -rw-r--r-- | tmk_core/common/print.h | 4 |
21 files changed, 46 insertions, 32 deletions
diff --git a/keyboards/ergodox/infinity/drivers/gdisp/IS31FL3731C/board_IS31FL3731C.h b/keyboards/ergodox/drivers/gdisp/IS31FL3731C/board_IS31FL3731C.h index 2ea73f1fb..2ea73f1fb 100644 --- a/keyboards/ergodox/infinity/drivers/gdisp/IS31FL3731C/board_IS31FL3731C.h +++ b/keyboards/ergodox/drivers/gdisp/IS31FL3731C/board_IS31FL3731C.h | |||
diff --git a/keyboards/ergodox/infinity/drivers/gdisp/IS31FL3731C/driver.mk b/keyboards/ergodox/drivers/gdisp/IS31FL3731C/driver.mk index f32d0d868..f32d0d868 100644 --- a/keyboards/ergodox/infinity/drivers/gdisp/IS31FL3731C/driver.mk +++ b/keyboards/ergodox/drivers/gdisp/IS31FL3731C/driver.mk | |||
diff --git a/keyboards/ergodox/infinity/drivers/gdisp/IS31FL3731C/gdisp_IS31FL3731C.c b/keyboards/ergodox/drivers/gdisp/IS31FL3731C/gdisp_IS31FL3731C.c index 1d21f0c49..1d21f0c49 100644 --- a/keyboards/ergodox/infinity/drivers/gdisp/IS31FL3731C/gdisp_IS31FL3731C.c +++ b/keyboards/ergodox/drivers/gdisp/IS31FL3731C/gdisp_IS31FL3731C.c | |||
diff --git a/keyboards/ergodox/infinity/drivers/gdisp/IS31FL3731C/gdisp_lld_config.h b/keyboards/ergodox/drivers/gdisp/IS31FL3731C/gdisp_lld_config.h index bb28ad775..bb28ad775 100644 --- a/keyboards/ergodox/infinity/drivers/gdisp/IS31FL3731C/gdisp_lld_config.h +++ b/keyboards/ergodox/drivers/gdisp/IS31FL3731C/gdisp_lld_config.h | |||
diff --git a/keyboards/ergodox/infinity/drivers/gdisp/emulator_lcd/driver.mk b/keyboards/ergodox/drivers/gdisp/emulator_lcd/driver.mk index 16c3f80f5..16c3f80f5 100644 --- a/keyboards/ergodox/infinity/drivers/gdisp/emulator_lcd/driver.mk +++ b/keyboards/ergodox/drivers/gdisp/emulator_lcd/driver.mk | |||
diff --git a/keyboards/ergodox/infinity/drivers/gdisp/emulator_lcd/emulator_lcd.c b/keyboards/ergodox/drivers/gdisp/emulator_lcd/emulator_lcd.c index babfe2b36..babfe2b36 100644 --- a/keyboards/ergodox/infinity/drivers/gdisp/emulator_lcd/emulator_lcd.c +++ b/keyboards/ergodox/drivers/gdisp/emulator_lcd/emulator_lcd.c | |||
diff --git a/keyboards/ergodox/infinity/drivers/gdisp/emulator_led/driver.mk b/keyboards/ergodox/drivers/gdisp/emulator_led/driver.mk index 255434432..255434432 100644 --- a/keyboards/ergodox/infinity/drivers/gdisp/emulator_led/driver.mk +++ b/keyboards/ergodox/drivers/gdisp/emulator_led/driver.mk | |||
diff --git a/keyboards/ergodox/infinity/drivers/gdisp/emulator_led/emulator_led.c b/keyboards/ergodox/drivers/gdisp/emulator_led/emulator_led.c index b0ebcdc47..b0ebcdc47 100644 --- a/keyboards/ergodox/infinity/drivers/gdisp/emulator_led/emulator_led.c +++ b/keyboards/ergodox/drivers/gdisp/emulator_led/emulator_led.c | |||
diff --git a/keyboards/ergodox/infinity/drivers/gdisp/st7565ergodox/board_ST7565.h b/keyboards/ergodox/drivers/gdisp/st7565ergodox/board_ST7565.h index 290571ce5..290571ce5 100644 --- a/keyboards/ergodox/infinity/drivers/gdisp/st7565ergodox/board_ST7565.h +++ b/keyboards/ergodox/drivers/gdisp/st7565ergodox/board_ST7565.h | |||
diff --git a/keyboards/ergodox/infinity/drivers/gdisp/st7565ergodox/driver.mk b/keyboards/ergodox/drivers/gdisp/st7565ergodox/driver.mk index 889a1a031..889a1a031 100644 --- a/keyboards/ergodox/infinity/drivers/gdisp/st7565ergodox/driver.mk +++ b/keyboards/ergodox/drivers/gdisp/st7565ergodox/driver.mk | |||
diff --git a/keyboards/ergodox/infinity/drivers/gdisp/st7565ergodox/gdisp_lld_ST7565.c b/keyboards/ergodox/drivers/gdisp/st7565ergodox/gdisp_lld_ST7565.c index c33aea81a..c33aea81a 100644 --- a/keyboards/ergodox/infinity/drivers/gdisp/st7565ergodox/gdisp_lld_ST7565.c +++ b/keyboards/ergodox/drivers/gdisp/st7565ergodox/gdisp_lld_ST7565.c | |||
diff --git a/keyboards/ergodox/infinity/drivers/gdisp/st7565ergodox/gdisp_lld_config.h b/keyboards/ergodox/drivers/gdisp/st7565ergodox/gdisp_lld_config.h index 48587b9e1..48587b9e1 100644 --- a/keyboards/ergodox/infinity/drivers/gdisp/st7565ergodox/gdisp_lld_config.h +++ b/keyboards/ergodox/drivers/gdisp/st7565ergodox/gdisp_lld_config.h | |||
diff --git a/keyboards/ergodox/infinity/drivers/gdisp/st7565ergodox/st7565.h b/keyboards/ergodox/drivers/gdisp/st7565ergodox/st7565.h index 48636b33d..48636b33d 100644 --- a/keyboards/ergodox/infinity/drivers/gdisp/st7565ergodox/st7565.h +++ b/keyboards/ergodox/drivers/gdisp/st7565ergodox/st7565.h | |||
diff --git a/keyboards/ergodox/ergodox.c b/keyboards/ergodox/ergodox.c index 992e95d81..e69de29bb 100644 --- a/keyboards/ergodox/ergodox.c +++ b/keyboards/ergodox/ergodox.c | |||
| @@ -1,8 +0,0 @@ | |||
| 1 | /* | ||
| 2 | * ergodox.c | ||
| 3 | * | ||
| 4 | * Created on: 7 jul 2016 | ||
| 5 | * Author: Fred Wales | ||
| 6 | */ | ||
| 7 | |||
| 8 | |||
diff --git a/keyboards/ergodox/ergodox.h b/keyboards/ergodox/ergodox.h index fe54e3260..f8ec8b5bf 100644 --- a/keyboards/ergodox/ergodox.h +++ b/keyboards/ergodox/ergodox.h | |||
| @@ -1,6 +1,5 @@ | |||
| 1 | #ifndef KEYBOARDS_ERGODOX_ERGODOX_H_ | 1 | #ifndef KEYBOARDS_ERGODOX_ERGODOX_H_ |
| 2 | #define KEYBOARDS_ERGODOX_ERGODOX_H_ | 2 | #define KEYBOARDS_ERGODOX_ERGODOX_H_ |
| 3 | |||
| 4 | #ifdef SUBPROJECT_ez | 3 | #ifdef SUBPROJECT_ez |
| 5 | #include "ez.h" | 4 | #include "ez.h" |
| 6 | #endif | 5 | #endif |
diff --git a/keyboards/ergodox/infinity/Makefile b/keyboards/ergodox/infinity/Makefile index 942032f83..22065e4d2 100644 --- a/keyboards/ergodox/infinity/Makefile +++ b/keyboards/ergodox/infinity/Makefile | |||
| @@ -52,14 +52,14 @@ ARMV = 7 | |||
| 52 | # Vector table for application | 52 | # Vector table for application |
| 53 | # 0x00000000-0x00001000 area is occupied by bootlaoder.*/ | 53 | # 0x00000000-0x00001000 area is occupied by bootlaoder.*/ |
| 54 | # The CORTEX_VTOR... is needed only for MCHCK/Infinity KB | 54 | # The CORTEX_VTOR... is needed only for MCHCK/Infinity KB |
| 55 | OPT_DEFS = -DCORTEX_VTOR_INIT=0x00002000 | 55 | OPT_DEFS += -DCORTEX_VTOR_INIT=0x00002000 |
| 56 | 56 | ||
| 57 | # Build Options | 57 | # Build Options |
| 58 | # comment out to disable the options. | 58 | # comment out to disable the options. |
| 59 | # | 59 | # |
| 60 | CUSTOM_MATRIX ?= yes # Custom matrix file | 60 | CUSTOM_MATRIX ?= yes # Custom matrix file |
| 61 | SERIAL_LINK_ENABLE = yes | 61 | SERIAL_LINK_ENABLE = yes |
| 62 | VISUALIZER_ENABLE ?= yes | 62 | VISUALIZER_ENABLE ?= no #temporarily disabled to make everything compile |
| 63 | LCD_ENABLE ?= yes | 63 | LCD_ENABLE ?= yes |
| 64 | LED_ENABLE ?= yes | 64 | LED_ENABLE ?= yes |
| 65 | LCD_BACKLIGHT_ENABLE ?= yes | 65 | LCD_BACKLIGHT_ENABLE ?= yes |
diff --git a/keyboards/ergodox/infinity/infinity.c b/keyboards/ergodox/infinity/infinity.c index 87ed40fab..85e61e3aa 100644 --- a/keyboards/ergodox/infinity/infinity.c +++ b/keyboards/ergodox/infinity/infinity.c | |||
| @@ -1,8 +1,10 @@ | |||
| 1 | #include "infinity_ergodox.h" | 1 | #include "infinity.h" |
| 2 | #include "ch.h" | 2 | #include "ch.h" |
| 3 | #include "hal.h" | 3 | #include "hal.h" |
| 4 | #include "serial_link/system/serial_link.h" | 4 | #include "serial_link/system/serial_link.h" |
| 5 | #ifdef VISUALIZER_ENABLE | ||
| 5 | #include "lcd_backlight.h" | 6 | #include "lcd_backlight.h" |
| 7 | #endif | ||
| 6 | 8 | ||
| 7 | void init_serial_link_hal(void) { | 9 | void init_serial_link_hal(void) { |
| 8 | PORTA->PCR[1] = PORTx_PCRn_PE | PORTx_PCRn_PS | PORTx_PCRn_PFE | PORTx_PCRn_MUX(2); | 10 | PORTA->PCR[1] = PORTx_PCRn_PE | PORTx_PCRn_PS | PORTx_PCRn_PFE | PORTx_PCRn_MUX(2); |
| @@ -36,7 +38,7 @@ void init_serial_link_hal(void) { | |||
| 36 | // Using a higher pre-scalar without flicker is possible but FTM0_MOD will need to be reduced | 38 | // Using a higher pre-scalar without flicker is possible but FTM0_MOD will need to be reduced |
| 37 | // Which will reduce the brightness range | 39 | // Which will reduce the brightness range |
| 38 | #define PRESCALAR_DEFINE 0 | 40 | #define PRESCALAR_DEFINE 0 |
| 39 | 41 | #ifdef VISUALIZER_ENABLE | |
| 40 | void lcd_backlight_hal_init(void) { | 42 | void lcd_backlight_hal_init(void) { |
| 41 | // Setup Backlight | 43 | // Setup Backlight |
| 42 | SIM->SCGC6 |= SIM_SCGC6_FTM0; | 44 | SIM->SCGC6 |= SIM_SCGC6_FTM0; |
| @@ -74,3 +76,18 @@ void lcd_backlight_hal_color(uint16_t r, uint16_t g, uint16_t b) { | |||
| 74 | CHANNEL_GREEN.CnV = g; | 76 | CHANNEL_GREEN.CnV = g; |
| 75 | CHANNEL_BLUE.CnV = b; | 77 | CHANNEL_BLUE.CnV = b; |
| 76 | } | 78 | } |
| 79 | #endif | ||
| 80 | |||
| 81 | void matrix_init_kb(void) { | ||
| 82 | // put your keyboard start-up code here | ||
| 83 | // runs once when the firmware starts up | ||
| 84 | |||
| 85 | matrix_init_user(); | ||
| 86 | } | ||
| 87 | |||
| 88 | void matrix_scan_kb(void) { | ||
| 89 | // put your looping keyboard code here | ||
| 90 | // runs every cycle (a lot) | ||
| 91 | |||
| 92 | matrix_scan_user(); | ||
| 93 | } | ||
diff --git a/keyboards/ergodox/infinity/infinity.h b/keyboards/ergodox/infinity/infinity.h index de7267594..a92aa89bb 100644 --- a/keyboards/ergodox/infinity/infinity.h +++ b/keyboards/ergodox/infinity/infinity.h | |||
| @@ -21,24 +21,24 @@ | |||
| 21 | B04, \ | 21 | B04, \ |
| 22 | B14, B24, B34 \ | 22 | B14, B24, B34 \ |
| 23 | ) { \ | 23 | ) { \ |
| 24 | { KC_NO, KC_NO, KC_NO, KC_##A03, KC_##A04 }, \ | 24 | { KC_NO, KC_NO, KC_NO, A03, A04 }, \ |
| 25 | { KC_NO, KC_NO, KC_NO, KC_##A13, KC_##A14 }, \ | 25 | { KC_NO, KC_NO, KC_NO, A13, A14 }, \ |
| 26 | { KC_##A20, KC_##A21, KC_NO, KC_##A23, KC_##A24 }, \ | 26 | { A20, A21, KC_NO, A23, A24 }, \ |
| 27 | { KC_##A30, KC_##A31, KC_##A32, KC_##A33, KC_##A34 }, \ | 27 | { A30, A31, A32, A33, A34 }, \ |
| 28 | { KC_##A40, KC_##A41, KC_##A42, KC_##A43, KC_##A44 }, \ | 28 | { A40, A41, A42, A43, A44 }, \ |
| 29 | { KC_##A50, KC_##A51, KC_##A52, KC_##A53, KC_##A54 }, \ | 29 | { A50, A51, A52, A53, A54 }, \ |
| 30 | { KC_##A60, KC_##A61, KC_##A62, KC_##A63, KC_##A64 }, \ | 30 | { A60, A61, A62, A63, A64 }, \ |
| 31 | { KC_##A70, KC_##A71, KC_##A72, KC_##A73, KC_##A74 }, \ | 31 | { A70, A71, A72, A73, A74 }, \ |
| 32 | { KC_##A80, KC_##A81, KC_##A82, KC_##A83, KC_##A84 }, \ | 32 | { A80, A81, A82, A83, A84 }, \ |
| 33 | { KC_NO, KC_NO, KC_NO, KC_##B03, KC_##B04 }, \ | 33 | { KC_NO, KC_NO, KC_NO, B03, B04 }, \ |
| 34 | { KC_NO, KC_NO, KC_NO, KC_##B13, KC_##B14 }, \ | 34 | { KC_NO, KC_NO, KC_NO, B13, B14 }, \ |
| 35 | { KC_##B20, KC_##B21, KC_NO, KC_##B23, KC_##B24 }, \ | 35 | { B20, B21, KC_NO, B23, B24 }, \ |
| 36 | { KC_##B30, KC_##B31, KC_##B32, KC_##B33, KC_##B34 }, \ | 36 | { B30, B31, B32, B33, B34 }, \ |
| 37 | { KC_##B40, KC_##B41, KC_##B42, KC_##B43, KC_##B44 }, \ | 37 | { B40, B41, B42, B43, B44 }, \ |
| 38 | { KC_##B50, KC_##B51, KC_##B52, KC_##B53, KC_##B54 }, \ | 38 | { B50, B51, B52, B53, B54 }, \ |
| 39 | { KC_##B60, KC_##B61, KC_##B62, KC_##B63, KC_##B64 }, \ | 39 | { B60, B61, B62, B63, B64 }, \ |
| 40 | { KC_##B70, KC_##B71, KC_##B72, KC_##B73, KC_##B74 }, \ | 40 | { B70, B71, B72, B73, B74 }, \ |
| 41 | { KC_##B80, KC_##B81, KC_##B82, KC_##B83, KC_##B84 } \ | 41 | { B80, B81, B82, B83, B84 } \ |
| 42 | } | 42 | } |
| 43 | 43 | ||
| 44 | #endif /* KEYBOARDS_INFINITY_ERGODOX_INFINITY_ERGODOX_H_ */ | 44 | #endif /* KEYBOARDS_INFINITY_ERGODOX_INFINITY_ERGODOX_H_ */ |
diff --git a/keyboards/ergodox/infinity/matrix.c b/keyboards/ergodox/infinity/matrix.c index 2b806cd64..1fda90484 100644 --- a/keyboards/ergodox/infinity/matrix.c +++ b/keyboards/ergodox/infinity/matrix.c | |||
| @@ -63,6 +63,8 @@ void matrix_init(void) | |||
| 63 | 63 | ||
| 64 | memset(matrix, 0, MATRIX_ROWS); | 64 | memset(matrix, 0, MATRIX_ROWS); |
| 65 | memset(matrix_debouncing, 0, LOCAL_MATRIX_ROWS); | 65 | memset(matrix_debouncing, 0, LOCAL_MATRIX_ROWS); |
| 66 | |||
| 67 | matrix_init_quantum(); | ||
| 66 | } | 68 | } |
| 67 | 69 | ||
| 68 | uint8_t matrix_scan(void) | 70 | uint8_t matrix_scan(void) |
| @@ -127,6 +129,7 @@ uint8_t matrix_scan(void) | |||
| 127 | } | 129 | } |
| 128 | debouncing = false; | 130 | debouncing = false; |
| 129 | } | 131 | } |
| 132 | matrix_scan_quantum(); | ||
| 130 | return 1; | 133 | return 1; |
| 131 | } | 134 | } |
| 132 | 135 | ||
diff --git a/quantum/quantum.h b/quantum/quantum.h index 7ebfb24e3..6e3fbcc79 100644 --- a/quantum/quantum.h +++ b/quantum/quantum.h | |||
| @@ -25,6 +25,7 @@ | |||
| 25 | #include "led.h" | 25 | #include "led.h" |
| 26 | #include "action_util.h" | 26 | #include "action_util.h" |
| 27 | #include <stdlib.h> | 27 | #include <stdlib.h> |
| 28 | #include "print.h" | ||
| 28 | 29 | ||
| 29 | 30 | ||
| 30 | extern uint32_t default_layer_state; | 31 | extern uint32_t default_layer_state; |
diff --git a/tmk_core/common/print.h b/tmk_core/common/print.h index 0368bcd4a..a1352527f 100644 --- a/tmk_core/common/print.h +++ b/tmk_core/common/print.h | |||
| @@ -29,7 +29,9 @@ | |||
| 29 | #include <stdbool.h> | 29 | #include <stdbool.h> |
| 30 | #include "util.h" | 30 | #include "util.h" |
| 31 | 31 | ||
| 32 | 32 | #if defined(PROTOCOL_CHIBIOS) | |
| 33 | #define PSTR(x) x | ||
| 34 | #endif | ||
| 33 | 35 | ||
| 34 | 36 | ||
| 35 | #ifndef NO_PRINT | 37 | #ifndef NO_PRINT |
