2011年7月31日

1组合逻辑电路--基本门电路

摘要: 1.1基本门电路1.1.1结构化描述方式代码如下View Code 1 module logics 2 ( 3 input iA, 4 input iB, 5 output oAnd, 6 output oOr, 7 output oNot 8 ); 9 10 and and_inst(oAnd,iA,iB);11 or or_inst(oOr,iA,iB);12 not not_inst(oNot,iA);13 14 endmodule 最底层的是门级原语and or notRTL级视图testbench如下View Code 1 `timescale 1 ns/ 1 ns 2 module 阅读全文

posted @ 2011-07-31 22:02 万好好 阅读(683) 评论(0) 推荐(1) 编辑

ASCII与汉字编码方法

摘要: 一、基础知识内码:国标码规定,每个汉字(包括非汉字的一些符号)由2字节代码表示。每个字节的最高位为0,只使用低7位,而低7位的编码中又有34个适用于控制用的,这样每个字节只有27 - 34 = 94个编码用于汉字。2个字节就有94 94=8836个汉字编码。在表示一个汉字的2个字节中,高字节对应编码表中的行号,称为区号;低字节对应编码表中的列号,称为位号。 ASCII字符:1Byte表示一个字符。二、两种编码方法,见头文件GB1616.hView Code 1 // ------------------ 汉字字模的数据结构定义 ------------------------ // 2 str 阅读全文

posted @ 2011-07-31 16:04 万好好 阅读(5074) 评论(0) 推荐(0) 编辑

导航