Avichal said:
Okay I just figured out that I don't understand the basic SR latch properly. I am continuously finding myself in the chicken-or-egg first position.
Let's say S input is 1 and R input is 0. So for the first NOR gate to give input it has to get the output from the other NOR gate but it won't get it until it give its own output!
Maybe because I have not studied how a gate works internally I am having trouble but still if anyone can help me understand, it would be great.
Thank You
No, there is no chicken-egg situation with a SR flipflop.
Have a look at this circuit which is from Wikipedia:
http://dl.dropbox.com/u/4222062/SR%20FFlop.PNG
It is made of 2 NOR gates. A NOR gate output is high unless one (or both) of the inputs is high. Then it goes low.
So, in the diagram the R input is high (shown as red in the diagram), so the output of that gate has to be low because it is a NOR gate.
The S input is low and the output from the top gate is low, so the lower gate has to have a high output.
This means that the top gate has to have a low output even if the R input is removed, because one of its inputs is still high.
Every time you make an input high, the input next to it on the same gate goes high and stays high.
You can see from this diagram, that if both inputs were high, then both outputs would be low. This is because each NOR gate has a high input and so its output must be low. This is not a problem.
The problem with this circuit is that if the gates were identical, there could be oscillation when you first turned it on. Both inputs would be low but both outputs would become high at the same time, forcing the outputs to go low. Very unfortunate oscillation would possibly happen until an input pulse hopefully forced the oscillation to stop.