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

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? al8051.vhd

?? 使用VHDL語言編寫的8051IP核
?? VHD
?? 第 1 頁 / 共 5 頁
字號(hào):
--------------------------------------------------------------------------------------
-- Copyright (c) 1999 by Alatek. All rights reserved.
--
-- DESIGN        :   AL8051
-- FILE NAME     :   AL8051.vhd
-- DESCRIPTION   :   Top Level
--
-- CREATED       :   01/01/1999
-- MODIFIED      :   
-- VERSION       :   1.0
-- AUTHOR        :   Anatoli Sergyienko, Volodymir Lepekha
-- HISTORY       :   
--------------------------------------------------------------------------------------

library IEEE;
use IEEE.Std_Logic_1164.all;
library work;
use work.registers.all;

--^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
--  I/O wires of the I8051 are the following
--^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
entity AL8051 is
	Port (
		Port0: inout Std_Logic_Vector (7 downto 0);
		Port1: inout Std_Logic_Vector (7 downto 0);
		Port2: inout Std_Logic_Vector (7 downto 0);
		Port3: inout Std_Logic_Vector (7 downto 0);
		CLK: Std_Logic;
		ALE: out Std_Logic;
		PSEN: out Std_Logic;
		EA: in Std_Logic;
		RST: Std_Logic
		);
end AL8051;

--^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
--  Architecture of the I8031 is the following
--^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^


architecture AL8051_ARCH of AL8051 is
	signal y,y1,x,z,h,h1,yk,ht,ht1,pop,pop1,popp,ht1p : Integer range 0 to 65535;
