HDLbits——Lfsr32
//Build a 32-bit Galois LFSR with taps at bit positions 32, 22, 2, and 1.
草图

verilog描述
module top_module(
input clk,
input reset, // Active-high synchronous reset to 32'h1
output reg [31:0] q
);
always @(posedge clk) begin
if(reset)begin
q <= 32'h1;
end
else begin
q <= {1'b0^q[0],q[31:23],q[22]^q[0],q[21:3],q[2]^q[0],q[1]^q[0]};
end
end
endmodule
vivado下的RTL原理图:

quartus下的RTL原理图:采用大量选择器

HDLbits——Lfsr32的更多相关文章
- 学会使用Hdlbits网页版Verilog代码仿真验证平台
给大家推荐一款网页版的 Verilog代码编辑仿真验证平台,这个平台是国外的一家开源FPGA学习网站,通过“https://hdlbits.01xz.net/wiki/Main_Page” 地址链接进 ...
- HDLBits答案——Circuits
1 Combinational Logic 1.1 Basic Gates 1.1.1 Exams/m2014 q4h module top_module ( input in, output out ...
- HDLBits答案——Verification: Writing Testbenches
1 clock module top_module ( ); reg clk; dut U1(.clk(clk)); initial begin clk = 0; end always begin # ...
- HDLBits答案——Verification: Reading Simulations
1 Finding bugs in code 1.1 Bugs mux2 module top_module ( input sel, input [7:0] a, input [7:0] b, ou ...
- HDLBits答案——Verilog Language
Verilog Language 1 Basics 1.1 Wire module top_module( input in, output out ); assign out = in; endmo ...
- HDLBits答案——Getting started
Getting started 1 Step one module top_module( output one ); // Insert your code here assign one = 1' ...
- verilog常见错误列表
Error/Warning 来源:https://hdlbits.01xz.net/wiki/ 题目: 1.Quartus Warning 10235: Warning (): Verilog HDL ...
- Verilog HDL
https://wenku.baidu.com/view/9943b7acf524ccbff1218463.html https://hdlbits.01xz.net/wiki/Main_Page h ...
- Verilog设计技巧实例及实现
Verilog设计技巧实例及实现 1 引言 最近在刷HDLBits的过程中学习了一些Verilog的设计技巧,在这里予以整理.部分操作可能降低代码的可读性和Debug的难度,请大家根据实际情况进行使用 ...
- 入行数字IC验证的一些建议
0x00 首先,推荐你看两本书,<"胡"说IC菜鸟工程师完美进阶>(pdf版本就行)本书介绍整个流程都有哪些岗位,充分了解IC行业的职业发展方向.<SoC设计方法 ...
随机推荐
- RDD编程练习
一.filter,map,flatmap练习: 1.读文本文件生成RDD lines 2.将一行一行的文本分割成单词 words 3.全部转换为小写 4.去掉长度小于3的单词 5.去掉停用词 6.练习 ...
- 区块链leveldb数据库安装
一.首先,需要在电脑上安装boost库. 下载地址在这里,下载压缩包之后解压,Index of main/release/1.79.0/source. 解压完成后在解压好的文件夹里面进入cmd,之后运 ...
- VUE学习-mixin混入
mixin混入 混入 (mixin) 提供了一种非常灵活的方式,来分发 Vue 组件中的可复用功能. 组件式混入 // 定义一个混入对象 var myMixin = { created: functi ...
- 蓝牙mesh组网实践(厂商透传模型介绍)
目录 CH582的官方EVT中,除了代理节点例程和天猫精灵例程外都提供了厂商定义的透传模型. 模型位于蓝牙mesh网络协议中的最上层,负责标准化用户应用场景的实例,比如说开关模型.亮度模型.风速模型. ...
- Centos 7.9 部署Kubernetes集群 (基于containerd 运行时)
前言 当Kubernetes社区宣布1.20版本之后会逐步弃用 dockershim ,当时也有很多自媒体在宣 传Kubernetes弃用Docker.其实,我觉得这是一种误导,也许仅仅是为了蹭热度. ...
- 靶场练习2:cloudantvirus
靶场链接 https://www.vulnhub.com/entry/boredhackerblog-cloud-av,453/ 信息收集 练习1用了arp-scan,这种工具有可能会被防火墙流量监测 ...
- Java程序(数组扩容的尝试)
import java.util.Scanner; public class ArrayAdd { public static void main(String[] args) { int arr[] ...
- react native 第三方富文本编辑器 wxik/react-native-rich-editor(在移动端使用)
//更新2021年8月23日 (1)wxik/react-native-rich-editor 个人认为功能比较全,推荐使用 关于使用的案例,官网上有,我直接粘贴我遇到的几个问题 1. 软键盘弹出时 ...
- vue.cli的安装配置
关于旧版本 Vue CLI 的包名称由 vue-cli 改成了 @vue/cli. 如果你已经全局安装了旧版本的 vue-cli(1.x 或 2.x),你需要先通过 npm uninstall vue ...
- 26_自定义Loader
自定义Loader loader就是对模块的源代码进行处理(转换),如css-loader.style-loader等 在上一篇的源代码中我们已经知道了loader是在runLoaders才会去使用l ...