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

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

?? tx_buff.vhd

?? USART coded in VHDL. It is writted in 5 files. I am uploading the files in order.
?? VHD
字號:

				--			TRANSMIT BLOCK

library ieee;
use ieee.std_logic_1164.all;

entity tx_buff is	
port(	ciport			: in		std_logic_vector(7 downto 0);
			miport			: in		std_logic_vector(7 downto 0);
			syn1port		: in		std_logic_vector(7 downto 0);
			syn2port		: in		std_logic_vector(7 downto 0);
			holdport		: in		std_logic_vector(7 downto 0);
			statusport	: in		std_logic_vector(7 downto 0);  
			holdreg_emp	: out		std_logic;
			txclk				: in		std_logic;
			txrdy				: out		std_logic;
			txe					: out		std_logic;
			txd					: out		std_logic; 
			modemclear	: in		std_logic;
			clk					: in		std_logic;
			hold_cts		: in		std_logic;
			txe_status	: out		std_logic );
end tx_buff;

architecture tb_arc of tx_buff is	   

	type serial is ( start, dbits,parity, stop );
	signal 	shiftreg	: std_logic_vector(7 downto 0);
	signal 	currtxd		: serial		:=stop;
	signal 	nexttxd		: serial		:=stop;
	signal 	i					: integer		:= 0;
	signal 	epar			: std_logic	:='0';
	signal 	len				: integer;
	signal 	shift_emp	: std_logic	:= '1';	   
	signal	hold_emp 	: std_logic	:= '1';	
	signal 	baud			: integer		:=1;
	signal 	count			: integer		:=1; 
	signal 	shift_full: std_logic	:= '0';
	signal 	tstop			: std_logic	:='0';
	signal 	d					: std_logic	:= '0';
begin 
	
	len <= 	5 when miport(3 downto 2) = "00" else
					6 when miport(3 downto 2) = "01" else
					7 when miport(3 downto 2) = "10" else
					8; 										 
			
	baud <= 1  when miport(1 downto 0) = "01" else
					16 when miport(1 downto 0) = "10" else
					64 when miport(1 downto 0) = "11" else
					1;
		 
	holdreg_emp <= hold_emp;	

	process ( clk, ciport(0), modemclear, hold_emp )
	begin
		if modemclear = '1' and ciport(0) = '1' then
			txrdy <= hold_emp;
		else
			txrdy <= '0';
		end if;			 
	end process;   

	process ( clk, modemclear, ciport(0), shift_emp, hold_emp, shiftreg, statusport(0))
	begin
		if (shiftreg = syn1port or shiftreg = syn2port) and statusport(0) = '1' then
			txe <= '1';
			txe_status <= '1';
		elsif shift_emp = '1' and hold_cts = '0' then
			txe <= '1';		  
			txe_status <= '1';
		else	
			txe <= shift_emp and hold_emp;
			txe_status <= shift_emp and hold_emp;
		end if;
	end process;
			
	process(txclk)
	begin
	if txclk = '0' and txclk'event then
		if miport(1 downto 0) = "01" or miport(1 downto 0) = "10" or miport(1 downto 0) = "11" then
			if count = baud then
				count <= 1;
				case currtxd is
					when start => 			  
						i <= 0;
						epar <= '0';
						txd <= '0';
						nexttxd <= dbits;
	
					when dbits =>
						if ciport(3) = '0' then
							txd <= shiftreg(i);
						else
							txd <= '0';
						end if;
						epar <= epar xor shiftreg(i);
						if i <= len-2 then	  
							i <= i+1;
							nexttxd <= dbits;
						elsif miport(4) = '1' then
							i <= 0;
							nexttxd <= parity;
						else	 			  
							i <= 0;
							nexttxd <= stop;
						end if;				 

					when parity =>		
						if ciport(3) = '0' then
							if miport(5) = '1' then
								txd <= epar;
							else
								txd <= not epar;
							end if;	  			   
						else
							txd <= '0';	
						end if;
						i <= 0; 
						epar <= '0';
						nexttxd <= stop; 

					when stop =>			
						i <= 0;
						epar <= '0';
						if ciport(3) = '1' then
							txd <= '0';	
						else
							txd <= '1';
						end if;
						if miport(7) = '1' and tstop = '0' then
							nexttxd <= stop;
							tstop <= '1';
						elsif hold_emp = '1' and shift_emp = '1' and modemclear = '0' then
							nexttxd <= stop;
						elsif shift_emp = '0' then
							nexttxd <= start;
							tstop <= '0';
						else				  
							nexttxd <= stop;
						end if;	
				end case;										
			else
				count <= count+1; 
			end if;
		elsif miport(1 downto 0) = "00" then
			case currtxd is
				when start | dbits =>
					if ciport(3) = '1' then
						txd <= '0';
						nexttxd <= nexttxd;
					else
						txd <= shiftreg(i);
						epar <= epar xor shiftreg(i);
						if i <= len-2 then
							i <= i+1;
							nexttxd <= dbits;	  
						elsif miport(4) = '1' then
							i <= 0;
							nexttxd <= parity;
						elsif shift_emp = '0' then
							i <= 0;		
							nexttxd <= start;
						elsif hold_emp = '1' and shift_emp = '1' and modemclear = '0' then
								nexttxd <= stop;
						end if;
					end if;

				when parity =>		   
					if ciport(3) = '0' then
						if miport(5) = '1' then
							txd <= epar;
						else
							txd <= not epar;
						end if;		
					else
						txd <= '0';
					end if;
					i <= 0;
					epar <= '0';
					if hold_emp = '1' and shift_emp = '1' and modemclear = '0' then
						nexttxd <= stop;
					elsif shift_emp = '0' then	
						nexttxd <= start;
					end if;
						
				when stop =>
					i <= 0;	
					if ciport(3) = '0' then
						txd <= '1';			   
					else 
						txd <= '0'; 
					end if;
					if hold_emp = '1' and shift_emp = '1' and modemclear = '0' then
						nexttxd <= stop;
					elsif shift_emp = '0' then
						nexttxd <= start;
					end if; 				
			end case;
		end if;
	end if;
	end process;

	process ( txclk )
	begin
		if ciport(0) = '1' then
			currtxd <= nexttxd; 
		else
			currtxd <= stop;
		end if;
	end process;   
	
	process ( txclk )
	begin
		if txclk = '1' and txclk'event then	 
			if i=len-1 and currtxd = dbits then
				shift_full <= '0';
			elsif shift_emp = '0' then
				shift_full <= '1';
			end if;
		end if;
	end process;
		
	process( txclk )
	begin		  
		if txclk = '0' and txclk'event then
			if shift_full = '0' and statusport(0) =  '0' then
					if miport(7) = '0' and shiftreg = syn1port then
						shiftreg <= syn2port;
						shift_emp <= '0'; 
						hold_emp <= '0';							
					elsif (hold_cts = '1' or modemclear = '1') and d = '1' then
						shiftreg <= holdport;
						shift_emp <= '0'; 
						hold_emp <= '1';
					else												 
						d <= '1';
						shift_emp <= '1'; 
						hold_emp <= '0';							
					end if;
			elsif shift_full = '0' and statusport(0) = '1' then
					if miport(1 downto 0) = "00" and modemclear = '1'then
						if miport(7) = '0' and shiftreg = syn1port then
							shiftreg <= syn2port;
							shift_emp <= '0'; 
							hold_emp <= '1';							
					 	else
							shiftreg <= syn1port; 
							shift_emp <= '0';
							hold_emp <= '1';
						end if;
					else
						shift_emp <= '1';
						hold_emp <= '1';
					end if;
			elsif shift_full = '1' and statusport(0) = '0' then
					hold_emp <= '0';
					shift_emp <= '0';
			elsif shift_full = '1' and statusport(0) = '1' then
					hold_emp <= '1';
					shift_emp <= '0';
			end if;
		end if;
	end process;

