亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? part2.txt

?? Thomas課本中的verilog例子。Thomas的verilog在可編程期間領域很有名
?? TXT
?? 第 1 頁 / 共 2 頁
字號:
output go;
output [3:0] count;
reg go;
reg [3:0] count;
input done, err; 

initial begin
go = 0;
count = 0;
end

endmodule
Last modified:3/6/95, by Tom Martin

The files in this directory are for the 18-360 Intro. to CAD project 1.

Name Description
-------------------------------------------------------------------------
memory.v Verilog module for the 512 bytes of memory and the
memory bus controller.    Note that a useful feature
of memory.v is that the entire contents of the memory
can be displayed on the postive edge of 'debug'.  

correct0.v Verilog module for 10 sectors of a disk.  Uses the file
good.dat as input.  All 10 sectors of the disk are error
free.  

error0.v Verilog module for 10 sectors of a disk.  Uses the file
bad.dat as input.  Sectors 0, 1, 2 have errors in them;
sectors 3-9 are correct

simint.v Simulation interface module.  Used to start the simulation
and see when it is done.  This probably isn't
necessary--just have the top level of the design
connect to the go, sector count, done, and error
signals of Wait.  Contains the timescale directive
which sets the time units for the whole simulation.
simint.v should be the first module listed on the
command line in order to avoid compilation errors,
i.e.  verilog simint.v blah1.v blah2.v


Comments
----------------------------------------------------------------------------

3/3/95 Removed the timescale directives from memory.v,
correct0.v, and error0.v.  Simint.v now sets the 
time scale for the whole simulation (10ns/1ns).  
Modified the clock definition in correct0.v and error0.v
to account for the change in the time scale.

3/6/95 Simint.v modified so that count is a 4 bit number
instead of a 3 bit number.  Thanks to Edith and the Chinman
for pointing out that you can't count to 10 with 3
bits...

3/7/95  Memory.v modified so that the address bits could address
477 bytes of memory.  Variable a was changed from 8 bits
to 9 bits.

3/10/95 Replaced the protected versions of correct0.v, error0.v,
and memory.v with their unprotected source, so that the
Cadence debugger can be used with the files.
//  disk module with correct data
//  by Tom Martin, February 1995
//  for 18-360.

`define P 400 // period is 4 us...

module disk(idx, rddata);
output idx, rddata;


reg [7:0] disk[0:5119];  // the 10 sectors of the disk
reg idx, rddata;

integer sector, byte, bit;
reg [7:0] tmp;

initial begin
idx = 0;
rddata = 0;
$readmemh("good.dat", disk);  
end 

//  set up the clock in rddata
`protect
always begin
#(`P/8) rddata = 1;   // these will have to change later
#(`P/8) rddata = 0;   // to have some randomness
#(`P*0.75);
end
`endprotect

// set up idx
`protect
always begin
#(`P/8) idx = 1;
#(`P*8) idx = 0;
#(4087.875*`P) ;
end
`endprotect

// and put the data in rddata.
`protect
always begin
for (sector=0; sector < 10; sector = sector + 1 ) 
begin
for (byte=0; byte < 512; byte = byte + 1) 
begin
tmp = disk[sector*512 + byte];
for (bit = 0; bit < 8; bit = bit + 1)
begin
@(posedge rddata);
if ( tmp[bit] ) 
begin
#(`P/2);
rddata = 1;
#(`P/8);
rddata = 0; 
end
end
end
end
end
`endprotect
endmodule
//  disk module with correct data
//  by Tom Martin, February 1995
//  for 18-360.

//  this particular module has a clock with ramping jitter

`define P 400 // period is 4 us...

module disk(idx, rddata);
output idx, rddata;


reg [7:0] disk[0:5119];  // the 10 sectors of the disk
reg idx, rddata;

integer sector, byte, bit, z;
integer ramp, flag;

//  for testing random rddata clock
//  integer ave, count, max;

reg [7:0] tmp;
file://reg [3:0] ran;
file://reg [3:0] ran2;

initial begin
idx = 0;
rddata = 0;

// ave = 0 ;
// max = 0;
// count = 0;
ramp = 0;
flag = 1;
// z = 1;

$readmemh("good.dat", disk);  
// ran =  $random(z);

end 