--	type BYTE1 is array (0 to 255) of Bit_Vector (7 downto 0);
--	type BYTE2 is array (0 to 1023) of Bit_Vector (7 downto 0);
	type VEC is array (4 downto 0) of Integer range 0 to 100;
	signal DRAM: RAMemo; 
	signal PCBus,zo,zo1,zo2,zo3,zcom,zcom1:Bit_Vector (7 downto 0); 
	signal SMOD,SBUFs,SBUF1,SCONs,SCON1:Bit_Vector (7 downto 0);
	signal zox: Bit_Vector(0 to 2);
	signal z1,u,u1,u1k,u12,u2,u3,u4,u5,u6,z2,zvp,z11,z12,flz2,ft: Bit;
	signal utt,utt1,utt1p,ut0,ut1,ut2,ut3,fal0,fal1,fal2,fal3: Bit;
	signal PRP0,PRP1,PRP00,PRP01,PRP02,PRP03,PRP04,PRP05: Bit;
	signal SDR,SDR1,zpp,strb:Bit;
	signal q1,q2,q3: Std_Logic;
	signal p5,p50,p51:Bit_Vector (4 downto 0);
	signal TMODs,TCONs,TL0s,TH0s,TL1s,TH1s,Accumulator,PSWs: Bit_Vector (7 downto 0);
	signal TCONa,TL0a,TH0a,TL1a,TH1a,dcom,ACOM: Bit_Vector (7 downto 0);
	signal ppp: Bit_Vector (15 downto 0);
	signal ttt:Std_Logic_Vector (7 downto 0);
	signal tt0:Std_Logic_Vector (7 downto 0);
	signal pp3: Bit_Vector (1 downto 0);
	signal zbuf,zpos,zsdv,zpp1,zpp2,start,zh,zh1,outact: Bit;
	signal PRT1,TFP,TFP1,TFP1p,PRR1,PB,RB1,SC2: Bit;
	signal PRBit,PRBit1,flpp,flpp0,flpp1,fr: Bit;
	signal flp0,flp1,flp2,flp3,CLKu,CYCLE : Bit;
	signal larger: Std_Logic;
	signal BUP0,BUP1,BUP2,BUP3: Bit_Vector (7 downto 0);   
	
	
	--^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
	-- this is a program ROM
	-- in file  IPMemory.vhd
	--^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
	component  IPMemory
		Port (
			i:  in Integer range 0 to 65535;    --address
			PCBus: inout Bit_Vector (7 downto 0);  --data
			z:  in Bit;                         --
			z1: in Bit
			);
	end component;
	
	component console  
		Port (
			qq: in RAMemo;
			BYTE1: in Bit_Vector (7 downto 0);
			com: in Bit_Vector (7 downto 0); 
			r_TCON: in Bit_Vector (7 downto 0);
			r_SCON: in Bit_Vector (7 downto 0);
			r_TH0: in Bit_Vector (7 downto 0);
			r_TL0: in Bit_Vector (7 downto 0);
			r_TH1: in Bit_Vector (7 downto 0);
			r_TL1: in Bit_Vector (7 downto 0);
			r_bp0: in Bit_Vector (7 downto 0);
			r_bp1: in Bit_Vector (7 downto 0);
			r_bp2: in Bit_Vector (7 downto 0);
			r_bp3: in Bit_Vector (7 downto 0);
			y : in Integer
			);
	end component;
	
	
	
	--^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
	-- this is a Timer Unit of MCS51
	-- 
	--^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
	component Timer is
		Port (
			l0: in Bit_Vector (7 downto 0);
			h0: in Bit_Vector (7 downto 0);
			l1: in Bit_Vector (7 downto 0);
			h1: in Bit_Vector (7 downto 0);
			l0a: out Bit_Vector (7 downto 0);        
			h0a: out Bit_Vector (7 downto 0);
			l1a: out Bit_Vector (7 downto 0);
			h1a: out Bit_Vector (7 downto 0);
			TCONa: out Bit_Vector (7 downto 0);
			TMOD: in Bit_Vector (7 downto 0);
			TCON: in Bit_Vector (7 downto 0);
			Port3: in Std_Logic_Vector (7 downto 0); 
			s: in Bit;
			TFP: out Bit
			);
	end component;
	
	begin
	--^^^^^^^^^^^^^^^^^^^^^^^^^^^
	-- Switshing memory and timers
	--^^^^^^^^^^^^^^^^^^^^^^^^^^^
	UPP:  IPMemory
	Port map (
		i => y,    --address 
		PCBus => PCBus,	--data
		z => zh,			  -- output data event
		z1 => zh1			--addres latch event
		);
	
	UUW: console 
	Port map(
		qq => dram,
		BYTE1 => ZCOM1,
		com => dcom,
		r_TCON => TCONa,
		r_SCON => SCONs,
		r_TH0 =>  TH0a,
		r_TL0 =>  TL0a,
		r_TH1 =>  TH1a,
		r_TL1 =>  TL1a,
		r_bp0 =>  bup0,
		r_bp1 =>  bup1,
		r_bp2 =>  bup2,
		r_bp3 =>  bup3,
		y  => y
		);
	
	
	UT: Timer
	Port map (
		TMOD => TMODs,
		l0 => TL0s,
		h0 => TH0s,
		l1 => TL1s,
		h1 => TH1s,
		TCON => TCONs,        
		l0a => TL0a,
		h0a => TH0a,
		l1a => TL1a,
		h1a => TH1a,
		TCONa => TCONa,
		Port3 => Port3,
		s => z1,
		TFP => TFP
		);
	
	--^^^^^^^^^^^^^^^^^^^^^^^^^^^
	-- Decoding machine cycles,
	-- Reset
	--^^^^^^^^^^^^^^^^^^^^^^^^^^^
	process (CLK)
		begin
		CLKu <=to_bit(CLK);
	end process;
		
	CLK_dc: process (CLKu,rst)
		variable a: Bit := '0';
		begin
		
		if ht = 23 then ht <= 0; 
						else ht <= ht +1;
		end if;
		if ht = 0 then utt <= not utt; end if;
		if ht = 10 then ut3 <= not ut3; end if;
		if ht = 20 then ut0 <= not ut0; end if;
		if ht = 21 then ut1 <= not ut1; end if; 
		if ht = 22 then ut2 <= not ut2; end if; 
					-- h- machine phase =0...11
		if h = 11 then h <= 0; else h <= h+1; end if;
					-- ui - machine phases =0, 1
					-- two times slower THan h
		if h = 10 then  u <= not u; end if;
		if h = 1 then  u12 <= not u12; end if; 
		if h = 2 then  u2 <= not u2; end if; 
		if h = 3 then  u3 <= not u3; end if;  
		if h = 4 then  u4 <= not u4; end if;   
		if h = 8 then  u5 <= not u5; end if;   
		if h = 9 then  u6 <= not u6; end if; 
		
		if h = 2 then PSEN <= '1';   end if;     	 --PSEN
		if flz2 = '0' and fr = '1'  then 
			if h = 8 then 
			PSEN <= '0'; end if;				  
		end if; 
		
		if flz2 = '0' then  
			if h = 2 then 
					ALE <= '1'; end if;			--ALE
		end if; 
		if h = 6 then ALE <= '0'; end if; 
	
		u1 <=to_bit(RST); 									--u1 = Reset
		if u1k = '1' then 
			ALE <= '1';
			PSEN <= '1'; 
		end if;
		
	end process CLK_dc;
	
	--^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
	-- Input outer Interrupt signals
	-- through Port3(2) and Port 3(3)
	--^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
	process (Port3(2),PRP00)    -- INT0
		variable a: Bit;
	begin
		if Port3(2) = '0' then
				PRP0 <= '1';
		else PRP0 <= '0';
		end if;   
		if a /= PRP00 then PRP0 <= '0'; end if;    
		a:= PRP00;           
	end process;
	
	
	process (Port3(3),PRP01)    -- INT1
		variable a: Bit;
	begin
		if Port3(3) = '0' then 
				PRP1 <= '1';
		else PRP1 <= '0';
		end if;    
		if a /= PRP01 then PRP1 <= '0'; end if;    
		a:= PRP01;                    
	end process;
	
	
