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.

question about how to use "`include" in verilog

Status
Not open for further replies.

satrap

Newbie level 1
Joined
Aug 31, 2007
Messages
1
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,290
I download uart16550 IP from opencore.org. In the core "`include" can be compiled normally, but when i include my own file the core could not compiled normally. when I remove the "`include" and move all design files to a list, they can be compiled normally. The tool what I use is modelsim. I meet these situation many times. I don't know the reason.
do anyone tell me.
thank you very much!
 

joe2moon

Full Member level 5
Joined
Apr 19, 2002
Messages
280
Helped
19
Reputation
38
Reaction score
7
Trophy points
1,298
Location
MOON
Activity points
3,731
Re: question about how to use "`include" in verilo

It's the same as used in C language.

Please pay attention to the "path" used by the include.

Without giving the correct directory path of the file, include cannot find the file.
 

aji_vlsi

Advanced Member level 2
Joined
Sep 10, 2004
Messages
646
Helped
85
Reputation
170
Reaction score
12
Trophy points
1,298
Location
Bangalore, India
Activity points
4,946
Re: question about how to use "`include" in verilo

satrap said:
I download uart16550 IP from opencore.org. In the core "`include" can be compiled normally, but when i include my own file the core could not compiled normally. when I remove the "`include" and move all design files to a list, they can be compiled normally. The tool what I use is modelsim. I meet these situation many times. I don't know the reason.
do anyone tell me.
thank you very much!

Use vlog +incidr+<Dir_Where_Your_Include_file_exists> file.v

HTH
Ajeetha, CVC
www.noveldv.com
 

carna

Newbie level 4
Joined
Aug 8, 2006
Messages
7
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,308
Also, you can use ncverilog +incdir+path
"path" is where the files you want to include is. If you have more than one paths, you can just type them together, with "+" between them.
 

cnspy

Full Member level 3
Joined
Sep 10, 2002
Messages
151
Helped
5
Reputation
10
Reaction score
1
Trophy points
1,298
Activity points
1,041
If I do not write "include" in RTL code. How the tools handle it? Such as modelsim/questa/synplify ?
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Top