Skip to main content
kvm16309876
Visitor II
February 10, 2020
Question

QSPI Erase block erases the whole memory?

  • February 10, 2020
  • 2 replies
  • 698 views

I am using STM32L4 discovery board and External QSPI to save data. From the datasheet, it is mentioned that before every write, erase command has to be issued. But when I issue Erase Block or Subblock command, complete Chip is getting erased. Can anybody help me with this issue on how to erase a block of the memory?

This topic has been closed for replies.

2 replies

Panometric
Associate III
February 10, 2020

Just guessing without more details like the part datasheet and logic analyzer capture, but QSPI commands can have a different width than the bulk transfer, perhaps you are using the wrong width and it being mis-interpretted. Look for sCommand.AddressMode=QSPI_ADDRESS_1_LINE

Andreas Bolsch
Lead III
February 11, 2020

Either you sent erase (sub-) sector commands for each sector or you sent a mass erase command instead of a (sub-) sector erase command.