We are trying to access qspi (MT25QL512ABB8E12), which is the boot device. Booting the application works just fine.
We also see that erase and read is functional from drivers (reading the section of application, shows the expected info), also the write does an erase, but on getting to writing the data (after erase) , the memory remains fffff... (seen from memory view!), i.e. write returns success but does not write the new data into flash !
Our test application is the same one provided in NIOS software developer handbook (just writes and reads 1024 bytes) as shown here.
(just changed device name to "/dev/qspi_0_avl_mem", all the rest is the same ).
I suspected that it is write-protect issue, but even adding unlock ( alt_lock_flash(dev, 0) ) did not change anything.
nios clock is 100Mhz
EPCQ clock is 25Mhz
see qsys image
I also tried to debug altera driver alt_qspi_controller_write_block():
I see that memcpy is done, no error from controller are recieved according to function, ( "check whether write triggered a illegal write interrupt ") , yet the memory remains 0xffff (memory view)...
Is it some bug in quartus 15.1 IP/drivers ?
Any suggestion why it fails and how to debug it will help!
Micron's MT25Q devices is supported in Quartus Prime 17.1 and later.
MT25Q is not supported in Quartus 15.1. Please use the latest Quartus version if yo want to use MT25Q device.
Please refer to following link to enable Micron's MT25Q in Intel Quartus Prime:
We upgraded to quartus 18.1, but the behavior is the same.
Only after changing I/O access from Quad to Standard, we managed to write info flash !
But we need the bandwidth of quad access...
More info: We use "altera flash controller" for our boot qspi.
Can you try to use "Quad SPI controller II" with MT25Q device?
Sometime Quad SPI controller I have some issue with MT25Q device. However, Quad SPI controller II is working with MT25Q with direct access.
Kindly try this out. Please let me know the results.
On trying to use the same IP with 512 qspi we can reach only 512M OK, but the qspi is 1G, we then tried to change the module in qsys to N25Q00AA1G1240 (no other 1G MT25Q option is available, but then on compile we get error
instantiated_with_wrong_parameters_error_see_comment_above becuase ADDR_WIDTH != 24,
Trying to use generic quad controller II, as you suggested, we get errors that "COMPOSITION_CALLBACK" is not supported with our quartus version (unfortunately we can't upgrade above 15.1)
Is there any idea how we can handle this ?