summaryrefslogtreecommitdiff
path: root/keyboards/infinity_ergodox
diff options
context:
space:
mode:
authorJack Humbert2016-07-06 09:48:58 -0400
committerGitHub2016-07-06 09:48:58 -0400
commit19f480992c015aec0a15dca43e740bad8b7834e6 (patch)
tree2d1470d076017af6d089a00f4bb317abdb331346 /keyboards/infinity_ergodox
parentc6d671e54c249497b5c01ad9badaa50425f394f9 (diff)
parente5726b017a9de2922ea923818c6e215600f68a85 (diff)
Merge pull request #487 from fredizzimo/serial_link_ergodox
Integrate serial link support for ChibiOS and Infinity Ergodox
Diffstat (limited to 'keyboards/infinity_ergodox')
-rw-r--r--keyboards/infinity_ergodox/Makefile1
-rw-r--r--keyboards/infinity_ergodox/infinity_ergodox.c10
2 files changed, 11 insertions, 0 deletions
diff --git a/keyboards/infinity_ergodox/Makefile b/keyboards/infinity_ergodox/Makefile
index fb21aae5e..efa32e037 100644
--- a/keyboards/infinity_ergodox/Makefile
+++ b/keyboards/infinity_ergodox/Makefile
@@ -66,6 +66,7 @@ COMMAND_ENABLE ?= yes # Commands for debug and configuration
SLEEP_LED_ENABLE ?= yes # Breathing sleep LED during USB suspend
NKRO_ENABLE ?= yes # USB Nkey Rollover
CUSTOM_MATRIX ?= yes # Custom matrix file
+SERIAL_LINK_ENABLE = yes
ifndef QUANTUM_DIR
include ../../Makefile
diff --git a/keyboards/infinity_ergodox/infinity_ergodox.c b/keyboards/infinity_ergodox/infinity_ergodox.c
index 34aded1a7..85054775e 100644
--- a/keyboards/infinity_ergodox/infinity_ergodox.c
+++ b/keyboards/infinity_ergodox/infinity_ergodox.c
@@ -1 +1,11 @@
#include "infinity_ergodox.h"
+#include "ch.h"
+#include "hal.h"
+#include "serial_link/system/serial_link.h"
+
+void init_serial_link_hal(void) {
+ PORTA->PCR[1] = PORTx_PCRn_PE | PORTx_PCRn_PS | PORTx_PCRn_PFE | PORTx_PCRn_MUX(2);
+ PORTA->PCR[2] = PORTx_PCRn_DSE | PORTx_PCRn_SRE | PORTx_PCRn_MUX(2);
+ PORTE->PCR[0] = PORTx_PCRn_PE | PORTx_PCRn_PS | PORTx_PCRn_PFE | PORTx_PCRn_MUX(3);
+ PORTE->PCR[1] = PORTx_PCRn_DSE | PORTx_PCRn_SRE | PORTx_PCRn_MUX(3);
+}