如何理解SR锁存器


10

我无法确定SR闩锁的工作原理。看来,您从R插入一条输入线,从S插入另一条输入线,应该在和得到结果。Q 'QQ

但是,R和S都需要对方的输出作为输入,对方的输出也需要对方的输出作为输入。鸡肉或鸡蛋是第一位的?

首次插入该电路时,如何开始使用?

SR锁存器


您正在读哪本书?莫里斯·马诺(Morris Mano)的书对此作了更好的解释。我建议你看看。
2013年

为了更好地全面了解SR锁存器以及它对于00、01、10和11等不同输入的行为,请观看此视频。www.youtube.com/watch?v=VtVIDgilwlA

注意有关电气工程的这篇文章,也吸引了(好的)答案。
拉斐尔

可视化/理解这的另一种方法是作为反馈循环,其中先前的状态被强制为新状态。换句话说,不管先前的反馈状态是什么,它都有效。如答案中所述,可以逐案解决。
vzn 2014年

Answers:


7

触发器被实现为双稳态多谐振荡器;因此,除了S = 1,R = 1时,Q和Q'保证彼此相反。SR触发器的激励表有助于理解将信号施加到输入时发生的情况。

S R  Q(t) Q(t+1)   
----------------
0 x   0     0       
1 0   0     1   
0 1   1     0   
x 0   1     1   

在将信号施加到S和R之后,输出Q和Q'将迅速改变状态并保持稳定状态。

Example 1: Q(t) = 0, Q'(t) = 1, S = 0, R = 0. 

State 1: Q(t+1 state 1)  = NOT(R OR Q'(t)) = NOT(0 OR 1) = 0
         Q'(t+1 state 1) = NOT(S OR Q(t)) =  NOT(0 OR 0) = 1

State 2: Q(t+1 state 1)  = NOT(R OR Q'(t+1 state 1)) = NOT(0 OR 1) = 0
         Q'(t+1 state 2) = NOT(S OR Q(t+1 state 1))  =  NOT(0 OR 0) = 1     

Since the outputs did not change, we have reached a steady state; therefore, Q(t+1) = 0, Q'(t+1) = 1.


Example 2: Q(t) = 0, Q'(t) = 1, S = 0, R = 1

State 1: Q(t+1 state 1)  = NOT(R OR Q'(t)) = NOT(1 OR 1) = 0
         Q'(t+1 state 1) = NOT(S OR Q(t))  = NOT(0 OR 0) = 1


State 2: Q(t+1 state 2)  = NOT(R OR Q'(t+1 state 1)) = NOT(1 OR 1) = 0
         Q'(t+1 state 2) = NOT(S OR Q(t+1 state 1))  =  NOT(0 OR 0) = 1     


We have reached a steady state; therefore, Q(t+1) = 0, Q'(t+1) = 1.


Example 3: Q(t) = 0, Q'(t) = 1, S = 1, R = 0

State 1: Q(t+1 state 1)  = NOT(R OR Q'(t)) = NOT(0 OR 1) = 0
         Q'(t+1 state 1) = NOT(S OR Q(t)) =  NOT(1 OR 0) = 0

State 2: Q(t+1 state 2)  = NOT(R OR Q'(t+1 state 1)) = NOT(0 OR 0) = 1
         Q'(t+1 state 2) = NOT(S OR Q(t+1 state 1))  = NOT(1 OR 0) = 0     

State 3: Q(t+1 state 3)  = NOT(R OR Q'(t+1 state 2)) = NOT(0 OR 0) = 1
         Q'(t+1 state 3) = NOT(S OR Q(t+1 state 2))  = NOT(1 OR 1) = 0     

We have reached a steady state; therefore, Q(t+1) = 1, Q'(t+1) = 0.


Example 4: Q(t) = 1, Q'(t) = 0, S = 1, R = 0

State 1: Q(t+1 state 1)  = NOT(R OR Q'(t)) = NOT(0 OR 0) = 1
         Q'(t+1 state 1) = NOT(S OR Q(t)) =  NOT(1 OR 1) = 0

State 2: Q(t+1 state 2)  = NOT(R OR Q'(t+1 state 1)) = NOT(0 OR 0) = 1
         Q'(t+1 state 2) = NOT(S OR Q(t+1 state 1))  = NOT(1 OR 1) = 0     

We have reached a steady state; therefore, Q(t+1) = 1, Q'(t+1) = 0.


Example 5: Q(t) = 1, Q'(t) = 0, S = 0, R = 0

State 1: Q(t+1 state 1)  = NOT(R OR Q'(t)) = NOT(0 OR 0) = 1
         Q'(t+1 state 1) = NOT(S OR Q(t)) =  NOT(0 OR 1) = 0

State 2: Q(t+1 state 2)  = NOT(R OR Q'(t+1 state 1)) = NOT(0 OR 0) = 1
         Q'(t+1 state 2) = NOT(S OR Q(t+1 state 1))  = NOT(0 OR 1) = 0     

We have reached a steady; state therefore, Q(t+1) = 1, Q'(t+1) = 0.



With Q=0, Q'=0, S=0, and R=0, an SR flip-flop will oscillate until one of the inputs is set to 1.

Example 6: Q(t) = 0, Q'(t) = 0, S = 0, R = 0

State 1: Q(t+1 state 1)  = NOT(R OR Q'(t)) = NOT(0 OR 0) = 1
         Q'(t+1 state 1) = NOT(S OR Q(t)) =  NOT(0 OR 0) = 1

State 2: Q(t+1 state 2)  = NOT(R OR Q'(t+1 state 1)) = NOT(0 OR 1) = 0
         Q'(t+1 state 2) = NOT(S OR Q(t+1 state 1))  = NOT(0 OR 1) = 0     

State 3: Q(t+1 state 3)  = NOT(R OR Q'(t+1 state 2)) = NOT(0 OR 0) = 1
         Q'(t+1 state 3) = NOT(S OR Q(t+1 state 2)) =  NOT(0 OR 0) = 1

State 4: Q(t+1 state 4)  = NOT(R OR Q'(t+1 state 3)) = NOT(0 OR 1) = 0
         Q'(t+1 state 4) = NOT(S OR Q(t+1 state 3))  = NOT(0 OR 1) = 0     


As one can see, a steady state is not possible until one of the inputs is set to 1 (which is usually handled by power-on reset circuitry).
By using our site, you acknowledge that you have read and understand our Cookie Policy and Privacy Policy.
Licensed under cc by-sa 3.0 with attribution required.