摘要: 1.sim module top_module ( input a, input b, output q );// assign q = a & b; // Fix me endmodule 2.circuit2 module top_module ( input a, input b, input 阅读全文
posted @ 2021-04-04 15:13 黑衣の甘铃儿 阅读(223) 评论(0) 推荐(0)
摘要: Python编程之数据类型 数字与字符串类型 .类型的概念:类型是编程语言对数据类型的一种划分,python语言的类型:数据类型,字符串类型,元组类型,列表类型,字典类型,文件类型 数字类型 python共包括三种数据类型:整数类型,浮点数类型,复数类型 整数类型: python中整数没有取值范围的 阅读全文
posted @ 2021-04-04 11:39 黑衣の甘铃儿 阅读(354) 评论(0) 推荐(0)
摘要: turtle库的简要解析 关于turtle库的应用,可能还是比较模糊,这里做一些补充的解析和说明。 turtle库画布的建立 turtle.setup(wide, height, startx, starty) 后面两个参数是可选项。 正如参数意思,前者是新建画布的宽与高,后者是新建画布左上角在屏幕 阅读全文
posted @ 2021-04-03 16:52 黑衣の甘铃儿 阅读(557) 评论(0) 推荐(0)
摘要: 1.Mux module top_module ( input sel, input [7:0] a, input [7:0] b, output[7:0]out ); assign out = (sel)? a : b; endmodule 这里的bug主要有两个,一是out的位宽不匹配,第二是s 阅读全文
posted @ 2021-04-03 14:34 黑衣の甘铃儿 阅读(260) 评论(0) 推荐(0)
摘要: module top_module ( input clk, input reset, output [9:0] q); always@(posedge clk) begin if(reset) q <= 10'b0; else begin if(q == 10'd999) q <= 10'b0; 阅读全文
posted @ 2021-04-03 11:34 黑衣の甘铃儿 阅读(225) 评论(0) 推荐(0)
摘要: 1.Simple FSM module top_module( input clk, input areset, // Asynchronous reset to state B input in, output out);// parameter A=1'b0, B=1'b1; reg state 阅读全文
posted @ 2021-03-30 23:37 黑衣の甘铃儿 阅读(563) 评论(0) 推荐(0)
摘要: 1.Shift4 module top_module( input clk, input areset, // async active-high reset to zero input load, input ena, input [3:0] data, output reg [3:0] q); 阅读全文
posted @ 2021-03-27 15:59 黑衣の甘铃儿 阅读(313) 评论(0) 推荐(0)
摘要: 1.Count15 module top_module ( input clk, input reset, // Synchronous active-high reset output [3:0] q); always@(posedge clk) begin if(reset) q <= 4'b0 阅读全文
posted @ 2021-03-26 20:57 黑衣の甘铃儿 阅读(124) 评论(0) 推荐(0)
摘要: 1.DFF module top_module ( input clk, // Clocks are used in sequential circuits input d, output reg q );// // Use a clocked always block // copy d to q 阅读全文
posted @ 2021-03-25 20:04 黑衣の甘铃儿 阅读(77) 评论(0) 推荐(0)
摘要: 1.Kmap1 module top_module( input a, input b, input c, output out ); assign out = ~((~a)&(~b)&(~c)); endmodule 2.Kmap2 依然是卡诺图化简,观察零少还是一少去化简可能方便一些。 modu 阅读全文
posted @ 2021-03-25 15:35 黑衣の甘铃儿 阅读(158) 评论(0) 推荐(0)