集成电路技术分享

 找回密码
 我要注册

QQ登录

只需一步,快速开始

搜索
查看: 2036|回复: 0

异步FIFO疑问

[复制链接]
usb 发表于 2010-6-28 00:26:39 | 显示全部楼层 |阅读模式
module async(aempty_n, afull_n, wptr, rptr, wrst_n);
output aempty_n, afull_n;
input [3:0] wptr, rptr;
input wrst_n;
reg direction;
wire high = 1'b1;
wire dirset_n = ~((wptr[3]^rptr[2]) & ~(wptr[2]^rptr[3]));
wire dirclr_n = ~((~(wptr[3]^rptr[2])&(wptr[2]^rptr[3])) | ~wrst_n);
always @(posedge high or negedge dirset_n or negedge dirclr_n)
if (!dirclr_n)
direction <= 1'b0;
else if (!dirset_n)
direction <= 1'b1;
else
direction <= high;


assign aempty_n = ~((wptr == rptr) && !direction);
assign afull_n = ~((wptr == rptr) && direction);
endmodule

字符串 high 做什么用的?不理解
您需要登录后才可以回帖 登录 | 我要注册

本版积分规则

关闭

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

QQ|小黑屋|手机版|Archiver|集成电路技术分享 ( 京ICP备20003123号-1 )

GMT+8, 2024-4-29 06:22 , Processed in 0.063541 second(s), 23 queries .

Powered by Discuz! X3.4

© 2001-2023 Discuz! Team.

快速回复 返回顶部 返回列表