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

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

手机号码,快捷登录

手机号码,快捷登录

找回密码

  登录   注册  

快捷导航
搜帖子
查看: 2070|回复: 4

[求助] 请教各位,我用synplify做综合,想加入自己的库文件,应该如何操作?

[复制链接]
发表于 2016-6-4 18:23:33 | 显示全部楼层 |阅读模式

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

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

x
请教各位,我用synplify做综合,想加入自己的库文件,应该如何操作?
直接 add file, 把自己的库文件 my_stupid_lib.vhd加入,是不行的,  synplify找不到



library ieee;
use ieee.std_logic_1164.all;
use ieee.numeric_std.all;
library my_stupid_lib;
use my_stupid_lib.components.all;
 楼主| 发表于 2016-6-4 18:29:27 | 显示全部楼层
这是自定义的库,my_stupid_lib.vhd

library ieee;
use ieee.std_logic_1164.all;
entity prim_dff is
    port (q : out std_logic;
          d : in std_logic;
          clk : in std_logic;
          r : in std_logic := '0';
          s : in std_logic := '0');
end prim_dff;

architecture beh of prim_dff is
begin
    ff : process (clk, r, s)
    begin
        if r = '1' then
            q <= '0';
        elsif s = '1' then
            q <= '1';
        elsif rising_edge(clk) then
            q <= d;
        end if;
    end process ff;
end beh;



library ieee;
use ieee.std_logic_1164.all;
package components is
   
    component prim_dff
        port (q : out std_logic;
              d : in std_logic;
              clk : in std_logic;
              r : in std_logic := '0';
              s : in std_logic := '0');
    end component;
       
end components;
 楼主| 发表于 2016-6-4 18:41:08 | 显示全部楼层
@W:CD645 : mytry.vhd(6) | Ignoring undefined library my_stupid_lib
@W:CD642 : mytry.vhd(7) | Ignoring use clause - library my_stupid_lib not found ...
@E:CD213 :  mhtry.vhd(26) | Undefined identifier

这是报错
 楼主| 发表于 2016-6-4 18:44:38 | 显示全部楼层
这是写的代码

报错没有发现 prim_dff, 说明用户库没有被引用


library ieee;
use ieee.std_logic_1164.all;
use ieee.numeric_std.all;
library my_stupid_lib;
use my_stupid_lib.components.all;

entity S_DFF is
port(
Q :  out std_logic;
D :  in std_logic;
CLK :  in std_logic;
CLRN :  in std_logic;
PRN :  in std_logic);
end S_DFF;

architecture beh of DDFF is
begin

Q_Z11: prim_dff port map (Q, D, CLK, CLRN, PRN);

end beh;
 楼主| 发表于 2020-1-19 14:44:00 | 显示全部楼层
synplify 好用,但是对于库文件怎么加入,总是没有头绪。
您需要登录后才可以回帖 登录 | 注册

本版积分规则

关闭

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

×

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

GMT+8, 2024-4-25 23:48 , Processed in 0.025562 second(s), 10 queries , Gzip On, Redis On.

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