Sandro
Well-known member
Hi all,
as long as I know the W25Q512 flash memory chip has not official support here.
This 64MB chip responds with:
id[0]:239
id[1]:112
id[2]:56
I sarted adding few lines to capacity(...) function, in SerialFlashChip.cpp:
And the only progress is that now the code should get the right value of capacity... but nothing else seems changed, writing files is still impossible. Anyone knows how far I'm from the goal?
Thanks in advance!
as long as I know the W25Q512 flash memory chip has not official support here.
This 64MB chip responds with:
id[0]:239
id[1]:112
id[2]:56
I sarted adding few lines to capacity(...) function, in SerialFlashChip.cpp:
Code:
uint32_t SerialFlashChip::capacity(const uint8_t *id)
{
uint32_t n = 1048576; // unknown chips, default to 1 MByte
if (id[0] == ID0_ADESTO && id[1] == 0x89)
{
n = 1048576*16; //16MB
}
else if (id[2] >= 16 && id[2] <= 31)
{
n = 1ul << id[2];
}
else if (id[2] >= 32 && id[2] <= 37)
{
n = 1ul << (id[2] - 6);
}
else if ((id[0]==0 && id[1]==0 && id[2]==0) ||
(id[0]==255 && id[1]==255 && id[2]==255))
{
n = 0;
}
// I added this new case
else if (id[2] == 56) // 0x38
{
n = 1ul << 26; // 2^26 = 64M
Serial.println("capacity: 64MB");
}
//Serial.printf("capacity %lu\n", n);
return n;
}
And the only progress is that now the code should get the right value of capacity... but nothing else seems changed, writing files is still impossible. Anyone knows how far I'm from the goal?
Thanks in advance!