Forum Discussion
Altera_Forum
Honored Contributor
17 years ago --- Quote Start --- 1. I make a reset and "nombre" should be "0101010101", instead it is "0000000". --- Quote End --- I think this is because your reset is connected to the "clrn()" of your DFF... What you can do is connect is to ground or Vcc depending on whether its active_low or active_high.... I guess its active_low by the looks of the way you have connected it... Also, your initialization is run only once, at the start of the program, so when you reset, the value of "nombre" gets cleared...
ff_sortida : DFF
port map (
d => nombre(4),
clk => clk,
clrn => not(reset),
prn => '1',
q => sortida
);and i'm just guessing here but --- Quote Start --- 2. It should add 1 to this variable at each rising edge clock. Instead sometimes it adds 3 and then subtracts 1. --- Quote End --- again has something to do with the way you are storing the value in your DFF... Hope it sheds some light on your query... Regards, YashD...