Verilog Variables
wire
- variable used to connect components together
reg
- variable that saves a value as part of a behavioral description
- usually corresponds to a wire in the circuit
- is NOT necessarily a register in the circuit
The rule:
- Declare a variable as a reg if it is the target of an assignment statement
- Continuous assign doesn’t count (confusing isn’t it?)