Skip to content

Commit f88c2c5

Browse files
committed
feat(spi_flash): Support Flash ID 0x164068
1 parent e5618e9 commit f88c2c5

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

components/spi_flash/src/spi_flash.c

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -259,6 +259,12 @@ bool spi_flash_check_wr_protect(void)
259259
special_flash_write_status(0x01, status&(~(SPI_GD25Q32_FLASH_WRITE_PROTECT_STATUS)), 1, true);
260260
}
261261
}
262+
} else if (flash_id == 0x164068) {
263+
if(spi_flash_read_status(&status)==0) { //Read status Ok
264+
if(status&SPI_GD25Q32_FLASH_WRITE_PROTECT_STATUS) {
265+
special_flash_write_status(0x01, status&(~(SPI_GD25Q32_FLASH_WRITE_PROTECT_STATUS)), 1, true);
266+
}
267+
}
262268
}
263269
//Others
264270
else {
@@ -435,6 +441,10 @@ void user_spi_flash_dio_to_qio_pre_init(void)
435441
to_qio = true;
436442
}
437443
//ENBALE FLASH QIO 0X01H+0X00+0X02
444+
} else if (flash_id == 0x164068) {
445+
if (flash_gd25q32c_enable_QIO_mode() == true) {
446+
to_qio = true;
447+
}
438448
} else {
439449
if (spi_flash_enable_qmode_raw(&g_rom_flashchip) == ESP_OK) {
440450
to_qio = true;

0 commit comments

Comments
 (0)