//  set up the clock in rddata
`protect
always begin
#(`P/8) rddata = 1;   // these will have to change later
#(`P/8) rddata = 0;   // to have some randomness
#(`P*0.7 + ramp); // delay between 280 and 
     // 320 counts--2.8 and 3.2us
if (ramp == 40) 
flag = -1;
if (ramp == 0) 
flag = 1;
if (flag == 1)
ramp = ramp + 1;
else 
ramp = ramp - 1;
// ave = `P*0.7 +  ramp;
// $monitor($time,, ave);
end
`endprotect

// set up idx
`protect
always begin
#(`P/8) idx = 1;
#(`P*8) idx = 0;
#(4087.875*`P) ;  // pulses per sector = 4096
end
`endprotect

// and put the data in rddata.
`protect
always begin
for (sector=0; sector < 10; sector = sector + 1 ) 
begin
for (byte=0; byte < 512; byte = byte + 1) 
begin
tmp = disk[sector*512 + byte];
for (bit = 0; bit < 8; bit = bit + 1)
begin
@(posedge rddata);
if ( tmp[bit] ) 
begin
#(0.5*(`P*0.7 + ramp+ `P/8));
// need to change this delay later to account for randomness
rddata = 1;
#(`P/8);
rddata = 0; 
end
end
end
end
end
`endprotect
endmodule
//  disk module with correct data
//  by Tom Martin, February 1995
//  for 18-360.

`define P 400 // period is 4 us...

module disk(idx, rddata);
output idx, rddata;


reg [7:0] disk[0:5119];  // the 10 sectors of the disk
reg idx, rddata;

integer sector, byte, bit;
reg [7:0] tmp;

initial begin
idx = 0;
rddata = 0;
$readmemh("bad.dat", disk);  
end 

//  set up the clock in rddata
`protect
always begin
#(`P/8) rddata = 1;   // these will have to change later
#(`P/8) rddata = 0;   // to have some randomness
#(`P*0.75);
end
`endprotect

// set up idx
`protect
always begin
#(`P/8) idx = 1;
#(`P*8) idx = 0;
#(4087.875*`P) ;
end
`endprotect

// and put the data in rddata.
`protect
always begin
for (sector=0; sector < 10; sector = sector + 1 ) 
begin
for (byte=0; byte < 512; byte = byte + 1) 
begin
tmp = disk[sector*512 + byte];
for (bit = 0; bit < 8; bit = bit + 1)
begin
@(posedge rddata);
if ( tmp[bit] ) 
begin
#(`P/2);
rddata = 1;
#(`P/8);
rddata = 0; 
end
end
end
end
end
`endprotect
endmodule
//  memory.v  
//  by Tom Martin for 18-360, February 1995.
//  Models the memory bus controller and memory for
//  use with the floppy disk controller (Project 1)


//  bus clock is specified to be 8 MHz, or 125ns/cycle

module memory(clock, hrq, hack, memw, d, a);
parameter tProp = 1;

output clock, hack;
reg clock, hack;
input hrq, memw;

inout [7:0] d; 
inout [8:0] a;

reg debug;


reg [7:0] m[0:511];  file://512 bytes of memory

initial begin
clock = 0;
hack = 0;
debug = 0;
//  set memory all to 0?
end

//  the bus clock
always 
#6.25 clock = ~clock;
`protect
// the bus protocol
always begin
@(posedge clock);
if (hrq && ~hack)  begin
#tProp;
hack = 1;
end
else if (hrq && hack) begin 
if (~memw) begin
@(negedge clock); 
m[a] = d;
@(posedge clock);
if (~memw) 
  $display($time,,,"Memw high error");
end  
end
else if (~hrq && hack ) begin
#tProp;
hack = 0;
end
end
`endprotect
//  debug stuff--print contents of memory.
//  to print contents of memory, just set debug = 1...

integer count;

always begin
@(posedge debug);
for (count = 0; count < 512; count = count + 1)
begin
// $write( "%0x ", m[count]);
$write( "%c ", m[count]);
if (( (count+1) % 25) == 0)
$display;
end
$display;
end
endmodule
//  disk module with correct data
//  by Tom Martin, February 1995
//  for 18-360.

//  this particular module has a clock with jitter.

`define P 400 // period is 4 us...

