A library with drivers for different peripherals on the LPC4088 QuickStart Board or related add-on boards.
Dependents: LPC4088test LPC4088test_ledonly LPC4088test_deleteall LPC4088_RAMtest ... more
Diff: QSPIFileSystem.cpp
- Revision:
- 18:9f1f1a8b4729
- Parent:
- 12:15597e45eea0
diff -r b3a179cc3d88 -r 9f1f1a8b4729 QSPIFileSystem.cpp --- a/QSPIFileSystem.cpp Wed Aug 27 14:24:16 2014 +0000 +++ b/QSPIFileSystem.cpp Mon Oct 27 10:18:08 2014 +0000 @@ -215,6 +215,20 @@ memInfo.tocBlockAddr = SPIFI_MEM_BASE + (NUM_BLOCKS * ERASE_SIZE) - (memInfo.numTocs * memInfo.tocSizeInBytes); break; + case SPIFI::Macronix_MX25L6435EM2I: + /* For the Macronix memory the TOC occupies 8192 bytes and that is bigger than + one erase block (which is 4096 bytes). It is possible to either keep only + one TOC or to create a couple to reduce wear on the memory. In this case + the multiple TOCs option is used. */ + strcpy(memInfo.memName, "Macronix_MX25L6435EM2I"); + memInfo.memSize = obj->memSize; + memInfo.eraseBlockSize = 4*1024; + memInfo.numEraseBlocks = memInfo.memSize / memInfo.eraseBlockSize; + memInfo.tocSizeInBytes = sizeof(toc_entry_t) * memInfo.numEraseBlocks; + memInfo.numTocs = 8; + memInfo.tocBlockAddr = SPIFI_MEM_BASE + (NUM_BLOCKS * ERASE_SIZE) - (memInfo.numTocs * memInfo.tocSizeInBytes); + break; + case SPIFI::UnknownDevice: default: debug("INIT: Memory is unknown and may not work as expected\n");