2018-12-29 08:20:03 +01:00
|
|
|
import board
|
|
|
|
|
2019-07-25 10:30:55 +02:00
|
|
|
from kmk.kmk_keyboard import KMKKeyboard as _KMKKeyboard
|
2022-10-09 17:44:45 +02:00
|
|
|
from kmk.quickpin.pro_micro.boardsource_blok import pinout as pins
|
2022-04-09 02:09:24 +02:00
|
|
|
from kmk.scanners import DiodeOrientation
|
2018-12-29 08:20:03 +01:00
|
|
|
|
|
|
|
|
2019-07-25 10:30:55 +02:00
|
|
|
class KMKKeyboard(_KMKKeyboard):
|
2022-10-09 17:44:45 +02:00
|
|
|
row_pins = (
|
|
|
|
board.pins[8],
|
|
|
|
board.pins[9],
|
|
|
|
board.pins[10],
|
|
|
|
board.pins[1],
|
|
|
|
board.pins[6],
|
|
|
|
)
|
2020-10-21 21:19:42 +02:00
|
|
|
col_pins = (
|
2022-10-09 17:44:45 +02:00
|
|
|
board.pins[17],
|
|
|
|
board.pins[16],
|
|
|
|
board.pins[15],
|
|
|
|
board.pins[14],
|
|
|
|
board.pins[13],
|
|
|
|
board.pins[12],
|
2020-10-21 21:19:42 +02:00
|
|
|
)
|
2018-12-29 08:20:03 +01:00
|
|
|
diode_orientation = DiodeOrientation.COLUMNS
|
2022-10-09 17:44:45 +02:00
|
|
|
led_pin = board.pins[11]
|
|
|
|
rgb_pixel_pin = pins[0]
|
2020-10-21 21:19:42 +02:00
|
|
|
rgb_num_pixels = 12
|
|
|
|
i2c = board.I2C
|
2022-10-09 17:44:45 +02:00
|
|
|
data_pin = board.pins[5]
|
2019-05-13 02:04:23 +02:00
|
|
|
|
2022-02-20 21:28:52 +01:00
|
|
|
# flake8: noqa
|
2022-10-09 17:44:45 +02:00
|
|
|
# fmt: off
|
2022-02-20 21:28:52 +01:00
|
|
|
coord_mapping = [
|
2022-07-14 08:59:25 +02:00
|
|
|
0, 1, 2, 3, 4, 5, 35, 34, 33, 32, 31, 30,
|
|
|
|
6, 7, 8, 9, 10, 11, 41, 40, 39, 38, 37, 36,
|
|
|
|
12, 13, 14, 15, 16, 17, 47, 46, 45, 44, 43, 42,
|
|
|
|
18, 19, 20, 21, 22, 23, 26, 56, 53, 52, 51, 50, 49, 48,
|
|
|
|
27, 28, 29, 59, 58, 57,
|
2022-02-20 21:28:52 +01:00
|
|
|
]
|