LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

JK ff in counter circuit

here's a 7-segment counter with JK flip flops. the main vi is the counter.vi . In the front panel you'll see 4 ff in a row. these ff are made of subvis rs.vi + untitled(3) +untitled (4). i will attach it too. i know how a JK ff works in theory but here i get lost a bit.

can someone help me understand how the JK ff is made of? how do all the sub vi's work and combine together to make it work?

 

Download All
0 Kudos
Message 1 of 6
(8,069 Views)
the other subvi is this.
0 Kudos
Message 2 of 6
(8,068 Views)

Hello Paoksal,

 

If we take a look at Untitled 3 we can see that this is simply a J-K flip-flop (made up of two RS flip-flops). In fact, the front panel of Untitled 3 (the J-K flip-flop) includes a great picture which denotes this (I attached a screen shot for reference).

 

What the J-K.vi VI is doing is simply looping this JK flip-flop (note the feedback nodes which simply act as a shift register and store the previous iterations value). Are these VIs being used with FPGA? This seems like the most common use case for something like this.

 

Then the top level (Counter) is taking all those VIs which are constantly updating and using those values to update the display (using 7segment.vi).

 

One thing I would highly recommend if you ever need to find out what a VI is doing is to use the context help (ctrl+h then hover on anything), highlight execution (which slows down execution of the VI so you can follow it), and probes. You can find out more about these techniques in the LabVIEW help under Debugging>>Techniques (when viewed indexed).

With warm regards,

David D.
Message 3 of 6
(8,029 Views)
thank you for your help. too kind of you... :manhappy:
0 Kudos
Message 4 of 6
(8,018 Views)

I HAVE ANOTHER QUESTION PLEASE IF YOU HAVE THE TIME TO HAVE A LOOK AT IT! WHAT DO THE BOOLEAN AND BOOLEAN2 DO IN THE RS FF ???? . ALSO I SEE THE INPUTS IN JK--> BOOLEAN2,BOOLEAN 3,BOOLEAN 4 AND BOOLEAN 5!! THE JK FF ISTHIS RIGHT? WHY DO I HAVE MORE INPUTS???? I HOPE YOU UNDERSTAND THE QUESTION CAUSE MY ENGLISH ARE NOT THAT GOOD. THANKS IN ADVANCE

 

 

 

 

 

 

800px-JK-FlipFlop_(4-NAND).PNG

0 Kudos
Message 5 of 6
(7,991 Views)

Hi Paoksal,

 

I don't know what those extra booleans are for, you would have to speak with whoever provided you with this VI, I'm not sure what functionality they were originally intended for.

 

If you have someone explain what this diagram means it should clear up all your questions (found on the front panel of untitled3):

ScreenHunter_03 Oct. 28 19.15.jpg

With warm regards,

David D.
0 Kudos
Message 6 of 6
(7,971 Views)