Forum Discussion
Altera_Forum
Honored Contributor
8 years agoHi, here is the code that works fine by it self:
if (condition_1) begin
signal <= '1';
end
if (condition_2) begin
signal <= '0';
end
assign output <= signal;
The conditions are met both when simulating as a stand alone unit and embedded, the problem is, when embedded on a test bench, even though the conditions are met, the output doesn't toggle, this fix made it work:
if (condition_1) begin
signal <= '1';
other_signal <= '1';
end
if (condition_2) begin
signal <= '0';
other_signal <= '0';
end
assign output <= other_signal;