From 6a2ba83e30e9a82ee99d08f4fe8d11efb6e22fce Mon Sep 17 00:00:00 2001 From: Dan Halbert Date: Fri, 14 May 2021 14:29:36 -0400 Subject: [PATCH] Update Rotary Trinkey and Slide Trinkey pins --- .../boards/adafruit_rotary_trinkey_m0/mpconfigboard.h | 1 + .../boards/adafruit_rotary_trinkey_m0/mpconfigboard.mk | 1 - ports/atmel-samd/boards/adafruit_rotary_trinkey_m0/pins.c | 3 ++- ports/atmel-samd/boards/adafruit_slide_trinkey_m0/board.c | 2 +- .../boards/adafruit_slide_trinkey_m0/mpconfigboard.h | 5 ++--- ports/atmel-samd/boards/adafruit_slide_trinkey_m0/pins.c | 6 +++--- 6 files changed, 9 insertions(+), 9 deletions(-) diff --git a/ports/atmel-samd/boards/adafruit_rotary_trinkey_m0/mpconfigboard.h b/ports/atmel-samd/boards/adafruit_rotary_trinkey_m0/mpconfigboard.h index 2b06b31ede..1f927d9a62 100644 --- a/ports/atmel-samd/boards/adafruit_rotary_trinkey_m0/mpconfigboard.h +++ b/ports/atmel-samd/boards/adafruit_rotary_trinkey_m0/mpconfigboard.h @@ -10,6 +10,7 @@ #define IGNORE_PIN_PA02 1 #define IGNORE_PIN_PA03 1 #define IGNORE_PIN_PA05 1 +#define IGNORE_PIN_PA07 1 #define IGNORE_PIN_PA08 1 #define IGNORE_PIN_PA09 1 #define IGNORE_PIN_PA10 1 diff --git a/ports/atmel-samd/boards/adafruit_rotary_trinkey_m0/mpconfigboard.mk b/ports/atmel-samd/boards/adafruit_rotary_trinkey_m0/mpconfigboard.mk index b596c726cd..3bcdd8f896 100644 --- a/ports/atmel-samd/boards/adafruit_rotary_trinkey_m0/mpconfigboard.mk +++ b/ports/atmel-samd/boards/adafruit_rotary_trinkey_m0/mpconfigboard.mk @@ -16,7 +16,6 @@ CIRCUITPY_PULSEIO = 0 CIRCUITPY_PWMIO = 0 CIRCUITPY_AUDIOCORE = 0 CIRCUITPY_BUSIO = 0 -CIRCUITPY_TOUCHIO = 0 # Include these Python libraries in firmware. FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_NeoPixel diff --git a/ports/atmel-samd/boards/adafruit_rotary_trinkey_m0/pins.c b/ports/atmel-samd/boards/adafruit_rotary_trinkey_m0/pins.c index cd014fcb64..95e3fef822 100644 --- a/ports/atmel-samd/boards/adafruit_rotary_trinkey_m0/pins.c +++ b/ports/atmel-samd/boards/adafruit_rotary_trinkey_m0/pins.c @@ -2,8 +2,9 @@ STATIC const mp_rom_map_elem_t board_global_dict_table[] = { { MP_ROM_QSTR(MP_QSTR_NEOPIXEL), MP_ROM_PTR(&pin_PA01) }, + { MP_ROM_QSTR(MP_QSTR_ROTA), MP_ROM_PTR(&pin_PA04) }, { MP_ROM_QSTR(MP_QSTR_ROTB), MP_ROM_PTR(&pin_PA00) }, - { MP_ROM_QSTR(MP_QSTR_ROTA), MP_ROM_PTR(&pin_PA06) }, { MP_ROM_QSTR(MP_QSTR_SWITCH), MP_ROM_PTR(&pin_PA27) }, + { MP_ROM_QSTR(MP_QSTR_TOUCH), MP_ROM_PTR(&pin_PA06) }, }; MP_DEFINE_CONST_DICT(board_module_globals, board_global_dict_table); diff --git a/ports/atmel-samd/boards/adafruit_slide_trinkey_m0/board.c b/ports/atmel-samd/boards/adafruit_slide_trinkey_m0/board.c index 095750731b..c1d1260143 100644 --- a/ports/atmel-samd/boards/adafruit_slide_trinkey_m0/board.c +++ b/ports/atmel-samd/boards/adafruit_slide_trinkey_m0/board.c @@ -37,5 +37,5 @@ bool board_requests_safe_mode(void) { } void reset_board(void) { - board_reset_user_neopixels(&pin_PA06, 2); + board_reset_user_neopixels(&pin_PA04, 2); } diff --git a/ports/atmel-samd/boards/adafruit_slide_trinkey_m0/mpconfigboard.h b/ports/atmel-samd/boards/adafruit_slide_trinkey_m0/mpconfigboard.h index 1d9a4122df..759290cda7 100644 --- a/ports/atmel-samd/boards/adafruit_slide_trinkey_m0/mpconfigboard.h +++ b/ports/atmel-samd/boards/adafruit_slide_trinkey_m0/mpconfigboard.h @@ -1,7 +1,7 @@ #define MICROPY_HW_BOARD_NAME "Adafruit Slide Trinkey M0" #define MICROPY_HW_MCU_NAME "samd21e18" -#define MICROPY_HW_NEOPIXEL (&pin_PA06) +#define MICROPY_HW_NEOPIXEL (&pin_PA04) #define MICROPY_PORT_A (0) #define MICROPY_PORT_B (0) @@ -9,10 +9,9 @@ #define IGNORE_PIN_PA00 1 #define IGNORE_PIN_PA01 1 -#define IGNORE_PIN_PA02 1 #define IGNORE_PIN_PA03 1 -#define IGNORE_PIN_PA04 1 #define IGNORE_PIN_PA05 1 +#define IGNORE_PIN_PA06 1 #define IGNORE_PIN_PA08 1 #define IGNORE_PIN_PA09 1 #define IGNORE_PIN_PA10 1 diff --git a/ports/atmel-samd/boards/adafruit_slide_trinkey_m0/pins.c b/ports/atmel-samd/boards/adafruit_slide_trinkey_m0/pins.c index 238610ddc2..a9b1c9eca0 100644 --- a/ports/atmel-samd/boards/adafruit_slide_trinkey_m0/pins.c +++ b/ports/atmel-samd/boards/adafruit_slide_trinkey_m0/pins.c @@ -1,8 +1,8 @@ #include "shared-bindings/board/__init__.h" STATIC const mp_rom_map_elem_t board_global_dict_table[] = { - // { MP_ROM_QSTR(MP_QSTR_TOUCH), MP_ROM_PTR(&pin_PA07) }, - { MP_ROM_QSTR(MP_QSTR_NEOPIXEL), MP_ROM_PTR(&pin_PA06) }, - { MP_ROM_QSTR(MP_QSTR_POTENTIOMETER), MP_ROM_PTR(&pin_PA07) }, + { MP_ROM_QSTR(MP_QSTR_NEOPIXEL), MP_ROM_PTR(&pin_PA04) }, + { MP_ROM_QSTR(MP_QSTR_POTENTIOMETER), MP_ROM_PTR(&pin_PA02) }, + { MP_ROM_QSTR(MP_QSTR_TOUCH), MP_ROM_PTR(&pin_PA07) }, }; MP_DEFINE_CONST_DICT(board_module_globals, board_global_dict_table);