module disk(idx, rddata);
output idx, rddata;


reg [7:0] disk[0:5119];  // the 10 sectors of the disk
reg idx, rddata;

integer sector, byte, bit, z;


//  for testing random rddata clock
integer ave, count, max;

reg [7:0] tmp;
reg [3:0] ran;
reg [3:0] ran2;

initial begin
idx = 0;
rddata = 0;

ave = 0 ;
max = 0;
count = 0;
// $monitor($time,,rddata);

z = 1;

$readmemh("good.dat", disk);  
ran =  $random(z);

end 

//  set up the clock in rddata
`protect
always begin
#(`P/8) rddata = 1;   // these will have to change later
#(`P/8) rddata = 0;   // to have some randomness
#(`P*0.7 + (40*ran)/15 ); // delay between 280 and 
     // 320 counts--2.8 and 3.2us
ave = `P*0.7 + (40*ran)/15 + `P/4;
// $display(ave);
ran = $random;
count = count + 1;
// if (ave > max) 
// max = ave;
// if (ave > 420) 
// $stop;
end
`endprotect

// set up idx
`protect
always begin
#(`P/8) idx = 1;
#(`P*8) idx = 0;
#(4087.875*`P) ;  // pulses per sector = 4096
end
`endprotect

// and put the data in rddata.
`protect
always begin
for (sector=0; sector < 10; sector = sector + 1 ) 
begin
for (byte=0; byte < 512; byte = byte + 1) 
begin
tmp = disk[sector*512 + byte];
for (bit = 0; bit < 8; bit = bit + 1)
begin
@(posedge rddata);
if ( tmp[bit] ) 
begin
ran2 = $random;
#(ave/2 - ave/40 + (ave/20)*ran2/15);
rddata = 1;
#(`P/8);
rddata = 0; 
end
end
end
end
end
`endprotect
endmodule
file://see separate files for good.dat and bad.dat

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
日韩午夜在线观看| 99re热这里只有精品免费视频| 国产精品视频一区二区三区不卡| 欧美系列一区二区| 9i看片成人免费高清| 成人a免费在线看| 成人精品视频一区| 大尺度一区二区| 久久av资源站| 精品在线观看视频| 九色综合国产一区二区三区| 麻豆精品一区二区av白丝在线| 性做久久久久久久久| 亚洲影视在线播放| 亚洲va韩国va欧美va精品| 亚洲黄网站在线观看| 亚洲一二三级电影| 日精品一区二区| 日韩中文字幕1| 免费看精品久久片| 国产激情一区二区三区桃花岛亚洲| 精品一区二区三区视频| 精品一区二区日韩| 国产91精品一区二区麻豆网站 | 亚洲1区2区3区4区| 免费看黄色91| 丰满放荡岳乱妇91ww| av资源网一区| 欧美日韩国产综合草草| 欧美日韩成人在线| 欧美大片日本大片免费观看| 国产午夜亚洲精品羞羞网站| 中文字幕亚洲一区二区av在线| 亚洲精品乱码久久久久久| 亚洲国产成人av好男人在线观看| 美女在线视频一区| 97精品国产97久久久久久久久久久久| 色综合天天综合色综合av| 884aa四虎影成人精品一区| xf在线a精品一区二区视频网站| 国产婷婷一区二区| 亚洲一二三区不卡| 国产成人自拍网| 欧洲一区二区av| 久久奇米777| 亚洲另类春色国产| 国产九色sp调教91| 欧美日韩中文国产| 中文字幕精品在线不卡| 肉色丝袜一区二区| 一本一道久久a久久精品综合蜜臀 一本一道综合狠狠老 | 中文字幕二三区不卡| 亚洲成年人网站在线观看| 国产成人综合视频| 日韩一区二区在线看片| 亚洲日本va在线观看| 国精产品一区一区三区mba视频 | 国模冰冰炮一区二区| 91国模大尺度私拍在线视频| 久久久久久日产精品| 亚洲成人在线免费| 色综合久久中文字幕| 欧美激情综合在线| 精品一区二区三区免费毛片爱 | 亚洲成a人片在线不卡一二三区| 国产精品77777竹菊影视小说| 欧美日韩国产片| 亚洲男同1069视频| 97精品国产露脸对白| 国产精品久线观看视频| 福利91精品一区二区三区| 精品国产百合女同互慰| 午夜精品123| 色一情一伦一子一伦一区| 国产精品女主播av| 成人av在线影院| 国产精品沙发午睡系列990531| 精品一区二区三区欧美| 日韩精品一区在线| 免费看精品久久片| 日韩欧美视频一区| 激情综合亚洲精品| 精品粉嫩超白一线天av| 国产另类ts人妖一区二区| 欧美zozozo| 国产福利91精品一区| 国产精品天干天干在线综合| 成人app下载| 亚洲日本一区二区三区| 色综合久久中文综合久久97| 亚洲一区二区精品视频| 6080亚洲精品一区二区| 麻豆成人综合网| www亚洲一区| 成人一区在线看| 亚洲色图欧洲色图婷婷| 欧美亚洲免费在线一区| 婷婷六月综合亚洲| 国产亚洲一区二区三区在线观看| 国产东北露脸精品视频| 亚洲手机成人高清视频| 欧美色图免费看| 久久99国内精品| 欧美国产精品一区二区| 欧美性猛交一区二区三区精品| 亚洲成人资源网| 欧美不卡123| 色综合天天综合网天天看片| 天天做天天摸天天爽国产一区| 日韩欧美一区二区在线视频| 国产电影一区二区三区| 亚洲欧美日韩在线不卡| 欧美精品乱码久久久久久按摩| 久久福利视频一区二区| 亚洲人成精品久久久久| 欧美精品色一区二区三区| 国产成人精品影视| 亚洲成人自拍一区| 国产欧美一区二区三区在线老狼| 91在线观看下载| 美女视频黄免费的久久| 亚洲欧美一区二区不卡| 日韩一区二区视频在线观看| 成人理论电影网| 免费观看在线综合色| 亚洲日本丝袜连裤袜办公室| 久久综合网色—综合色88| 色久优优欧美色久优优| 国产盗摄精品一区二区三区在线 | 日韩和欧美一区二区三区| 欧美激情在线看| 日韩精品中文字幕在线不卡尤物| 97se亚洲国产综合自在线观| 九九九久久久精品| 天天综合日日夜夜精品| 亚洲少妇30p| 久久久久久久久久久久久夜| 欧美性xxxxxxxx| www.亚洲人| 国产99久久精品| 激情久久五月天| 三级在线观看一区二区| 亚洲影院在线观看| 亚洲免费观看视频| 欧美激情综合五月色丁香小说| 欧美岛国在线观看| 日韩欧美国产一区二区三区 | 精品成人a区在线观看| 欧美日本一区二区在线观看| 91社区在线播放| 91网页版在线| 91蝌蚪porny| 色综合咪咪久久| 91亚洲国产成人精品一区二区三| 粉嫩av一区二区三区在线播放| 九九视频精品免费| 久久国产福利国产秒拍| 国产在线看一区| 国产一区二区三区精品视频| 蜜臀av亚洲一区中文字幕| 奇米亚洲午夜久久精品| 蜜臀久久99精品久久久画质超高清 | 国产高清精品在线| 粉嫩高潮美女一区二区三区| 成人av网站免费| 99在线精品观看| 在线中文字幕一区| 欧美乱妇15p| 欧美一区二区在线播放| 欧美一区二区不卡视频| 日韩精品中文字幕一区二区三区| 日韩三级在线免费观看| 久久综合av免费| 国产精品污网站| 一区二区欧美国产| 婷婷六月综合网| 美女在线一区二区| 大胆亚洲人体视频| 欧美性三三影院| 日韩精品资源二区在线| 国产日韩欧美高清在线| 中文字幕欧美三区| 天堂一区二区在线免费观看| 精品在线一区二区三区| 成人理论电影网| 欧美视频一区二区三区四区| 日韩欧美的一区| 亚洲欧洲精品一区二区三区 | 欧美日韩日本视频| 日韩精品一区国产麻豆| 国产精品久久久久国产精品日日| 中文字幕中文字幕中文字幕亚洲无线| 日韩毛片精品高清免费| 青青草国产成人99久久| 国产91丝袜在线播放0| 欧美日韩久久一区| 国产欧美久久久精品影院| 亚洲一区二区在线免费看| 国产伦精一区二区三区| 欧美午夜一区二区三区|