Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Should i use wire type under inout port?

Status
Not open for further replies.

u24c02

Advanced Member level 1
Joined
May 8, 2012
Messages
404
Helped
2
Reputation
4
Reaction score
2
Trophy points
1,298
Activity points
4,101
Hi

I trying to connent with instance module in my top module in verilog.
Thier's instance have inout port. Then i use "reg" type connent to that port.
So ncverilog's result is port connections to inout ports must be collapsible, they must be nets.
But i can understand why it's error?

Should i use net type to connect with inout port?
 

You can't connect 'reg' with inout port in verilog. This is done because 'reg' can't be driven any way except procedural assignment.

If you really need connect this 'reg' to inout (ex., inout will be always in 'input' mode), you can use something like this:
Code:
...
reg in_reg;
wire in_wire;
assign in_wire = in_reg;
...
.inout_port(in_wire),
...
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top