Rename internal pins to add underscore in front
This commit is contained in:
parent
f5f4932220
commit
3826ca4194
|
@ -192,26 +192,26 @@ def init():
|
||||||
_tick = time.monotonic()
|
_tick = time.monotonic()
|
||||||
|
|
||||||
_rows = (
|
_rows = (
|
||||||
digitalio.DigitalInOut(board.R1),
|
digitalio.DigitalInOut(board._R1),
|
||||||
digitalio.DigitalInOut(board.R2),
|
digitalio.DigitalInOut(board._R2),
|
||||||
digitalio.DigitalInOut(board.R3),
|
digitalio.DigitalInOut(board._R3),
|
||||||
digitalio.DigitalInOut(board.R4),
|
digitalio.DigitalInOut(board._R4),
|
||||||
digitalio.DigitalInOut(board.R5),
|
digitalio.DigitalInOut(board._R5),
|
||||||
digitalio.DigitalInOut(board.R6),
|
digitalio.DigitalInOut(board._R6),
|
||||||
digitalio.DigitalInOut(board.R7),
|
digitalio.DigitalInOut(board._R7),
|
||||||
digitalio.DigitalInOut(board.R8),
|
digitalio.DigitalInOut(board._R8),
|
||||||
)
|
)
|
||||||
|
|
||||||
_cols = (
|
_cols = (
|
||||||
digitalio.DigitalInOut(board.C1),
|
digitalio.DigitalInOut(board._C1),
|
||||||
digitalio.DigitalInOut(board.C2),
|
digitalio.DigitalInOut(board._C2),
|
||||||
digitalio.DigitalInOut(board.C3),
|
digitalio.DigitalInOut(board._C3),
|
||||||
digitalio.DigitalInOut(board.C4),
|
digitalio.DigitalInOut(board._C4),
|
||||||
digitalio.DigitalInOut(board.C5),
|
digitalio.DigitalInOut(board._C5),
|
||||||
digitalio.DigitalInOut(board.C6),
|
digitalio.DigitalInOut(board._C6),
|
||||||
digitalio.DigitalInOut(board.C7),
|
digitalio.DigitalInOut(board._C7),
|
||||||
digitalio.DigitalInOut(board.C8),
|
digitalio.DigitalInOut(board._C8),
|
||||||
)
|
)
|
||||||
_buttons = digitalio.DigitalInOut(board.BUTTONS)
|
_buttons = digitalio.DigitalInOut(board._BUTTONS)
|
||||||
_pew.PewPew(_screen.buffer, _rows, _cols, _buttons)
|
_pew.PewPew(_screen.buffer, _rows, _cols, _buttons)
|
||||||
keys = _pew.get_pressed
|
keys = _pew.get_pressed
|
||||||
|
|
|
@ -3,23 +3,23 @@
|
||||||
#include "supervisor/shared/board_busses.h"
|
#include "supervisor/shared/board_busses.h"
|
||||||
|
|
||||||
STATIC const mp_rom_map_elem_t board_global_dict_table[] = {
|
STATIC const mp_rom_map_elem_t board_global_dict_table[] = {
|
||||||
{ MP_ROM_QSTR(MP_QSTR_R1), MP_ROM_PTR(&pin_PA05) },
|
{ MP_ROM_QSTR(MP_QSTR__R1), MP_ROM_PTR(&pin_PA05) },
|
||||||
{ MP_ROM_QSTR(MP_QSTR_R2), MP_ROM_PTR(&pin_PA11) },
|
{ MP_ROM_QSTR(MP_QSTR__R2), MP_ROM_PTR(&pin_PA11) },
|
||||||
{ MP_ROM_QSTR(MP_QSTR_R3), MP_ROM_PTR(&pin_PA28) },
|
{ MP_ROM_QSTR(MP_QSTR__R3), MP_ROM_PTR(&pin_PA28) },
|
||||||
{ MP_ROM_QSTR(MP_QSTR_R4), MP_ROM_PTR(&pin_PA09) },
|
{ MP_ROM_QSTR(MP_QSTR__R4), MP_ROM_PTR(&pin_PA09) },
|
||||||
{ MP_ROM_QSTR(MP_QSTR_R5), MP_ROM_PTR(&pin_PA16) },
|
{ MP_ROM_QSTR(MP_QSTR__R5), MP_ROM_PTR(&pin_PA16) },
|
||||||
{ MP_ROM_QSTR(MP_QSTR_R6), MP_ROM_PTR(&pin_PA27) },
|
{ MP_ROM_QSTR(MP_QSTR__R6), MP_ROM_PTR(&pin_PA27) },
|
||||||
{ MP_ROM_QSTR(MP_QSTR_R7), MP_ROM_PTR(&pin_PA17) },
|
{ MP_ROM_QSTR(MP_QSTR__R7), MP_ROM_PTR(&pin_PA17) },
|
||||||
{ MP_ROM_QSTR(MP_QSTR_R8), MP_ROM_PTR(&pin_PA22) },
|
{ MP_ROM_QSTR(MP_QSTR__R8), MP_ROM_PTR(&pin_PA22) },
|
||||||
|
|
||||||
{ MP_ROM_QSTR(MP_QSTR_C8), MP_ROM_PTR(&pin_PA10) },
|
{ MP_ROM_QSTR(MP_QSTR__C8), MP_ROM_PTR(&pin_PA10) },
|
||||||
{ MP_ROM_QSTR(MP_QSTR_C7), MP_ROM_PTR(&pin_PA18) },
|
{ MP_ROM_QSTR(MP_QSTR__C7), MP_ROM_PTR(&pin_PA18) },
|
||||||
{ MP_ROM_QSTR(MP_QSTR_C6), MP_ROM_PTR(&pin_PA19) },
|
{ MP_ROM_QSTR(MP_QSTR__C6), MP_ROM_PTR(&pin_PA19) },
|
||||||
{ MP_ROM_QSTR(MP_QSTR_C5), MP_ROM_PTR(&pin_PA06) },
|
{ MP_ROM_QSTR(MP_QSTR__C5), MP_ROM_PTR(&pin_PA06) },
|
||||||
{ MP_ROM_QSTR(MP_QSTR_C4), MP_ROM_PTR(&pin_PA23) },
|
{ MP_ROM_QSTR(MP_QSTR__C4), MP_ROM_PTR(&pin_PA23) },
|
||||||
{ MP_ROM_QSTR(MP_QSTR_C3), MP_ROM_PTR(&pin_PA07) },
|
{ MP_ROM_QSTR(MP_QSTR__C3), MP_ROM_PTR(&pin_PA07) },
|
||||||
{ MP_ROM_QSTR(MP_QSTR_C2), MP_ROM_PTR(&pin_PA14) },
|
{ MP_ROM_QSTR(MP_QSTR__C2), MP_ROM_PTR(&pin_PA14) },
|
||||||
{ MP_ROM_QSTR(MP_QSTR_C1), MP_ROM_PTR(&pin_PA15) },
|
{ MP_ROM_QSTR(MP_QSTR__C1), MP_ROM_PTR(&pin_PA15) },
|
||||||
|
|
||||||
{ MP_ROM_QSTR(MP_QSTR_P1), MP_ROM_PTR(&pin_PA30) },
|
{ MP_ROM_QSTR(MP_QSTR_P1), MP_ROM_PTR(&pin_PA30) },
|
||||||
{ MP_ROM_QSTR(MP_QSTR_P2), MP_ROM_PTR(&pin_PA31) },
|
{ MP_ROM_QSTR(MP_QSTR_P2), MP_ROM_PTR(&pin_PA31) },
|
||||||
|
@ -29,7 +29,7 @@ STATIC const mp_rom_map_elem_t board_global_dict_table[] = {
|
||||||
{ MP_ROM_QSTR(MP_QSTR_P6), MP_ROM_PTR(&pin_PA03) },
|
{ MP_ROM_QSTR(MP_QSTR_P6), MP_ROM_PTR(&pin_PA03) },
|
||||||
{ MP_ROM_QSTR(MP_QSTR_P7), MP_ROM_PTR(&pin_PA04) },
|
{ MP_ROM_QSTR(MP_QSTR_P7), MP_ROM_PTR(&pin_PA04) },
|
||||||
|
|
||||||
{ MP_ROM_QSTR(MP_QSTR_BUTTONS), MP_ROM_PTR(&pin_PA08) },
|
{ MP_ROM_QSTR(MP_QSTR__BUTTONS), MP_ROM_PTR(&pin_PA08) },
|
||||||
|
|
||||||
};
|
};
|
||||||
MP_DEFINE_CONST_DICT(board_module_globals, board_global_dict_table);
|
MP_DEFINE_CONST_DICT(board_module_globals, board_global_dict_table);
|
||||||
|
|
Loading…
Reference in New Issue