




版權(quán)說明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請進行舉報或認領(lǐng)
文檔簡介
1、2015.06.15 UESTC數(shù)電加油站lesson-3課程內(nèi)容計數(shù)器概念以及應(yīng)用移位寄存器的概念以及應(yīng)用Counter(計數(shù)器)(P710)The name counter is generally used for any clocked sequential circuit whose state diagram contains a single cycle, as in Figure 8-26. The modulus of a counter is the number of states in the cycle. A counter with m states is call
2、ed a modulo-m counter or, sometimes, a divide-by-m counter. A counter with a nonpower-of-2 modulus has extra states that are not used in normal operation. 計數(shù)器的分類按時鐘:同步、異步按計數(shù)方式:加法、減法、可逆按編碼方式:二進制、十進制BCD碼、循環(huán)碼計數(shù)器的功能計數(shù)、分頻、定時、產(chǎn)生脈沖序列、數(shù)字運算本節(jié)內(nèi)容行波計數(shù)器、同步計數(shù)器MSI型計數(shù)器及其應(yīng)用二進制計數(shù)器狀態(tài)的譯碼8.4.1 Ripple Counterswhen a part
3、icular bit changes from 1 to 0, it generates a carry to the next most significant bit. The counter is called a ripple counter because the carry information ripples from the less significant bits to the more significant bits, one bit at a time. 00-01-10-11-008.4.1 Ripple Counters(行波計數(shù)器) use T flip-fl
4、opQ* = QQQT考慮二進制計數(shù)順序:只有當?shù)?i-1 位由10時,第 i 位才翻轉(zhuǎn)。CLKQQTQQTQQTQQTQ0Q1Q2Q3T flip-flop changes state (toggles) on every rising edge of its clock input. 8.4.2 Synchronous Counters(同步計數(shù)器)A synchronous counter connects all of its flip-flop clock inputs to the same common CLK signal, so that all of the flip-fl
5、op outputs change at the same time, after only tTQ ns of delay. synchronous counter同步二進制加法計數(shù)器1 0 1 1 0 1 1+ 11 0 1 1 1 0 0在多位二進制數(shù)的末位加 1,僅當?shù)?i 位以下的各位都為 1 時,第 i 位的狀態(tài)才會改變。最低位的狀態(tài)每次加1都要改變。EN QT Q 利用有使能端的 T 觸發(fā)器實現(xiàn):Q* = ENQ + ENQ = EN Q通過EN端進行控制,需要翻轉(zhuǎn)時,使 EN = 1 ENi = Qi-1 Qi-2 Q1 Q0EN0 = ? 1synchronous count
6、er1CLKQ0Q1Q2C8.4.3 MSI counters and applications MSI型計數(shù)器及應(yīng)用-同步4位二進制計數(shù)器74x163CLR同步清零LD同步預(yù)置數(shù)RCO進位輸出ENPENT使能端進位輸出清零8.4.3 MSI Counters and Applications4位二進制計數(shù)器74x16374x163的功能表01111CLK工作狀態(tài)同步清零同步置數(shù)保持保持,RCO=0計數(shù)CLR_LLD_LENP ENT0111 0 1 0 1 174x161異步清零Other MSI counters1bit BCD counter 74x160 Synchronous cle
7、ar 、74x162 Asynchronous clear 01234567890QAQBQCQD74x160、74x162 the counting sequence is modified to go to state 0 after state 9. In other words, these are modulo-10 counters, sometimes called decade counters.the QD and QC outputs have one-tenth of the CLK frequency, they do not have a 50% duty cycle
8、.Other MSI counters74x169-up/down counterUP/DNUP/DN = 1 counts up (升序)UP/DN = 0 counts down(降序)Enable inputsripple carry outActive-lowABCG1G2AG2BY0Y1Y2Y3Y4Y5Y6Y774x138EN1EN2_LEN3_LSRC0SRC1SRC2P0P1P7SDATA如何控制地址端自動輪流選擇輸出Y0Y7 application of the counterTiming diagram for a modulo-8 binary counter and de
9、coder,showing decoding glitches. 若在一次狀態(tài)轉(zhuǎn)移中有2位或多位計數(shù)位同時變化,譯碼器輸出端可能會產(chǎn)生“尖峰脈沖” 功能性冒險01234567012Modulo-m counterUse SSI device Clocked Synchronous State-Machine DesignUse MSI counter using n bit binary counter as a modulo-m counter in two cases: m 2nAlthough the 163 is a modulo-16 counter, it can be made
10、to count in a modulus less than 16 by using the CLR_L or LD_L input to shorten the normal counting sequence. Cascading 74x163s(計數(shù)器的級聯(lián))CLOCKRESET_LLOAD_LCNTEND0D1D2D3Q4Q5Q6Q774x16374x16374x16274x162個位十位計數(shù)范圍: 0-255計數(shù)范圍:099EXERCISE 1八.74X163 is a synchronous 4-bit binary counter with synchronous load a
11、nd synchronous clear inputs, the basic function table is shown as follow. Design a modulo-10 counter, using one 74X163 and some necessary gates, and the counting sequence is 2-4-2-1BCD. Complete the design and draw a logic diagram. ANSWER:LD_L=(QDQCQBQA)D=QDC=QCB=QBA=QA九、Clocked Synchronous State Ma
12、chine Design(15) 74x163 is a synchronous 4-bit binary counter with synchronous CLEAR input and LOAD input. LD_L=(QBQC), CLR_L=(QDQB ) in the following circuit.1. Finish the logic circuit.2. Draw the state diagram with all states of “Q3Q2Q1Q0” . (“Q3Q2Q1Q0” is the output of 74x163)3. Write the sequen
13、ce of Y. Y is the output of 74x151. (Assumed state of 74x163 start in Q3Q2Q1Q0=0000.) EXERCISE 2V. Design a variable modulus counter only with 74x163, which will be a module-6 counter when the input control signal M = 1 or a module-8 counter when M = 0. The states of module-6 counter should be(11,12
14、,13,14,15,0).The states of module-8 counter should be (9,10,11,12,13,14,15,0). (10)Please write out the input equations of LD_L, A, B, C, D. ( 5) Draw the circuit line linked of 74x163.(5) EXERCISE 3【Solution】:the input equations: LD_L=應(yīng)該檢測0000狀態(tài) D=A=1 C=0 B=M EXERCISE 4A shift register is an n-bit
15、register with a provision for shifting its stored data byone bit position at each tick of the clock. 8.5 Shift Registersan MSI 4-bit bidirectional, parallel-in, parallel-out shift register (4位雙向移位寄存器74x194) CLKCLRS1S0LIND QDC QCB QBA QARIN74x194left-in 左移輸入right-in 右移輸入left means “in the direction f
16、rom QD to QA,” right means “in the direction from QA to QD.”Function table for the74x194 4-bit universalshift register CLKCLRS1S0LIND QDC QCB QBA QARIN74x194 CLKCLRS1S0LIND QDC QCB QBA QARINCLKCLRS1S0LINRIN移位寄存器的擴展并行輸入(8位)并行輸出8位8.5.5 Shift-Register Counters(移位寄存器計數(shù)器)D0 = F ( Q0 , Q1 , , Qn-1 )Feedba
17、ck logicD Q CK QD Q CK QD Q CK QD Q CK QCLKFF0FF1FF2FF3一般結(jié)構(gòu): 1000010000010010有效狀態(tài)其他狀態(tài)8.5.6 Ring Counters (環(huán)型計數(shù)器)D Q CK QD Q CK QD Q CK QD Q CK QCLKFF0FF1FF2FF31000010000010010D0 D1 D2 D3 非自啟動的無效狀態(tài)D0 = Qn-1self-correcting counter self-correcting counter is designed so that all abnormal states have tr
18、ansitions leading to normal states. Self-correcting counters are desirable for the same reason that we use a minimal-risk approach to state assignment : If something unexpected happens, a counter or state machine should go to a “safe” state. 有效狀態(tài)無效狀態(tài)D Q CK QD Q CK QD Q CK QD Q CK QCLKFF0FF1FF2FF3100
19、0010000010010D0 D1 D2 D3self-correcting自啟動的,自校正的Self-correcting 4-bit,4 state ring counter with a single circulating 1Q0Q1Q2Q310CLOCKQ0Q1Q2Q3101000Q0Q1Q2Q3RESET載入Q0Q1Q2Q3CLOCK自校正的RING COUNTER(P735)The major appeal of a ring counter for control applications is that its states appear in 1-out-of-n dec
20、oded form directly on the flip-flop outputs. That is,exactly one flip-flop output is asserted in each state. Furthermore, these outputs are “glitch free”. For the general case, an n-bit self-correcting ring counter uses an n-1-input NOR gate, and corrects an abnormal state within n - 1 clock ticks.S
21、hift-Register Counters一般結(jié)構(gòu):反 饋 邏 輯D0 = F ( Q0 , Q1 , , Qn-1 )環(huán)形計數(shù)器:1000010000100001最簡單的:D0 = Qn-1反 饋 邏 輯自校正的:D0 = (Qn-2 + + Q1 + Q0)0111101111011110(Qn-2 Q1 Q0) D Q CK QD Q CK QD Q CK QD Q CK QCLKFF0FF1FF2FF3Q3Q0Q2Q1Q0 Q1 Q2 Q3Johnson Counter(扭環(huán)計數(shù)器)D Q CK QD Q CK QD Q CK QD Q CK QCLKFF0FF1FF2FF3D0 =
22、 Qn-100001000110011101111011100110001無效有效的狀態(tài)循環(huán)JOHNSON COUNTER:最簡單的實現(xiàn):D0 = Qn-1D Q CK QD Q CK QD Q CK QD Q CK QCLKFF0FF1FF2FF31001010010101101011010110101001000001000110011101111011100110001有效狀態(tài)無效狀態(tài)如何得到自校正的扭環(huán)計數(shù)器?Q3Q0Q2Q1Q0 Q1 Q2 Q3Johnson counter(P533)An n-bit shift register with the complement of th
23、e serial output fed back into the serial input is a counter with 2n states and is called a twisted-ring, Moebius, orJohnson counter.An n-bit Johnson counter has 2n - 2n abnormal states, and is therefore subject to the same robustness problems as a ring counter. dddddddd最小成本self-correcting1、確定有效的狀態(tài)循環(huán)
24、2、對無效狀態(tài)進行處理, 使其進入有效循環(huán)。Q0 Q1 Q2 Q31111000011110000Q0Q100 01 11 1000011110Q2Q3D0100001000110011101111011100110001有效無效100101001010110101101011010100101D0 = Q3 + Q2Q0Self-correcting 4-bit,8 state Johnson counter S1S0 wired as a shift-left shift register(接成左移形式)自校正改進:(法一)LIN = Q3 + Q2Q0 CLKCLRS1S0LIND QD
25、C QCB QBA QARIN74x194+5VCLOCKRESET_LQ0Q1Q2Q3Johnson counterself-correcting1、確定有效的狀態(tài)循環(huán)2、對無效狀態(tài)進行處理, 使其進入有效循環(huán)。Q0 Q1 Q2 Q300001000110011101111011100110001有效無效10010100101011010110101101010010可利用置數(shù)法。自校正改進: (法二)利用置數(shù)每當電路Q3Q2Q1Q0出現(xiàn)0XX0就置數(shù)到下一狀態(tài)0001D0 = Q3.Q0Self-correcting 4-bit,8 state Johnson counter CLKCLR
26、S1S0LIND QDC QCB QBA QARIN74x194+5VCLOCKRESET_L自校正改進:(法二)利用置數(shù)每當電路Q3Q2Q1Q0出現(xiàn)0XX0就置數(shù)到下一狀態(tài)0001,S0 = Q3.Q0Q0Q1Q2Q300018.5.6 Linear Feedback Shift Register Counters線性反饋移位寄存器(LFSR)計數(shù)器LFSR計數(shù)器 有 2n-1 種有效狀態(tài) 最大長度序列發(fā)生器反 饋 邏 輯D Q CK QD Q CK QD Q CK QD Q CK QCLKFF0FF1FF2FF3移位寄存器型計數(shù)器的一般結(jié)構(gòu)RESET_LCLOCKLFSR n -bit L
27、inear Feedback Shift Register Counters a maximum-length sequence generator. 奇校驗電路全0態(tài)的下一狀態(tài)?反饋方程 P535 表8-21LFSR計數(shù)器 有 2n-1 種有效狀態(tài) 最大長度序列發(fā)生器LFSR counter example: 3 bits Shift register counters Q0Q1Q2移位寄存器應(yīng)用 Shifting the stored data to the next flip-flopApplications: Delay line Data may be reusedSequentia
28、l signal detector序列檢測器Data not be reusedSequential signal detector序列檢測器順序脈沖發(fā)生器利用移位寄存器構(gòu)成(無毛刺) 注意自校正(環(huán)形計數(shù)器 )利用計數(shù)器和譯碼器構(gòu)成 注意“毛刺”(二進制計數(shù)器的狀態(tài)譯碼 )CLKQ0Q1Q2Q3序列信號發(fā)生器 用于產(chǎn)生一組特定的串行數(shù)字信號例:設(shè)計一個 110100 序列信號發(fā)生器利用觸發(fā)器利用計數(shù)器利用移位寄存器利用D觸發(fā)器設(shè)計一個110100序列信號發(fā)生器1、畫狀態(tài)轉(zhuǎn)換圖2、狀態(tài)編碼000101 表示 S0 S5S0S1S5S2S4S3/1/1/0/1/0/03、列狀態(tài)轉(zhuǎn)換輸出表0 0 00 0 10 1 00 1 11 0 01 0 10 0 10 1 00 1 11 0 01 0 10 0 0Q2Q1Q0Q2*Q1*Q0*Y1101004、得到激勵方程和輸出方程 考慮未用狀態(tài)的處理5、得到電路圖000001用計數(shù)器和數(shù)據(jù)選擇器構(gòu)成序列信號發(fā)生器74x163 CLKCLRLDENPENTA QAB QBC QCD QD RCOENABCD0D1D2D3D4D5D6D7YY
溫馨提示
- 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請下載最新的WinRAR軟件解壓。
- 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶所有。
- 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁內(nèi)容里面會有圖紙預(yù)覽,若沒有圖紙預(yù)覽就沒有圖紙。
- 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
- 5. 人人文庫網(wǎng)僅提供信息存儲空間,僅對用戶上傳內(nèi)容的表現(xiàn)方式做保護處理,對用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對任何下載內(nèi)容負責(zé)。
- 6. 下載文件中如有侵權(quán)或不適當內(nèi)容,請與我們聯(lián)系,我們立即糾正。
- 7. 本站不保證下載資源的準確性、安全性和完整性, 同時也不承擔(dān)用戶因使用這些下載資源對自己和他人造成任何形式的傷害或損失。
最新文檔
- geren借款合同范本
- 企業(yè)品牌策劃設(shè)計合同范本
- 產(chǎn)品維修授權(quán)合同范本
- 償還貨款合同范本
- 割松油合同范例
- 勞務(wù)分包合同范本2003
- 公司購銷合同范本正規(guī)
- 男友出租合同范本
- 撰稿勞務(wù)合同范本
- 華能電廠采購合同范例
- 《智慧旅游認知與實踐》課件-第九章 智慧旅行社
- 馬工程《刑法學(xué)(下冊)》教學(xué)課件 第16章 刑法各論概述
- 英國簽證戶口本翻譯模板(共4頁)
- 現(xiàn)金調(diào)撥業(yè)務(wù)
- 空白個人簡歷表格1
- 廣東省中小學(xué)生休學(xué)、復(fù)學(xué)申請表
- GPIB控制VP-8194D收音信號發(fā)生器指令
- 建立良好師生關(guān)系
- 鋼管、扣件、絲杠租賃明細表
- 施工現(xiàn)場臨電臨水施工方案
評論
0/150
提交評論