【温故而知新】【4】Verilog序列检测
seuchenrui@126.com
11/21/2015 2:21:04 PM
本次博客的内容是回顾状态机的的编写。状态机的经典描述方式为三段式描述。这三段分别为:
状态转移(时序逻辑)–> 状态变换条件(组合逻辑)–> 输出逻辑(组合逻辑或者时序逻辑)。
下文为一个序列检测的状态机代码,可持续检测序列“00100111”。
代码:
`timescale 1ns / 1ns
//
// Company:
// Engineer:
// seuchenrui@126.com
// Create Date:09:31:28 11/21/2015
// Design Name:
// Module Name:sequence_00100111
// Project Name:
// Target Devices:
// Tool versions:
// Description:
// this is the module for check sequence "00100111"
// Dependencies:
//
// Revision:
// Revision 0.01 - File Created
// Usage of asynchronous resets may negatively impact FPGA resources
// and timing. In general faster and smaller FPGA designs will
// result from not using asynchronous resets. Please refer to
// the Synthesis and Simulation Des