Forum Discussion

Fabrizio2's avatar
Fabrizio2
Icon for New Contributor rankNew Contributor
2 years ago

Nios2 generic_quad_spi_controller2 set dummy clycles

Hi all, on Nios2 - MAX10 device, with QUARTUS 18.1 :

I'm working on an old project and I use the generic_quad_spi_controller2 to interface a flash memory MICRON MT25QU512ABB .

The generic_quad_spi_controller2 driver works fine since many years in this active project.

We want to set the dummy cycles of the flash to a certain value in order to slow down the working clock frq from 60Mhz to 30 Mhz .

As per MICRON datasheet this is done by writing to the flash memory register "Non volatile configuration register" .

The NIOS2 generic_quad_spi_controller2 apparently doesn't provide any HAL function that can be used to set dummy cycles or access any Memory config registers.

Is there a way to do this?

11 Replies

  • KennyT_altera's avatar
    KennyT_altera
    Icon for Super Contributor rankSuper Contributor

    Kindly note that there will be some slowness on the first reply due to the public holiday, we will get back to you as soon as possible.



  • hareesh's avatar
    hareesh
    Icon for Frequent Contributor rankFrequent Contributor

    Hi,


    I am checking the driver files. please give me some time to solve this issue.




  • hareesh's avatar
    hareesh
    Icon for Frequent Contributor rankFrequent Contributor

    Hi,


    you are doing it in the Non-Volatile register. if you do that in that register those changes are permanent. because of that, we are not recommended.


    may I know why you are trying to configure the Non-Volatile register? any particular reason?


    Thank you,


  • Fabrizio2's avatar
    Fabrizio2
    Icon for New Contributor rankNew Contributor

    Hi Hareesh,

    thank you for the help, actually what I would like to do is:

    -See the flash refresh rate (should be something like 30Mhz)

    -Slow down the refresh rate of the flash to 30Mhz by modifying the dummy cycles in the flash , this is done by writing the nonvolatile register of the flash, but I don't know how to do it through the generic_quad_spi_controller2 driver controller2.

    Let me know, please.

    Thank you

    Best regards

    Fabrizio

  • hareesh's avatar
    hareesh
    Icon for Frequent Contributor rankFrequent Contributor

    Hi,


    if you configure the Volatile Configuration Register or Non-Volatile Configuration Register for the Number of dummy clock cycles, it generates some dummy clock cycles before command execution. it may cause some data loss. so we are not recommended to configure the Volatile Configuration Register or Non-Volatile Configuration Registers.


    To slow down the refresh rate please control the DCLOCK. for this follow the billow document.


    https://media-www.micron.com/-/media/client/global/documents/products/data-sheet/nor-flash/serial-nor/mt25q/die-rev-b/mt25q_qlkt_u_512_abb_0.pdf?rev=b259aadc3bea49ea8210a41c9ad58211


    Thank you,



    • FRava3's avatar
      FRava3
      Icon for New Contributor rankNew Contributor

      Hi Hareesh,

      So, this means that we cannot configure the dummy cycles of the flash using the controller2 driver, hence to configure the actual working clock frequency of the flash.

      In order to use flash we need to know the clock frequency we can use to drive it, so we must know how :

      -1 the dummy clock cycles setting .

      -2 If the flash is set in QuadOut Fast Read or Quad I/O fast read

      This is because the controller2 doesn't provide any information regarding the above .

  • hareesh's avatar
    hareesh
    Icon for Frequent Contributor rankFrequent Contributor

    Hi,

    sorry for delaying. actually, I was not able to see your last post. now it's fine. just give me the time and I will give you information about your query.


  • hareesh's avatar
    hareesh
    Icon for Frequent Contributor rankFrequent Contributor

    Hi,

    yes, we are not recommended to configure the dummy cycles.

    i am trying to get some more information related to your issue.


  • hareesh's avatar
    hareesh
    Icon for Frequent Contributor rankFrequent Contributor

    Hi,

    sorry for taking a long time. may I know the current status of your issue?


  • hareesh's avatar
    hareesh
    Icon for Frequent Contributor rankFrequent Contributor

    As we do not receive any response from you on the previous question/reply/answer that we have provided. Please login to ‘https://supporttickets.intel.com’, view details of the desire request, and post a feed/response within the next 15 days to allow me to continue to support you. After 15 days, this thread will be transitioned to community support. The community users will be able to help you on your follow-up questions.