end tb_arc;

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
老司机精品视频一区二区三区| 久久女同互慰一区二区三区| 成人高清视频免费观看| 国产麻豆一精品一av一免费| 精品午夜一区二区三区在线观看| 日本午夜一本久久久综合| 天涯成人国产亚洲精品一区av| 亚洲一区二区精品久久av| 一区二区三区在线观看国产| 亚洲人快播电影网| 夜夜嗨av一区二区三区| 亚洲3atv精品一区二区三区| 日av在线不卡| 国内国产精品久久| 成人毛片在线观看| 99久久久精品| 欧美在线视频日韩| 日韩视频一区二区三区在线播放| 精品久久久久久久久久久久包黑料 | 欧美日韩在线观看一区二区| 91官网在线观看| 91精品婷婷国产综合久久竹菊| 日韩欧美久久久| 国产精品欧美久久久久一区二区| 亚洲欧洲www| 日韩影视精彩在线| 国产在线精品免费| 91在线无精精品入口| 欧美日韩亚洲高清一区二区| 精品区一区二区| 综合久久国产九一剧情麻豆| 视频一区二区三区入口| 国产精华液一区二区三区| 91免费视频大全| 欧美一区二区视频在线观看2020 | 欧美在线观看视频一区二区三区| 欧美日韩高清在线| 久久久国产午夜精品| 国产精品久久久久永久免费观看| 丝袜美腿亚洲色图| 国产69精品久久久久777| 欧美日韩综合在线免费观看| 国产亚洲精品久| 五月天久久比比资源色| 成人国产精品免费观看动漫| 91麻豆精品国产综合久久久久久| 国产三级精品视频| 日韩va亚洲va欧美va久久| 成人国产精品免费网站| 日韩欧美精品在线| 亚洲一区二区三区四区的| 国产成人a级片| 日韩免费在线观看| 亚洲一区在线观看免费观看电影高清| 国产精品888| 日韩欧美国产精品一区| 一区二区三区在线视频免费观看 | 18成人在线观看| 激情六月婷婷综合| 欧美片在线播放| 最近中文字幕一区二区三区| 国产精品1区二区.| 久久综合色天天久久综合图片| 亚洲国产精品精华液网站| 91在线播放网址| 中文字幕日韩一区二区| 国产成人免费视频网站高清观看视频| 在线成人高清不卡| 亚洲成人午夜电影| 欧美色视频在线| 洋洋av久久久久久久一区| 色综合天天综合网国产成人综合天| 国产精品理伦片| 国产成人在线视频网址| 26uuu国产在线精品一区二区| 久久精品国产久精国产爱| 91精品国产色综合久久久蜜香臀| 亚洲一区二区五区| 欧美视频一区二区| 首页国产欧美日韩丝袜| 欧美日韩国产首页| 日韩电影网1区2区| 9191久久久久久久久久久| 日韩成人一级大片| 欧美成人猛片aaaaaaa| 精品一区二区在线看| 精品国产一区二区在线观看| 久久99国产精品麻豆| 久久精品夜色噜噜亚洲aⅴ| 国产**成人网毛片九色| 国产精品免费网站在线观看| 91在线视频18| 亚洲一区二区三区四区五区中文| 欧美另类一区二区三区| 奇米影视一区二区三区| 亚洲精品一区二区三区在线观看| aaa欧美大片| 亚洲色图都市小说| 欧美日韩中文精品| 精品一区二区三区免费观看| 中文字幕成人网| 91国产丝袜在线播放| 日本人妖一区二区| 国产亚洲人成网站| 91豆麻精品91久久久久久| 日韩国产高清在线| 国产欧美日韩久久| 欧美午夜寂寞影院| 精品影视av免费| 国产精品久久夜| 欧美蜜桃一区二区三区| 国产精品 日产精品 欧美精品| 一区二区视频在线| 精品日韩在线观看| 日本高清成人免费播放| 黄色小说综合网站| 一区二区三区 在线观看视频| 欧美成人video| 在线免费av一区| 国产资源在线一区| 亚洲国产你懂的| 国产女主播视频一区二区| 欧美精品在线一区二区| 成人激情免费网站| 久久精品噜噜噜成人av农村| 综合久久久久综合| 久久久久久久国产精品影院| 欧美在线观看禁18| www.亚洲精品| 国产一区二区免费在线| 日韩av电影免费观看高清完整版| 久久亚洲一区二区三区明星换脸 | 一区二区在线观看免费| 久久久久久97三级| 67194成人在线观看| 91看片淫黄大片一级在线观看| 国产在线播精品第三| 日韩精品欧美精品| 亚洲资源在线观看| 中文字幕一区二区三区色视频| 日韩三级精品电影久久久| 欧美揉bbbbb揉bbbbb| 91麻豆精品在线观看| 9人人澡人人爽人人精品| 国产成人综合在线| 国产精品亚洲午夜一区二区三区| 蜜臀久久99精品久久久久宅男| 亚洲伊人伊色伊影伊综合网| 亚洲色图在线视频| 亚洲视频资源在线| 日韩一区欧美一区| 中文字幕二三区不卡| 久久精品一区二区| 国产欧美日韩精品a在线观看| 久久丝袜美腿综合| 国产丝袜美腿一区二区三区| 久久综合网色—综合色88| 欧美www视频| 久久久国产综合精品女国产盗摄| 精品少妇一区二区三区在线播放| 欧美一区二区三区免费视频| 欧美一二三区在线观看| 日韩一区二区三区四区| 日韩欧美亚洲一区二区| 精品91自产拍在线观看一区| 久久综合九色欧美综合狠狠| 精品国产伦一区二区三区观看体验| 欧美变态口味重另类| 久久久久久9999| 国产精品久久久久婷婷| 亚洲日本一区二区三区| 亚洲午夜羞羞片| 日韩电影在线观看网站| 久草中文综合在线| 成人免费va视频| 欧美性三三影院| 日韩精品一区二区三区在线观看 | 欧美影院精品一区| 91麻豆精品91久久久久同性| 欧美videos大乳护士334| 国产亚洲欧美日韩在线一区| 中文字幕在线观看不卡| 亚洲国产中文字幕| 国产精品一区二区三区乱码| 91小视频在线| 日韩一区二区三区免费看| 国产亚洲欧美在线| 亚洲国产成人av网| 韩国一区二区三区| 91成人免费在线视频| 精品久久久久久久久久久院品网| |精品福利一区二区三区| 婷婷综合在线观看| 成人精品鲁一区一区二区| 欧美午夜一区二区| 国产三级欧美三级| 首页亚洲欧美制服丝腿| 成人app网站| 日韩精品在线网站| 亚洲电影你懂得|