Forum Discussion
4 Replies
- Altera_Forum
Honored Contributor
I'm guessing
data <= data_out when cs = '1' and oe = '1' and we = '0' else (others => 'Z'); I don't personally speak Verilog but I'm guessing that the gist is: when the boolean expression "cs and oe and not we" is 1, assign data_out to data otherwise tri-state data. I hope that's nough to make sense of the VHDL above anyway. - Altera_Forum
Honored Contributor
THanks Batflink! It should be it.
- Altera_Forum
Honored Contributor
Sorry I should have said that the above only applies if you are trying to construct a stand-alone concurrent statement. If this is a line in a process then you need to use an "if" clause, i.e:
process (clk) begin if rising_edge (clk) then if (cs = '1' and oe = '1' and we = '0' ) then data <= data_out; else data <= (others => 'Z'); end if; end if; end process; - Altera_Forum
Honored Contributor
--- Quote Start --- I should have said that the above only applies if you are trying to construct a stand-alone concurrent statement --- Quote End --- That's the same with Verilog assign. It doesn't work in an always block.