TAMS / Java / Hades / applets: contents | previous | next | ||||
Hades Applets contents visual index introduction std_logic_1164 gatelevel circuits delay models flipflops basic SR fli... SR flipflop ... clocked SR f... D-latch D-flipflop D-flipflop w... JK-flipflop JK-flipflop JK-flipflop ... 7476 JK-flip... flipflop demo LSSD latch 74273 D-regi... 74166 shift-... c-gate c-gate (3 in... micropipeline traffic ligh... traffic ligh... traffic ligh... traffic ligh... adders and arithm... counters LFSR and selftest memories programmable logic state-machine editor misc. demos I/O and displays DCF-77 clock relays (switch-le... CMOS circuits (sw... RTLIB logic RTLIB registers Prima processor D*CORE MicroJava Pic16 cosimulation Mips R3000 cosimu... Intel MCS4 (i4004) image processing ... [Sch04] Codeumsetzer [Sch04] Addierer [Sch04] Flipflops [Sch04] Schaltwerke [Sch04] RALU, Min... [Fer05] State-Mac... [Fer05] PIC16F84/... [Fer05] Miscellan... [Fer05] Femtojava FreeTTS | Master-slave JK-flipflop (metastable) Circuit Description This circuit shows a typical master-slave JK-flipflop, built from two basic D-type NAND-latches. For a description of the normal circuit behaviour, read the documentation for the previous applet. However, while the circuit in the previous applet was built from standard NAND gates, this applet uses special, metastable simulation models for the NAND gates. That means that the circuits look the same, and behaves the same under normal operation conditions. However, the behaviour for undefined input values or timing violations is completely different. While the metastable gates used in this circuit also accept all input values from the nine-valued std_logic logic model, they never generate an undefined (U or X) output value. Instead, they behave more or less like the real gates, which enter metastable states for a possibly long time before settling into one of the 0 or 1 output states. As a consequence of this gate behaviour, this circuit is much easier to initialize than the companion applet built from the normal gates. In fact, no extra reset input is required at all, because the flipflop gates will eventuall enter a (random) initial state. (Oscillations after timing violations are still possible, however). Naturally, you might ask why Hades or the VHDL std_logic logic system don't use the metastable gates as the default, when the circuit initialization appears so much simpler with them. The obvious answer is that customers are usually not interested in how easy it is to design a circuit, but how well it works in practice. For example, the metastable gates used in this circuit will enter random states when encountering undefined inputs, so that multiple simulation runs with the same input values can result in different (and even random) simulation results. The point is that both the initialization problems and the circuit oscillations in the simulation indicate similar problems in the real circuit, which should be avoided. For example, problems to initialize a chip due to feedback problems and missing reset inputs can result in very hard-to-diagnose failures in the actual chips, ranging from complete malfunction to intermittent bugs. On the other hand, a digital circuit that is well-behaved in the simulation has a very good chance to work out-of-the-box after manufacturing. | |||
Print version | Run this demo in the Hades editor (via Java WebStart) | ||||
Usage | FAQ | About | License | Feedback | Tutorial (PDF) | Referenzkarte (PDF, in German) | ||||
Impressum | http://tams.informatik.uni-hamburg.de/applets/hades/webdemos/16-flipflops/40-jkff/jkff-metastable.html |