Forum Discussion

Altera_Forum's avatar
Altera_Forum
Icon for Honored Contributor rankHonored Contributor
20 years ago

How to reset the user logic ?

Hi, I use QuartusII 4.0, Nios 3.1, and Stratix1S10.

I write a user logic circuit, and this circuit need to do some calculations repeated.

That means I use it in a loop(in software).

I hope to know after the circuit calculate once, how do I reset it ?

I means how do I clear all singnals in it.

There are some reset signals in my HDL code design, and how do I use it ??

Does anybody know it ?

Thanks a lot. http://forum.niosforum.com/work2/style_emoticons/<#EMO_DIR#>/huh.gif

4 Replies

  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    Hi pipiwau,

    I think there are various ways to do it.

    For example if your peripheral has some registers, u can use one of these to reset the logic: id est you write first all zeros (for example) this register and this event resets all your logic.

    Otherwise you could use an export reset signal controlled by CPU, for example through an output PIO...
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    Soin, thanks for ur suggestion.

    Because there is an accumulator in my circuit, I think it is impossible to write a value, like zero, to clear the result calculated by the accumulator.

    And I use the circuit in a loop (in software), that means I need use the circuit again and again in the loop.

    Therefore, I can not use an export reset, like PIO, to reset or clear the result.

    Hence I hope to know if there are some methods to clear the result of accumulator just at the time of the circuit finishing the calculation once.

    That means if there are 20 times calculation in the software loop, I may need 20 times reset of my circuit.

    If I say something wrong, please tells me.

    Anyway, thanks a lot. http://forum.niosforum.com/work2/style_emoticons/<#EMO_DIR#>/smile.gif
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    Hi pipiwau,

    I don&#39;t understand why u can&#39;t use an export PIO again and again in the loop to reset your logic: for example if your reset signal is active low you put the output PIO low at the beginning of the loop and set it high after a defined time, then you do the calculation. Why not?