Restore official Waveshare display register init sequence and LEDC backlight driver to fix blank display screen
This commit is contained in:
@@ -18,15 +18,15 @@ int g_favoriteMemoryId = -1;
|
||||
|
||||
// ── SD Init ───────────────────────────────────────────────────────────────────
|
||||
void SD_Init() {
|
||||
if (!SD_MMC.setPins(SD_CLK_PIN, SD_CMD_PIN, SD_D0_PIN)) {
|
||||
if (!SD_MMC.setPins(SD_CLK_PIN, SD_CMD_PIN, SD_D0_PIN, SD_D1_PIN, SD_D2_PIN, SD_D3_PIN)) {
|
||||
printf("SD MMC: Pin change failed!\r\n");
|
||||
return;
|
||||
}
|
||||
if (!SD_MMC.begin("/sdcard", true, true)) {
|
||||
if (!SD_MMC.begin("/sdcard", false, true)) {
|
||||
printf("SD card initialization failed!\r\n");
|
||||
return;
|
||||
}
|
||||
printf("SD card OK (1-bit mode)\r\n");
|
||||
printf("SD card OK (4-bit mode)\r\n");
|
||||
uint8_t cardType = SD_MMC.cardType();
|
||||
if (cardType == CARD_NONE) { printf("No SD card attached\r\n"); return; }
|
||||
|
||||
|
||||
Reference in New Issue
Block a user