--^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
--  the main process 
--  of the I8051 processor kernel
--
--  there are some procedures
--  which work only in this process
--  and use this process variables
--  as side effects
--^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
	kernel: process
		variable pCLK,s,bank,fpr,fpru,j,k1,k2: Integer range -300 to 65663 := 0;
		variable si,sti,ik,k,ik1,kk,jk: Integer range -300 to 65663 := 0;
		variable PR,pr0,pr1,pr10,prp,pr111,ccom:Bit_Vector (7 downto 0);		
		--	variable com	   :Bit_Vector (7 downto 0);
		variable pr2:Bit_Vector (15 downto 0);
		variable pr3:Bit_Vector (3 downto 0);
		variable pr4:Bit_Vector (2 downto 0);
		variable pr5:Bit_Vector (4 downto 0);	  
		variable pr6:Bit_Vector (6 downto 0);
		variable pr50,pr51:Bit_Vector (4 downto 0);
		variable fl0,fl1,flint,flint1: Bit;         
		variable ff,ffc,b,b1,b2,b3,b4,b5,ff1b:Bit := '0';
		variable G0,G1,CT0,CT1,M00,M01,M10,M11:Bit := '0';
		variable FBit,TR0,TR1,TF0,TF1,INT0,INT1,T0,T1:Bit := '0';
		variable ADBit:Bit_Vector (255 downto 0);
		variable BUFP0,BUFP1,BUFP2,BUFP3: Bit_Vector (7 downto 0);		  
		Variable addrhi:	   Bit_Vector (7 downto 0);	
		variable pre: bit;		   		
		variable adp: integer;	
		variable fli: bit;
		
--^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-- this procedure returns <k1>
-- -Integer value of the byte Vector <com>        
--^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 
		procedure Proc2         					       -- byte ==> Integer
			(variable k1 : out Integer range 0 to 255;
			variable com1 : in Bit_Vector (7 downto 0) )
			is                         
			variable k11 : Integer range 0 to 255;
			variable com11 : Bit_Vector (7 downto 0);
		begin 
			com11 := com1; k11:=0;
			for j in 7 downto 0 loop
				k11:=2*k11;
				if com11(j) = '1' then 
					k11:=k11+1;
				end if;
			end loop;
			k1:= k11;
		end procedure Proc2;
		
---^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-- this procedure returns the byte Vector <com1>
-- -representation of the Integer<k1>   	  
--^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
		procedure Proc3         						       -- Integer ==>  byte 
			(variable k1 : in Integer range 0 to 255;
			variable com1 : out Bit_Vector (7 downto 0)	)
			is                         
			variable t,k11 : Integer range 0 to 255;
			variable com11 : Bit_Vector (7 downto 0);
		begin 
			k11:= k1;  t:=128;
			for j in 7 downto 0 loop
				if k11 < t then com11(j) := '0';
								else com11(j) := '1'; k11 := k11 - t; 
				end if;
				t := t/2;
			end loop;    
			com1 := com11; 
		end procedure Proc3;
		
--^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^  
-- this procedure returns <k1>
-- -Integer value of a half word Vector <com1>         	
--^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^  
		procedure Proc21                -- 2 byte ==> Integer
			(variable k1 : out Integer range 0 to 65535;
			variable com1 : in Bit_Vector (15 downto 0)	)
			is                         
			variable k11 : Integer range 0 to 65535;
			variable com11 : Bit_Vector (15 downto 0);
		begin 
			com11 := com1;  k11:=0;
			for j in 15 downto 0 loop
				k11:=2*k11;
				if com11(j) = '1' then k11:=k11+1;  end if;
			end loop;
			k1:= k11;
		end procedure Proc21;
		
