freepeople性欧美熟妇, 色戒完整版无删减158分钟hd, 无码精品国产vα在线观看DVD, 丰满少妇伦精品无码专区在线观看,艾栗栗与纹身男宾馆3p50分钟,国产AV片在线观看,黑人与美女高潮,18岁女RAPPERDISSSUBS,国产手机在机看影片

正文內(nèi)容

畢業(yè)設(shè)計基于fpga的電機(jī)控制-預(yù)覽頁

2025-07-14 13:10 上一頁面

下一頁面
 

【正文】 按鍵輸入電機(jī)控制模塊(FPGA最小系統(tǒng))步進(jìn)電機(jī)驅(qū)動電路步進(jìn)電機(jī)LED(電機(jī)運(yùn)行狀態(tài))add_s/sub_s/shift伺服電機(jī)驅(qū)動電路clk/cs_shift伺服電機(jī)add_c/sub_c/shift 圖4 電機(jī)控制總框圖: 步進(jìn)電機(jī)的驅(qū)動電路如圖5所示,其驅(qū)動電路原理很簡單。則電機(jī)在脈沖序列信號的作用下按預(yù)定方向轉(zhuǎn)動,通過改變脈沖序列信號的快慢即頻率來控制步進(jìn)電機(jī)轉(zhuǎn)速。4與電機(jī)DCMotor一起形成一個回路,從而驅(qū)動電機(jī)正轉(zhuǎn)。在此,光耦集成電路的電源VCC為+9V,H型驅(qū)動電路中晶體管功率放大器6的發(fā)射極所加的電源為9V。系統(tǒng)啟動時,首先運(yùn)行系統(tǒng)初始化程序,程序先轉(zhuǎn)到步進(jìn)電機(jī)控制模塊,送復(fù)位信號使步進(jìn)電機(jī)處于初始狀態(tài),再轉(zhuǎn)到伺服電機(jī)控制模塊,送復(fù)位信號使伺服電機(jī)處于初始狀態(tài)。 :控制模塊的程序流程圖如圖8所示。按鍵檢測部分檢測到按鍵信號,則送至按鍵去抖部分處理后得到穩(wěn)定的控制信號;在沒有收到控制信號時,PWM波產(chǎn)生部分則按默認(rèn)的設(shè)置產(chǎn)生PWM波,一旦收到控制信號,波形產(chǎn)生部分則根據(jù)按鍵為累加或遞減信號來產(chǎn)生相應(yīng)的PWM波脈沖,相應(yīng)的,占空比計數(shù)部分則開始對輸出脈沖計數(shù), PWM信號占空比的初始值為50%,通過對時鐘進(jìn)行計數(shù),每計50個脈沖輸出一個高電平,再過50個脈沖輸出一個低電平。原因:分壓電阻過大,導(dǎo)致電機(jī)驅(qū)動電流過??;解決辦法:根據(jù)電機(jī)驅(qū)動電流大小換分壓電阻。:, 技術(shù)實(shí)用教程[m].北京:。use 。use 。end ztsd。039。 then t:=0。 else t:=32000000。 end if。039。 end if。/**/步進(jìn)電機(jī)控制脈沖產(chǎn)生模塊library IEEE。entity step_motor is Port ( clk,rst : in std_logic。 步機(jī)電機(jī)四相輸出end step_motor。beginprocess(clk,rst) 電機(jī)運(yùn)轉(zhuǎn)脈沖分頻模塊variable t:integer range 0 to 1499999。 elsif clk39。t:=0。end process。039。 then if index=6 then index:=index+1。 else index:=7。 end if。use 。use 。 七段數(shù)碼管end cepin。signal clkkk:std_logic。begincepin:block 測頻模塊beginprocess(clk,rst)variable t:integer range 1 to 32000000。 elsif rising_edge(clk) then if t=32000000 then clkk=not clkk。 end if。)。 then t:=(others=39。 elsif rising_edge(clk1) then if clkk=39。 if t(3 downto 0)9 then t(3 downto 0):=t(3 downto 0)+1。 if t(11 downto 8)9 then t(11 downto 8):=t(11 downto 8)+1。 end if。 end if。 end if。end block。 then d2=count。begin if rst=39。t:=0。end process。 then t:=00。 data_ledin=d2(3 downto 0)。 t:=t+1。 when 11=shift=0111。t:=00。end block。2 when0011=data_led=10110000。6 when0111=data_led=11111000。No signal。end Behavioral。use 。 復(fù)位信號/系統(tǒng)時鐘/減速輸入/加速輸入 count:out std_logic )。039。039。139。 end if。 end if。end process。 then t:=0。 then if t=1499999 then clkk=not clkk。 end if。 then t1=0。 elsif t1=con then count=39。039。end process。use 。entity step_top is Port (clk,add,sub,sel,rst,startstop:in std_logic。七段數(shù)碼管end step_top。ponent bianpin is Port (clk,sub,add,rst:in std_logic。 sel : in std_logic。ponent ztsd is Port (clk,key,rst:in std_logic。ponent cepin is Port (clk,clk1,rst:std_logic。signal sel1,ss,sel2,count1,y1,y2,startstop1:std_logic。u3:step_motor port map (clk=count1,sel=sel2,clkkk=y2,control=step1,rst=rst)。step2(3)=step1(3) and y1。step(3)=step2(3) and ss。process(rst,startstop1) 啟動/停止模塊variable t:std_logic。039。039。139。 end case。use 。use 。 脈沖輸入end ztsdpwm。139。039。 end if。process(key,yin,y2) variable t:std_logic:=39。 case t is when 39。039。039。yf=39。end Behavioral。use 。 系統(tǒng)時鐘/加鍵/減鍵/復(fù)位 con:out std_logic_vector(6 downto 0) )。begin if rst=39。t:=0。 then if t=1499999 then clkk=not clkk。 end if。039。139。 end if。 end if。end process。use 。entity pwm is Port (clk,rst:in std_logic。architecture Behavioral of pwm issignal clkk:std_logic:=39。event and clk=39。 else t:=t+1。process(clkk,rst)variable t:std_logic_vector(6 downto 0)。y=39。139。 if t=con then y=39。 end if。/**/占空比計數(shù)模塊library IEEE。 Unment the following lines to use the declarations that are provided for instantiating Xilinx primitive ponents.library UNISIM。 系統(tǒng)時鐘 data_led:out std_logic_vector(7 downto 0)。signal clkk:std_logic:=39。begin if rising_edge(clk) then if t=79999 then clkk=not clkk。 end if。 if d1(7 downto 4)9 then d1(7 downto 4)=d1(7 downto 4)+1。 end if。 end if。begin if rising_edge(clkk) then case t is when 00=shift=0111。 data_ledin=d2(11 downto 8)。 t:=t+1。 when others=t:=00。end process。2 when0011=data_led=10110000。6 when0111=data_led=11111000。No signal。/**/按鍵去抖模塊(同下,略去)頂層模塊/**/按鍵去抖模塊library IEEE。 Unment the following lines to use the declarations that are provided for instantiating Xilinx primitive ponents.library UNISIM。輸出按鍵end anjianqd。event and clk=39。139。 end if。begin process(clk) begin if clk39。139。 r=not d0 and not d1。 dly=r nor ndly。 begin process(clk) begin if clk39。d0=dly。end block。use 。use 。 數(shù)碼管位選信號輸出 data_led:out std_logic_vector(7 downto 0)。architecture Behavioral of top isponent step_top is Port (clk,add,sub,sel,rst,startstop:in std_logic。end ponent step_top。 data_led:out std_logic_vector(7 downto 0))。end ponent anjianqd。signal shiftp,shifts:std_logic_vector(3 downto 0)。end process。subp=sub。 adds=39。sels=39。startstops=39。 when 39。subp=39。rstp=39。 adds=add。startstops=startstop。 end case。sel1=39。 elsif t200000 then t:=t+1。039。rst5=39。139。sel1=39。 elsif t600000 then t:=t+1。139。 end if。u1:anjianqd port map (clk=clk,key=shift1,keyo=key)。
點(diǎn)擊復(fù)制文檔內(nèi)容
范文總結(jié)相關(guān)推薦
文庫吧 www.dybbs8.com
備案圖鄂ICP備17016276號-1