四位BCD计数器verilog_verilog--计数器设计12-hour clock

本文记录了一位新手使用Verilog设计12小时制BCD计数器的过程,包括秒、分、小时的计数,其中小时计数需考虑AM/PM状态切换。设计中秒和分的计数器通过例化实现,小时计数部分单独处理,以适应12小时制的时间转换。
摘要由CSDN通过智能技术生成

题目来源于:

https://hdlbits.01xz.net/wiki/Count_clock​hdlbits.01xz.net

前言:

新手入门,以下内容主要记录学习过程,便于后期改正。新人对语法、结构理解还欠缺,欢迎指出。

进入正题:

题目描述:

Create a set of counters suitable for use as a 12-hour clock (with am/pm indicator). Your counters are clocked by a fast-running clk, with a pulse on ena whenever your clock should increment (i.e., once per second).

reset resets the clock to 12:00 AM. pm is 0 for AM and 1 for PM. hh,mm, and ss are two BCD(Binary-Coded Decimal) digits each for hours (01-12), minutes (00-59), and seconds (00-59). Reset has higher priority than enable, and can occur even when not enabled.

958191d9d2b61c1b71d4795ab846902c.png

大概意思:使用计数器设计一个12小时制的时钟。要求使用BCD,

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值