From ca2cb9af2b9421e29eddc81ec6c924842e280f15 Mon Sep 17 00:00:00 2001 From: Scott Shawcroft Date: Thu, 15 Jul 2021 16:20:04 -0700 Subject: [PATCH 1/2] Remove MICROPY_PORT_* macros used for never reset Now we use never_reset which is generally more correct and easier to get right. Fixes #5001 and fixes #4997 --- .../atmel-samd/boards/8086_commander/mpconfigboard.h | 4 ---- .../boards/adafruit_neokey_trinkey_m0/mpconfigboard.h | 4 ---- .../adafruit_proxlight_trinkey_m0/mpconfigboard.h | 4 ---- .../boards/adafruit_rotary_trinkey_m0/mpconfigboard.h | 4 ---- .../boards/adafruit_slide_trinkey_m0/mpconfigboard.h | 4 ---- ports/atmel-samd/boards/aloriumtech_evo_m51/board.c | 1 + .../boards/aloriumtech_evo_m51/mpconfigboard.h | 8 -------- .../atmel-samd/boards/arduino_mkr1300/mpconfigboard.h | 4 ---- .../atmel-samd/boards/arduino_mkrzero/mpconfigboard.h | 4 ---- .../boards/arduino_nano_33_iot/mpconfigboard.h | 4 ---- ports/atmel-samd/boards/arduino_zero/mpconfigboard.h | 4 ---- .../boards/bast_pro_mini_m0/mpconfigboard.h | 4 ---- .../boards/bdmicro_vina_d21/mpconfigboard.h | 5 ----- .../boards/bdmicro_vina_d51/mpconfigboard.h | 7 ------- .../boards/bdmicro_vina_d51_pcb7/mpconfigboard.h | 7 ------- ports/atmel-samd/boards/blm_badge/mpconfigboard.h | 4 ---- .../boards/capablerobot_usbhub/mpconfigboard.h | 8 -------- .../atmel-samd/boards/catwan_usbstick/mpconfigboard.h | 4 ---- .../boards/circuitbrains_basic_m0/mpconfigboard.h | 5 ----- .../boards/circuitbrains_deluxe_m4/mpconfigboard.h | 8 -------- .../boards/circuitplayground_express/mpconfigboard.h | 5 ----- .../circuitplayground_express_crickit/mpconfigboard.h | 5 ----- .../mpconfigboard.h | 5 ----- ports/atmel-samd/boards/cp32-m4/mpconfigboard.h | 6 ------ ports/atmel-samd/boards/cp_sapling_m0/mpconfigboard.h | 4 ---- .../boards/cp_sapling_m0_revb/mpconfigboard.h | 4 ---- .../boards/cp_sapling_m0_spiflash/mpconfigboard.h | 4 ---- .../atmel-samd/boards/datalore_ip_m4/mpconfigboard.h | 8 -------- .../atmel-samd/boards/datum_distance/mpconfigboard.h | 4 ---- ports/atmel-samd/boards/datum_imu/mpconfigboard.h | 4 ---- ports/atmel-samd/boards/datum_light/mpconfigboard.h | 4 ---- ports/atmel-samd/boards/datum_weather/mpconfigboard.h | 4 ---- ports/atmel-samd/boards/dynalora_usb/mpconfigboard.h | 5 ----- .../boards/dynossat_edu_eps/mpconfigboard.h | 5 ----- .../boards/dynossat_edu_obc/mpconfigboard.h | 6 ------ .../boards/escornabot_makech/mpconfigboard.h | 5 ----- .../boards/feather_m0_adalogger/mpconfigboard.h | 4 ---- .../boards/feather_m0_basic/mpconfigboard.h | 4 ---- .../boards/feather_m0_express/mpconfigboard.h | 5 ----- .../boards/feather_m0_express_crickit/mpconfigboard.h | 5 ----- .../boards/feather_m0_rfm69/mpconfigboard.h | 4 ---- .../boards/feather_m0_rfm9x/mpconfigboard.h | 4 ---- .../boards/feather_m0_supersized/mpconfigboard.h | 5 ----- .../atmel-samd/boards/feather_m4_can/mpconfigboard.h | 8 -------- .../boards/feather_m4_express/mpconfigboard.h | 8 -------- ports/atmel-samd/boards/fluff_m0/mpconfigboard.h | 4 ---- ports/atmel-samd/boards/gemma_m0/mpconfigboard.h | 4 ---- .../boards/grandcentral_m4_express/mpconfigboard.h | 9 --------- ports/atmel-samd/boards/hallowing_m0_express/board.c | 1 + .../boards/hallowing_m0_express/mpconfigboard.h | 7 ------- .../boards/hallowing_m4_express/mpconfigboard.h | 8 -------- ports/atmel-samd/boards/huntercat_nfc/mpconfigboard.h | 4 ---- .../boards/itsybitsy_m0_express/mpconfigboard.h | 5 ----- .../boards/itsybitsy_m4_express/mpconfigboard.h | 8 -------- .../atmel-samd/boards/kicksat-sprite/mpconfigboard.h | 5 ----- .../boards/loc_ber_m4_base_board/mpconfigboard.h | 8 -------- .../atmel-samd/boards/matrixportal_m4/mpconfigboard.h | 8 -------- ports/atmel-samd/boards/meowmeow/mpconfigboard.h | 5 ----- .../boards/metro_m0_express/mpconfigboard.h | 5 ----- .../boards/metro_m4_airlift_lite/mpconfigboard.h | 8 -------- .../boards/metro_m4_express/mpconfigboard.h | 8 -------- ports/atmel-samd/boards/mini_sam_m4/mpconfigboard.h | 8 -------- ports/atmel-samd/boards/monster_m4sk/mpconfigboard.h | 8 -------- .../atmel-samd/boards/ndgarage_ndbit6/mpconfigboard.h | 4 ---- .../boards/ndgarage_ndbit6_v2/mpconfigboard.h | 4 ---- .../boards/neopixel_trinkey_m0/mpconfigboard.h | 4 ---- ports/atmel-samd/boards/nfc_copy_cat/mpconfigboard.h | 4 ---- ports/atmel-samd/boards/openbook_m4/mpconfigboard.h | 8 -------- ports/atmel-samd/boards/pewpew10/mpconfigboard.h | 4 ---- ports/atmel-samd/boards/pewpew_m4/mpconfigboard.h | 6 ------ ports/atmel-samd/boards/picoplanet/mpconfigboard.h | 4 ---- ports/atmel-samd/boards/pybadge/mpconfigboard.h | 8 -------- ports/atmel-samd/boards/pycubed/mpconfigboard.h | 5 ----- ports/atmel-samd/boards/pycubed_mram/mpconfigboard.h | 8 -------- ports/atmel-samd/boards/pygamer/mpconfigboard.h | 8 -------- ports/atmel-samd/boards/pyportal/mpconfigboard.h | 8 -------- .../atmel-samd/boards/pyportal_titano/mpconfigboard.h | 8 -------- ports/atmel-samd/boards/pyruler/mpconfigboard.h | 4 ---- ports/atmel-samd/boards/qtpy_m0/mpconfigboard.h | 4 ---- .../boards/qtpy_m0_haxpress/mpconfigboard.h | 4 ---- ports/atmel-samd/boards/robohatmm1_m4/mpconfigboard.h | 7 ------- ports/atmel-samd/boards/sam32/mpconfigboard.h | 5 ----- .../atmel-samd/boards/same54_xplained/mpconfigboard.h | 8 -------- .../boards/seeeduino_wio_terminal/mpconfigboard.h | 8 -------- .../atmel-samd/boards/seeeduino_xiao/mpconfigboard.h | 4 ---- ports/atmel-samd/boards/sensebox_mcu/mpconfigboard.h | 4 ---- ports/atmel-samd/boards/serpente/mpconfigboard.h | 5 ----- ports/atmel-samd/boards/shirtty/mpconfigboard.h | 4 ---- .../boards/silicognition-m4-shim/mpconfigboard.h | 8 -------- ports/atmel-samd/boards/snekboard/mpconfigboard.h | 5 ----- .../boards/sparkfun_lumidrive/mpconfigboard.h | 4 ---- .../sparkfun_qwiic_micro_no_flash/mpconfigboard.h | 4 ---- .../sparkfun_qwiic_micro_with_flash/mpconfigboard.h | 4 ---- .../boards/sparkfun_redboard_turbo/mpconfigboard.h | 4 ---- .../boards/sparkfun_samd21_dev/mpconfigboard.h | 4 ---- .../boards/sparkfun_samd21_mini/mpconfigboard.h | 4 ---- .../boards/sparkfun_samd51_micromod/mpconfigboard.h | 7 ------- .../boards/sparkfun_samd51_thing_plus/mpconfigboard.h | 7 ------- .../boards/stackrduino_m0_pro/mpconfigboard.h | 5 ----- .../boards/stringcar_m0_express/mpconfigboard.h | 5 ----- .../boards/trellis_m4_express/mpconfigboard.h | 8 -------- ports/atmel-samd/boards/trinket_m0/mpconfigboard.h | 4 ---- .../boards/trinket_m0_haxpress/mpconfigboard.h | 5 ----- ports/atmel-samd/boards/uartlogger2/mpconfigboard.h | 8 -------- ports/atmel-samd/boards/uchip/board.c | 8 ++++++++ ports/atmel-samd/boards/uchip/mpconfigboard.h | 6 ++---- ports/atmel-samd/boards/ugame10/mpconfigboard.h | 5 ----- .../winterbloom_big_honking_button/mpconfigboard.h | 5 ----- .../atmel-samd/boards/winterbloom_sol/mpconfigboard.h | 8 -------- ports/atmel-samd/boards/xinabox_cc03/mpconfigboard.h | 4 ---- ports/atmel-samd/boards/xinabox_cs11/mpconfigboard.h | 4 ---- ports/atmel-samd/common-hal/microcontroller/Pin.c | 8 ++++---- ports/atmel-samd/supervisor/qspi_flash.c | 11 +++++++++-- supervisor/shared/status_leds.c | 2 ++ 114 files changed, 27 insertions(+), 595 deletions(-) diff --git a/ports/atmel-samd/boards/8086_commander/mpconfigboard.h b/ports/atmel-samd/boards/8086_commander/mpconfigboard.h index 0b5d3a267d..5f5cad0fe8 100644 --- a/ports/atmel-samd/boards/8086_commander/mpconfigboard.h +++ b/ports/atmel-samd/boards/8086_commander/mpconfigboard.h @@ -6,10 +6,6 @@ #define MICROPY_HW_LED_STATUS (&pin_PA06) -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - // USB is always used internally so skip the pin objects for it. #define IGNORE_PIN_PA24 1 #define IGNORE_PIN_PA25 1 diff --git a/ports/atmel-samd/boards/adafruit_neokey_trinkey_m0/mpconfigboard.h b/ports/atmel-samd/boards/adafruit_neokey_trinkey_m0/mpconfigboard.h index 3cd85ac1bc..c932a0652f 100644 --- a/ports/atmel-samd/boards/adafruit_neokey_trinkey_m0/mpconfigboard.h +++ b/ports/atmel-samd/boards/adafruit_neokey_trinkey_m0/mpconfigboard.h @@ -3,10 +3,6 @@ #define MICROPY_HW_NEOPIXEL (&pin_PA15) -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define IGNORE_PIN_PA00 1 #define IGNORE_PIN_PA01 1 #define IGNORE_PIN_PA02 1 diff --git a/ports/atmel-samd/boards/adafruit_proxlight_trinkey_m0/mpconfigboard.h b/ports/atmel-samd/boards/adafruit_proxlight_trinkey_m0/mpconfigboard.h index a760fbe376..c792b01272 100644 --- a/ports/atmel-samd/boards/adafruit_proxlight_trinkey_m0/mpconfigboard.h +++ b/ports/atmel-samd/boards/adafruit_proxlight_trinkey_m0/mpconfigboard.h @@ -3,10 +3,6 @@ #define MICROPY_HW_NEOPIXEL (&pin_PA15) -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define IGNORE_PIN_PA01 1 #define IGNORE_PIN_PA02 1 #define IGNORE_PIN_PA04 1 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 1f927d9a62..7f31955f6d 100644 --- a/ports/atmel-samd/boards/adafruit_rotary_trinkey_m0/mpconfigboard.h +++ b/ports/atmel-samd/boards/adafruit_rotary_trinkey_m0/mpconfigboard.h @@ -3,10 +3,6 @@ #define MICROPY_HW_NEOPIXEL (&pin_PA01) -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define IGNORE_PIN_PA02 1 #define IGNORE_PIN_PA03 1 #define IGNORE_PIN_PA05 1 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 759290cda7..da7caf9b44 100644 --- a/ports/atmel-samd/boards/adafruit_slide_trinkey_m0/mpconfigboard.h +++ b/ports/atmel-samd/boards/adafruit_slide_trinkey_m0/mpconfigboard.h @@ -3,10 +3,6 @@ #define MICROPY_HW_NEOPIXEL (&pin_PA04) -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define IGNORE_PIN_PA00 1 #define IGNORE_PIN_PA01 1 #define IGNORE_PIN_PA03 1 diff --git a/ports/atmel-samd/boards/aloriumtech_evo_m51/board.c b/ports/atmel-samd/boards/aloriumtech_evo_m51/board.c index c67701512f..69b7a2664a 100644 --- a/ports/atmel-samd/boards/aloriumtech_evo_m51/board.c +++ b/ports/atmel-samd/boards/aloriumtech_evo_m51/board.c @@ -32,6 +32,7 @@ #include "mpconfigboard.h" void board_init(void) { + never_reset_pin_number(PIN_PB20); REG_PORT_DIRSET1 = PORT_PB20; // PB20 as output REG_PORT_OUTCLR1 = PORT_PB20; // PB20 cleared PORT->Group[1].PINCFG[20].reg |= PORT_PINCFG_PMUXEN; // Mux enabled on PB20 diff --git a/ports/atmel-samd/boards/aloriumtech_evo_m51/mpconfigboard.h b/ports/atmel-samd/boards/aloriumtech_evo_m51/mpconfigboard.h index 3882c2b6db..72d3709c91 100644 --- a/ports/atmel-samd/boards/aloriumtech_evo_m51/mpconfigboard.h +++ b/ports/atmel-samd/boards/aloriumtech_evo_m51/mpconfigboard.h @@ -8,14 +8,6 @@ #define MICROPY_HW_LED_STATUS (&pin_PA23) #define MICROPY_HW_NEOPIXEL (&pin_PB03) -// These are pins not to reset. -// QSPI Data pins -#define MICROPY_PORT_A (PORT_PA08 | PORT_PA09 | PORT_PA10 | PORT_PA11) -// QSPI CS, QSPI SCK and NeoPixel pin -#define MICROPY_PORT_B (PORT_PB03 | PORT_PB10 | PORT_PB11 | PORT_PB20) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - // BC needed? // #define AUTORESET_DELAY_MS 500 diff --git a/ports/atmel-samd/boards/arduino_mkr1300/mpconfigboard.h b/ports/atmel-samd/boards/arduino_mkr1300/mpconfigboard.h index 226717c83b..f0748f35de 100644 --- a/ports/atmel-samd/boards/arduino_mkr1300/mpconfigboard.h +++ b/ports/atmel-samd/boards/arduino_mkr1300/mpconfigboard.h @@ -1,10 +1,6 @@ #define MICROPY_HW_BOARD_NAME "Arduino MKR1300" #define MICROPY_HW_MCU_NAME "samd21g18" -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define MICROPY_HW_LED_STATUS (&pin_PB23) #define DEFAULT_I2C_BUS_SCL (&pin_PA09) diff --git a/ports/atmel-samd/boards/arduino_mkrzero/mpconfigboard.h b/ports/atmel-samd/boards/arduino_mkrzero/mpconfigboard.h index 4871b1798b..6226ecf49a 100644 --- a/ports/atmel-samd/boards/arduino_mkrzero/mpconfigboard.h +++ b/ports/atmel-samd/boards/arduino_mkrzero/mpconfigboard.h @@ -1,10 +1,6 @@ #define MICROPY_HW_BOARD_NAME "Arduino MKR Zero" #define MICROPY_HW_MCU_NAME "samd21g18" -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PA09) #define DEFAULT_I2C_BUS_SDA (&pin_PA08) diff --git a/ports/atmel-samd/boards/arduino_nano_33_iot/mpconfigboard.h b/ports/atmel-samd/boards/arduino_nano_33_iot/mpconfigboard.h index 847e1a6792..62883ad4a5 100644 --- a/ports/atmel-samd/boards/arduino_nano_33_iot/mpconfigboard.h +++ b/ports/atmel-samd/boards/arduino_nano_33_iot/mpconfigboard.h @@ -3,10 +3,6 @@ #define MICROPY_HW_LED_STATUS (&pin_PA17) -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PB09) #define DEFAULT_I2C_BUS_SDA (&pin_PB08) diff --git a/ports/atmel-samd/boards/arduino_zero/mpconfigboard.h b/ports/atmel-samd/boards/arduino_zero/mpconfigboard.h index bf2a68c57a..3cddc38546 100644 --- a/ports/atmel-samd/boards/arduino_zero/mpconfigboard.h +++ b/ports/atmel-samd/boards/arduino_zero/mpconfigboard.h @@ -6,10 +6,6 @@ #define MICROPY_HW_LED_TX &pin_PA27 #define MICROPY_HW_LED_RX &pin_PB03 -#define MICROPY_PORT_A (PORT_PA27) -#define MICROPY_PORT_B (PORT_PB03) -#define MICROPY_PORT_C (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PA23) #define DEFAULT_I2C_BUS_SDA (&pin_PA22) diff --git a/ports/atmel-samd/boards/bast_pro_mini_m0/mpconfigboard.h b/ports/atmel-samd/boards/bast_pro_mini_m0/mpconfigboard.h index cbfb11d200..88c6c1a0fd 100644 --- a/ports/atmel-samd/boards/bast_pro_mini_m0/mpconfigboard.h +++ b/ports/atmel-samd/boards/bast_pro_mini_m0/mpconfigboard.h @@ -1,10 +1,6 @@ #define MICROPY_HW_BOARD_NAME "Electronic Cats Bast Pro Mini M0" #define MICROPY_HW_MCU_NAME "samd21e18" -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - // No microcontroller.nvm #define CIRCUITPY_INTERNAL_NVM_SIZE 0 diff --git a/ports/atmel-samd/boards/bdmicro_vina_d21/mpconfigboard.h b/ports/atmel-samd/boards/bdmicro_vina_d21/mpconfigboard.h index f2332bbe54..1c56e39a0f 100644 --- a/ports/atmel-samd/boards/bdmicro_vina_d21/mpconfigboard.h +++ b/ports/atmel-samd/boards/bdmicro_vina_d21/mpconfigboard.h @@ -1,11 +1,6 @@ #define MICROPY_HW_BOARD_NAME "BDMICRO VINA-D21" #define MICROPY_HW_MCU_NAME "samd21g18" -// These are pins not to reset. -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define SPI_FLASH_CS_PIN &pin_PA13 #define SPI_FLASH_MISO_PIN &pin_PB03 #define SPI_FLASH_MOSI_PIN &pin_PB22 diff --git a/ports/atmel-samd/boards/bdmicro_vina_d51/mpconfigboard.h b/ports/atmel-samd/boards/bdmicro_vina_d51/mpconfigboard.h index 24d78b8ed1..6b1c9113be 100644 --- a/ports/atmel-samd/boards/bdmicro_vina_d51/mpconfigboard.h +++ b/ports/atmel-samd/boards/bdmicro_vina_d51/mpconfigboard.h @@ -6,13 +6,6 @@ #define CIRCUITPY_MCU_FAMILY samd51 -// These are pins not to reset. -// Don't reset QSPI data pins -#define MICROPY_PORT_A (PORT_PA08 | PORT_PA09 | PORT_PA10 | PORT_PA11) -#define MICROPY_PORT_B (PORT_PB10 | PORT_PB11) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - #define BOARD_HAS_CRYSTAL 1 #define DEFAULT_I2C_BUS_SCL (&pin_PA12) diff --git a/ports/atmel-samd/boards/bdmicro_vina_d51_pcb7/mpconfigboard.h b/ports/atmel-samd/boards/bdmicro_vina_d51_pcb7/mpconfigboard.h index 8b015df05e..36d1125ba3 100644 --- a/ports/atmel-samd/boards/bdmicro_vina_d51_pcb7/mpconfigboard.h +++ b/ports/atmel-samd/boards/bdmicro_vina_d51_pcb7/mpconfigboard.h @@ -3,13 +3,6 @@ #define CIRCUITPY_MCU_FAMILY samd51 -// These are pins not to reset. -// Don't reset QSPI data pins -#define MICROPY_PORT_A (PORT_PA08 | PORT_PA09 | PORT_PA10 | PORT_PA11) -#define MICROPY_PORT_B (PORT_PB10 | PORT_PB11) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - #define BOARD_HAS_CRYSTAL 1 #define DEFAULT_I2C_BUS_SCL (&pin_PA16) diff --git a/ports/atmel-samd/boards/blm_badge/mpconfigboard.h b/ports/atmel-samd/boards/blm_badge/mpconfigboard.h index 7343455b80..cc35610f1a 100644 --- a/ports/atmel-samd/boards/blm_badge/mpconfigboard.h +++ b/ports/atmel-samd/boards/blm_badge/mpconfigboard.h @@ -3,10 +3,6 @@ #define MICROPY_HW_LED_STATUS (&pin_PA03) -#define MICROPY_PORT_A (PORT_PA24 | PORT_PA25) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PA01) #define DEFAULT_I2C_BUS_SDA (&pin_PA00) diff --git a/ports/atmel-samd/boards/capablerobot_usbhub/mpconfigboard.h b/ports/atmel-samd/boards/capablerobot_usbhub/mpconfigboard.h index d359687e13..6ed80fbdf7 100644 --- a/ports/atmel-samd/boards/capablerobot_usbhub/mpconfigboard.h +++ b/ports/atmel-samd/boards/capablerobot_usbhub/mpconfigboard.h @@ -5,14 +5,6 @@ #define MICROPY_HW_LED_STATUS (&pin_PA22) -// These are pins not to reset. -// QSPI Data pins -#define MICROPY_PORT_A (PORT_PA08 | PORT_PA09 | PORT_PA10 | PORT_PA11) -// QSPI CS, and QSPI SCK -#define MICROPY_PORT_B (PORT_PB10 | PORT_PB11) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PA23) #define DEFAULT_I2C_BUS_SDA (&pin_PA22) diff --git a/ports/atmel-samd/boards/catwan_usbstick/mpconfigboard.h b/ports/atmel-samd/boards/catwan_usbstick/mpconfigboard.h index b92c2a65e3..3418466fb9 100644 --- a/ports/atmel-samd/boards/catwan_usbstick/mpconfigboard.h +++ b/ports/atmel-samd/boards/catwan_usbstick/mpconfigboard.h @@ -3,10 +3,6 @@ #define MICROPY_HW_LED_RX &pin_PA14 -#define MICROPY_PORT_A (PORT_PA14) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define DEFAULT_SPI_BUS_SCK (&pin_PA19) #define DEFAULT_SPI_BUS_MOSI (&pin_PA18) #define DEFAULT_SPI_BUS_MISO (&pin_PA22) diff --git a/ports/atmel-samd/boards/circuitbrains_basic_m0/mpconfigboard.h b/ports/atmel-samd/boards/circuitbrains_basic_m0/mpconfigboard.h index 321436c6b7..384022f874 100755 --- a/ports/atmel-samd/boards/circuitbrains_basic_m0/mpconfigboard.h +++ b/ports/atmel-samd/boards/circuitbrains_basic_m0/mpconfigboard.h @@ -11,11 +11,6 @@ #define SPI_FLASH_SCK_PIN &pin_PA17 #define SPI_FLASH_CS_PIN &pin_PA19 -// These are pins not to reset. -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define SPI_FLASH_BAUDRATE (8000000) #define CALIBRATE_CRYSTALLESS 1 diff --git a/ports/atmel-samd/boards/circuitbrains_deluxe_m4/mpconfigboard.h b/ports/atmel-samd/boards/circuitbrains_deluxe_m4/mpconfigboard.h index 687e97a5a3..38c6d1e559 100755 --- a/ports/atmel-samd/boards/circuitbrains_deluxe_m4/mpconfigboard.h +++ b/ports/atmel-samd/boards/circuitbrains_deluxe_m4/mpconfigboard.h @@ -5,14 +5,6 @@ #define MICROPY_HW_LED_STATUS (&pin_PB13) -// These are pins not to reset. -// QSPI Data pins -#define MICROPY_PORT_A (PORT_PA08 | PORT_PA09 | PORT_PA10 | PORT_PA11) -// QSPI CS, QSPI SCK -#define MICROPY_PORT_B (PORT_PB10 | PORT_PB11) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - #define AUTORESET_DELAY_MS 500 #define BOARD_HAS_CRYSTAL 1 diff --git a/ports/atmel-samd/boards/circuitplayground_express/mpconfigboard.h b/ports/atmel-samd/boards/circuitplayground_express/mpconfigboard.h index a32133e353..105205f191 100644 --- a/ports/atmel-samd/boards/circuitplayground_express/mpconfigboard.h +++ b/ports/atmel-samd/boards/circuitplayground_express/mpconfigboard.h @@ -15,11 +15,6 @@ #define SPI_FLASH_SCK_PIN &pin_PA21 #define SPI_FLASH_CS_PIN &pin_PB22 -// These are pins not to reset. -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define SPEAKER_ENABLE_PIN (&pin_PA30) #define CALIBRATE_CRYSTALLESS 1 diff --git a/ports/atmel-samd/boards/circuitplayground_express_crickit/mpconfigboard.h b/ports/atmel-samd/boards/circuitplayground_express_crickit/mpconfigboard.h index bc40554217..852e9651b1 100644 --- a/ports/atmel-samd/boards/circuitplayground_express_crickit/mpconfigboard.h +++ b/ports/atmel-samd/boards/circuitplayground_express_crickit/mpconfigboard.h @@ -15,11 +15,6 @@ #define SPI_FLASH_SCK_PIN &pin_PA21 #define SPI_FLASH_CS_PIN &pin_PB22 -// These are pins not to reset. -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define SPEAKER_ENABLE_PIN (&pin_PA30) #define CALIBRATE_CRYSTALLESS 1 diff --git a/ports/atmel-samd/boards/circuitplayground_express_displayio/mpconfigboard.h b/ports/atmel-samd/boards/circuitplayground_express_displayio/mpconfigboard.h index 1586a32890..a0bb560752 100644 --- a/ports/atmel-samd/boards/circuitplayground_express_displayio/mpconfigboard.h +++ b/ports/atmel-samd/boards/circuitplayground_express_displayio/mpconfigboard.h @@ -15,11 +15,6 @@ #define SPI_FLASH_SCK_PIN &pin_PA21 #define SPI_FLASH_CS_PIN &pin_PB22 -// These are pins not to reset. -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define SPEAKER_ENABLE_PIN (&pin_PA30) #define CALIBRATE_CRYSTALLESS 1 diff --git a/ports/atmel-samd/boards/cp32-m4/mpconfigboard.h b/ports/atmel-samd/boards/cp32-m4/mpconfigboard.h index bdc44c79b1..13433707af 100644 --- a/ports/atmel-samd/boards/cp32-m4/mpconfigboard.h +++ b/ports/atmel-samd/boards/cp32-m4/mpconfigboard.h @@ -4,14 +4,8 @@ #define MICROPY_HW_APA102_MOSI (&pin_PA12) #define MICROPY_HW_APA102_SCK (&pin_PA13) - #define CIRCUITPY_MCU_FAMILY samd51 -#define MICROPY_PORT_A (PORT_PA08 | PORT_PA09 | PORT_PA10 | PORT_PA11 | PORT_PA12 | PORT_PA13) -#define MICROPY_PORT_B (PORT_PB10 | PORT_PB11) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PB09) #define DEFAULT_I2C_BUS_SDA (&pin_PB08) diff --git a/ports/atmel-samd/boards/cp_sapling_m0/mpconfigboard.h b/ports/atmel-samd/boards/cp_sapling_m0/mpconfigboard.h index b04a31c46f..ce9319d479 100644 --- a/ports/atmel-samd/boards/cp_sapling_m0/mpconfigboard.h +++ b/ports/atmel-samd/boards/cp_sapling_m0/mpconfigboard.h @@ -3,10 +3,6 @@ #define MICROPY_HW_NEOPIXEL (&pin_PA15) -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define IGNORE_PIN_PA02 1 #define IGNORE_PIN_PA03 1 #define IGNORE_PIN_PA04 1 diff --git a/ports/atmel-samd/boards/cp_sapling_m0_revb/mpconfigboard.h b/ports/atmel-samd/boards/cp_sapling_m0_revb/mpconfigboard.h index 2299f69998..5c0526d0d9 100644 --- a/ports/atmel-samd/boards/cp_sapling_m0_revb/mpconfigboard.h +++ b/ports/atmel-samd/boards/cp_sapling_m0_revb/mpconfigboard.h @@ -3,10 +3,6 @@ #define MICROPY_HW_NEOPIXEL (&pin_PA15) -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define IGNORE_PIN_PA04 1 #define IGNORE_PIN_PA05 1 #define IGNORE_PIN_PA06 1 diff --git a/ports/atmel-samd/boards/cp_sapling_m0_spiflash/mpconfigboard.h b/ports/atmel-samd/boards/cp_sapling_m0_spiflash/mpconfigboard.h index 528d989edd..ad97ae2262 100644 --- a/ports/atmel-samd/boards/cp_sapling_m0_spiflash/mpconfigboard.h +++ b/ports/atmel-samd/boards/cp_sapling_m0_spiflash/mpconfigboard.h @@ -3,10 +3,6 @@ #define MICROPY_HW_NEOPIXEL (&pin_PA15) -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define SPI_FLASH_MOSI_PIN &pin_PA18 #define SPI_FLASH_MISO_PIN &pin_PA17 #define SPI_FLASH_SCK_PIN &pin_PA19 diff --git a/ports/atmel-samd/boards/datalore_ip_m4/mpconfigboard.h b/ports/atmel-samd/boards/datalore_ip_m4/mpconfigboard.h index f560cfa493..e2bf02e8d2 100644 --- a/ports/atmel-samd/boards/datalore_ip_m4/mpconfigboard.h +++ b/ports/atmel-samd/boards/datalore_ip_m4/mpconfigboard.h @@ -12,14 +12,6 @@ #define MICROPY_HW_NEOPIXEL (&pin_PB22) -// These are pins not to reset. -// QSPI Data pins -#define MICROPY_PORT_A (PORT_PA08 | PORT_PA09 | PORT_PA10 | PORT_PA11) -// QSPI CS, QSPI SCK and NeoPixel pin -#define MICROPY_PORT_B (PORT_PB10 | PORT_PB11 | PORT_PB22) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - #define BOARD_HAS_CRYSTAL 1 #define DEFAULT_I2C_BUS_SCL (&pin_PB03) diff --git a/ports/atmel-samd/boards/datum_distance/mpconfigboard.h b/ports/atmel-samd/boards/datum_distance/mpconfigboard.h index 74706ba040..cd9be70fe3 100644 --- a/ports/atmel-samd/boards/datum_distance/mpconfigboard.h +++ b/ports/atmel-samd/boards/datum_distance/mpconfigboard.h @@ -6,10 +6,6 @@ #define MICROPY_HW_BOARD_NAME "J&J Studios datum-Distance" #define MICROPY_HW_MCU_NAME "samd21g18" -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PA23) #define DEFAULT_I2C_BUS_SDA (&pin_PA22) diff --git a/ports/atmel-samd/boards/datum_imu/mpconfigboard.h b/ports/atmel-samd/boards/datum_imu/mpconfigboard.h index 3cc218f9e0..07a71e2e15 100644 --- a/ports/atmel-samd/boards/datum_imu/mpconfigboard.h +++ b/ports/atmel-samd/boards/datum_imu/mpconfigboard.h @@ -6,10 +6,6 @@ #define MICROPY_HW_BOARD_NAME "J&J Studios datum-IMU" #define MICROPY_HW_MCU_NAME "samd21g18" -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PA23) #define DEFAULT_I2C_BUS_SDA (&pin_PA22) diff --git a/ports/atmel-samd/boards/datum_light/mpconfigboard.h b/ports/atmel-samd/boards/datum_light/mpconfigboard.h index 33e80d06d0..6e531b6c74 100644 --- a/ports/atmel-samd/boards/datum_light/mpconfigboard.h +++ b/ports/atmel-samd/boards/datum_light/mpconfigboard.h @@ -6,10 +6,6 @@ #define MICROPY_HW_BOARD_NAME "J&J Studios datum-Light" #define MICROPY_HW_MCU_NAME "samd21g18" -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PA23) #define DEFAULT_I2C_BUS_SDA (&pin_PA22) diff --git a/ports/atmel-samd/boards/datum_weather/mpconfigboard.h b/ports/atmel-samd/boards/datum_weather/mpconfigboard.h index 328a6860c4..5b06a14c8c 100644 --- a/ports/atmel-samd/boards/datum_weather/mpconfigboard.h +++ b/ports/atmel-samd/boards/datum_weather/mpconfigboard.h @@ -6,10 +6,6 @@ #define MICROPY_HW_BOARD_NAME "J&J Studios datum-Weather" #define MICROPY_HW_MCU_NAME "samd21g18" -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PA23) #define DEFAULT_I2C_BUS_SDA (&pin_PA22) diff --git a/ports/atmel-samd/boards/dynalora_usb/mpconfigboard.h b/ports/atmel-samd/boards/dynalora_usb/mpconfigboard.h index 12359ce8f6..ef039292f1 100644 --- a/ports/atmel-samd/boards/dynalora_usb/mpconfigboard.h +++ b/ports/atmel-samd/boards/dynalora_usb/mpconfigboard.h @@ -9,11 +9,6 @@ #define SPI_FLASH_SCK_PIN &pin_PA07 #define SPI_FLASH_CS_PIN &pin_PA06 -// These are pins not to reset. -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PA01) #define DEFAULT_I2C_BUS_SDA (&pin_PA00) diff --git a/ports/atmel-samd/boards/dynossat_edu_eps/mpconfigboard.h b/ports/atmel-samd/boards/dynossat_edu_eps/mpconfigboard.h index 02707a69d4..75b7b1fc8a 100644 --- a/ports/atmel-samd/boards/dynossat_edu_eps/mpconfigboard.h +++ b/ports/atmel-samd/boards/dynossat_edu_eps/mpconfigboard.h @@ -8,11 +8,6 @@ #define SPI_FLASH_SCK_PIN &pin_PA23 #define SPI_FLASH_CS_PIN &pin_PA20 -// These are pins not to reset. -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define BOARD_HAS_CRYSTAL 1 #define DEFAULT_I2C_BUS_SCL (&pin_PA09) diff --git a/ports/atmel-samd/boards/dynossat_edu_obc/mpconfigboard.h b/ports/atmel-samd/boards/dynossat_edu_obc/mpconfigboard.h index 102a8cfb64..f97569435d 100644 --- a/ports/atmel-samd/boards/dynossat_edu_obc/mpconfigboard.h +++ b/ports/atmel-samd/boards/dynossat_edu_obc/mpconfigboard.h @@ -8,12 +8,6 @@ #define SPI_FLASH_SCK_PIN &pin_PA17 #define SPI_FLASH_CS_PIN &pin_PA19 -// These are pins not to reset. -#define MICROPY_PORT_A (PORT_PA16 | PORT_PA17 | PORT_PA18 | PORT_PA19) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - #define BOARD_HAS_CRYSTAL 1 #define DEFAULT_I2C_BUS_SCL (&pin_PB13) diff --git a/ports/atmel-samd/boards/escornabot_makech/mpconfigboard.h b/ports/atmel-samd/boards/escornabot_makech/mpconfigboard.h index c4c8c4f3ca..bb99c412ae 100644 --- a/ports/atmel-samd/boards/escornabot_makech/mpconfigboard.h +++ b/ports/atmel-samd/boards/escornabot_makech/mpconfigboard.h @@ -3,11 +3,6 @@ #define MICROPY_HW_LED_STATUS (&pin_PA02) -// These are pins not to reset. -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define CALIBRATE_CRYSTALLESS 1 // Explanation of how a user got into safe mode. diff --git a/ports/atmel-samd/boards/feather_m0_adalogger/mpconfigboard.h b/ports/atmel-samd/boards/feather_m0_adalogger/mpconfigboard.h index 704c0552d3..9be08fcf34 100644 --- a/ports/atmel-samd/boards/feather_m0_adalogger/mpconfigboard.h +++ b/ports/atmel-samd/boards/feather_m0_adalogger/mpconfigboard.h @@ -4,10 +4,6 @@ #define MICROPY_HW_BOARD_NAME "Adafruit Feather M0 Adalogger" #define MICROPY_HW_MCU_NAME "samd21g18" -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define DEFAULT_I2C_BUS_SDA (&pin_PA22) #define DEFAULT_I2C_BUS_SCL (&pin_PA23) diff --git a/ports/atmel-samd/boards/feather_m0_basic/mpconfigboard.h b/ports/atmel-samd/boards/feather_m0_basic/mpconfigboard.h index 41a4bde212..e80dbafa08 100644 --- a/ports/atmel-samd/boards/feather_m0_basic/mpconfigboard.h +++ b/ports/atmel-samd/boards/feather_m0_basic/mpconfigboard.h @@ -4,10 +4,6 @@ #define MICROPY_HW_BOARD_NAME "Adafruit Feather M0 Basic" #define MICROPY_HW_MCU_NAME "samd21g18" -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PA23) #define DEFAULT_I2C_BUS_SDA (&pin_PA22) diff --git a/ports/atmel-samd/boards/feather_m0_express/mpconfigboard.h b/ports/atmel-samd/boards/feather_m0_express/mpconfigboard.h index feeb16bec8..7c6492728e 100644 --- a/ports/atmel-samd/boards/feather_m0_express/mpconfigboard.h +++ b/ports/atmel-samd/boards/feather_m0_express/mpconfigboard.h @@ -10,11 +10,6 @@ #define SPI_FLASH_SCK_PIN &pin_PA09 #define SPI_FLASH_CS_PIN &pin_PA13 -// These are pins not to reset. -#define MICROPY_PORT_A (PORT_PA06) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define BOARD_HAS_CRYSTAL 1 #define DEFAULT_I2C_BUS_SCL (&pin_PA23) diff --git a/ports/atmel-samd/boards/feather_m0_express_crickit/mpconfigboard.h b/ports/atmel-samd/boards/feather_m0_express_crickit/mpconfigboard.h index 112dd80fa6..fb8444639b 100644 --- a/ports/atmel-samd/boards/feather_m0_express_crickit/mpconfigboard.h +++ b/ports/atmel-samd/boards/feather_m0_express_crickit/mpconfigboard.h @@ -10,11 +10,6 @@ #define SPI_FLASH_SCK_PIN &pin_PA09 #define SPI_FLASH_CS_PIN &pin_PA13 -// These are pins not to reset. -#define MICROPY_PORT_A (PORT_PA06) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define BOARD_HAS_CRYSTAL 1 #define DEFAULT_I2C_BUS_SCL (&pin_PA23) diff --git a/ports/atmel-samd/boards/feather_m0_rfm69/mpconfigboard.h b/ports/atmel-samd/boards/feather_m0_rfm69/mpconfigboard.h index 2a319a4129..e2520ef4fc 100644 --- a/ports/atmel-samd/boards/feather_m0_rfm69/mpconfigboard.h +++ b/ports/atmel-samd/boards/feather_m0_rfm69/mpconfigboard.h @@ -4,10 +4,6 @@ #define MICROPY_HW_BOARD_NAME "Adafruit Feather M0 RFM69" #define MICROPY_HW_MCU_NAME "samd21g18" -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PA23) #define DEFAULT_I2C_BUS_SDA (&pin_PA22) diff --git a/ports/atmel-samd/boards/feather_m0_rfm9x/mpconfigboard.h b/ports/atmel-samd/boards/feather_m0_rfm9x/mpconfigboard.h index 850033dbe4..e338fe4d69 100644 --- a/ports/atmel-samd/boards/feather_m0_rfm9x/mpconfigboard.h +++ b/ports/atmel-samd/boards/feather_m0_rfm9x/mpconfigboard.h @@ -4,10 +4,6 @@ #define MICROPY_HW_BOARD_NAME "Adafruit Feather M0 RFM9x" #define MICROPY_HW_MCU_NAME "samd21g18" -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PA23) #define DEFAULT_I2C_BUS_SDA (&pin_PA22) diff --git a/ports/atmel-samd/boards/feather_m0_supersized/mpconfigboard.h b/ports/atmel-samd/boards/feather_m0_supersized/mpconfigboard.h index 9fa2ba9ce7..2bc6eb6115 100644 --- a/ports/atmel-samd/boards/feather_m0_supersized/mpconfigboard.h +++ b/ports/atmel-samd/boards/feather_m0_supersized/mpconfigboard.h @@ -12,11 +12,6 @@ #define SPI_FLASH_SCK_PIN &pin_PA09 #define SPI_FLASH_CS_PIN &pin_PA13 -// These are pins not to reset. -#define MICROPY_PORT_A (PORT_PA06) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PA23) #define DEFAULT_I2C_BUS_SDA (&pin_PA22) diff --git a/ports/atmel-samd/boards/feather_m4_can/mpconfigboard.h b/ports/atmel-samd/boards/feather_m4_can/mpconfigboard.h index 4cf4c57859..c7178f2c90 100644 --- a/ports/atmel-samd/boards/feather_m4_can/mpconfigboard.h +++ b/ports/atmel-samd/boards/feather_m4_can/mpconfigboard.h @@ -9,14 +9,6 @@ #define MICROPY_HW_NEOPIXEL (&pin_PB02) #define CIRCUITPY_STATUS_LED_POWER (&pin_PB03) -// These are pins not to reset. -// QSPI Data pins -#define MICROPY_PORT_A (PORT_PA08 | PORT_PA09 | PORT_PA10 | PORT_PA11) -// QSPI CS, QSPI SCK and NeoPixel pin -#define MICROPY_PORT_B (PORT_PB10 | PORT_PB11) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - #define EXTERNAL_FLASH_QSPI_DUAL #define BOARD_HAS_CRYSTAL 1 diff --git a/ports/atmel-samd/boards/feather_m4_express/mpconfigboard.h b/ports/atmel-samd/boards/feather_m4_express/mpconfigboard.h index ef4a556227..0744fc3f92 100644 --- a/ports/atmel-samd/boards/feather_m4_express/mpconfigboard.h +++ b/ports/atmel-samd/boards/feather_m4_express/mpconfigboard.h @@ -8,14 +8,6 @@ #define MICROPY_HW_LED_STATUS (&pin_PA23) #define MICROPY_HW_NEOPIXEL (&pin_PB03) -// These are pins not to reset. -// QSPI Data pins -#define MICROPY_PORT_A (PORT_PA08 | PORT_PA09 | PORT_PA10 | PORT_PA11) -// QSPI CS, QSPI SCK and NeoPixel pin -#define MICROPY_PORT_B (PORT_PB10 | PORT_PB11) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - #define BOARD_HAS_CRYSTAL 1 #define DEFAULT_I2C_BUS_SCL (&pin_PA13) diff --git a/ports/atmel-samd/boards/fluff_m0/mpconfigboard.h b/ports/atmel-samd/boards/fluff_m0/mpconfigboard.h index 0782c980df..a2b34b6eb1 100644 --- a/ports/atmel-samd/boards/fluff_m0/mpconfigboard.h +++ b/ports/atmel-samd/boards/fluff_m0/mpconfigboard.h @@ -1,10 +1,6 @@ #define MICROPY_HW_BOARD_NAME "Fluff M0" #define MICROPY_HW_MCU_NAME "samd21e18" -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PA23) #define DEFAULT_I2C_BUS_SDA (&pin_PA22) diff --git a/ports/atmel-samd/boards/gemma_m0/mpconfigboard.h b/ports/atmel-samd/boards/gemma_m0/mpconfigboard.h index b6d8f946bc..81a81d6f54 100644 --- a/ports/atmel-samd/boards/gemma_m0/mpconfigboard.h +++ b/ports/atmel-samd/boards/gemma_m0/mpconfigboard.h @@ -6,10 +6,6 @@ #define MICROPY_HW_APA102_MOSI (&pin_PA00) #define MICROPY_HW_APA102_SCK (&pin_PA01) -#define MICROPY_PORT_A (PORT_PA00 | PORT_PA01 | PORT_PA24 | PORT_PA25) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PA05) #define DEFAULT_I2C_BUS_SDA (&pin_PA04) diff --git a/ports/atmel-samd/boards/grandcentral_m4_express/mpconfigboard.h b/ports/atmel-samd/boards/grandcentral_m4_express/mpconfigboard.h index f2f3d7cc46..893ff80b18 100644 --- a/ports/atmel-samd/boards/grandcentral_m4_express/mpconfigboard.h +++ b/ports/atmel-samd/boards/grandcentral_m4_express/mpconfigboard.h @@ -12,15 +12,6 @@ #define MICROPY_HW_NEOPIXEL (&pin_PC24) -// These are pins not to reset. -// QSPI Data pins -#define MICROPY_PORT_A (PORT_PA08 | PORT_PA09 | PORT_PA10 | PORT_PA11) -// QSPI CS, and QSPI SCK -#define MICROPY_PORT_B (PORT_PB10 | PORT_PB11) -// NeoPixel pin, RX LED, TX LED -#define MICROPY_PORT_C (PORT_PC24 | PORT_PC30 | PORT_PC31) -#define MICROPY_PORT_D (0) - #define BOARD_HAS_CRYSTAL 1 #define DEFAULT_I2C_BUS_SCL (&pin_PB21) diff --git a/ports/atmel-samd/boards/hallowing_m0_express/board.c b/ports/atmel-samd/boards/hallowing_m0_express/board.c index a9c11f1bae..76551426e3 100644 --- a/ports/atmel-samd/boards/hallowing_m0_express/board.c +++ b/ports/atmel-samd/boards/hallowing_m0_express/board.c @@ -72,6 +72,7 @@ void board_init(void) { displayio_fourwire_obj_t *bus = &displays[0].fourwire_bus; bus->base.type = &displayio_fourwire_type; busio_spi_obj_t *spi = common_hal_board_create_spi(); + common_hal_busio_spi_never_reset(spi); common_hal_displayio_fourwire_construct(bus, spi, &pin_PA28, // Command or data diff --git a/ports/atmel-samd/boards/hallowing_m0_express/mpconfigboard.h b/ports/atmel-samd/boards/hallowing_m0_express/mpconfigboard.h index 28ce108119..9672199a4d 100644 --- a/ports/atmel-samd/boards/hallowing_m0_express/mpconfigboard.h +++ b/ports/atmel-samd/boards/hallowing_m0_express/mpconfigboard.h @@ -9,13 +9,6 @@ #define SPI_FLASH_SCK_PIN &pin_PB11 #define SPI_FLASH_CS_PIN &pin_PA07 -// These are pins not to reset. -// NeoPixel and for the display: Reset, Command or data, and Chip select -#define MICROPY_PORT_A (PORT_PA01 | PORT_PA12 | PORT_PA27 | PORT_PA28) -// Data and Clock for the display -#define MICROPY_PORT_B (PORT_PB22 | PORT_PB23) -#define MICROPY_PORT_C (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PA17) #define DEFAULT_I2C_BUS_SDA (&pin_PA16) diff --git a/ports/atmel-samd/boards/hallowing_m4_express/mpconfigboard.h b/ports/atmel-samd/boards/hallowing_m4_express/mpconfigboard.h index 38f78da4d3..c85c8f40d0 100644 --- a/ports/atmel-samd/boards/hallowing_m4_express/mpconfigboard.h +++ b/ports/atmel-samd/boards/hallowing_m4_express/mpconfigboard.h @@ -8,14 +8,6 @@ #define MICROPY_HW_LED_STATUS (&pin_PA23) #define MICROPY_HW_NEOPIXEL (&pin_PB16) -// These are pins not to reset. -// QSPI Data pins -#define MICROPY_PORT_A (PORT_PA08 | PORT_PA09 | PORT_PA10 | PORT_PA11) -// NeoPixel pin, QSPI CS, and QSPI SCK -#define MICROPY_PORT_B (PORT_PB16 | PORT_PB10 | PORT_PB11) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PA13) #define DEFAULT_I2C_BUS_SDA (&pin_PA12) diff --git a/ports/atmel-samd/boards/huntercat_nfc/mpconfigboard.h b/ports/atmel-samd/boards/huntercat_nfc/mpconfigboard.h index 3be98beb38..61248c5496 100644 --- a/ports/atmel-samd/boards/huntercat_nfc/mpconfigboard.h +++ b/ports/atmel-samd/boards/huntercat_nfc/mpconfigboard.h @@ -8,10 +8,6 @@ #define SPI_FLASH_SCK_PIN &pin_PA19 #define SPI_FLASH_CS_PIN &pin_PA17 -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define CALIBRATE_CRYSTALLESS 1 #define DEFAULT_I2C_BUS_SCL (&pin_PA08) diff --git a/ports/atmel-samd/boards/itsybitsy_m0_express/mpconfigboard.h b/ports/atmel-samd/boards/itsybitsy_m0_express/mpconfigboard.h index db5e2a4df2..d57479e164 100644 --- a/ports/atmel-samd/boards/itsybitsy_m0_express/mpconfigboard.h +++ b/ports/atmel-samd/boards/itsybitsy_m0_express/mpconfigboard.h @@ -11,11 +11,6 @@ #define SPI_FLASH_SCK_PIN &pin_PB23 #define SPI_FLASH_CS_PIN &pin_PA27 -// These are pins not to reset. -#define MICROPY_PORT_A (PORT_PA00 | PORT_PA01) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PA23) #define DEFAULT_I2C_BUS_SDA (&pin_PA22) diff --git a/ports/atmel-samd/boards/itsybitsy_m4_express/mpconfigboard.h b/ports/atmel-samd/boards/itsybitsy_m4_express/mpconfigboard.h index 7926967635..c893d614d2 100644 --- a/ports/atmel-samd/boards/itsybitsy_m4_express/mpconfigboard.h +++ b/ports/atmel-samd/boards/itsybitsy_m4_express/mpconfigboard.h @@ -9,14 +9,6 @@ #define MICROPY_HW_APA102_MOSI (&pin_PB03) #define MICROPY_HW_APA102_SCK (&pin_PB02) -// These are pins not to reset. -// QSPI Data pins -#define MICROPY_PORT_A (PORT_PA08 | PORT_PA09 | PORT_PA10 | PORT_PA11) -// DotStar SCK, DotStar MOSI, QSPI SCK, and QSPI CS -#define MICROPY_PORT_B (PORT_PB02 | PORT_PB03 | PORT_PB10 | PORT_PB11) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PA13) #define DEFAULT_I2C_BUS_SDA (&pin_PA12) diff --git a/ports/atmel-samd/boards/kicksat-sprite/mpconfigboard.h b/ports/atmel-samd/boards/kicksat-sprite/mpconfigboard.h index 0ac595edf7..7b73e4d6cf 100644 --- a/ports/atmel-samd/boards/kicksat-sprite/mpconfigboard.h +++ b/ports/atmel-samd/boards/kicksat-sprite/mpconfigboard.h @@ -5,11 +5,6 @@ #define MICROPY_HW_LED_STATUS (&pin_PB03) -#define MICROPY_PORT_A (PORT_PA24 | PORT_PA25) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - #define CIRCUITPY_INTERNAL_NVM_SIZE 0 #define DEFAULT_I2C_BUS_SCL (&pin_PA17) diff --git a/ports/atmel-samd/boards/loc_ber_m4_base_board/mpconfigboard.h b/ports/atmel-samd/boards/loc_ber_m4_base_board/mpconfigboard.h index cbc7b25c16..a15b19aa64 100644 --- a/ports/atmel-samd/boards/loc_ber_m4_base_board/mpconfigboard.h +++ b/ports/atmel-samd/boards/loc_ber_m4_base_board/mpconfigboard.h @@ -9,14 +9,6 @@ #define MICROPY_HW_APA102_MOSI (&pin_PB03) #define MICROPY_HW_APA102_SCK (&pin_PB02) -// These are pins not to reset. -// QSPI Data pins -#define MICROPY_PORT_A (PORT_PA08 | PORT_PA09 | PORT_PA10 | PORT_PA11) -// DotStar pins, QSPI CS, and QSPI SCK -#define MICROPY_PORT_B (PORT_PB02 | PORT_PB03 | PORT_PB10 | PORT_PB11) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PA13) #define DEFAULT_I2C_BUS_SDA (&pin_PA12) diff --git a/ports/atmel-samd/boards/matrixportal_m4/mpconfigboard.h b/ports/atmel-samd/boards/matrixportal_m4/mpconfigboard.h index 475752afb3..912b986dd0 100644 --- a/ports/atmel-samd/boards/matrixportal_m4/mpconfigboard.h +++ b/ports/atmel-samd/boards/matrixportal_m4/mpconfigboard.h @@ -7,14 +7,6 @@ #define MICROPY_HW_NEOPIXEL (&pin_PA23) -// These are pins not to reset. -// QSPI Data pins, PA23 is NeoPixel -#define MICROPY_PORT_A (PORT_PA08 | PORT_PA09 | PORT_PA10 | PORT_PA11 | PORT_PA23) -// QSPI CS, QSPI SCK -#define MICROPY_PORT_B (PORT_PB10 | PORT_PB11) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PB30) #define DEFAULT_I2C_BUS_SDA (&pin_PB31) diff --git a/ports/atmel-samd/boards/meowmeow/mpconfigboard.h b/ports/atmel-samd/boards/meowmeow/mpconfigboard.h index 7bbbf33223..73853dab5d 100644 --- a/ports/atmel-samd/boards/meowmeow/mpconfigboard.h +++ b/ports/atmel-samd/boards/meowmeow/mpconfigboard.h @@ -3,11 +3,6 @@ #define MICROPY_HW_LED_STATUS (&pin_PB23) -// These are pins not to reset. -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define CALIBRATE_CRYSTALLESS 1 // Explanation of how a user got into safe mode. diff --git a/ports/atmel-samd/boards/metro_m0_express/mpconfigboard.h b/ports/atmel-samd/boards/metro_m0_express/mpconfigboard.h index d48c596ace..315cdf1e9a 100644 --- a/ports/atmel-samd/boards/metro_m0_express/mpconfigboard.h +++ b/ports/atmel-samd/boards/metro_m0_express/mpconfigboard.h @@ -16,11 +16,6 @@ #define SPI_FLASH_SCK_PIN &pin_PB23 #define SPI_FLASH_CS_PIN &pin_PA13 -// These are pins not to reset. -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define BOARD_HAS_CRYSTAL 1 #define DEFAULT_I2C_BUS_SCL (&pin_PA23) diff --git a/ports/atmel-samd/boards/metro_m4_airlift_lite/mpconfigboard.h b/ports/atmel-samd/boards/metro_m4_airlift_lite/mpconfigboard.h index 9fa4018046..803fd30526 100644 --- a/ports/atmel-samd/boards/metro_m4_airlift_lite/mpconfigboard.h +++ b/ports/atmel-samd/boards/metro_m4_airlift_lite/mpconfigboard.h @@ -10,14 +10,6 @@ #define MICROPY_HW_NEOPIXEL (&pin_PB22) -// These are pins not to reset. -// QSPI Data pins -#define MICROPY_PORT_A (PORT_PA08 | PORT_PA09 | PORT_PA10 | PORT_PA11) -// QSPI CS, QSPI SCK and NeoPixel pin -#define MICROPY_PORT_B (PORT_PB10 | PORT_PB11 | PORT_PB22) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - #define BOARD_HAS_CRYSTAL 1 #define DEFAULT_I2C_BUS_SCL (&pin_PB03) diff --git a/ports/atmel-samd/boards/metro_m4_express/mpconfigboard.h b/ports/atmel-samd/boards/metro_m4_express/mpconfigboard.h index 7f8dbb1d2b..3b9ca96669 100644 --- a/ports/atmel-samd/boards/metro_m4_express/mpconfigboard.h +++ b/ports/atmel-samd/boards/metro_m4_express/mpconfigboard.h @@ -12,14 +12,6 @@ #define MICROPY_HW_NEOPIXEL (&pin_PB22) -// These are pins not to reset. -// QSPI Data pins -#define MICROPY_PORT_A (PORT_PA08 | PORT_PA09 | PORT_PA10 | PORT_PA11) -// QSPI CS, QSPI SCK and NeoPixel pin -#define MICROPY_PORT_B (PORT_PB10 | PORT_PB11 | PORT_PB22) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - #define BOARD_HAS_CRYSTAL 1 #define DEFAULT_I2C_BUS_SCL (&pin_PB03) diff --git a/ports/atmel-samd/boards/mini_sam_m4/mpconfigboard.h b/ports/atmel-samd/boards/mini_sam_m4/mpconfigboard.h index 08ab7e16b9..ac54a36802 100644 --- a/ports/atmel-samd/boards/mini_sam_m4/mpconfigboard.h +++ b/ports/atmel-samd/boards/mini_sam_m4/mpconfigboard.h @@ -9,14 +9,6 @@ #define MICROPY_HW_APA102_MOSI (&pin_PB03) #define MICROPY_HW_APA102_SCK (&pin_PB02) -// These are pins not to reset. -// QSPI Data pins -#define MICROPY_PORT_A (PORT_PA08 | PORT_PA09 | PORT_PA10 | PORT_PA11) -// RGB Status LED pins, QSPI CS, and QSPI SCK -#define MICROPY_PORT_B (PORT_PB02 | PORT_PB03 | PORT_PB10 | PORT_PB11) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PA13) #define DEFAULT_I2C_BUS_SDA (&pin_PA12) diff --git a/ports/atmel-samd/boards/monster_m4sk/mpconfigboard.h b/ports/atmel-samd/boards/monster_m4sk/mpconfigboard.h index ed8f15856c..26100960d8 100644 --- a/ports/atmel-samd/boards/monster_m4sk/mpconfigboard.h +++ b/ports/atmel-samd/boards/monster_m4sk/mpconfigboard.h @@ -5,14 +5,6 @@ #define MICROPY_HW_LED_STATUS (&pin_PA27) -// These are pins not to reset. -// QSPI Data pins -#define MICROPY_PORT_A (PORT_PA08 | PORT_PA09 | PORT_PA10 | PORT_PA11) -// DotStar pins, QSPI CS, and QSPI SCK -#define MICROPY_PORT_B (PORT_PB10 | PORT_PB11) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PA01) #define DEFAULT_I2C_BUS_SDA (&pin_PA00) diff --git a/ports/atmel-samd/boards/ndgarage_ndbit6/mpconfigboard.h b/ports/atmel-samd/boards/ndgarage_ndbit6/mpconfigboard.h index 51be8d7c06..dee3565cb1 100644 --- a/ports/atmel-samd/boards/ndgarage_ndbit6/mpconfigboard.h +++ b/ports/atmel-samd/boards/ndgarage_ndbit6/mpconfigboard.h @@ -8,10 +8,6 @@ #define SPI_FLASH_SCK_PIN &pin_PA17 #define SPI_FLASH_CS_PIN &pin_PA15 -#define MICROPY_PORT_A (PORT_PA24 | PORT_PA25) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define CIRCUITPY_INTERNAL_NVM_SIZE 256 #define BOARD_FLASH_SIZE (0x00040000 - 0x2000 - 0x010000 CIRCUITPY_INTERNAL_NVM_SIZE) diff --git a/ports/atmel-samd/boards/ndgarage_ndbit6_v2/mpconfigboard.h b/ports/atmel-samd/boards/ndgarage_ndbit6_v2/mpconfigboard.h index 0dc7f5d196..7401b256c5 100644 --- a/ports/atmel-samd/boards/ndgarage_ndbit6_v2/mpconfigboard.h +++ b/ports/atmel-samd/boards/ndgarage_ndbit6_v2/mpconfigboard.h @@ -3,10 +3,6 @@ #define MICROPY_HW_LED_STATUS (&pin_PA23) -#define MICROPY_PORT_A (PORT_PA24 | PORT_PA25) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define CIRCUITPY_INTERNAL_NVM_SIZE 256 #define BOARD_FLASH_SIZE (0x00040000 - 0x2000 - 0x010000 CIRCUITPY_INTERNAL_NVM_SIZE) diff --git a/ports/atmel-samd/boards/neopixel_trinkey_m0/mpconfigboard.h b/ports/atmel-samd/boards/neopixel_trinkey_m0/mpconfigboard.h index ebf8b1e345..7a923ead11 100644 --- a/ports/atmel-samd/boards/neopixel_trinkey_m0/mpconfigboard.h +++ b/ports/atmel-samd/boards/neopixel_trinkey_m0/mpconfigboard.h @@ -3,10 +3,6 @@ #define MICROPY_HW_NEOPIXEL (&pin_PA05) -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define IGNORE_PIN_PA00 1 #define IGNORE_PIN_PA01 1 #define IGNORE_PIN_PA02 1 diff --git a/ports/atmel-samd/boards/nfc_copy_cat/mpconfigboard.h b/ports/atmel-samd/boards/nfc_copy_cat/mpconfigboard.h index 3790d23ff6..697cab8a12 100644 --- a/ports/atmel-samd/boards/nfc_copy_cat/mpconfigboard.h +++ b/ports/atmel-samd/boards/nfc_copy_cat/mpconfigboard.h @@ -3,10 +3,6 @@ #define MICROPY_HW_LED_STATUS (&pin_PA14) -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define SPI_FLASH_MOSI_PIN &pin_PA08 #define SPI_FLASH_MISO_PIN &pin_PA11 #define SPI_FLASH_SCK_PIN &pin_PA09 diff --git a/ports/atmel-samd/boards/openbook_m4/mpconfigboard.h b/ports/atmel-samd/boards/openbook_m4/mpconfigboard.h index 6d75c086e9..21463a5851 100644 --- a/ports/atmel-samd/boards/openbook_m4/mpconfigboard.h +++ b/ports/atmel-samd/boards/openbook_m4/mpconfigboard.h @@ -5,14 +5,6 @@ #define MICROPY_HW_LED_STATUS (&pin_PA23) -// These are pins not to reset. -// QSPI Data pins -#define MICROPY_PORT_A (PORT_PA08 | PORT_PA09 | PORT_PA10 | PORT_PA11) -// DotStar pins, QSPI CS, and QSPI SCK -#define MICROPY_PORT_B (PORT_PB10 | PORT_PB11) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PA13) #define DEFAULT_I2C_BUS_SDA (&pin_PA12) diff --git a/ports/atmel-samd/boards/pewpew10/mpconfigboard.h b/ports/atmel-samd/boards/pewpew10/mpconfigboard.h index 2cb097e8dc..661c578f1e 100644 --- a/ports/atmel-samd/boards/pewpew10/mpconfigboard.h +++ b/ports/atmel-samd/boards/pewpew10/mpconfigboard.h @@ -1,10 +1,6 @@ #define MICROPY_HW_BOARD_NAME "PewPew 10.2" #define MICROPY_HW_MCU_NAME "samd21e18" -#define MICROPY_PORT_A (PORT_PA24 | PORT_PA25) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define IGNORE_PIN_PB00 1 #define IGNORE_PIN_PB01 1 #define IGNORE_PIN_PB02 1 diff --git a/ports/atmel-samd/boards/pewpew_m4/mpconfigboard.h b/ports/atmel-samd/boards/pewpew_m4/mpconfigboard.h index 4b88c89f28..3360db6021 100644 --- a/ports/atmel-samd/boards/pewpew_m4/mpconfigboard.h +++ b/ports/atmel-samd/boards/pewpew_m4/mpconfigboard.h @@ -3,12 +3,6 @@ #define CIRCUITPY_MCU_FAMILY samd51 -// These are pins not to reset. -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PA01) #define DEFAULT_I2C_BUS_SDA (&pin_PA00) diff --git a/ports/atmel-samd/boards/picoplanet/mpconfigboard.h b/ports/atmel-samd/boards/picoplanet/mpconfigboard.h index 153150d1e1..1f0636eb9a 100644 --- a/ports/atmel-samd/boards/picoplanet/mpconfigboard.h +++ b/ports/atmel-samd/boards/picoplanet/mpconfigboard.h @@ -1,10 +1,6 @@ #define MICROPY_HW_BOARD_NAME "PicoPlanet" #define MICROPY_HW_MCU_NAME "samd21e18" -#define MICROPY_PORT_A (PORT_PA00 | PORT_PA01) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define IGNORE_PIN_PA00 1 #define IGNORE_PIN_PA01 1 #define IGNORE_PIN_PA10 1 diff --git a/ports/atmel-samd/boards/pybadge/mpconfigboard.h b/ports/atmel-samd/boards/pybadge/mpconfigboard.h index 435185322a..468ee2b3e0 100644 --- a/ports/atmel-samd/boards/pybadge/mpconfigboard.h +++ b/ports/atmel-samd/boards/pybadge/mpconfigboard.h @@ -6,14 +6,6 @@ // This is for Rev B #define MICROPY_HW_LED_STATUS (&pin_PA23) -// These are pins not to reset. -// QSPI Data pins -#define MICROPY_PORT_A (PORT_PA08 | PORT_PA09 | PORT_PA10 | PORT_PA11) -// DotStar pins, QSPI CS, and QSPI SCK -#define MICROPY_PORT_B (PORT_PB10 | PORT_PB11) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PA13) #define DEFAULT_I2C_BUS_SDA (&pin_PA12) diff --git a/ports/atmel-samd/boards/pycubed/mpconfigboard.h b/ports/atmel-samd/boards/pycubed/mpconfigboard.h index 244f41da38..3df0afd6b5 100644 --- a/ports/atmel-samd/boards/pycubed/mpconfigboard.h +++ b/ports/atmel-samd/boards/pycubed/mpconfigboard.h @@ -6,11 +6,6 @@ #define MICROPY_HW_LED_STATUS (&pin_PA16) #define MICROPY_HW_NEOPIXEL (&pin_PA21) -#define MICROPY_PORT_A (PORT_PA08 | PORT_PA09 | PORT_PA10 | PORT_PA11) -#define MICROPY_PORT_B (PORT_PB10 | PORT_PB11) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - #define AUTORESET_DELAY_MS 500 #define CIRCUITPY_INTERNAL_NVM_SIZE 8192 diff --git a/ports/atmel-samd/boards/pycubed_mram/mpconfigboard.h b/ports/atmel-samd/boards/pycubed_mram/mpconfigboard.h index 0d49e1b00f..f7dfbae3a2 100644 --- a/ports/atmel-samd/boards/pycubed_mram/mpconfigboard.h +++ b/ports/atmel-samd/boards/pycubed_mram/mpconfigboard.h @@ -5,14 +5,6 @@ #define MICROPY_HW_LED_STATUS (&pin_PA16) #define MICROPY_HW_NEOPIXEL (&pin_PA21) -#define MICROPY_PORT_A (PORT_PA08 | PORT_PA09 | PORT_PA10 | PORT_PA11) -#define MICROPY_PORT_B (PORT_PA21 | PORT_PB10 | PORT_PB11) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - -#define SPI_FLASH_WP_PIN &pin_PA10 -#define SPI_FLASH_HOLD_PIN &pin_PA11 - // External flash MR2xH40 MRAM #define EXTERNAL_FLASH_QSPI_SINGLE #define EXTERNAL_FLASH_NO_JEDEC diff --git a/ports/atmel-samd/boards/pygamer/mpconfigboard.h b/ports/atmel-samd/boards/pygamer/mpconfigboard.h index 102c259567..bfe41988e4 100644 --- a/ports/atmel-samd/boards/pygamer/mpconfigboard.h +++ b/ports/atmel-samd/boards/pygamer/mpconfigboard.h @@ -5,14 +5,6 @@ #define MICROPY_HW_LED_STATUS (&pin_PA23) -// These are pins not to reset. -// QSPI Data pins -#define MICROPY_PORT_A (PORT_PA08 | PORT_PA09 | PORT_PA10 | PORT_PA11) -// DotStar pins, QSPI CS, and QSPI SCK -#define MICROPY_PORT_B (PORT_PB10 | PORT_PB11) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PA13) #define DEFAULT_I2C_BUS_SDA (&pin_PA12) diff --git a/ports/atmel-samd/boards/pyportal/mpconfigboard.h b/ports/atmel-samd/boards/pyportal/mpconfigboard.h index 351647b122..6cd9290af0 100644 --- a/ports/atmel-samd/boards/pyportal/mpconfigboard.h +++ b/ports/atmel-samd/boards/pyportal/mpconfigboard.h @@ -9,14 +9,6 @@ #define MICROPY_HW_NEOPIXEL (&pin_PB22) -// These are pins not to reset. -// QSPI Data pins -#define MICROPY_PORT_A (PORT_PA08 | PORT_PA09 | PORT_PA10 | PORT_PA11) -// QSPI CS, and QSPI SCK -#define MICROPY_PORT_B (PORT_PB10 | PORT_PB11 | PORT_PB22) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PB03) #define DEFAULT_I2C_BUS_SDA (&pin_PB02) diff --git a/ports/atmel-samd/boards/pyportal_titano/mpconfigboard.h b/ports/atmel-samd/boards/pyportal_titano/mpconfigboard.h index 61c6117d96..5b7408d6ec 100644 --- a/ports/atmel-samd/boards/pyportal_titano/mpconfigboard.h +++ b/ports/atmel-samd/boards/pyportal_titano/mpconfigboard.h @@ -7,14 +7,6 @@ #define MICROPY_HW_NEOPIXEL (&pin_PB22) -// These are pins not to reset. -// QSPI Data pins -#define MICROPY_PORT_A (PORT_PA08 | PORT_PA09 | PORT_PA10 | PORT_PA11) -// QSPI CS, and QSPI SCK -#define MICROPY_PORT_B (PORT_PB10 | PORT_PB11 | PORT_PB22) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PB03) #define DEFAULT_I2C_BUS_SDA (&pin_PB02) diff --git a/ports/atmel-samd/boards/pyruler/mpconfigboard.h b/ports/atmel-samd/boards/pyruler/mpconfigboard.h index 4d0586d912..d7c26364f8 100644 --- a/ports/atmel-samd/boards/pyruler/mpconfigboard.h +++ b/ports/atmel-samd/boards/pyruler/mpconfigboard.h @@ -6,10 +6,6 @@ #define MICROPY_HW_APA102_MOSI (&pin_PA00) #define MICROPY_HW_APA102_SCK (&pin_PA01) -#define MICROPY_PORT_A (PORT_PA00 | PORT_PA01) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define IGNORE_PIN_PA12 1 #define IGNORE_PIN_PA13 1 #define IGNORE_PIN_PA16 1 diff --git a/ports/atmel-samd/boards/qtpy_m0/mpconfigboard.h b/ports/atmel-samd/boards/qtpy_m0/mpconfigboard.h index 305a9b55f6..d03ce51d15 100644 --- a/ports/atmel-samd/boards/qtpy_m0/mpconfigboard.h +++ b/ports/atmel-samd/boards/qtpy_m0/mpconfigboard.h @@ -4,10 +4,6 @@ #define MICROPY_HW_NEOPIXEL (&pin_PA18) #define CIRCUITPY_STATUS_LED_POWER (&pin_PA15) -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define IGNORE_PIN_PA00 1 #define IGNORE_PIN_PA01 1 #define IGNORE_PIN_PA12 1 diff --git a/ports/atmel-samd/boards/qtpy_m0_haxpress/mpconfigboard.h b/ports/atmel-samd/boards/qtpy_m0_haxpress/mpconfigboard.h index c3434e22f0..569fe1264a 100644 --- a/ports/atmel-samd/boards/qtpy_m0_haxpress/mpconfigboard.h +++ b/ports/atmel-samd/boards/qtpy_m0_haxpress/mpconfigboard.h @@ -4,10 +4,6 @@ #define MICROPY_HW_NEOPIXEL (&pin_PA18) #define CIRCUITPY_STATUS_LED_POWER (&pin_PA15) -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define SPI_FLASH_MOSI_PIN &pin_PA22 #define SPI_FLASH_MISO_PIN &pin_PA19 #define SPI_FLASH_SCK_PIN &pin_PA23 diff --git a/ports/atmel-samd/boards/robohatmm1_m4/mpconfigboard.h b/ports/atmel-samd/boards/robohatmm1_m4/mpconfigboard.h index 4e482cff5a..90fbcd9b04 100644 --- a/ports/atmel-samd/boards/robohatmm1_m4/mpconfigboard.h +++ b/ports/atmel-samd/boards/robohatmm1_m4/mpconfigboard.h @@ -14,13 +14,6 @@ #define SPI_FLASH_SCK_PIN &pin_PA13 #define SPI_FLASH_CS_PIN &pin_PA15 -// These are pins not to reset. -// SPI Data pins -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PA23) #define DEFAULT_I2C_BUS_SDA (&pin_PA22) diff --git a/ports/atmel-samd/boards/sam32/mpconfigboard.h b/ports/atmel-samd/boards/sam32/mpconfigboard.h index 19f326782a..6c4cdec768 100644 --- a/ports/atmel-samd/boards/sam32/mpconfigboard.h +++ b/ports/atmel-samd/boards/sam32/mpconfigboard.h @@ -5,11 +5,6 @@ #define MICROPY_HW_LED_STATUS (&pin_PA27) #define MICROPY_HW_NEOPIXEL (&pin_PA15) -#define MICROPY_PORT_A (PORT_PA24 | PORT_PA25) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - #define CIRCUITPY_INTERNAL_NVM_SIZE 0 #define CIRCUITPY_INTERNAL_FLASH_FILESYSTEM_SIZE (128 * 1024) diff --git a/ports/atmel-samd/boards/same54_xplained/mpconfigboard.h b/ports/atmel-samd/boards/same54_xplained/mpconfigboard.h index dbdd1aaa6a..766821f72e 100644 --- a/ports/atmel-samd/boards/same54_xplained/mpconfigboard.h +++ b/ports/atmel-samd/boards/same54_xplained/mpconfigboard.h @@ -7,14 +7,6 @@ #define MICROPY_HW_LED_STATUS (&pin_PC18) -// These are pins not to reset. -// QSPI Data pins -#define MICROPY_PORT_A (PORT_PA08 | PORT_PA09 | PORT_PA10 | PORT_PA11) -// QSPI CS, and QSPI SCK -#define MICROPY_PORT_B (PORT_PB10 | PORT_PB11) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - #define BOARD_HAS_CRYSTAL 1 #define DEFAULT_I2C_BUS_SCL (&pin_PD09) diff --git a/ports/atmel-samd/boards/seeeduino_wio_terminal/mpconfigboard.h b/ports/atmel-samd/boards/seeeduino_wio_terminal/mpconfigboard.h index 94538ed851..9743b018d1 100644 --- a/ports/atmel-samd/boards/seeeduino_wio_terminal/mpconfigboard.h +++ b/ports/atmel-samd/boards/seeeduino_wio_terminal/mpconfigboard.h @@ -5,14 +5,6 @@ #define MICROPY_HW_LED_STATUS (&pin_PA15) -// These are pins not to reset. -// QSPI Data pins -#define MICROPY_PORT_A (PORT_PA08 | PORT_PA09 | PORT_PA10 | PORT_PA11) -// QSPI CS, QSPI SCK and NeoPixel pin -#define MICROPY_PORT_B (PORT_PB03 | PORT_PB10 | PORT_PB11) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - #define EXTERNAL_FLASH_QSPI_DUAL #define BOARD_HAS_CRYSTAL 1 diff --git a/ports/atmel-samd/boards/seeeduino_xiao/mpconfigboard.h b/ports/atmel-samd/boards/seeeduino_xiao/mpconfigboard.h index 4bd10ca412..7eca910a37 100644 --- a/ports/atmel-samd/boards/seeeduino_xiao/mpconfigboard.h +++ b/ports/atmel-samd/boards/seeeduino_xiao/mpconfigboard.h @@ -1,10 +1,6 @@ #define MICROPY_HW_BOARD_NAME "Seeeduino XIAO" #define MICROPY_HW_MCU_NAME "samd21g18" -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PA09) // was PA23 #define DEFAULT_I2C_BUS_SDA (&pin_PA08) // was PA22 diff --git a/ports/atmel-samd/boards/sensebox_mcu/mpconfigboard.h b/ports/atmel-samd/boards/sensebox_mcu/mpconfigboard.h index 13aca289f6..9e3fa10df8 100644 --- a/ports/atmel-samd/boards/sensebox_mcu/mpconfigboard.h +++ b/ports/atmel-samd/boards/sensebox_mcu/mpconfigboard.h @@ -3,10 +3,6 @@ #define MICROPY_HW_LED_STATUS (&pin_PA27) -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PA09) #define DEFAULT_I2C_BUS_SDA (&pin_PA08) diff --git a/ports/atmel-samd/boards/serpente/mpconfigboard.h b/ports/atmel-samd/boards/serpente/mpconfigboard.h index 515bc14410..5ade0c50c1 100644 --- a/ports/atmel-samd/boards/serpente/mpconfigboard.h +++ b/ports/atmel-samd/boards/serpente/mpconfigboard.h @@ -8,11 +8,6 @@ #define SPI_FLASH_SCK_PIN &pin_PA17 #define SPI_FLASH_CS_PIN &pin_PA15 -// These are pins not to reset. -#define MICROPY_PORT_A (PORT_PA00 | PORT_PA01) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PA09) #define DEFAULT_I2C_BUS_SDA (&pin_PA08) diff --git a/ports/atmel-samd/boards/shirtty/mpconfigboard.h b/ports/atmel-samd/boards/shirtty/mpconfigboard.h index 796d23f869..184584112e 100644 --- a/ports/atmel-samd/boards/shirtty/mpconfigboard.h +++ b/ports/atmel-samd/boards/shirtty/mpconfigboard.h @@ -3,10 +3,6 @@ #define MICROPY_HW_LED_STATUS (&pin_PA16) -#define MICROPY_PORT_A (PORT_PA00 | PORT_PA01) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - // #define IGNORE_PIN_PA00 1 // #define IGNORE_PIN_PA01 1 // #define IGNORE_PIN_PA02 1 diff --git a/ports/atmel-samd/boards/silicognition-m4-shim/mpconfigboard.h b/ports/atmel-samd/boards/silicognition-m4-shim/mpconfigboard.h index 5028679edc..faf689b911 100644 --- a/ports/atmel-samd/boards/silicognition-m4-shim/mpconfigboard.h +++ b/ports/atmel-samd/boards/silicognition-m4-shim/mpconfigboard.h @@ -8,14 +8,6 @@ #define MICROPY_HW_LED_STATUS (&pin_PA23) #define MICROPY_HW_NEOPIXEL (&pin_PB03) -// These are pins not to reset. -// QSPI Data pins -#define MICROPY_PORT_A (PORT_PA08 | PORT_PA09 | PORT_PA10 | PORT_PA11) -// QSPI CS, QSPI SCK and NeoPixel pin -#define MICROPY_PORT_B (PORT_PB03 | PORT_PB10 | PORT_PB11) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - #define BOARD_HAS_CRYSTAL 1 #define DEFAULT_I2C_BUS_SCL (&pin_PA13) diff --git a/ports/atmel-samd/boards/snekboard/mpconfigboard.h b/ports/atmel-samd/boards/snekboard/mpconfigboard.h index 0c9f274c06..aa05b2f94b 100644 --- a/ports/atmel-samd/boards/snekboard/mpconfigboard.h +++ b/ports/atmel-samd/boards/snekboard/mpconfigboard.h @@ -10,11 +10,6 @@ #define SPI_FLASH_SCK_PIN &pin_PB23 #define SPI_FLASH_CS_PIN &pin_PA27 -// These are pins not to reset. -#define MICROPY_PORT_A (PORT_PB11) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define BOARD_HAS_CRYSTAL 0 #define DEFAULT_I2C_BUS_SCL (&pin_PA08) /* ANALOG 5 */ diff --git a/ports/atmel-samd/boards/sparkfun_lumidrive/mpconfigboard.h b/ports/atmel-samd/boards/sparkfun_lumidrive/mpconfigboard.h index 836261bf8d..8d442c6049 100644 --- a/ports/atmel-samd/boards/sparkfun_lumidrive/mpconfigboard.h +++ b/ports/atmel-samd/boards/sparkfun_lumidrive/mpconfigboard.h @@ -9,10 +9,6 @@ #define SPI_FLASH_SCK_PIN &pin_PA09 #define SPI_FLASH_CS_PIN &pin_PA13 -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define BOARD_HAS_CRYSTAL 1 // I2C diff --git a/ports/atmel-samd/boards/sparkfun_qwiic_micro_no_flash/mpconfigboard.h b/ports/atmel-samd/boards/sparkfun_qwiic_micro_no_flash/mpconfigboard.h index c2527301ff..530b53054c 100644 --- a/ports/atmel-samd/boards/sparkfun_qwiic_micro_no_flash/mpconfigboard.h +++ b/ports/atmel-samd/boards/sparkfun_qwiic_micro_no_flash/mpconfigboard.h @@ -1,10 +1,6 @@ #define MICROPY_HW_BOARD_NAME "SparkFun Qwiic Micro" #define MICROPY_HW_MCU_NAME "samd21e18" -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define CALIBRATE_CRYSTALLESS 1 #define BOARD_HAS_CRYSTAL 0 diff --git a/ports/atmel-samd/boards/sparkfun_qwiic_micro_with_flash/mpconfigboard.h b/ports/atmel-samd/boards/sparkfun_qwiic_micro_with_flash/mpconfigboard.h index 4fb43629b4..6afaade5f1 100644 --- a/ports/atmel-samd/boards/sparkfun_qwiic_micro_with_flash/mpconfigboard.h +++ b/ports/atmel-samd/boards/sparkfun_qwiic_micro_with_flash/mpconfigboard.h @@ -9,10 +9,6 @@ #define SPI_FLASH_SCK_PIN &pin_PA17 #define SPI_FLASH_CS_PIN &pin_PA19 -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define CALIBRATE_CRYSTALLESS 1 #define BOARD_HAS_CRYSTAL 0 diff --git a/ports/atmel-samd/boards/sparkfun_redboard_turbo/mpconfigboard.h b/ports/atmel-samd/boards/sparkfun_redboard_turbo/mpconfigboard.h index b4076523f4..6a3f860ccc 100644 --- a/ports/atmel-samd/boards/sparkfun_redboard_turbo/mpconfigboard.h +++ b/ports/atmel-samd/boards/sparkfun_redboard_turbo/mpconfigboard.h @@ -15,10 +15,6 @@ #define SPI_FLASH_SCK_PIN &pin_PB23 #define SPI_FLASH_CS_PIN &pin_PA13 -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define BOARD_HAS_CRYSTAL 1 // I2C - also QWIIC diff --git a/ports/atmel-samd/boards/sparkfun_samd21_dev/mpconfigboard.h b/ports/atmel-samd/boards/sparkfun_samd21_dev/mpconfigboard.h index 13bb263803..fd7ccc473c 100644 --- a/ports/atmel-samd/boards/sparkfun_samd21_dev/mpconfigboard.h +++ b/ports/atmel-samd/boards/sparkfun_samd21_dev/mpconfigboard.h @@ -1,10 +1,6 @@ #define MICROPY_HW_BOARD_NAME "SparkFun SAMD21 Dev Breakout" #define MICROPY_HW_MCU_NAME "samd21g18" -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PA23) #define DEFAULT_I2C_BUS_SDA (&pin_PA22) diff --git a/ports/atmel-samd/boards/sparkfun_samd21_mini/mpconfigboard.h b/ports/atmel-samd/boards/sparkfun_samd21_mini/mpconfigboard.h index 2cfdd9e73b..b4e65d15cc 100644 --- a/ports/atmel-samd/boards/sparkfun_samd21_mini/mpconfigboard.h +++ b/ports/atmel-samd/boards/sparkfun_samd21_mini/mpconfigboard.h @@ -1,10 +1,6 @@ #define MICROPY_HW_BOARD_NAME "SparkFun SAMD21 Mini Breakout" #define MICROPY_HW_MCU_NAME "samd21g18" -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PA23) #define DEFAULT_I2C_BUS_SDA (&pin_PA22) diff --git a/ports/atmel-samd/boards/sparkfun_samd51_micromod/mpconfigboard.h b/ports/atmel-samd/boards/sparkfun_samd51_micromod/mpconfigboard.h index dc9809d564..1842629266 100644 --- a/ports/atmel-samd/boards/sparkfun_samd51_micromod/mpconfigboard.h +++ b/ports/atmel-samd/boards/sparkfun_samd51_micromod/mpconfigboard.h @@ -9,13 +9,6 @@ #define SPI_FLASH_SCK_PIN &pin_PA08 #define SPI_FLASH_CS_PIN &pin_PA11 -// These are pins not to reset. -// SPI Data pins -#define MICROPY_PORT_A (PORT_PA08 | PORT_PA09 | PORT_PA10 | PORT_PA11) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - #define BOARD_HAS_CRYSTAL 1 #define DEFAULT_I2C_BUS_SCL (&pin_PA16) diff --git a/ports/atmel-samd/boards/sparkfun_samd51_thing_plus/mpconfigboard.h b/ports/atmel-samd/boards/sparkfun_samd51_thing_plus/mpconfigboard.h index 97a4465a19..5d405860c2 100644 --- a/ports/atmel-samd/boards/sparkfun_samd51_thing_plus/mpconfigboard.h +++ b/ports/atmel-samd/boards/sparkfun_samd51_thing_plus/mpconfigboard.h @@ -9,13 +9,6 @@ #define SPI_FLASH_SCK_PIN &pin_PA09 #define SPI_FLASH_CS_PIN &pin_PA10 -// These are pins not to reset. -// SPI Data pins -#define MICROPY_PORT_A (PORT_PA08 | PORT_PA09 | PORT_PA10 | PORT_PA11) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - #define BOARD_HAS_CRYSTAL 1 #define DEFAULT_I2C_BUS_SCL (&pin_PA23) diff --git a/ports/atmel-samd/boards/stackrduino_m0_pro/mpconfigboard.h b/ports/atmel-samd/boards/stackrduino_m0_pro/mpconfigboard.h index f0b2764a49..b4eb4233e7 100644 --- a/ports/atmel-samd/boards/stackrduino_m0_pro/mpconfigboard.h +++ b/ports/atmel-samd/boards/stackrduino_m0_pro/mpconfigboard.h @@ -11,11 +11,6 @@ #define SPI_FLASH_SCK_PIN &pin_PB23 #define SPI_FLASH_CS_PIN &pin_PA27 -// These are pins not to reset. -#define MICROPY_PORT_A (PORT_PA06) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define BOARD_HAS_CRYSTAL 1 #define DEFAULT_I2C_BUS_SCL (&pin_PA23) diff --git a/ports/atmel-samd/boards/stringcar_m0_express/mpconfigboard.h b/ports/atmel-samd/boards/stringcar_m0_express/mpconfigboard.h index 02a6e7f7ce..51acc0ba68 100644 --- a/ports/atmel-samd/boards/stringcar_m0_express/mpconfigboard.h +++ b/ports/atmel-samd/boards/stringcar_m0_express/mpconfigboard.h @@ -11,11 +11,6 @@ #define SPI_FLASH_SCK_PIN &pin_PA17 #define SPI_FLASH_CS_PIN &pin_PA11 -// These are pins not to reset. -#define MICROPY_PORT_A (PORT_PA00 | PORT_PA01) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PA05) #define DEFAULT_I2C_BUS_SDA (&pin_PA04) diff --git a/ports/atmel-samd/boards/trellis_m4_express/mpconfigboard.h b/ports/atmel-samd/boards/trellis_m4_express/mpconfigboard.h index 331ee894b1..7b238e2e9a 100644 --- a/ports/atmel-samd/boards/trellis_m4_express/mpconfigboard.h +++ b/ports/atmel-samd/boards/trellis_m4_express/mpconfigboard.h @@ -8,14 +8,6 @@ #define MICROPY_HW_APA102_MOSI (&pin_PB03) #define MICROPY_HW_APA102_SCK (&pin_PB02) -// These are pins not to reset. -// QSPI Data pins -#define MICROPY_PORT_A (PORT_PA08 | PORT_PA09 | PORT_PA10 | PORT_PA11) -// DotStar Pins, QSPI CS, and QSPI SCK -#define MICROPY_PORT_B (PORT_PB02 | PORT_PB03 | PORT_PB10 | PORT_PB11) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - #define DEFAULT_I2C_BUS_SCL (&pin_PB09) #define DEFAULT_I2C_BUS_SDA (&pin_PB08) diff --git a/ports/atmel-samd/boards/trinket_m0/mpconfigboard.h b/ports/atmel-samd/boards/trinket_m0/mpconfigboard.h index 69517534ee..7570e214d8 100644 --- a/ports/atmel-samd/boards/trinket_m0/mpconfigboard.h +++ b/ports/atmel-samd/boards/trinket_m0/mpconfigboard.h @@ -7,10 +7,6 @@ #define MICROPY_HW_APA102_MOSI (&pin_PA00) #define MICROPY_HW_APA102_SCK (&pin_PA01) -#define MICROPY_PORT_A (PORT_PA00 | PORT_PA01) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define IGNORE_PIN_PA03 1 #define IGNORE_PIN_PA04 1 #define IGNORE_PIN_PA11 1 diff --git a/ports/atmel-samd/boards/trinket_m0_haxpress/mpconfigboard.h b/ports/atmel-samd/boards/trinket_m0_haxpress/mpconfigboard.h index af473b1288..5588e371b5 100644 --- a/ports/atmel-samd/boards/trinket_m0_haxpress/mpconfigboard.h +++ b/ports/atmel-samd/boards/trinket_m0_haxpress/mpconfigboard.h @@ -11,11 +11,6 @@ #define SPI_FLASH_SCK_PIN &pin_PA17 #define SPI_FLASH_CS_PIN &pin_PA11 -// These are pins not to reset. -#define MICROPY_PORT_A (PORT_PA00 | PORT_PA01 | PORT_PA18) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define CALIBRATE_CRYSTALLESS 1 #define DEFAULT_I2C_BUS_SCL (&pin_PA09) diff --git a/ports/atmel-samd/boards/uartlogger2/mpconfigboard.h b/ports/atmel-samd/boards/uartlogger2/mpconfigboard.h index bd341d3039..d94df8da4b 100644 --- a/ports/atmel-samd/boards/uartlogger2/mpconfigboard.h +++ b/ports/atmel-samd/boards/uartlogger2/mpconfigboard.h @@ -10,14 +10,6 @@ #define MICROPY_HW_NEOPIXEL (&pin_PB22) -// These are pins not to reset. -// QSPI Data pins -#define MICROPY_PORT_A (PORT_PA08 | PORT_PA09 | PORT_PA10 | PORT_PA11) -// QSPI CS, QSPI SCK and NeoPixel pin -#define MICROPY_PORT_B (PORT_PB11 | PORT_PB10 | PORT_PB22) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - #define BOARD_HAS_CRYSTAL 1 #define DEFAULT_I2C_BUS_SCL (&pin_PB03) diff --git a/ports/atmel-samd/boards/uchip/board.c b/ports/atmel-samd/boards/uchip/board.c index 7af05ba45a..a9d226577c 100644 --- a/ports/atmel-samd/boards/uchip/board.c +++ b/ports/atmel-samd/boards/uchip/board.c @@ -29,6 +29,14 @@ #include "hal/include/hal_gpio.h" void board_init(void) { + // BOOST_ENABLE + never_reset_pin_number(PIN_PA14); + // VEXT_SELECT + never_reset_pin_number(PIN_PA15); + // USB_DETECT + never_reset_pin_number(PIN_PA28); + // USB_HOST_EN + never_reset_pin_number(PORT_PA27); } bool board_requests_safe_mode(void) { diff --git a/ports/atmel-samd/boards/uchip/mpconfigboard.h b/ports/atmel-samd/boards/uchip/mpconfigboard.h index 6b8435877a..b95f772af4 100644 --- a/ports/atmel-samd/boards/uchip/mpconfigboard.h +++ b/ports/atmel-samd/boards/uchip/mpconfigboard.h @@ -3,9 +3,7 @@ #define MICROPY_HW_LED_STATUS (&pin_PA07) -#define MICROPY_PORT_A (PORT_PA00 | PORT_PA01 | PORT_PA14 | PORT_PA15 | PORT_PA28 | PORT_PA27 | PORT_PA24 | PORT_PA25) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) +#define BOARD_HAS_CRYSTAL (1) // No microcontroller.nvm #define CIRCUITPY_INTERNAL_NVM_SIZE 0 @@ -17,6 +15,7 @@ #define IGNORE_PIN_PA27 1 #define IGNORE_PIN_PA28 1 +#define IGNORE_PIN_PB00 1 #define IGNORE_PIN_PB01 1 #define IGNORE_PIN_PB02 1 #define IGNORE_PIN_PB03 1 @@ -38,7 +37,6 @@ #define IGNORE_PIN_PB23 1 #define IGNORE_PIN_PB30 1 #define IGNORE_PIN_PB31 1 -#define IGNORE_PIN_PB00 1 #define DEFAULT_I2C_BUS_SCL (&pin_PA23) #define DEFAULT_I2C_BUS_SDA (&pin_PA22) diff --git a/ports/atmel-samd/boards/ugame10/mpconfigboard.h b/ports/atmel-samd/boards/ugame10/mpconfigboard.h index 550172a517..d7a6d990f0 100644 --- a/ports/atmel-samd/boards/ugame10/mpconfigboard.h +++ b/ports/atmel-samd/boards/ugame10/mpconfigboard.h @@ -6,11 +6,6 @@ #define SPI_FLASH_SCK_PIN &pin_PA17 #define SPI_FLASH_CS_PIN &pin_PA18 -// These are pins not to reset. -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define CALIBRATE_CRYSTALLESS 1 #define DEFAULT_SPI_BUS_SCK (&pin_PA07) diff --git a/ports/atmel-samd/boards/winterbloom_big_honking_button/mpconfigboard.h b/ports/atmel-samd/boards/winterbloom_big_honking_button/mpconfigboard.h index 9a9397c92d..89de7e3676 100644 --- a/ports/atmel-samd/boards/winterbloom_big_honking_button/mpconfigboard.h +++ b/ports/atmel-samd/boards/winterbloom_big_honking_button/mpconfigboard.h @@ -8,11 +8,6 @@ #define SPI_FLASH_SCK_PIN &pin_PB23 #define SPI_FLASH_CS_PIN &pin_PA27 -// These are pins not to reset. -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define BOARD_HAS_CRYSTAL 0 // USB is always used internally so skip the pin objects for it. diff --git a/ports/atmel-samd/boards/winterbloom_sol/mpconfigboard.h b/ports/atmel-samd/boards/winterbloom_sol/mpconfigboard.h index 86b1ad8a03..c022dd5daa 100644 --- a/ports/atmel-samd/boards/winterbloom_sol/mpconfigboard.h +++ b/ports/atmel-samd/boards/winterbloom_sol/mpconfigboard.h @@ -6,14 +6,6 @@ #define MICROPY_HW_LED_STATUS (&pin_PA23) #define MICROPY_HW_NEOPIXEL (&pin_PB03) -// These are pins not to reset. -// QSPI Data pins -#define MICROPY_PORT_A (PORT_PA08 | PORT_PA09 | PORT_PA10 | PORT_PA11) -// QSPI CS, QSPI SCK and NeoPixel pin -#define MICROPY_PORT_B (PORT_PB03 | PORT_PB10 | PORT_PB11) -#define MICROPY_PORT_C (0) -#define MICROPY_PORT_D (0) - #define AUTORESET_DELAY_MS 500 #define BOARD_HAS_CRYSTAL 1 diff --git a/ports/atmel-samd/boards/xinabox_cc03/mpconfigboard.h b/ports/atmel-samd/boards/xinabox_cc03/mpconfigboard.h index 4690ed3416..a7f60e60fd 100644 --- a/ports/atmel-samd/boards/xinabox_cc03/mpconfigboard.h +++ b/ports/atmel-samd/boards/xinabox_cc03/mpconfigboard.h @@ -1,10 +1,6 @@ #define MICROPY_HW_BOARD_NAME "XinaBox CC03" #define MICROPY_HW_MCU_NAME "samd21g18" -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define CIRCUITPY_INTERNAL_NVM_SIZE 256 #define BOARD_FLASH_SIZE (0x00040000 - 0x2000 - 0x010000 - CIRCUITPY_INTERNAL_NVM_SIZE) diff --git a/ports/atmel-samd/boards/xinabox_cs11/mpconfigboard.h b/ports/atmel-samd/boards/xinabox_cs11/mpconfigboard.h index 0b2f99c56e..31ac83e8b4 100644 --- a/ports/atmel-samd/boards/xinabox_cs11/mpconfigboard.h +++ b/ports/atmel-samd/boards/xinabox_cs11/mpconfigboard.h @@ -1,10 +1,6 @@ #define MICROPY_HW_BOARD_NAME "XinaBox CS11" #define MICROPY_HW_MCU_NAME "samd21g18" -#define MICROPY_PORT_A (0) -#define MICROPY_PORT_B (0) -#define MICROPY_PORT_C (0) - #define CIRCUITPY_INTERNAL_NVM_SIZE 256 #define BOARD_FLASH_SIZE (0x00040000 - 0x2000 - 0x010000 - CIRCUITPY_INTERNAL_NVM_SIZE) diff --git a/ports/atmel-samd/common-hal/microcontroller/Pin.c b/ports/atmel-samd/common-hal/microcontroller/Pin.c index 8032673d03..41cfff763e 100644 --- a/ports/atmel-samd/common-hal/microcontroller/Pin.c +++ b/ports/atmel-samd/common-hal/microcontroller/Pin.c @@ -63,13 +63,13 @@ void reset_all_pins(void) { pin_mask[i] &= ~never_reset_pins[i]; } - gpio_set_port_direction(GPIO_PORTA, pin_mask[0] & ~MICROPY_PORT_A, GPIO_DIRECTION_OFF); - gpio_set_port_direction(GPIO_PORTB, pin_mask[1] & ~MICROPY_PORT_B, GPIO_DIRECTION_OFF); + gpio_set_port_direction(GPIO_PORTA, pin_mask[0], GPIO_DIRECTION_OFF); + gpio_set_port_direction(GPIO_PORTB, pin_mask[1], GPIO_DIRECTION_OFF); #if PORT_BITS > 64 - gpio_set_port_direction(GPIO_PORTC, pin_mask[2] & ~MICROPY_PORT_C, GPIO_DIRECTION_OFF); + gpio_set_port_direction(GPIO_PORTC, pin_mask[2], GPIO_DIRECTION_OFF); #endif #if PORT_BITS > 96 - gpio_set_port_direction(GPIO_PORTD, pin_mask[3] & ~MICROPY_PORT_D, GPIO_DIRECTION_OFF); + gpio_set_port_direction(GPIO_PORTD, pin_mask[3], GPIO_DIRECTION_OFF); #endif // Configure SWD. SWDIO will be automatically switched on PA31 when a signal is input on diff --git a/ports/atmel-samd/supervisor/qspi_flash.c b/ports/atmel-samd/supervisor/qspi_flash.c index e59c2ee4a6..304a2e1b8b 100644 --- a/ports/atmel-samd/supervisor/qspi_flash.c +++ b/ports/atmel-samd/supervisor/qspi_flash.c @@ -242,11 +242,18 @@ void spi_flash_init(void) { QSPI->CTRLA.reg = QSPI_CTRLA_ENABLE; // The QSPI is only connected to one set of pins in the SAMD51 so we can hard code it. - uint32_t pins[6] = {PIN_PA08, PIN_PA09, PIN_PA10, PIN_PA11, PIN_PB10, PIN_PB11}; - for (uint8_t i = 0; i < 6; i++) { + #ifdef EXTERNAL_FLASH_QSPI_SINGLE + uint32_t pins[] = {PIN_PA08, PIN_PB10, PIN_PB11}; + #elif defined(EXTERNAL_FLASH_QSPI_DUAL) + uint32_t pins[] = {PIN_PA08, PIN_PA09, PIN_PB10, PIN_PB11}; + #else + uint32_t pins[] = {PIN_PA08, PIN_PA09, PIN_PA10, PIN_PA11, PIN_PB10, PIN_PB11}; + #endif + for (uint8_t i = 0; i < MP_ARRAY_SIZE(pins); i++) { gpio_set_pin_direction(pins[i], GPIO_DIRECTION_IN); gpio_set_pin_pull_mode(pins[i], GPIO_PULL_OFF); gpio_set_pin_function(pins[i], GPIO_PIN_FUNCTION_H); + never_reset_pin_number(pins[i]); } } diff --git a/supervisor/shared/status_leds.c b/supervisor/shared/status_leds.c index e8b0983d9b..d57aba1973 100644 --- a/supervisor/shared/status_leds.c +++ b/supervisor/shared/status_leds.c @@ -306,10 +306,12 @@ void init_rxtx_leds(void) { #if CIRCUITPY_DIGITALIO && defined(MICROPY_HW_LED_RX) common_hal_digitalio_digitalinout_construct(&rx_led, MICROPY_HW_LED_RX); common_hal_digitalio_digitalinout_switch_to_output(&rx_led, true, DRIVE_MODE_PUSH_PULL); + common_hal_digitalio_digitalinout_never_reset(&rx_led); #endif #if CIRCUITPY_DIGITALIO && defined(MICROPY_HW_LED_TX) common_hal_digitalio_digitalinout_construct(&tx_led, MICROPY_HW_LED_TX); common_hal_digitalio_digitalinout_switch_to_output(&tx_led, true, DRIVE_MODE_PUSH_PULL); + common_hal_digitalio_digitalinout_never_reset(&tx_led); #endif } From e042d54702c4f21060103441acb87ad125842656 Mon Sep 17 00:00:00 2001 From: Scott Shawcroft Date: Fri, 16 Jul 2021 11:15:05 -0700 Subject: [PATCH 2/2] Fix three boards and xtensa cache key --- .github/workflows/build.yml | 2 +- ports/atmel-samd/boards/aloriumtech_evo_m51/board.c | 1 + ports/atmel-samd/boards/trinket_m0_haxpress/mpconfigboard.h | 4 ++-- ports/atmel-samd/boards/uchip/board.c | 5 ++++- 4 files changed, 8 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index c3c04960bf..e8fc12083f 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -531,7 +531,7 @@ jobs: id: idf-cache with: path: ${{ github.workspace }}/.idf_tools - key: ${{ runner.os }}-idf-tools-${{ hashFiles('.git/modules/ports/esp32s2/esp-idf/HEAD') }}-20210506 + key: ${{ runner.os }}-idf-tools-${{ hashFiles('.git/modules/ports/esp32s2/esp-idf/HEAD') }}-20210716 - name: Clone IDF submodules run: | (cd $IDF_PATH && git submodule update --init) diff --git a/ports/atmel-samd/boards/aloriumtech_evo_m51/board.c b/ports/atmel-samd/boards/aloriumtech_evo_m51/board.c index 69b7a2664a..68717070d6 100644 --- a/ports/atmel-samd/boards/aloriumtech_evo_m51/board.c +++ b/ports/atmel-samd/boards/aloriumtech_evo_m51/board.c @@ -30,6 +30,7 @@ #include "supervisor/board.h" #include "mpconfigboard.h" +#include "common-hal/microcontroller/Pin.h" void board_init(void) { never_reset_pin_number(PIN_PB20); diff --git a/ports/atmel-samd/boards/trinket_m0_haxpress/mpconfigboard.h b/ports/atmel-samd/boards/trinket_m0_haxpress/mpconfigboard.h index 5588e371b5..25e00c03bb 100644 --- a/ports/atmel-samd/boards/trinket_m0_haxpress/mpconfigboard.h +++ b/ports/atmel-samd/boards/trinket_m0_haxpress/mpconfigboard.h @@ -3,8 +3,8 @@ // Rev B - Black #define MICROPY_HW_LED_STATUS (&pin_PA10) -// #define MICROPY_HW_APA102_MOSI (&pin_PA00) -// #define MICROPY_HW_APA102_SCK (&pin_PA01) +#define MICROPY_HW_APA102_MOSI (&pin_PA00) +#define MICROPY_HW_APA102_SCK (&pin_PA01) #define SPI_FLASH_MOSI_PIN &pin_PA16 #define SPI_FLASH_MISO_PIN &pin_PA19 diff --git a/ports/atmel-samd/boards/uchip/board.c b/ports/atmel-samd/boards/uchip/board.c index a9d226577c..6c2c219a2f 100644 --- a/ports/atmel-samd/boards/uchip/board.c +++ b/ports/atmel-samd/boards/uchip/board.c @@ -25,7 +25,10 @@ */ #include "supervisor/board.h" + +#include "common-hal/microcontroller/Pin.h" #include "mpconfigboard.h" + #include "hal/include/hal_gpio.h" void board_init(void) { @@ -36,7 +39,7 @@ void board_init(void) { // USB_DETECT never_reset_pin_number(PIN_PA28); // USB_HOST_EN - never_reset_pin_number(PORT_PA27); + never_reset_pin_number(PIN_PA27); } bool board_requests_safe_mode(void) {