在线咨询
eetop公众号 创芯大讲堂 创芯人才网
切换到宽版

EETOP 创芯网论坛 (原名:电子顶级开发网)

手机号码,快捷登录

手机号码,快捷登录

找回密码

  登录   注册  

快捷导航
搜帖子
查看: 3120|回复: 8

[资料] NC使用技巧

[复制链接]
发表于 2010-8-29 10:03:43 | 显示全部楼层 |阅读模式

马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。

您需要 登录 才可以下载或查看,没有账号?注册

x
NC使用技巧

NC-verilog经验.txt

2.89 KB, 下载次数: 31 , 下载积分: 资产 -2 信元, 下载支出 2 信元

发表于 2010-8-29 15:31:16 | 显示全部楼层
谢谢啊
发表于 2010-8-29 18:44:59 | 显示全部楼层
ding............
发表于 2010-8-29 20:46:38 | 显示全部楼层
资料不错,谢谢分享!
发表于 2010-9-12 00:26:20 | 显示全部楼层
Ncverilog 的一些经验
推荐1.Verilog和Ncverilog命令使用库文件或库目录
   ex). ncverilog -f run.f -v lib/lib.v -y lib2 +libext+.v  //一般编译文件在run.f中, 库文件在lib.v中,lib2目录中的.v文件系统自动搜索
          使用库文件或库目录,只编译需要的模块而不必全部编译
2.Verilog Testbench信号记录的系统任务:
  1). SHM数据库可以记录在设计仿真过程中信号的变化. 它只在probes有效的时间内记录你set probe on的信号的变化.
       ex). $shm_open("waves.shm");  //打开波形数据库
              $shm_probe(top, "AS"); // set probe on "top",
                       第二个参数:  A --  signals of the specific  scrope   
                                        S -- Ports of the specified scope and below, excluding library cells
                                        C -- Ports of the specified scope and below, including library cells
                                        AS -- Signals of the specified scope and below, excluding library cells
                                        AC -- Signals of the specified scope and below, including library cells
                                        还有一个 M ,表示当前scope的memories, 可以跟上面的结合使用, "AM" "AMS" "AMC"
                                        什么都不加表示当前scope的ports;
              $shm_close    //关闭数据库
   2). VCD数据库也可以记录在设计仿真过程中信号的变化. 它只记录你选择的信号的变化.
         ex). $dumpfile("filename");    //打开数据库
               $dumpvars(1, top.u1);   //scope = top.u1, depth = 1
                       第一个参数表示深度, 为0时记录所有深度; 第二个参数表示scope,省略时表当前的scope.
                       $dumpvars; //depth = all scope = all
                       $dumpvars(0); //depth = all scope = current
                       $dumpvars(1, top.u1); //depth = 1 scope = top.u1
                $dumpoff      //暂停记录数据改变,信号变化不写入库文件中
                $dumpon      //重新恢复记录
    3). Debussy fsdb数据库也可以记录信号的变化,它的优势是可以跟debussy结合,方便调试.
         如果要在ncverilog仿真时,记录信号, 首先要设置debussy:
         a. setenv LD_LIBRARY_PATH LD_LIBRARY_PATH
            (path for debpli.so file (/share/PLI/nc_xl//nc_loadpli1))
         b. while invoking ncverilog use the +ncloadpli1 option.
              ncverilog -f run.f +debug +ncloadpli1=debpli:deb_PLIPtr
       fsdb数据库文件的记录方法,是使用$fsdbDumpfile和$fsdbDumpvars系统函数,使用方法参见VCD
    注意: 在用ncverilog的时候,为了正确地记录波形,要使用参数: "+access+rw", 否则没有读写权限
3. ncverilog编译的顺序:  ncverilog file1 file2 ....
   有时候这些文件存在依存关系,如在file2中要用到在file1中定义的变量,这时候就要注意其编译的顺序是从后到前,就先编译file2然后才是file2.
4. 信号的强制赋值force
   首先, force语句只能在过程语句中出现,即要在initial 或者 always 中间. 去除force 用 release 语句.
          initial begin     force sig1 = 1'b1; ... ; release sig1; end
   force可以对wire赋值,这时整个net都被赋值; 也可以对reg赋值.
发表于 2010-9-13 03:46:09 | 显示全部楼层
谢了!
发表于 2011-7-11 14:07:05 | 显示全部楼层
谢谢了
发表于 2011-7-11 17:16:57 | 显示全部楼层
垃圾,说和没说一个样
发表于 2011-7-11 17:43:07 | 显示全部楼层
dddddddddd
您需要登录后才可以回帖 登录 | 注册

本版积分规则

关闭

站长推荐 上一条 /1 下一条

X

小黑屋| 手机版| 关于我们| 联系我们| 隐私声明| EETOP 创芯网
( 京ICP备:10050787号 京公网安备:11010502037710 )

GMT+8, 2025-7-2 11:24 , Processed in 0.030124 second(s), 12 queries , Gzip On, MemCached On.

eetop公众号 创芯大讲堂 创芯人才网
快速回复 返回顶部 返回列表