digital logic

Discussion in 'Homework Help' started by matt-nick, Dec 17, 2014.

  1. matt-nick

    Thread Starter New Member

    Dec 15, 2014
    10
    0
    hi guys, i posted a thread recentley about creating a counting circuit which counts in a set order rather than 1 to 15 in numerical order.

    i was just curcious as to wether it would be possible to link a jk flip flop counting cirtuit to a decade counter as there are only ten values i need to count, the other 5 are do not car items. and if so can you then make the decade coounter count in a chosen sequence such as 8 - 1 - 5 - 12 - 3 etc.

    many thanks
     
  2. MikeML

    AAC Fanatic!

    Oct 2, 2009
    5,450
    1,066
    A counter (state-machine) has some number of flip-flops (state elements). A decade counter usually has either four of five flip-flops. The maximum number of unique states for a given number of flip-flops is 2^n, or 16 states for 4ff or 32 states for 5ff, so a decade counter makes some of the states into "dont-cares" so as to count in a decimal sequence.

    In order to make a counter count in a different sequence, you must change the steering logic, not add more flip-flops. The new sequence comes out of the steering logic which decodes the "Present state" and encodes the inputs of the flip-flops (be they JK or something else) so that the "Next state" is the one in desired counting sequence. In other words, it is all about the steering logic...
     
    matt-nick likes this.
  3. matt-nick

    Thread Starter New Member

    Dec 15, 2014
    10
    0
    thank you very much. i shall look into changing the steering logic.
     
  4. tshuck

    Well-Known Member

    Oct 18, 2012
    3,531
    675
    Note: steering logic is generally referred to as input forming logic.

    If you see the thread I linked in your other thread, the Karnaugh maps are used to minimize the input forming logic, based on the desired count sequence (which can be anything, provided it is deterministic), and is described by the state transition table.
     
  5. JWHassler

    Member

    Sep 25, 2013
    201
    33
    You could count 0,1,2,..9,0 and encode those states into anything you want.
    Not as complicated as steering the inputs.
     
  6. WBahn

    Moderator

    Mar 31, 2012
    17,747
    4,796
    You are still missing a state -- there are 16 states.

    If your counter has exactly ten used states, then you can use a decade counter and simply decode the outputs so that you remap them from the 0-9 sequence to the sequence you want. You could even start the map at any of the ten states, which might result in a simpler mapping.

    If you want to use the outputs of your machine directly, then using a counter IC is not a very good approach because it already has the excitation logic hardwired into it to make it count in a particular sequence and you don't have good access to it in order to override it. So you would be left with a kluge. Better to just use four flip flops and design the excitation logic directly -- it's not that hard.
     
Loading...