summaryrefslogtreecommitdiff
path: root/keyboards/helix
diff options
context:
space:
mode:
authorRyan <fauxpark@gmail.com>2020-03-15 02:31:15 +1100
committerGitHub <noreply@github.com>2020-03-14 15:31:15 +0000
commitd597af9e1e15ed54b3f967c52e39a6cc3b980b68 (patch)
tree0271c0c4f4993ba28b1ad6354ff438ee22bca078 /keyboards/helix
parent03ed8197175ffe046de050b3c2fd7b70f641cc60 (diff)
Remove pro_micro.h (#8374)
* Remove pro_micro.h * Include quantum.h
Diffstat (limited to 'keyboards/helix')
-rw-r--r--keyboards/helix/pico/matrix.c17
-rw-r--r--keyboards/helix/rev1/matrix.c9
-rw-r--r--keyboards/helix/rev2/matrix.c17
3 files changed, 23 insertions, 20 deletions
diff --git a/keyboards/helix/pico/matrix.c b/keyboards/helix/pico/matrix.c
index a537ef03c4..27170e0394 100644
--- a/keyboards/helix/pico/matrix.c
+++ b/keyboards/helix/pico/matrix.c
@@ -29,7 +29,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#include "util.h"
#include "matrix.h"
#include "split_util.h"
-#include "pro_micro.h"
+#include "quantum.h"
#ifdef USE_MATRIX_I2C
# include "i2c.h"
@@ -99,9 +99,10 @@ void matrix_init(void)
unselect_rows();
init_cols();
- TX_RX_LED_INIT;
- TXLED0;
- RXLED0;
+ setPinOutput(B0);
+ setPinOutput(D5);
+ writePinHigh(B0);
+ writePinHigh(D5);
// initialize matrix state: all keys off
for (uint8_t i=0; i < MATRIX_ROWS; i++) {
@@ -180,10 +181,10 @@ int serial_transaction(void) {
int slaveOffset = (isLeftHand) ? (ROWS_PER_HAND) : 0;
int ret=serial_update_buffers();
if (ret ) {
- if(ret==2)RXLED1;
+ if(ret==2) writePinLow(B0);
return 1;
}
- RXLED0;
+ writePinHigh(B0);
for (int i = 0; i < ROWS_PER_HAND; ++i) {
matrix[slaveOffset+i] = serial_slave_buffer[i];
}
@@ -235,7 +236,7 @@ uint8_t matrix_master_scan(void) {
if( serial_transaction() ) {
#endif
// turn on the indicator led when halves are disconnected
- TXLED1;
+ writePinLow(D5);
error_count++;
@@ -248,7 +249,7 @@ uint8_t matrix_master_scan(void) {
}
} else {
// turn off the indicator led on no error
- TXLED0;
+ writePinHigh(D5);
error_count = 0;
}
matrix_scan_quantum();
diff --git a/keyboards/helix/rev1/matrix.c b/keyboards/helix/rev1/matrix.c
index f2506868ea..06ef49b563 100644
--- a/keyboards/helix/rev1/matrix.c
+++ b/keyboards/helix/rev1/matrix.c
@@ -29,8 +29,8 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#include "util.h"
#include "matrix.h"
#include "split_util.h"
-#include "pro_micro.h"
#include "config.h"
+#include "quantum.h"
#ifdef USE_MATRIX_I2C
# include "i2c.h"
@@ -100,7 +100,8 @@ void matrix_init(void)
unselect_rows();
init_cols();
- TX_RX_LED_INIT;
+ setPinOutput(B0);
+ setPinOutput(D5);
// initialize matrix state: all keys off
for (uint8_t i=0; i < MATRIX_ROWS; i++) {
@@ -201,7 +202,7 @@ uint8_t matrix_scan(void)
if( serial_transaction() ) {
#endif
// turn on the indicator led when halves are disconnected
- TXLED1;
+ writePinLow(D5);
error_count++;
@@ -214,7 +215,7 @@ uint8_t matrix_scan(void)
}
} else {
// turn off the indicator led on no error
- TXLED0;
+ writePinHigh(D5);
error_count = 0;
}
matrix_scan_quantum();
diff --git a/keyboards/helix/rev2/matrix.c b/keyboards/helix/rev2/matrix.c
index 050dcac2d2..8ea070aa3a 100644
--- a/keyboards/helix/rev2/matrix.c
+++ b/keyboards/helix/rev2/matrix.c
@@ -30,7 +30,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#include "util.h"
#include "matrix.h"
#include "split_util.h"
-#include "pro_micro.h"
+#include "quantum.h"
#ifdef USE_MATRIX_I2C
# include "i2c.h"
@@ -100,9 +100,10 @@ void matrix_init(void)
unselect_rows();
init_cols();
- TX_RX_LED_INIT;
- TXLED0;
- RXLED0;
+ setPinOutput(B0);
+ setPinOutput(D5);
+ writePinHigh(B0);
+ writePinHigh(D5);
// initialize matrix state: all keys off
for (uint8_t i=0; i < MATRIX_ROWS; i++) {
@@ -185,10 +186,10 @@ int serial_transaction(int master_changed) {
int ret=serial_update_buffers();
#endif
if (ret ) {
- if(ret==2) RXLED1;
+ if(ret==2) writePinLow(B0);
return 1;
}
- RXLED0;
+ writePinHigh(B0);
memcpy(&matrix[slaveOffset],
(void *)serial_slave_buffer, sizeof(serial_slave_buffer));
return 0;
@@ -239,7 +240,7 @@ uint8_t matrix_master_scan(void) {
if( serial_transaction(mchanged) ) {
#endif
// turn on the indicator led when halves are disconnected
- TXLED1;
+ writePinLow(D5);
error_count++;
@@ -252,7 +253,7 @@ uint8_t matrix_master_scan(void) {
}
} else {
// turn off the indicator led on no error
- TXLED0;
+ writePinHigh(D5);
error_count = 0;
}
matrix_scan_quantum();