Skip to content

Fix M5Stack CoreS3 boot crash - #11155

Merged
dhalbert merged 5 commits into
adafruit:mainfrom
CDarius:fix-cores3-boot-crash
Jul 31, 2026
Merged

Fix M5Stack CoreS3 boot crash#11155
dhalbert merged 5 commits into
adafruit:mainfrom
CDarius:fix-cores3-boot-crash

Conversation

@CDarius

@CDarius CDarius commented Jul 29, 2026

Copy link
Copy Markdown

This PR fixes the issue #11009
The problem was the SPI bus definition. The GPIO35 is either the MISO pin on the M5Bus but also the display DC signal.
I have changed the SPI definition removing the MISO pin.
I made the same change also for the CoreS3 SE

@dhalbert dhalbert left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for fixing this.

Are the SPI pins available externally, or are they just used for SD and the display D/C? A board.SPI() that doesn't have a MOSI is not very useful. I wonder if we should just remove board.SPI() entirely if it can't be used as a regular SPI.

@CDarius

CDarius commented Jul 30, 2026

Copy link
Copy Markdown
Author

On the CoreS3 the SPI use the following gpios:

  • SCK -> GPIO36
  • MOSI -> GPIO37
  • MISO -> GPIO35

This SPI bus is used for the display, the SD card and exposed on the M5Bus (on the back)
Unfortunately the GPIO35 is also the DC signal for the display.

I can remove the SPI definition from mpconfigboard.h (and pins.c) but then I should probably create the display SPI bus in board.c. Do you prefer to go in this direction?

@dhalbert

Copy link
Copy Markdown
Collaborator

I can remove the SPI definition from mpconfigboard.h (and pins.c) but then I should probably create the display SPI bus in board.c. Do you prefer to go in this direction?

I guess this is the best way. Maybe also rename the pins to TFT_SCK, TFT_MOSI, TFT_DC.

Most people trying to do regular SPI on the supposed "SPI" pins are going to be disappointed. I looked at the Arduino pin defs for the board and they also say MISO for pin 35. If someone wants SPI they should use other pins.

@dhalbert dhalbert left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks - now we can remove the DEfAULT_SPI_* definitions too, since there is no board.SPI().

Comment thread ports/espressif/boards/m5stack_cores3/mpconfigboard.h Outdated
Comment thread ports/espressif/boards/m5stack_cores3_se/mpconfigboard.h Outdated

@dhalbert dhalbert left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great - thanks for fixing this!

@dhalbert
dhalbert merged commit 719f88d into adafruit:main Jul 31, 2026
18 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants