SN74LS75N Design Issue

Thread Starter

Marvin1961

Joined Dec 21, 2020
4
Hi all, glad to be here to learn and share.

I am new at electronics in general so please forgive me for misspeaking and my lack of knowledge.

I have a project that will have four (4) push buttons and when each button is pressed, I want to turn on an LED representing the button that was pressed.

Before I bread boarded up the circuit, I used a free online simulator from AutoDesk called TinkerCad.

Based on my limited knowledge, I assembled a circuit and made changes until I had a working simulation (a simulation where I did not “fry” components).

Once I had the simulation functioning, I order the parts and bread boarded up the circuit. Nothing “fried/burnt up” but the circuit does not function as expected.

Here is the link to the TinkerCad simulation:
Simulation Link

Here is the schematic I drew up.
7475 Test.jpg

Here is the basic component list:
VR1: 7805
IC1: SN74LS75N
D1-4: 1N4001
LED1-4: v1.8
R1: 1k
C1-2: 47uf 33v
Sw1-4: SP NO

If someone with more knowledge than I, can tell me what I’ve missed or done wrong, it would be greatly appreciated.

Thank you all in advanced.

PS
Man, I thought I had the circuit figured out once the simulation was working, I guess I should not trust the simulators, first lesson learned I guess.
 

dl324

Joined Mar 30, 2015
12,256
Welcome to AAC!
If someone with more knowledge than I, can tell me what I’ve missed or done wrong, it would be greatly appreciated.
  1. You're violating the setup time for the D inputs
  2. You're not debouncing the switches
  3. You're letting inputs float
  4. You're supposed to know more than the simulator so you know when you're not getting realistic results
 

Thread Starter

Marvin1961

Joined Dec 21, 2020
4
Welcome to AAC!

  1. You're violating the setup time for the D inputs
  2. You're not debouncing the switches
  3. You're letting inputs float
  4. You're supposed to know more than the simulator so you know when you're not getting realistic results
Thank you for the reply Dennis, it certainly points me in the direction I need to look.

1) On violating the setup time for the D inputs, I'm lost, could you point me to something that I could read that would enlighten me to the subject?

2) On the debouncing the switches, I located this post, this is what you are referring to what I need to do with debouncing the switches?
Debouncing Switch

3) On letting the inputs float, I assume based on the following article, this is what you are referring to, meaning I need a pull down resistor on the inputs?
Inputs Floating

On another note, am I on the right track to do a circuit like I need, is there a better ic and design I should go with?

Again, thank you Dennis for your input, I truly appreciate you taking the time to point me in the proper direction to resolve my issues.

Marvin
 

MrChips

Joined Oct 2, 2009
22,536
I have a project that will have four (4) push buttons and when each button is pressed, I want to turn on an LED representing the button that was pressed.

... but the circuit does not function as expected.
Describe how you expect the circuit to function.
What do you want to happen to the other LEDs when one pushbutton is pressed?
What do you expect to happen when two or more buttons are pressed, simultaneously, and in any other time sequence?

A 74LS75 is a 4-bit latch. This is probably not the correct IC for your project depending on your expectations.
What you might be looking for is a flip-flop, not a latch.
You may want to look at an MC14532 8-bit priority encoder. This will provide you with part of the solution.
 

dl324

Joined Mar 30, 2015
12,256
1) On violating the setup time for the D inputs, I'm lost, could you point me to something that I could read that would enlighten me to the subject?
clipimage.jpg

In other circuits, hold time and pulse width may also be of concern:
clipimage.jpg
clipimage.jpg

The values for 74LS75:
clipimage.jpg
2) On the debouncing the switches, I located this post, this is what you are referring to what I need to do with debouncing the switches?
Debouncing Switch
Didn't follow the link. Contacts in mechanical switches will bounce. That will cause the inputs and latch control to experience multiple transitions for each button press.
3) On letting the inputs float, I assume based on the following article, this is what you are referring to, meaning I need a pull down resistor on the inputs?
Inputs Floating
Yes. Floating inputs on TTL are usually recognized as HIGH, but I wouldn't count on it as it's not a good design practice.
On another note, am I on the right track to do a circuit like I need, is there a better ic and design I should go with?
I'd choose to use a different solution all together.
clipimage.jpg
This eliminates the timing and switch bounce issues. You could replace the 3 input OR gates with diodes to get the chip count back to 1. Since CD4043 can operate from 5-15V, you can eliminate the voltage regulator.

You do need to make certain that you don't load the outputs because they need to maintain valid logic levels.
 

Thread Starter

Marvin1961

Joined Dec 21, 2020
4
Sorry, I did omit what my intended goal was.

Describe how you expect the circuit to function.
What do you want to happen to the other LEDs when one pushbutton is pressed?
I am making a guitar amp channel switcher. I have the circuit functioning as expected with the helpful guidance from another board (I use the foot peddle on a daily basis). The peddle consists of four (4) momentary n/o switches.

The issues is, I have no visual indicator show which button was pressed last.

So I thought replace the SPST buttons with DPDT buttons and see if I could not locate a circuit that would switch the leds accordingly as to which button was pressed last.

So not being able to find a circuit or one with out some type of processor, I thought I give a stab at designing something. I have a little electronics knowledge but not enough to carry me though a project like this.

What do you expect to happen when two or more buttons are pressed, simultaneously, and in any other time sequence?
Nothing really, it means I've "fat footed" while stepping on one of the foot switches.
 

Thread Starter

Marvin1961

Joined Dec 21, 2020
4
Sorry for not replying sooner, holidays were a little busy.

Describe how you expect the circuit to function.
What do you want to happen to the other LEDs when one pushbutton is pressed?
What do you expect to happen when two or more buttons are pressed, simultaneously, and in any other time sequence?
I have explain what the project is for above based on MrChips questions.

I've explore the subjects of debouncing and floating inputs as Dennis explained.

I am still trying to figure out the setup issue that Dennis mentioned.

At this point, I've think I've resolved the debounce and floating issues based on the updated schematic.

Am I on the right path for those two subjects?

7475 Test 02.jpg

Again, thanks for all the help and suggestions.

Marvin
 

MrChips

Joined Oct 2, 2009
22,536
I have explain what the project is for above based on MrChips questions.
Marvin
Often that helps but that was not what I was asking.

Usually it goes something like this.

1) Press a button. Its LED turns on, all others are turned off.
2) If two buttons are pressed simultaneously the button with the highest priority wins.
3) If one button is released before the other there are various options to choose:
#1 First button pressed wins
#2 Highest priority button wins
#3 Last button released wins
 

crutschow

Joined Mar 14, 2008
26,044
I am still trying to figure out the setup issue that Dennis mentioned.
The SN74LS75N is a latch so all you need to do is have the inputs high or low, as desired, when the clock goes back low
Unfortunately your circuit does not do that for the PB that generates the high signal. so you need add a delay to the clock signal going low relative to the D input after the PB is released.
I've think I've resolved the debounce and floating issues based on the updated schematic.

Am I on the right path for those two subjects?
It would appear you are.
 
Last edited:

dl324

Joined Mar 30, 2015
12,256
I am still trying to figure out the setup issue that Dennis mentioned.
You're also ignoring the hold requirement.

For reliable operation, the D input needs to be stable for a minimum of 20ns before the enable signal. The D input then needs to be held for at least 5ns after enable goes LOW.
 
Top