如何在vhdl中将信号延迟几个周期
如何在VHDL中将信号延迟给定的周期数? 循环数作为通用值给出。
还有其他选择吗
process(CLK) is
begin
if rising_edge(CLK) then
a_q <= a;
a_q_q <= a_q;
a_q_q_q <= a_q_q;
-- etc
end if;
end process;
?
How to delay signal for a given number of cycles in VHDL?
Number of cycles is given as a generic.
Any other options instead of
process(CLK) is
begin
if rising_edge(CLK) then
a_q <= a;
a_q_q <= a_q;
a_q_q_q <= a_q_q;
-- etc
end if;
end process;
?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
创建适当类型信号的一维数组(我们称之为
a_store
),数组长度与周期数相关。这可能意味着您必须为数组创建一个新类型,除非已经有一个可以使用的向量类型:例如。std_logic_vector
或integer_vector
(后者仅在 VHDL-2008 中为标准)。然后沿着每个刻度打乱数组:
Create an 1-d array (let's call it
a_store
) of the appropriate type of signal with the length of the array related to the number of cycles. This may mean you have to create a new type for the array unless there's already a vector type you can use: eg.std_logic_vector
orinteger_vector
(the latter is standard only in VHDL-2008).Then shuffle the array along each tick: