diff --git a/ports/espressif/boards/m5stack_dial/board.cmake b/ports/espressif/boards/m5stack_dial/board.cmake new file mode 100644 index 00000000..9bac46d6 --- /dev/null +++ b/ports/espressif/boards/m5stack_dial/board.cmake @@ -0,0 +1,2 @@ +# Apply board specific content here +set(IDF_TARGET "esp32s3") diff --git a/ports/espressif/boards/m5stack_dial/board.h b/ports/espressif/boards/m5stack_dial/board.h new file mode 100644 index 00000000..55614ded --- /dev/null +++ b/ports/espressif/boards/m5stack_dial/board.h @@ -0,0 +1,70 @@ +/* + * The MIT License (MIT) + * + * Copyright (c) 2025 Alec Delaney + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + * THE SOFTWARE. + */ + + +#ifndef M5STACK_DIAL_BOARD_H_ +#define M5STACK_DIAL_BOARD_H_ + +//--------------------------------------------------------------------+ +// Button +//--------------------------------------------------------------------+ + +// Enter UF2 mode if GPIO is pressed while 2nd stage bootloader indicator +// is on e.g RGB = Purple. If it is GPIO0, user should not hold this while +// reset since that will instead run the 1st stage ROM bootloader +#define PIN_BUTTON_UF2 0 + +// GPIO that implement 1-bit memory with RC components which hold the +// pin value long enough for double reset detection. +//#define PIN_DOUBLE_RESET_RC + +//--------------------------------------------------------------------+ +// LED +//--------------------------------------------------------------------+ + +// GPIO connected to Neopixel data +#define NEOPIXEL_PIN 21 + +// Brightness percentage from 1 to 255 +#define NEOPIXEL_BRIGHTNESS 0x10 + +// Number of neopixels +#define NEOPIXEL_NUMBER 1 + +//--------------------------------------------------------------------+ +// USB UF2 +//--------------------------------------------------------------------+ + +#define USB_VID 0x303A +#define USB_PID 0x811A + +#define USB_MANUFACTURER "M5Stack" +#define USB_PRODUCT "Stamp S3" + +#define UF2_PRODUCT_NAME USB_MANUFACTURER " " USB_PRODUCT +#define UF2_BOARD_ID "ESP32S3-StampS3-01" +#define UF2_VOLUME_LABEL "M5S3BOOT" +#define UF2_INDEX_URL "https://docs.m5stack.com/en/core/StampS3" + +#endif diff --git a/ports/espressif/boards/m5stack_dial/sdkconfig b/ports/espressif/boards/m5stack_dial/sdkconfig new file mode 100644 index 00000000..04513503 --- /dev/null +++ b/ports/espressif/boards/m5stack_dial/sdkconfig @@ -0,0 +1,8 @@ +# Board Specific Config + +# Partition Table +CONFIG_PARTITION_TABLE_CUSTOM_FILENAME="partitions-8MB.csv" + +# Serial flasher config +CONFIG_ESPTOOLPY_FLASHSIZE_8MB=y +CONFIG_ESPTOOLPY_FLASHSIZE="8MB" diff --git a/ports/espressif/boards/waveshare_esp32_s3_tiny/board.cmake b/ports/espressif/boards/waveshare_esp32_s3_tiny/board.cmake new file mode 100644 index 00000000..9bac46d6 --- /dev/null +++ b/ports/espressif/boards/waveshare_esp32_s3_tiny/board.cmake @@ -0,0 +1,2 @@ +# Apply board specific content here +set(IDF_TARGET "esp32s3") diff --git a/ports/espressif/boards/waveshare_esp32_s3_tiny/board.h b/ports/espressif/boards/waveshare_esp32_s3_tiny/board.h new file mode 100644 index 00000000..5863ae79 --- /dev/null +++ b/ports/espressif/boards/waveshare_esp32_s3_tiny/board.h @@ -0,0 +1,74 @@ +/* + * The MIT License (MIT) + * + * Copyright (c) 2020 Ha Thach (tinyusb.org) for Adafruit Industries + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + * THE SOFTWARE. + */ + +#ifndef WAVESHARE_ESP32_S3_TINY_H_ +#define WAVESHARE_ESP32_S3_TINY_H_ + +//--------------------------------------------------------------------+ +// Button +//--------------------------------------------------------------------+ + +// Enter UF2 mode if GPIO is pressed while 2nd stage bootloader indicator +// is on e.g RGB = Purple. If it is GPIO0, user should not hold this while +// reset since that will instead run the 1st stage ROM bootloader +#define PIN_BUTTON_UF2 0 + +// GPIO that implement 1-bit memory with RC components which hold the +// pin value long enough for double reset detection. +// #define PIN_DOUBLE_RESET_RC + +//--------------------------------------------------------------------+ +// LED +//--------------------------------------------------------------------+ + +// GPIO connected to Neopixel data +#define NEOPIXEL_PIN 38 + +// Brightness percentage from 1 to 255 +#define NEOPIXEL_BRIGHTNESS 0x10 + +// Number of neopixels +#define NEOPIXEL_NUMBER 1 + +// Invert Neopixel red and green +#define NEOPIXEL_INVERT_RG 1 + +// LED for indicator and writing flash +// If not defined neopixel will be use for flash writing instead + +//--------------------------------------------------------------------+ +// USB UF2 +//--------------------------------------------------------------------+ + +#define USB_VID 0x303a +#define USB_PID 0x81F8 +#define USB_MANUFACTURER "Waveshare Electronics" +#define USB_PRODUCT "ESP32-S3-Tiny" + +#define UF2_PRODUCT_NAME USB_MANUFACTURER " " USB_PRODUCT +#define UF2_BOARD_ID "ESP32-S3-Tiny" +#define UF2_VOLUME_LABEL "WS3TINYBOOT" +#define UF2_INDEX_URL "https://www.waveshare.com/wiki/ESP32-S3-Tiny" + +#endif diff --git a/ports/espressif/boards/waveshare_esp32_s3_tiny/sdkconfig b/ports/espressif/boards/waveshare_esp32_s3_tiny/sdkconfig new file mode 100644 index 00000000..6eb1896c --- /dev/null +++ b/ports/espressif/boards/waveshare_esp32_s3_tiny/sdkconfig @@ -0,0 +1,7 @@ +# Board Specific Config + +# Partition Table +CONFIG_PARTITION_TABLE_CUSTOM_FILENAME="partitions-4MB-noota.csv" + +# Serial flasher config +CONFIG_ESPTOOLPY_FLASHSIZE_4MB=y diff --git a/ports/mimxrt10xx/boards/imxrt1170_evk/board/clock_config.c b/ports/mimxrt10xx/boards/imxrt1170_evk/board/clock_config.c index ba940e17..43ce839d 100644 --- a/ports/mimxrt10xx/boards/imxrt1170_evk/board/clock_config.c +++ b/ports/mimxrt10xx/boards/imxrt1170_evk/board/clock_config.c @@ -160,10 +160,12 @@ void BOARD_BootClockRUN(void) { rootCfg.div = 1; CLOCK_SetRootClock(kCLOCK_Root_Cssys, &rootCfg); - /* Configure FLEXSPI1 using OSC_RC_48M_DIV2 */ - rootCfg.mux = kCLOCK_FLEXSPI1_ClockRoot_MuxOscRc48MDiv2; - rootCfg.div = 1; + /* Configure FLEXSPI1 using OSC_RC_400M (100MHz) */ + rootCfg.mux = kCLOCK_FLEXSPI1_ClockRoot_MuxOscRc400M; + rootCfg.div = 4; CLOCK_SetRootClock(kCLOCK_Root_Flexspi1, &rootCfg); + FLEXSPI1->MCR0 |= FLEXSPI_MCR0_SWRESET_MASK; + while (FLEXSPI1->MCR0 & FLEXSPI_MCR0_SWRESET_MASK) {} /* Configure GPT1 using OSC_24M for timing */ rootCfg.mux = kCLOCK_GPT1_ClockRoot_MuxOsc24MOut; diff --git a/ports/mimxrt10xx/boards/imxrt1170_evk/mimxrt1170_evkb.mex b/ports/mimxrt10xx/boards/imxrt1170_evk/mimxrt1170_evkb.mex index 2099126d..4474e3d4 100644 --- a/ports/mimxrt10xx/boards/imxrt1170_evk/mimxrt1170_evkb.mex +++ b/ports/mimxrt10xx/boards/imxrt1170_evk/mimxrt1170_evkb.mex @@ -231,7 +231,7 @@ - + @@ -303,6 +303,8 @@ + + diff --git a/supported_boards.md b/supported_boards.md index a8c6c4a3..6fa60833 100644 --- a/supported_boards.md +++ b/supported_boards.md @@ -71,6 +71,7 @@ | m5stack_atoms3_lite | M5Stack AtomS3 Lite | 0x303A:0x8160 | https://shop.m5stack.com/products/atoms3-lite-esp32s3-dev-kit | | m5stack_atoms3u | M5Stack AtomS3U | 0x303A:0x8188 | https://docs.m5stack.com/en/core/AtomS3U | | m5stack_cores3 | M5Stack CoreS3 | 0x303A:0x811B | https://shop.m5stack.com/products/m5stack-cores3-esp32s3-lotdevelopment-kit | +| m5stack_dial | M5Stack Dial | 0x303A:0x811A | https://docs.m5stack.com/en/core/M5Dial | | m5stack_stamps3 | M5Stack Stamp S3 | 0x303A:0x811A | https://docs.m5stack.com/en/core/StampS3 | | magiclick_s3_n4r2 | MakerM0 MagiClick S3 | 0x303A:0x81AC | https://github.com/MakerM0/MagiClick-esp32s3 | | maker_badge | Czech maker Maker badge | 0x239A:0x2030 | https://github.com/dronecz/maker_badge | @@ -104,6 +105,7 @@ | waveshare_esp32_s3_pico | Waveshare Electronics ESP32-S3-Pico | 0x303A:0x81A2 | http://www.waveshare.com/wiki/ESP32-S2-Pico | | waveshare_esp32_s3_touch_lcd_169 | Waveshare Electronics ESP32-S3-Touch-LCD-1.69 | 0x303A:0x8220 | https://www.waveshare.com/product/esp32-s3-touch-lcd-1.69.htm | | waveshare_esp32_s3_touch_lcd_2 | Waveshare Electronics ESP32-S3-Touch-LCD-2 | 0x303A:0x82CF | https://www.waveshare.com/esp32-s3-touch-lcd-2.htm?sku=29667 | +| waveshare_esp32_s3_tiny | Waveshare Electronics ESP32-S3-Tiny | 0x303A:0x81F8 | https://www.waveshare.com/wiki/ESP32-S3-Tiny | | waveshare_esp32_s3_zero | Waveshare Electronics ESP32-S3-Zero | 0x303A:0x81B3 | https://www.waveshare.com/wiki/ESP32-S3-Zero | | waveshare_esp32s2_pico | Waveshare Electronics ESP32-S2-Pico | 0x303A:0x8109 | http://www.waveshare.com/wiki/ESP32-S2-Pico | | waveshare_esp32s3_lcd_169 | Waveshare Electronics ESP32-S3-LCD-1.69 | 0x303A:0x8223 | https://www.waveshare.com/product/esp32-s3-lcd-1.69.htm |