Arbitrary Sequence Counter Up/Down

Catalin Lupu

Joined Dec 31, 2018
5
I've been having problems with one particular exercise at Digital Logic Design. I can't quite put my finger on it and i can't figure out why. I have to design a up/down counter on a given sequence. example:

A=(1,1,1,0,0,0,0,0)

b=(0,0,1,1,1,0,0,0)

c=(0,0,0,0,1,1,1,0)

d=(1,0,0,0,0,0,1,1)
where a,b,c,d are the bits of the number . D-most significant bit A-least significant bit
For x = 1 , counts up and for x = 0 it counts down. If smh can help me, it would make my day. Anyway,thanks in advance. Happy new Year.

ScottWang

Joined Aug 23, 2012
7,342
Is this Homework or just personal practice?

Catalin Lupu

Joined Dec 31, 2018
5
Personal practice, lecturer gave it to us as a "challenge" for the winter-break. It's not mandatory , but none of colleague gave it a shot.

Catalin Lupu

Joined Dec 31, 2018
5
Pardon my impoliteness. It was not in my intention to ask for the solution , and above all, it is not homework material. This exercise is for personal practice and i consider myself being self-taught. For this particular exercise,i decided to use jk flip-flops. 4 equal to the number of bits. Made the state diagram, and with the excitation table the ff/+circuitside by side. Furthermore,i drew the karnaugh map , simplified the functions for each of the j/k input. Maybe i've done smth wrong , or it was my lack of concentration.Anyway,that's for the replay & time.

WBahn

Joined Mar 31, 2012
28,514
We can't even try to tell you what you did wrong unless you show us what you did.

Present your work like you would to someone that is paying you to solve a problem and expects you to convince them that your solution is correct by walking through your design process. One of two things will likely happen: you will figure out what you did wrong while writing it up, or you will make it easy for someone here to spot where you went wrong and point it out to you.

dl324

Joined Mar 30, 2015
15,536
Welcome to AAC!
A=(1,1,1,0,0,0,0,0)
b=(0,0,1,1,1,0,0,0)
c=(0,0,0,0,1,1,1,0)
d=(1,0,0,0,0,0,1,1)
where a,b,c,d are the bits of the number . D-most significant bit A-least significant bit
For x = 1 , counts up and for x = 0 it counts down.
It's easier to understand the count sequence if you list it as decimal numbers: 9, 1, 3, 2, 6, 4, 12, 8

I assume this is for a synchronous counter. What type of flip flop?

Post your truth table and Kmaps.

Catalin Lupu

Joined Dec 31, 2018
5
So. After spending quite some time on this exercise, i chose to use 4 jk flip flops. I have to admit that i didnt try the other types.It has to be a synchronous counter . If i can make the circuit for the first stance in which it counts up ,i can manage beyond. here is my work so far.

Attachments

• 149.9 KB Views: 10
• 151.3 KB Views: 11

WBahn

Joined Mar 31, 2012
28,514
MOD NOTE: Even though this is not homework, per se, the intent is the same -- to learn something as opposed to just get a solution. So I'm moving it to Homework Help where it will receive that kind of attention. Responders can certainly take the assertion that it's not a graded assignment into account.

dl324

Joined Mar 30, 2015
15,536
here is my work so far.
Equations:

What do the circled groupings mean?

Kmap for A:

Is there a reason why you're not using the invalid counts as don't cares to simplify the equations?

Truth Table drawn more conventionally:

djsfantasi

Joined Apr 11, 2010
8,912
Have you noted the sequences between the bits? It’s fairly obvious to me. I.e,, there is a relationship between sequence a and b. What is the relationship between b and c? You might be able to recognize it right away. Then, do the same process for c and d.

This step may be critical in your understanding the problem. Read ahead, but come back here until you have an answer.

You don’t mention if the original problem limits you as to what digital components you can use. If there is in fact no limitation, the problem is simplified. Otherwise, use the resources you have. It can be accomplished in many ways.

The secret for me is not in truth tables. At least not initially. It is in recognizing the patterns within the given data.

Catalin Lupu

Joined Dec 31, 2018
5
Equations:
View attachment 166859
What do the circled groupings mean?

Kmap for A:
View attachment 166861
Is there a reason why you're not using the invalid counts as don't cares to simplify the equations?

Truth Table drawn more conventionally:
View attachment 166863
Well, i thought that by ignoring the specific values , It would be easier to simplify but that was not the case, now that i replaced the slashed cases with X , i seem to get quite simple functions this time . I will try to apply what results i got and follow-up with the complete solution. Thanks a lot.

dl324

Joined Mar 30, 2015
15,536
now that i replaced the slashed cases with X , i seem to get quite simple functions this time . I will try to apply what results i got and follow-up with the complete solution.
It would be helpful if you wrote the minterms in the same order, i.e. write the most significant bit first. That would make it easier to read equations when handwriting isn't neat.