Skip to content

Commit

Permalink
infinity: Add initial files for keyboard support
Browse files Browse the repository at this point in the history
  • Loading branch information
tmk committed Jan 4, 2015
1 parent c6e533c commit d0fefb7
Show file tree
Hide file tree
Showing 18 changed files with 1,029 additions and 411 deletions.
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ You can find some keyboard specific projects under `converter` and `keyboard` di
* [macway](keyboard/macway/) - [Compact keyboard mod][GH_macway] [retired]
* [KMAC](keyboard/kmac/) - Korean custom keyboard
* [Lightsaber](keyboard/lightsaber/) - Korean custom keyboard
* [Infinity](keyboard/infinity/) - Massdrop [Infinity keyboard][Infinity]

[GH_macway]: http://geekhack.org/showwiki.php?title=Island:11930
[GH_hhkb]: http://geekhack.org/showwiki.php?title=Island:12047
Expand All @@ -72,6 +73,7 @@ You can find some keyboard specific projects under `converter` and `keyboard` di
[PC98]: http://en.wikipedia.org/wiki/NEC_PC-9801
[Sun]: http://en.wikipedia.org/wiki/Sun-3
[IIGS]: http://en.wikipedia.org/wiki/Apple_IIGS
[Infinity]: https://www.massdrop.com/buy/infinity-keyboard-kit



Expand Down
9 changes: 8 additions & 1 deletion common/matrix.h
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,10 @@ typedef uint32_t matrix_row_t;
#define MATRIX_IS_ON(row, col) (matrix_get_row(row) && (1<<col))


#ifdef __cplusplus
extern "C" {
#endif

/* number of matrix rows */
uint8_t matrix_rows(void);
/* number of matrix columns */
Expand All @@ -48,7 +52,7 @@ bool matrix_is_modified(void) __attribute__ ((deprecated));
/* whether a swtich is on */
bool matrix_is_on(uint8_t row, uint8_t col);
/* matrix state on row */
matrix_row_t matrix_get_row(uint8_t row);
matrix_row_t matrix_get_row(uint8_t row);
/* print matrix for debug */
void matrix_print(void);

Expand All @@ -57,5 +61,8 @@ void matrix_print(void);
void matrix_power_up(void);
void matrix_power_down(void);

#ifdef __cplusplus
}
#endif

#endif
5 changes: 5 additions & 0 deletions common/mbed/xprintf.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@

#define STRING_STACK_LIMIT 120

//TODO
int xprintf(const char* format, ...) { return 0; }

#if 0
/* mbed Serial */
Serial ser(UART_TX, UART_RX);

Expand Down Expand Up @@ -44,3 +48,4 @@ int xprintf(const char* format, ...)
return r;
*/
}
#endif
Loading

0 comments on commit d0fefb7

Please sign in to comment.