赛灵思
直播中

黄飞高

7年用户 231经验值
私信 关注
[问答]

最大频率太低

你好
我是FPGA项目的初学者,我做了一个项目,但是没有用。
合成过程以最高频率结束:20 MHZ,我的项目需要64 MHZ。
所以我用2个计数器和2个DCM来降低项目,但问题仍然存在。
任何人都可以解释原因吗?
我正在使用斯巴达3E。
它遵循我的代码:
核心
--------------------------------------------------
-------------------------------- library IEEE;使用IEEE.STD_LOGIC_1164.ALL;使用IEEE.STD_LOGIC_ARITH.ALL;使用
IEEE.STD_LOGIC_UNSIGNED.ALL;
----如果在此code.library UNISIM中实例化----任何Xilinx原语,则取消注释以下库声明;使用UNISIM.VComponents.all;
实体核心是端口(clk:在STD_LOGIC中; rst:在std_logic中; led1:输出STD_LOGIC; led2:输出STD_LOGIC);结束核心;
架构核心的行为是
COMPONENT low_dcmPORT(CLKIN_IN:IN std_logic; RST_IN:IN std_logic; CLKDV_OUT:OUT std_logic; CLKIN_IBUFG_OUT:OUT std_logic; CLK0_OUT:OUT std_logic; LOCKED_OUT:OUT std_logic); END COMPONENT;
COMPONENT core_dcmPORT(CLKIN_IN:IN std_logic; RST_IN:IN std_logic; CLKFX_OUT:OUT std_logic; LOCKED_OUT:OUT std_logic); END COMPONENT;
COMPONENT counterPORT(clk:IN std_logic; saida:OUT std_logic); END COMPONENT;
signal reset_dcm,reset_locked,low_dcm_locked:std_logic; signal clock_6m,clock_4m,clk4mhz,clk_in:std_logic; signal clkin_ibufg,clock_64m,core_dcm_locked,mclk:std_logic;
开始
reset_dcm
Inst_low_dcm:low_dcm PORT MAP(CLKIN_IN => clk,RST_IN => reset_dcm,CLKDV_OUT => clock_4m,CLKIN_IBUFG_OUT => clkin_ibufg,CLK0_OUT => clock_6m,LOCKED_OUT => low_dcm_locked);
Inst_core_dcm:core_dcm PORT MAP(CLKIN_IN => clkin_ibufg,RST_IN => reset_dcm,CLKFX_OUT => clock_64m,LOCKED_OUT => core_dcm_locked);
Inst_counter1:计数器端口映射(clk => clock_4m,saida => led1);
Inst_counter2:计数器端口映射(clk => clock_64m,saida => led2);
结束行为;
柜台
库IEEE;使用IEEE.STD_LOGIC_1164.ALL;使用IEEE.STD_LOGIC_ARITH.ALL;使用IEEE.STD_LOGIC_UNSIGNED.ALL;
----如果在此代码中实例化----任何Xilinx原语,则取消注释以下库声明.-- library UNISIM;  - 使用UNISIM.VComponents.all;
实体计数器是端口(clk:在STD_LOGIC中;表示:输出STD_LOGIC);结束计数器;
建筑的行为是
信号计数:std_logic_vector(23 downto 0);
开始
process(clk)beginif clk ='0'和clk'event thencount end if if; end process;
说最终行为;
合成结果:
时间概要:---------------速度等级:-4
最小周期:50.187ns(最大频率:19.926MHz)时钟前的最小输入到达时间:未找到路径时钟后的最大输出所需时间:4.310ns最大组合路径延迟:未找到路径
我发现当我评论CORE_DCM组件和实例化时,以及COUNTER2实例化项目运行时:
时间概要:---------------速度等级:-4
最小周期:3.137ns(最大频率:318.810MHz)时钟前的最小输入到达时间:未找到路径时钟后的最大输出所需时间:4.310ns最大组合路径延迟:未找到路径
非常感谢。

以上来自于谷歌翻译


以下为原文

Hi

I'm a beginner in fpga projects and I have made a project, but it didn't work. The synthesize process ends with maximum frequency very low: 20 MHZ and my project need 64 MHZ. So I made a project lower with 2 counters and 2 DCMs, but problem persists still. Can anybody explain why?
I'm using Spartan 3E.
It follows my code:


THE CORE

----------------------------------------------------------------------------------
library IEEE;
use IEEE.STD_LOGIC_1164.ALL;
use IEEE.STD_LOGIC_ARITH.ALL;
use IEEE.STD_LOGIC_UNSIGNED.ALL;
---- Uncomment the following library declaration if instantiating
---- any Xilinx primitives in this code.
library UNISIM;
use UNISIM.VComponents.all;
entity core is
    Port ( clk : in  STD_LOGIC;
     rst : in std_logic;
           led1 : out  STD_LOGIC;
           led2 : out  STD_LOGIC);
end core;
architecture Behavioral of core is

COMPONENT low_dcm
PORT(
  CLKIN_IN : IN std_logic;
  RST_IN : IN std_logic;         
  CLKDV_OUT : OUT std_logic;
  CLKIN_IBUFG_OUT : OUT std_logic;
  CLK0_OUT : OUT std_logic;
  LOCKED_OUT : OUT std_logic
  );
