FPGA, SoC, And CPLD Boards And Kits
FPGA Evaluation and Development Kits
6474 Discussions

Problem erasing EPCQ flash memory on INTEL Cyclone evaluation board with Generic Serial Flash Interface Intel running on NIOS II

MMinu3
Beginner
4,156 Views

As mentioned above, I'm not able to erase Flash Memory (neither sectors, sub-sectors, or bulk) using the Generic Serial Flash Interface Intel running on NIOS II: only with "Quartus programmer" I can.

 

In the attached image you can see the waveforms on memory pins (clock, data in and CS): nothing changes if the first interval of "Status read" is stretched up to several milliseconds.

 

Sometimes, the memory locations seems to be "partially erased" (meaning that the content changes, but not to 0xFF), sometime the content doesn't change...

 

What do you suggest me?

 

Thanks in advance for your support.

Maurizio

 

SubSectorErase.png

0 Kudos
29 Replies
MMinu3
Beginner
1,193 Views

Hi,

the only way I know to unprotect the whole memory is clear the flags "TP", "BP2", "BP1", "BP0" into the status register and I do that as soon the program starts: are there others way to unprotect the whole memory space?

 

BTW: I've already tested your last suggestion and, unfortunately, both "sector" and "bulk" operations fails,

 

Thanks again, Regards

Maurizio

0 Kudos
JohnT_Intel
Employee
1,193 Views

Hi,

 

Could you try to read the Status Register?

0 Kudos
MMinu3
Beginner
1,193 Views

Hi,

I already read the status register before "erase" operation to be sure that "WEL" bit is settled to "1", so I'm sure that all others flag are cleared.

 

Do I check something different?

 

MM

 

0 Kudos
JohnT_Intel
Employee
1,193 Views

Hi,

 

What are you observing when you performed read status register? May I know if you have another board to test it out?

0 Kudos
MMinu3
Beginner
1,193 Views

EPCQA_SectorEraseEarly.pngEPCQA_SectorErase.png

Hi, if you take a look to the attached images, you can see that the erase operation take about 160ms and the Status values is always 0x03, except the last one whose value is "0"... as expected.

 

MM

0 Kudos
JohnT_Intel
Employee
1,193 Views

Hi MM,

 

From my understanding, after 160ms, you are observing the Status values is 0x0. So if you performed a read, what will happen? It should be 0xff right?

0 Kudos
MMinu3
Beginner
1,193 Views

Hi John,

unfortunately when I read data after "sector Erase" completes, I don't find 0xFF, but the values I've stored before (0x7D).

So, now, I have a new question: If I want erase the sector starting at address "0x1F0000" in the memory array organization (as explained in "EPCQ-A Serial Configuration Device Datasheet") which address do I need specify in "erase sector" command? Is "0x1F0000" correct?

Moreover, if you look in to the attached picture (related to an "Erase Bulk" operation, you can see that that flag WIP is cleared at the first Status read (so the operation is considered completed at the first check).

 

I hope this can help you to better understand where I'm wrong.

Thank you

Maurizio

 

erase bulk.png

0 Kudos
JohnT_Intel
Employee
1,193 Views

Hi,

 

May I know if you have other board for testing?

0 Kudos
MMinu3
Beginner
1,193 Views

Hi,

I tried on 2 different boards but nothing change

Maurizio

0 Kudos
Reply