Programmable Devices
CPLDs, FPGAs, SoC FPGAs, Configuration, and Transceivers
Announcements
FPGA community forums and blogs on community.intel.com are migrating to the new Altera Community and are read-only. For urgent support needs during this transition, please visit the FPGA Design Resources page or contact an Altera Authorized Distributor.
21615 Discussions

Correct use of reset input of a FF. VHDL

Altera_Forum
Honored Contributor II
2,183 Views

Hello, 

 

In my design I will process an image. 

 

In part of my hardware I need to RESET some FLIP FLOPS when FVAL(frame valid) arrives. 

 

Is bad if I use the signal FVAL directly connected to the reset input of the Flip FLop? 

 

Please look the attached file. 

 

If I give reset directly with the FVAL, it will use less resources, but I do not know if it is bad. 

 

Or the reset must be always connected to the global reset. 

 

Sorry for the dummy question. 

 

Thanks.
0 Kudos
2 Replies
Altera_Forum
Honored Contributor II
1,291 Views

It's safer to use a synchronous reset instead of an asynchronous one like you are proposing. if FVAL signal is glitch free, it could work, however, i guess FVAL is synchronous to master clock and is preferable adding a synchronous reset signal to your hardware.

0 Kudos
Altera_Forum
Honored Contributor II
1,291 Views

Selecting between async or sync reset is not a trivial issue. 

 

You need async reset at power-up, or when you have no clock yet, or when you can't afford the pipeline cycle (sync reset would reset the flip-flop in the next cycle, async would reset on "this" one). 

 

In either case you should synchronize the reset signal to the flip-flop clock.
0 Kudos
Reply