END COMPONENT;

COMPONENT core_dcm
PORT(
  CLKIN_IN : IN std_logic;
  RST_IN : IN std_logic;         
  CLKFX_OUT : OUT std_logic;
  LOCKED_OUT : OUT std_logic
  );
END COMPONENT;

COMPONENT counter
PORT(
  clk : IN std_logic;         
  saida : OUT std_logic
  );
END COMPONENT;
signal reset_dcm, reset_locked, low_dcm_locked : std_logic;
signal clock_6m, clock_4m, clk4mhz, clk_in : std_logic;
signal clkin_ibufg, clock_64m, core_dcm_locked, mclk : std_logic;

begin
reset_dcm <= '1' when rst = '1' else '0';

Inst_low_dcm: low_dcm PORT MAP(
  CLKIN_IN => clk,
  RST_IN => reset_dcm,
  CLKDV_OUT => clock_4m,
  CLKIN_IBUFG_OUT => clkin_ibufg,
  CLK0_OUT => clock_6m,
  LOCKED_OUT => low_dcm_locked
);

Inst_core_dcm: core_dcm PORT MAP(
  CLKIN_IN => clkin_ibufg,
  RST_IN => reset_dcm,
  CLKFX_OUT => clock_64m,
  LOCKED_OUT => core_dcm_locked
);

Inst_counter1: counter PORT MAP(
  clk => clock_4m,
  saida => led1
);

Inst_counter2: counter PORT MAP(
  clk => clock_64m,
  saida => led2
);

end Behavioral;


THE COUNTER

library IEEE;
use IEEE.STD_LOGIC_1164.ALL;
use IEEE.STD_LOGIC_ARITH.ALL;
use IEEE.STD_LOGIC_UNSIGNED.ALL;
---- Uncomment the following library declaration if instantiating
---- any Xilinx primitives in this code.
--library UNISIM;
--use UNISIM.VComponents.all;
entity counter is
    Port ( clk : in  STD_LOGIC;
           saida : out  STD_LOGIC);
end counter;
architecture Behavioral of counter is
signal count : std_logic_vector (23 downto 0);
begin
  process (clk)
  begin
   if clk = '0' and clk'event then
    count <= count + 1;
   end if;
  end process;
  saida <= count(23);
end Behavioral;




SYNTHESIZE RESULTS:


Timing Summary:
---------------
Speed Grade: -4
   Minimum period: 50.187ns (Maximum Frequency: 19.926MHz)
   Minimum input arrival time before clock: No path found
   Maximum output required time after clock: 4.310ns
   Maximum combinational path delay: No path found


I discovered that when I comment CORE_DCM component and instantiation, and COUNTER2 instantiation the project run at:

Timing Summary:
---------------
Speed Grade: -4
   Minimum period: 3.137ns (Maximum Frequency: 318.810MHz)
   Minimum input arrival time before clock: No path found
   Maximum output required time after clock: 4.310ns
   Maximum combinational path delay: No path found


Thanks so much.

回帖(14)

潘晶燕

2019-5-17 11:43:15
p,
你是如何限制你的设计的?
在论坛页面上查看我的博客,了解如何限制时间限制。
我是第5部分中的第3部分,但您已经讨论过所需要的内容。
这些工具只会像你告诉他们一样努力。
如果没有周期时间限制,它将在放置和路由方面做最少量的工作,然后说“我已经完成了”。
你得到的就是你所要求的:一个运行的解决方案(功能)。
如果你想拥有速度,你需要问工具给你速度。
如果适当约束,24位同步计数器将运行得更快。
添加或删除内容时为什么会发生变化非常简单:由于您没有要求任何性能,因此在设计中进行小的更改时,性能会随机变化。
Austin Lesea主要工程师Xilinx San Jose

以上来自于谷歌翻译


以下为原文

p,
 
How are you constraining your design?
 
See my blog on the forums page on how touse timing constraints.  I am on part 3 of 5, but what you need has already been discussed.
 
The tools will only work as hard as you tell them to.  With no period timing constraint, it will do the least amount of work on placement and routing, and then say "I am all done."
 
What you get is what you asked for: a solution that runs (functions).
 
If you wish to have speed, you need to ask the tools to give you than speed.
 
A 24 bit synchronous counter, if properly constrained, will run much faster.
 
Why it changes when you add or drop something is very simple:  since you did not ask for any performance, performance will vary at random when small changes are made in the design.
 
 
 
Austin Lesea
Principal Engineer
Xilinx San Jose
举报

杨天舒

2019-5-17 12:01:07
受到警告
提示: 作者被禁止或删除 内容自动屏蔽
举报

杨天舒

2019-5-17 12:17:22
受到警告
提示: 作者被禁止或删除 内容自动屏蔽
举报

杨天舒

2019-5-17 12:23:07
受到警告
提示: 作者被禁止或删除 内容自动屏蔽
举报

更多回帖

发帖
×
20
完善资料,
赚取积分