--^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^	  
-- this procedure returns the halphword Vector <com1>
-- -representation of the Integer<k1>   	  	  
--^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
		procedure Proc31                -- Integer ==> 2 byte 
			(variable k1 : in Integer range 0 to 65536;
			variable com1 : out Bit_Vector (15 downto 0))
			is                         
			variable t,k11 : Integer range 0 to 65536;
			variable com11 : Bit_Vector (15 downto 0);
		begin 
			k11:= k1; t:=32768;
			for j in 15 downto 0 loop
				if k11 < t then com11(j) := '0';
								else com11(j) := '1'; k11 := k11 - t; 
				end if;
				t := t/2;
			end loop;    
			com1 := com11; 
		end procedure Proc31;
		
--^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-- this procedure returns byte <com>
-- -a following instruction byte        
--^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
		procedure Proc1 is  -- com := pc
			variable a: Bit; -- flag (0 - vnutr./1 - vnesh.) PP
			variable ih: Integer :=0;
		begin
			ik := (ik + 1) mod 32;
			outact<='0';
			ih := i;
			if EA = '1'or EA='H'  then 
				if i < 4095 then a := '0'; 
								else a := '1'; ih := y; 			-- - 4096; 
					outact<='1';
				end if;
				else a := '1'; ih := y;
			end if;                         
			fr <= a;
			if a = '0'then
				wait on u2;
				zh <= not zh; 			   -- output data event IPMemory
				wait for 0.5 ns;
				for j in 0 to 7 loop
					if PCBus(j) = '1' then com(j) := '1'; 
												else com(j) := '0'; 
					end if;
				end loop;     
				zcom1 <= com; 
				wait on u4;
				zh1 <= not zh1; 			   --addres latch event	 IPMemory
				wait for 0.5 ns;
				wait on u;   
			else 
				BUFP0 := "11111111"; 
				bup0 <= bufp0; wait for 1 ps;
				y1 <= ih;
				wait for 1 ns;
				proc31(ih,pr2);
				ppp <= pr2;
				y1 <= ih;
				wait on u2; 
				
				for j in 0 to 7 loop
					if Port0(j) = '1' then com(j) := '1'; 
											else com(j) := '0'; 
					end if;

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號(hào) Ctrl + =
減小字號(hào) Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
成人精品亚洲人成在线| 激情亚洲综合在线| 欧美一级专区免费大片| 国内精品第一页| 亚洲一区自拍偷拍| 久久精品夜色噜噜亚洲a∨| 色欧美片视频在线观看| 久久se精品一区二区| 亚洲欧美日韩电影| 久久色在线观看| 91美女蜜桃在线| 五月综合激情日本mⅴ| 2024国产精品视频| 91久久精品一区二区| 美女性感视频久久| 综合分类小说区另类春色亚洲小说欧美 | 国产福利一区二区三区视频在线 | 国产成人免费高清| 亚洲精品日产精品乱码不卡| 欧美色图激情小说| 国产麻豆9l精品三级站| 午夜欧美视频在线观看| 久久久一区二区三区捆绑**| 欧美三级日韩三级| 盗摄精品av一区二区三区| 天天综合网天天综合色| 国产精品传媒在线| 欧美电影免费观看完整版| 色婷婷综合久久久| 日本不卡中文字幕| 一区二区激情小说| 日韩黄色片在线观看| 国产精品国产三级国产普通话99| 91精品国产综合久久精品麻豆| www.66久久| 国产在线精品国自产拍免费| 亚洲影院久久精品| 国产精品久久久久一区二区三区| 欧美一级黄色大片| 欧美色图在线观看| 成人天堂资源www在线| 国产乱子伦视频一区二区三区| 午夜欧美在线一二页| 亚洲免费毛片网站| 国产精品美女久久久久久| 精品成人在线观看| 日韩亚洲电影在线| 欧美亚洲图片小说| 色综合天天综合在线视频| 国产成人精品午夜视频免费| 久久激情综合网| 日韩精品高清不卡| 亚洲国产视频一区二区| 中文字幕一区视频| 中文av一区特黄| 欧美国产精品一区二区| 久久天堂av综合合色蜜桃网| 精品国产一二三| 欧美丰满嫩嫩电影| 69久久99精品久久久久婷婷| 欧美日韩在线一区二区| 欧美性生活大片视频| 99精品桃花视频在线观看| 国产精品99久久久久| 久久er99热精品一区二区| 国产精品污网站| 精品国产精品网麻豆系列| 国产亚洲精久久久久久| 日韩欧美国产精品一区| 91精品国产免费久久综合| 91精品国产入口在线| 日韩免费看网站| 精品国产乱码久久久久久牛牛| 欧美大片免费久久精品三p| 精品国产网站在线观看| 久久久精品tv| 国产精品理伦片| 一区二区三区**美女毛片| 五月天一区二区三区| 视频一区视频二区中文| 青青青伊人色综合久久| 韩国理伦片一区二区三区在线播放| 久久国产尿小便嘘嘘| 国产一区激情在线| 成人免费看视频| 91成人免费在线| 亚洲视频香蕉人妖| 亚洲精品老司机| 婷婷开心久久网| 国产尤物一区二区在线| 国产精品1024| 91麻豆国产福利精品| 欧美日韩一区三区四区| 欧美哺乳videos| 国产精品国产三级国产普通话99 | 国产精品三级在线观看| 综合av第一页| 日韩精品五月天| 国产福利一区二区| 日本韩国欧美在线| 欧美高清性hdvideosex| 日韩一区二区三区av| 精品国产91九色蝌蚪| 国产日韩av一区二区| 亚洲综合区在线| 麻豆精品久久久| 不卡视频一二三| 欧美精品123区| 中文字幕乱码亚洲精品一区| 亚洲一区二区三区免费视频| 久88久久88久久久| 91福利国产成人精品照片| 久久综合九色综合97婷婷女人| 亚洲欧洲精品一区二区三区| 婷婷成人综合网| 成人av免费在线播放| 欧美一区二区三区免费观看视频| 欧美极品aⅴ影院| 天堂久久一区二区三区| 成人免费av网站| 欧美一区二区成人| 亚洲欧美日韩中文字幕一区二区三区| 日本在线不卡一区| 色综合久久久久综合体桃花网| 欧美mv日韩mv| 蜜桃视频在线观看一区二区| 欧美日韩视频在线观看一区二区三区| 国产精品午夜在线观看| 国产不卡视频在线播放| www激情久久| 狠狠色丁香婷婷综合久久片| 日韩一区二区在线观看| 天堂在线一区二区| 51精品视频一区二区三区| 亚洲成人资源网| 在线免费观看日韩欧美| 一区二区三区四区国产精品| 91色九色蝌蚪| 亚洲视频综合在线| 色综合咪咪久久| 亚洲午夜私人影院| 欧美日韩午夜精品| 欧美a级理论片| 欧美精选一区二区| 一区二区三区免费观看| 欧美写真视频网站| 悠悠色在线精品| 91在线你懂得| 中文字幕在线免费不卡| 国产精品 欧美精品| 久久久一区二区三区| 国产在线精品一区二区三区不卡| 日韩一区二区中文字幕| 天天影视涩香欲综合网| 欧美怡红院视频| 亚洲精品一二三区| 91污片在线观看| 亚洲日本va午夜在线电影| 99热99精品| 亚洲欧美aⅴ...| 91丨porny丨户外露出| 国产精品第一页第二页第三页| 国产91丝袜在线播放九色| 精品国产一区二区三区久久久蜜月| 日韩激情在线观看| 日韩免费福利电影在线观看| 美女在线观看视频一区二区| 精品蜜桃在线看| 国产在线一区二区| 久久精品这里都是精品| 国产91高潮流白浆在线麻豆| 欧美成人aa大片| 99re成人精品视频| 亚洲精品欧美激情| 欧美日韩美女一区二区| 蜜桃传媒麻豆第一区在线观看| 日韩欧美你懂的| 高清成人免费视频| 一区二区三区四区在线播放 | 91视频在线观看免费| 亚洲另类在线视频| 538prom精品视频线放| 国精品**一区二区三区在线蜜桃| 久久久久国产精品人| 成人免费视频国产在线观看| 亚洲黄色性网站| 日韩免费观看2025年上映的电影 | 成人欧美一区二区三区| 国产成人av一区二区| 欧美成人精精品一区二区频| 国产成人午夜精品影院观看视频| 国产精品每日更新| 欧美在线观看你懂的| 麻豆极品一区二区三区| 成人欧美一区二区三区视频网页| 欧美午夜电影在线播放| 韩国欧美国产1区| 亚洲综合色噜噜狠狠| 精品国产乱码久久久久久1区2区| 粉嫩av亚洲一区二区图片|