【问题标题】:Signal <signal> cannot be synthesized, bad synchronous description信号 <signal> 无法合成,同步描述错误
【发布时间】:2017-01-05 19:41:57
【问题描述】:

我正在尝试实现一个组件,该组件接收一个基本时钟输入并根据该方案输出一个模式:

我遇到了这个错误,我已经尝试按照 stackoverflow 的各种建议以多种方式修复它,但没有...

ERROR:Xst:827 - “E:/Progetti/nuovi/Clock_generator/CG_ex_3/clock_ex3.vhd”第 34 行:信号 check_0 无法合成,错误的同步描述。当前软件版本不支持您用于描述同步元素(寄存器、内存等)的描述样式。

有时同样的错误是指pre_forma_clk

library IEEE;
use IEEE.STD_LOGIC_1164.ALL;

entity clock_ex3 is
    Port ( base_clk : in  STD_LOGIC;
           forma_clk : out  STD_LOGIC);
end clock_ex3;

architecture Behavioral of clock_ex3 is
    signal pre_forma_clk : std_logic := '0';
begin

forma_clk <= pre_forma_clk;

pattern_generator : process(base_clk)  --line 34

    variable check_0 : natural := 0;
    variable check_1 : natural := 0;
    variable check_2 : natural := 0;
    variable check_3 : natural := 0;

begin
    if (rising_edge(base_clk)) then
        check_0 := check_0 + 1;
        if (check_0 = 15) then
            pre_forma_clk <= not pre_forma_clk;
        end if;
    end if;

    if (falling_edge(base_clk) and check_0 >= 15) then
        check_1 := check_1 + 1;
        if (check_1 = 10) then
            pre_forma_clk <= not pre_forma_clk;
        end if;
    end if;

    if (falling_edge(base_clk) and check_1 >= 10) then
        check_2 := check_2 + 1;
        if (check_2 = 15) then
            pre_forma_clk <= not pre_forma_clk;
        end if;
    end if;

    if (rising_edge(base_clk) and check_2 >= 15) then
        check_3 := check_3 + 1;
        if (check_3 = 10) then
            pre_forma_clk <= not pre_forma_clk;
            check_0 := 0;
            check_1 := 0;
            check_2 := 0;
            check_3 := 0;
        end if;
    end if;

end process;

end Behavioral;

我已经尝试在不同的 IF 中分离 IF 条件... 感谢帮助

【问题讨论】:

    标签: vhdl


    【解决方案1】:

    here 你的问题得到了很好的回答。该问题与您的问题之间的区别在于,您的代码中的特定错误是您在一个进程中有多个 if (rising_edge(clk)) then 结构;一个符合合成条件的过程只能包含一个这种类型的边缘检测器。

    查看您的功能要求,我将使用两个独立的上升沿和下降沿计数器来实现这一点,每个计数器都有自己的进程,然后编写另一个进程来实现与这些计数器一起工作的状态机,以实现所需的状态转换和计数器重置.

    【讨论】:

      猜你喜欢
      • 2014-10-03
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2020-12-15
      相关资源
      最近更新 更多