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

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

?? alu_avr.vhd

?? AVR IP CORE 可以直接用于工程的開發(fā)和 已經(jīng)通過編譯和仿真
?? VHD
字號:
--************************************************************************************************--  ALU(internal module) for AVR core--	Version 1.1--  Designed by Ruslan Lepetenok --	Modified 20.02.2002 (CPC/SBC/SBCI Z-flag bug found)--************************************************************************************************library IEEE;use IEEE.std_logic_1164.all;entity alu_avr is port(              alu_data_r_in   : in std_logic_vector(7 downto 0);              alu_data_d_in   : in std_logic_vector(7 downto 0);                            alu_c_flag_in   : in std_logic;              alu_z_flag_in   : in std_logic;-- OPERATION SIGNALS INPUTS              idc_add         :in std_logic;              idc_adc         :in std_logic;              idc_adiw        :in std_logic;              idc_sub         :in std_logic;              idc_subi        :in std_logic;              idc_sbc         :in std_logic;              idc_sbci        :in std_logic;              idc_sbiw        :in std_logic;              adiw_st         : in std_logic;              sbiw_st         : in std_logic;              idc_and         :in std_logic;              idc_andi        :in std_logic;              idc_or          :in std_logic;              idc_ori         :in std_logic;              idc_eor         :in std_logic;                            idc_com         :in std_logic;                            idc_neg         :in std_logic;              idc_inc         :in std_logic;              idc_dec         :in std_logic;              idc_cp          :in std_logic;                            idc_cpc         :in std_logic;              idc_cpi         :in std_logic;              idc_cpse        :in std_logic;                                          idc_lsr         :in std_logic;              idc_ror         :in std_logic;              idc_asr         :in std_logic;              idc_swap        :in std_logic;-- DATA OUTPUT              alu_data_out    : out std_logic_vector(7 downto 0);-- FLAGS OUTPUT              alu_c_flag_out  : out std_logic;              alu_z_flag_out  : out std_logic;              alu_n_flag_out  : out std_logic;              alu_v_flag_out  : out std_logic;              alu_s_flag_out  : out std_logic;              alu_h_flag_out  : out std_logic);end alu_avr;architecture rtl of alu_avr is-- ####################################################-- INTERNAL SIGNALS-- ####################################################signal alu_data_out_int		    : std_logic_vector (7 downto 0);	-- ALU FLAGS (INTERNAL)signal alu_z_flag_out_int       : std_logic;signal alu_c_flag_in_int        : std_logic;            -- INTERNAL CARRY FLAGsignal alu_n_flag_out_int       : std_logic;signal alu_v_flag_out_int       : std_logic;signal alu_c_flag_out_int       : std_logic;-- ADDER SIGNALS --signal adder_nadd_sub : std_logic;        -- 0 -> ADD ,1 -> SUBsignal adder_v_flag_out	: std_logic;signal adder_carry : std_logic_vector(8 downto 0);signal adder_d_in  : std_logic_vector(8 downto 0);signal adder_r_in  : std_logic_vector(8 downto 0);signal adder_out   : std_logic_vector(8 downto 0);-- NEG OPERATOR SIGNALS signal neg_op_in    : std_logic_vector(7 downto 0);	signal neg_op_carry : std_logic_vector(8 downto 0);signal neg_op_out   : std_logic_vector(8 downto 0);-- INC, DEC OPERATOR SIGNALS signal incdec_op_in    : std_logic_vector (7 downto 0);	signal incdec_op_carry : std_logic_vector(7 downto 0);signal incdec_op_out   : std_logic_vector(7 downto 0);signal com_op_out : std_logic_vector(7 downto 0);signal and_op_out : std_logic_vector(7 downto 0);signal or_op_out : std_logic_vector(7 downto 0);signal eor_op_out : std_logic_vector(7 downto 0);-- SHIFT SIGNALSsignal right_shift_out : std_logic_vector(7 downto 0);-- SWAP SIGNALSsignal swap_out : std_logic_vector(7 downto 0);begin	-- ########################################################################-- ###############              ALU-- ########################################################################adder_nadd_sub <=(idc_sub or idc_subi or idc_sbc or idc_sbci or idc_sbiw or sbiw_st or                  idc_cp or idc_cpc or idc_cpi or idc_cpse ); -- '0' -> '+'; '1' -> '-' -- SREG C FLAG (ALU INPUT)alu_c_flag_in_int <= alu_c_flag_in and (idc_adc or adiw_st or idc_sbc or idc_sbci or sbiw_st or idc_cpc oridc_ror);                                          -- SREG Z FLAG ()-- alu_z_flag_out <= (alu_z_flag_out_int and not(adiw_st or sbiw_st)) or --                   ((alu_z_flag_in and alu_z_flag_out_int) and (adiw_st or sbiw_st));alu_z_flag_out <= (alu_z_flag_out_int and not(adiw_st or sbiw_st or idc_cpc or idc_sbc or idc_sbci)) or                   ((alu_z_flag_in and alu_z_flag_out_int) and (adiw_st or sbiw_st))or				  (alu_z_flag_in and alu_z_flag_out_int and(idc_cpc or idc_sbc or idc_sbci));   -- Previous value (for CPC/SBC/SBCI instructions)-- SREG N FLAGalu_n_flag_out <= alu_n_flag_out_int;				  				  -- SREG V FLAGalu_v_flag_out <= alu_v_flag_out_int;				  alu_c_flag_out <= alu_c_flag_out_int;				  alu_data_out <= alu_data_out_int;-- #########################################################################################adder_d_in <= '0'&alu_data_d_in;adder_r_in <= '0'&alu_data_r_in;  --########################## ADDEER ###################################adder_out(0) <= adder_d_in(0) xor adder_r_in(0) xor alu_c_flag_in_int;adder_carry(0) <= ((adder_d_in(0) xor adder_nadd_sub) and adder_r_in(0)) or                (((adder_d_in(0) xor adder_nadd_sub) or adder_r_in(0)) and alu_c_flag_in_int);summator:for i in 1 to 8 generateadder_out(i) <= adder_d_in(i) xor adder_r_in(i) xor adder_carry(i-1);adder_carry(i) <= ((adder_d_in(i) xor adder_nadd_sub) and adder_r_in(i)) or                 (((adder_d_in(i) xor adder_nadd_sub) or adder_r_in(i)) and adder_carry(i-1));end generate;-- FLAGS  FOR ADDER INSTRUCTIONS: -- CARRY FLAG (C) -> adder_out(8)-- HALF CARRY FLAG (H) -> adder_carry(3)-- TOW'S COMPLEMENT OVERFLOW  (V) -> adder_v_flag_out <= (((adder_d_in(7) and adder_r_in(7) and not adder_out(7)) or                     (not adder_d_in(7) and not adder_r_in(7) and adder_out(7))) and not adder_nadd_sub) or -- ADD                    (((adder_d_in(7) and not adder_r_in(7) and not adder_out(7)) or					(not adder_d_in(7) and adder_r_in(7) and adder_out(7))) and adder_nadd_sub);																										   -- SUB--#####################################################################-- LOGICAL OPERATIONS FOR ONE OPERAND--########################## NEG OPERATION ####################neg_op_out(0)   <= not alu_data_d_in(0) xor '1';neg_op_carry(0) <= not alu_data_d_in(0) and '1';neg_op:for i in 1 to 7 generateneg_op_out(i)   <= not alu_data_d_in(i) xor neg_op_carry(i-1);neg_op_carry(i) <= not alu_data_d_in(i) and neg_op_carry(i-1);end generate;neg_op_out(8) <= neg_op_carry(7) xor '1';neg_op_carry(8) <= neg_op_carry(7);                            -- ??!!-- CARRY FLAGS  FOR NEG INSTRUCTION: -- CARRY FLAG -> neg_op_out(8)-- HALF CARRY FLAG -> neg_op_carry(3)-- TOW's COMPLEMENT OVERFLOW FLAG -> alu_data_d_in(7) and neg_op_carry(6) --############################################################################	--########################## INC, DEC OPERATIONS ####################incdec_op_out(0)      <=  alu_data_d_in(0) xor '1';incdec_op_carry(0)    <=  alu_data_d_in(0) xor idc_dec;inc_dec:for i in 1 to 7 generateincdec_op_out(i)   <= alu_data_d_in(i) xor incdec_op_carry(i-1);incdec_op_carry(i) <= (alu_data_d_in(i) xor idc_dec) and incdec_op_carry(i-1);end generate;-- TOW's COMPLEMENT OVERFLOW FLAG -> (alu_data_d_in(7) xor idc_dec) and incdec_op_carry(6) --####################################################################--########################## COM OPERATION ###################################com_op_out <= not alu_data_d_in;-- FLAGS -- TOW's COMPLEMENT OVERFLOW FLAG (V)  -> '0'-- CARRY FLAG (C) -> '1' --############################################################################-- LOGICAL OPERATIONS FOR TWO OPERANDS	--########################## AND OPERATION ###################################and_op_out <= alu_data_d_in and alu_data_r_in;-- FLAGS -- TOW's COMPLEMENT OVERFLOW FLAG (V)  -> '0'--############################################################################--########################## OR OPERATION ###################################or_op_out <= alu_data_d_in or alu_data_r_in;-- FLAGS -- TOW's COMPLEMENT OVERFLOW FLAG (V)  -> '0'--############################################################################--########################## EOR OPERATION ###################################eor_op_out <= alu_data_d_in xor alu_data_r_in;-- FLAGS -- TOW's COMPLEMENT OVERFLOW FLAG (V)  -> '0'--############################################################################-- SHIFT OPERATIONS -- ########################## RIGHT(LSR, ROR, ASR) #######################right_shift_out(7) <= (idc_ror and alu_c_flag_in_int) or (idc_asr and alu_data_d_in(7)); -- right_shift_out(7)shift_right:for i in 6 downto 0 generateright_shift_out(i) <= alu_data_d_in(i+1);end generate;	-- FLAGS -- CARRY FLAG (C)                      -> alu_data_d_in(0) -- NEGATIVE FLAG (N)                   -> right_shift_out(7)-- TOW's COMPLEMENT OVERFLOW FLAG (V)  -> N xor C  (left_shift_out(7) xor alu_data_d_in(0))-- #######################################################################-- ################################## SWAP ###############################swap_h:for i in 7 downto 4 generateswap_out(i) <= alu_data_d_in(i-4);end generate;swap_l:for i in 3 downto 0 generateswap_out(i) <= alu_data_d_in(i+4);end generate;-- #######################################################################-- ALU OUTPUT MUXalu_data_out_mux:for i in alu_data_out_int'range generatealu_data_out_int(i) <= (adder_out(i) and (idc_add or idc_adc or (idc_adiw or adiw_st) or    -- !!!!!                                     idc_sub or idc_subi or idc_sbc or idc_sbci or                                     (idc_sbiw or sbiw_st) or    -- !!!!!                                     idc_cpse or idc_cp or idc_cpc or idc_cpi)) or                                      (neg_op_out(i) and idc_neg) or                               -- NEG                                     (incdec_op_out(i) and (idc_inc or idc_dec)) or               -- INC/DEC                                     (com_op_out(i) and idc_com) or                               -- COM                                     (and_op_out(i) and (idc_and or idc_andi)) or                 -- AND/ANDI                                                                        (or_op_out(i)  and (idc_or or idc_ori)) or                   -- OR/ORI                                                                        (eor_op_out(i) and idc_eor) or                               -- EOR                                     (right_shift_out(i) and (idc_lsr or idc_ror or idc_asr)) or  -- LSR/ROR/ASR                                     (swap_out(i) and idc_swap);                                  -- SWAP                                     end generate;--@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ ALU FLAGS OUTPUTS @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@alu_h_flag_out <= (adder_carry(3) and                                                      -- ADDER INSTRUCTIONS             (idc_add or idc_adc or idc_sub or idc_subi or idc_sbc or idc_sbci or idc_cp or idc_cpc or idc_cpi)) or                (neg_op_carry(3) and idc_neg);                                          -- NEG                          alu_s_flag_out <= alu_n_flag_out_int xor alu_v_flag_out_int;alu_v_flag_out_int <= (adder_v_flag_out and	                            (idc_add or idc_adc or idc_sub or idc_subi or idc_sbc or idc_sbci or adiw_st or sbiw_st or idc_cp or idc_cpi or idc_cpc)) or             ((alu_data_d_in(7) and neg_op_carry(6)) and idc_neg) or                                       -- NEG		     (not alu_data_d_in(7) and incdec_op_carry(6) and idc_inc) or -- INC		     (alu_data_d_in(7) and incdec_op_carry(6) and idc_dec) or	  -- DEC			 ((alu_n_flag_out_int xor alu_c_flag_out_int) and (idc_lsr or idc_ror or idc_asr));            -- LSR,ROR,ASRalu_n_flag_out_int <= alu_data_out_int(7);alu_z_flag_out_int <= '1' when alu_data_out_int="00000000" else '0';alu_c_flag_out_int <= (adder_out(8) and                        (idc_add or idc_adc or (idc_adiw or adiw_st) or idc_sub or idc_subi or idc_sbc or idc_sbci or (idc_sbiw or sbiw_st) or idc_cp or idc_cpc or idc_cpi)) or -- ADDER					   (not alu_z_flag_out_int and idc_neg) or    -- NEG					   (alu_data_d_in(0) and (idc_lsr or idc_ror or idc_asr)) or idc_com;-- @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@end rtl;

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
色久优优欧美色久优优| 国产精品久久久久久亚洲毛片| 欧美精品一区二区三区蜜臀| 国产精品国产三级国产aⅴ原创| 天天色综合成人网| 99久久免费视频.com| 欧美变态凌虐bdsm| 亚洲国产一区二区三区青草影视| 国产精品自拍一区| 欧美一区欧美二区| 亚洲国产综合91精品麻豆| 福利一区在线观看| 精品国产精品一区二区夜夜嗨| 亚洲第一综合色| 欧美影院午夜播放| 最新国产の精品合集bt伙计| 国产91精品一区二区麻豆网站 | 欧美久久高跟鞋激| 一区二区三区免费观看| av欧美精品.com| 国产拍揄自揄精品视频麻豆| 精品写真视频在线观看| 欧美大片在线观看| 奇米精品一区二区三区在线观看一| 在线观看中文字幕不卡| 亚洲乱码国产乱码精品精可以看 | 日韩一区欧美一区| 成人高清伦理免费影院在线观看| 精品91自产拍在线观看一区| 六月婷婷色综合| 日韩一级黄色片| 久久国产精品免费| 久久久久久久电影| 国产做a爰片久久毛片| 久久色视频免费观看| 久久精品国产一区二区| 日韩精品一区二区在线| 激情综合色综合久久综合| 精品国产91乱码一区二区三区 | 午夜av一区二区三区| 91福利视频在线| 午夜成人在线视频| 欧美一区午夜精品| 国产尤物一区二区| 国产精品无码永久免费888| av中文一区二区三区| 亚洲人精品午夜| 欧美午夜精品久久久久久孕妇| 亚洲午夜激情网站| 欧美不卡一区二区三区四区| 国产一区二区三区免费观看 | 日韩一级免费观看| 国产一二三精品| 综合色中文字幕| 欧美日韩一区 二区 三区 久久精品| 婷婷中文字幕一区三区| 日韩欧美国产麻豆| 99麻豆久久久国产精品免费| 一区二区在线观看视频| 欧美一区二区三区成人| 成人av在线一区二区| 亚洲一区二区三区四区五区中文 | 日韩中文字幕一区二区三区| 在线电影一区二区三区| 国产精品资源在线观看| 亚洲乱码国产乱码精品精可以看| 日韩手机在线导航| 97se狠狠狠综合亚洲狠狠| 三级久久三级久久| 中文字幕乱码久久午夜不卡| 精品视频免费看| 成人精品视频.| 日日噜噜夜夜狠狠视频欧美人 | 日韩电影免费一区| 国产精品久久久久aaaa樱花| 欧美精品日韩一本| 成人免费高清视频在线观看| 石原莉奈在线亚洲二区| 国产精品久久久久久妇女6080 | 中文字幕一区二区三区四区| 欧美日韩午夜在线视频| 成人av网站在线观看| 久久91精品久久久久久秒播 | 中文字幕在线不卡一区二区三区| 欧美一区二区三区啪啪| 91污在线观看| 国产成人自拍网| 人禽交欧美网站| 樱花影视一区二区| 国产精品国模大尺度视频| 日韩一区二区免费在线观看| 欧美视频在线观看一区| 成人中文字幕合集| 国内外成人在线| 另类中文字幕网| 日韩电影在线观看电影| 亚洲图片自拍偷拍| 亚洲一区免费在线观看| 国产精品国产自产拍高清av| 久久精品日产第一区二区三区高清版| 91麻豆精品国产91| 欧美亚日韩国产aⅴ精品中极品| 成年人国产精品| 成人动漫视频在线| 成人av一区二区三区| 国产成人精品aa毛片| 国产又粗又猛又爽又黄91精品| 捆绑调教美女网站视频一区| 日韩av不卡一区二区| 婷婷综合另类小说色区| 午夜视频一区二区| 日韩成人午夜电影| 偷窥少妇高潮呻吟av久久免费| 亚洲第一电影网| 亚洲va韩国va欧美va| 天使萌一区二区三区免费观看| 亚洲国产精品一区二区久久恐怖片| 亚洲桃色在线一区| 亚洲主播在线观看| 亚洲一区二区三区激情| 视频一区在线播放| 免费成人小视频| 国产自产2019最新不卡| 国产传媒欧美日韩成人| 99久久久久久| 欧美性色黄大片| 欧美一级在线免费| 久久久久国产精品麻豆| 国产精品久久99| 亚洲成av人**亚洲成av**| 日产国产欧美视频一区精品| 看电视剧不卡顿的网站| 国产精品91一区二区| 不卡av在线网| 欧美日韩不卡视频| 精品久久人人做人人爽| 亚洲国产电影在线观看| 一区二区三区四区av| 免费高清视频精品| 成人三级在线视频| 欧美丝袜丝交足nylons| 精品久久人人做人人爰| 《视频一区视频二区| 亚洲h动漫在线| 国产一区二区电影| 在线观看视频一区二区欧美日韩| 欧美一级二级在线观看| 欧美激情一区二区三区蜜桃视频| 亚洲猫色日本管| 精东粉嫩av免费一区二区三区| av电影在线观看一区| 欧美一二三四区在线| 亚洲欧美中日韩| 老鸭窝一区二区久久精品| 成人黄色在线看| 欧美一区日韩一区| 亚洲免费视频中文字幕| 久久99国产乱子伦精品免费| 色综合久久久久| 久久久久久久久久美女| 午夜欧美视频在线观看| 粉嫩av一区二区三区粉嫩 | 久久久不卡网国产精品一区| 亚洲激情六月丁香| 麻豆成人免费电影| 欧美在线制服丝袜| 国产精品你懂的在线欣赏| 日韩激情一二三区| 91久久精品国产91性色tv| 精品国产凹凸成av人网站| 丝袜美腿成人在线| 91搞黄在线观看| 日韩一区中文字幕| 成人在线综合网| 久久婷婷综合激情| 另类调教123区 | 国产精品乱码久久久久久| 日韩电影在线观看网站| 色老综合老女人久久久| 国产精品素人视频| 国产一区在线观看麻豆| 欧美一区二区三区免费在线看 | 久久精品国产精品亚洲精品| 欧美午夜宅男影院| 亚洲精品视频在线观看网站| 成人性生交大片免费看在线播放| 精品国产三级a在线观看| 婷婷综合另类小说色区| 欧美日韩国产综合视频在线观看| 亚洲欧洲99久久| 97国产一区二区| 亚洲欧美色综合| 一本大道久久a久久综合| 中文字幕乱码一区二区免费| 国产精品小仙女| 国产欧美综合色| 大陆成人av片| 亚洲免费视频中文字幕| 91九色02白丝porn| 亚洲一区二区三区激情|