# Memory in circuit logic

Discussion in 'The Projects Forum' started by jlatshaw, Sep 2, 2014.

1. ### jlatshaw Thread Starter New Member

Jul 20, 2013
28
0
Hello,
So for a project, I am attempting to make a circuit able to record some integer values (from inputs) and then make decisions based off of their values (return which input gave the highest input) .

My question is, how can I best store values with a digital logic circuit? I was thinking that I could use flip flops to store values, but I am trying to find the best way to go about this. Any suggestions?

Thanks,
James

2. ### MrChips Moderator

Oct 2, 2009
12,633
3,453
The best way would be to use a microcontroller.

3. ### djsfantasi AAC Fanatic!

Apr 11, 2010
2,905
878
How many is "some", so we can have an idea of how to "best store" them?
And are you looking at one set on inputs or multiple sets?
And how large are your integer inputs (how many bits are required to store and compare)?

Without specific requirements, I can think of several suggestions, none of which may be applicable.

4. ### jlatshaw Thread Starter New Member

Jul 20, 2013
28
0
Thanks for the replies.
I agree that a microcontroller would probably be best, but I am trying to challenge myself and see if I can do this project without one.

And I would like to store multiple 6 bit values from various inputs. However, we can simplify the process for now and assume there is only one 6 bit input.

Thanks,
James

5. ### crutschow Expert

Mar 14, 2008
13,496
3,373
You could use a 74VHC573 8-bit (octal) latch to store the 6-bit value for each input. That would require one IC per 6-bit word.

6. ### jlatshaw Thread Starter New Member

Jul 20, 2013
28
0
Thanks for your input.

But as a follow up question, what are the main differences between the various kinds of flip flops (such as D-latch and SR)?
In particular, how is the one more useful than the other?

Thanks so much, you all are very helpful,
James

Apr 5, 2008
15,801
2,386
8. ### tshuck Well-Known Member

Oct 18, 2012
3,531
675
Which is more useful depends on the situation. The two most popular are D flip flops and JK flip flops.

Each has their own characteristics that are useful in various situations.

9. ### pwdixon Member

Oct 11, 2012
488
56
As someone else already said use a micro. I've been designing electronics for 40 years and in the early days logic was all we had, that was just before micros came along. I can pretty much say that in the last 10 years or more I haven't touched a logic chip, everything (other than absolutely single logic chip circuits) can be done simpler, more flexible and cheaper using a micro unless you are looking for some high speed parallel processing and even then multi-processor solutions are my first go-to.

10. ### jlatshaw Thread Starter New Member

Jul 20, 2013
28
0
Thanks for the input and advice everyone.
You all are super helpful.
-James