Do flip flops oscillate when you write the same value to it?

Thread Starter

PauloConstantino

Joined Jun 23, 2016
266
Hey friends,

this question has come to mind.... If you write the same value to a flip flop, say a D flip flop, in between clock cycles, will the output Q oscillate or will it remain constant like a rock ?

Thanks in advance.
 

hp1729

Joined Nov 23, 2015
2,304
Hey friends,

this question has come to mind.... If you write the same value to a flip flop, say a D flip flop, in between clock cycles, will the output Q oscillate or will it remain constant like a rock ?

Thanks in advance.
Usually, yes, it should stay the same. There are exceptions. Some circuits will toggle on each clock pulse. A J-K flip flop with both inputs high, will toggle on each clock pulse.
 

Thread Starter

PauloConstantino

Joined Jun 23, 2016
266
Usually, yes, it should stay the same. There are exceptions. Some circuits will toggle on each clock pulse. A J-K flip flop with both inputs high, will toggle on each clock pulse.

Indeed... Are flip flops made with latches ? Or can they be made differently ? Because as far as I know SR latches will remain constant if you apply the same input many times. So If flops are made of latches then they certainly will hold their values and not oscillate. Oscillation is such a drag :)
 

ErnieM

Joined Apr 24, 2011
8,377
ANY gate's output will remain constant as long as the inputs don't change.

A flip flop can do that even if the inputs do change.
 

EM Fields

Joined Jun 8, 2016
583
Hey friends,

this question has come to mind.... If you write the same value to a flip flop, say a D flip flop, in between clock cycles, will the output Q oscillate or will it remain constant like a rock ?

Thanks in advance.
It doesn't matter what value you write to the D input of a "D" type flip-flop between clocks, the output will remain rock-solid until the next clock, and then it'll only change if the input was different from the output immediately prior to the clock. Like this:
Dflop timing.png
 
Last edited:

hp1729

Joined Nov 23, 2015
2,304
Indeed... Are flip flops made with latches ? Or can they be made differently ? Because as far as I know SR latches will remain constant if you apply the same input many times. So If flops are made of latches then they certainly will hold their values and not oscillate. Oscillation is such a drag :)
Latches and flip flops are made from gates so anything is possible. Google J-K Master-Slave flip flops. Download some data sheets for 7473, 7476, 74107 and such.
www.alldatasheet.com is a good site.
 

Deleted member 115935

Joined Dec 31, 1969
0
provided your talking about registers, not latches,
and your using off the shelf ones, not making your own out of gates
and you meet the set up and hold times,
and you aren't using the S/R type inputs, then output rock solid.

If your failing the setup / hold times, then the output can toggle a few times till it settles,
but if I read your question right then you have static input,
 

WBahn

Joined Mar 31, 2012
30,060
ANY gate's output will remain constant as long as the inputs don't change.

A flip flop can do that even if the inputs do change.
But a flip flop's output can also change even if the inputs remain constant. Consider the T-type flip flop or a JK with both inputs tied high.
 

WBahn

Joined Mar 31, 2012
30,060
"Can" does not mean "must."
That wasn't the point. The claim was that ANY gate's output WILL remain constant as long as the inputs don't change.

Of course, the fine print is what is considered a "gate" -- if you mean it to be a purely combinatorial logic element, then this is true. If it is more general and applies to any logic circuit that can be put into a black box, then it isn't. You can find definitions that favor both viewpoints.
 

hp1729

Joined Nov 23, 2015
2,304
General comments are inconclusive. Many results are possible. so, getting specific ...

D-type latch. Writing the same thing to it the outputs stay the same.
"T" type. The flip flop toggles with each clock.
"J-K" type. With both inputs high the output will toggle with each clock.
"S-R". No clock.
"Transparent" latch. No toggling if the input stays constant.
None will "oscillate". Oscillate implies a free running condition. Outputs can toggle but this is not oscillation ... is it?
Counters made of latches or flip flops toggle with clock pulses accomplishing frequency division of the clocks, but is this really "oscillation"?
.
 

GopherT

Joined Nov 23, 2012
8,009
That wasn't the point. The claim was that ANY gate's output WILL remain constant as long as the inputs don't change.

You are telling the OP how to do the opposite of what he is asking then you claim, "that's not the point!"?

Really? Please stop trying to confuse OPs
 

WBahn

Joined Mar 31, 2012
30,060
You are telling the OP how to do the opposite of what he is asking then you claim, "that's not the point!"?

Really? Please stop trying to confuse OPs
I see you are once again up to your childish baiting games. If you would bother to actually read you would see that that response was not directed at the OP.
 

GopherT

Joined Nov 23, 2012
8,009
I see you are once again up to your childish baiting games. If you would bother to actually read you would see that that response was not directed at the OP.
Ok, sorry. Let me change my comment then. Please stop trying to confuse the OP with answers that are exactly the opposite of what they were looking for.
 

EM Fields

Joined Jun 8, 2016
583
But a flip flop's output can also change even if the inputs remain constant. Consider the T-type flip flop or a JK with both inputs tied high.
Strictly speaking, the clock signal is an input, so if it never changes (that is, if its voltage remains constant) the device's output(s) will never change.

Consequently, "But a flip flop's output can also change even if the inputs remain constant." is technically incorrect.
 
Top