adafruit / adafruit/Adafruit_VS1053_Library
Pinouts in feather_player.ino don't work with Feather ESP32-S3
- Dominant language
- C++
- Stars
- 152
- Forks
- 116
- PR merge metrics
- No merged PRs in 30d
Description
The Feather Music Maker documentation and the feather_player.ino source imply that the pinouts should work with all boards. However, the correct Feather ESP32-S3 pinout matches the S2, but [line 26](https://github.com/adafruit/Adafruit_VS1053_Library/blob/master/examples/feather_player/feather_player.ino#L26C1-L26C67) `#elif defined(ESP32) && !defined(ARDUINO_ADAFRUIT_FEATHER_ESP32S2)` returns True for the ESP32-S3, which means the wrong pinout definitions are used in this example file. Furthermore it caused device crashes rather than the error to print to Serial, which was doubly frustrating for me let alone new users.
I tested that the ESP32-S2 pinout (the very last `#else` block in the file) worked with the ESP32-S3. However I believe these variables come from Platform.io, e.g. [here for my board](https://github.com/platformio/platform-espressif32/blob/develop/boards/adafruit_feather_esp32s3_nopsram.json). That would imply we need to check for 7 variables:
* `ARDUINO_ADAFRUIT_FEATHER_ESP32S2`
* `ARDUINO_ADAFRUIT_FEATHER_ESP32S2_REVTFT`
* `ARDUINO_ADAFRUIT_FEATHER_ESP32S2_TFT`
* `ARDUINO_ADAFRUIT_FEATHER_ESP32S3`
* `ARDUINO_ADAFRUIT_FEATHER_ESP32S3_NOPSRAM`
* `ARDUINO_ADAFRUIT_FEATHER_ESP32S3_REVTFT`
* `ARDUINO_ADAFRUIT_FEATHER_ESP32S3_TFT`
I'm not sure if we should rewrite that `#elif` block to exclude all 7 of these cases, just leave a comment for someone viewing the code that they'll need to fix it for these cases, or if there's some more efficient way to check for these cases?
Contributor guide
No contributing guide indexed for this repository
Research direction
Start in examples/feather_player/feather_player.ino at line 26 and compare the conditional pinout branches with the listed ESP32-S2 and ESP32-S3 board macros. Check the linked PlatformIO board definition, then test the example on an ESP32-S3; done means it selects the working S2-compatible pinout without crashing.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- embedded-iot
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100