Author Topic: Any current/voltage limiting protection for 74HC165 parallel inputs?  (Read 729 times)

0 Members and 1 Guest are viewing this topic.

Offline kreyszigTopic starter

  • Regular Contributor
  • *
  • Posts: 131
  • Country: ca
Hi,

Around the web I have seen circuit designs where people were adding ~10k resistors to 75HC165 buffer parallel inputs in order to read DIP switch positions. I do not understand the requirement for these resistors from a current limiting standpoint as the buffer inputs have very large impedance, correct? Why are they used? If they are not used for current limiting, but instead for some high transient voltage protection, then I am not sure why one resistor per input is required instead of a single resistor for all inputs. Also, if it is for ESD protection, why not using TVS diodes instead?

Thanks!
 

Online pcprogrammer

  • Super Contributor
  • ***
  • Posts: 3698
  • Country: nl
Re: Any current/voltage limiting protection for 74HC165 parallel inputs?
« Reply #1 on: February 10, 2023, 02:50:20 pm »
Are you sure these resistors were in series, and not setup as pull up or down resistors. A dip switch mostly is either close or open and not a toggle between ground and supply.

When the input of a digital circuit is left floating it could either be seen as low or high depending on system noise and needs to be pulled to the intended level.

Offline kreyszigTopic starter

  • Regular Contributor
  • *
  • Posts: 131
  • Country: ca
Re: Any current/voltage limiting protection for 74HC165 parallel inputs?
« Reply #2 on: February 10, 2023, 03:16:59 pm »
  :palm: Yep you must be right, sorry, I was going to do a very dumb mistake. Would it be any useful to add TVS diodes to protect the 165's inputs though since I could see how static discharge to the DIP switches could occur from the user handling them?
« Last Edit: February 10, 2023, 03:18:42 pm by kreyszig »
 

Online pcprogrammer

  • Super Contributor
  • ***
  • Posts: 3698
  • Country: nl
Re: Any current/voltage limiting protection for 74HC165 parallel inputs?
« Reply #3 on: February 10, 2023, 04:26:53 pm »
DIP switches have been around for a long time, and I have never heard of problems with static discharge surrounding them, so I think you are safe without additional TVS diodes.

Offline kreyszigTopic starter

  • Regular Contributor
  • *
  • Posts: 131
  • Country: ca
Re: Any current/voltage limiting protection for 74HC165 parallel inputs?
« Reply #4 on: February 10, 2023, 07:35:08 pm »
DIP switches have been around for a long time, and I have never heard of problems with static discharge surrounding them, so I think you are safe without additional TVS diodes.

Ok thanks. Regarding the resistor array, I assume it makes sense to wire them to NSS and wire the other side of the DIP switches to VCC so the resistors act as pull-down when NSS goes low, but otherwise when NSS is high there will be no current flowing through them so they will consume no power regardless of the DIP switch positions?
« Last Edit: February 10, 2023, 07:37:00 pm by kreyszig »
 

Online pcprogrammer

  • Super Contributor
  • ***
  • Posts: 3698
  • Country: nl
Re: Any current/voltage limiting protection for 74HC165 parallel inputs?
« Reply #5 on: February 10, 2023, 07:49:49 pm »
You could do that, but it creates an additional load on your NSS line, which has a limited fanout. It depends on how many resistors and their value of course, and it might even draw not that much current if you just scale them right and use them in a normal way. Pull up to supply, and dip switch to ground. Very small current into the input when high, bigger current when dip switch is on.

Offline kreyszigTopic starter

  • Regular Contributor
  • *
  • Posts: 131
  • Country: ca
Re: Any current/voltage limiting protection for 74HC165 parallel inputs?
« Reply #6 on: February 10, 2023, 08:06:18 pm »
You could do that, but it creates an additional load on your NSS line, which has a limited fanout. It depends on how many resistors and their value of course, and it might even draw not that much current if you just scale them right and use them in a normal way. Pull up to supply, and dip switch to ground. Very small current into the input when high, bigger current when dip switch is on.

I was going to use 20k resistors, so 4 mA for 16 of them at 5V. My MCU pins are fine up to 50 mA draw. I would be reading the DIP switches only when resetting the board, so it would be nice to only have them consume power during the initialisation stage. If current draw through the NSS line was a concern I could always tie a transistor to NSS to drive the resistor array, but for my application I don't think it is necessary.
 

Online pcprogrammer

  • Super Contributor
  • ***
  • Posts: 3698
  • Country: nl
Re: Any current/voltage limiting protection for 74HC165 parallel inputs?
« Reply #7 on: February 10, 2023, 08:18:04 pm »
Are you running the system from a battery, that you are concerned about current draw?

When using the NSS solution to reduce the current make sure to allow enough time for the signals to settle before loading them into the shift registers. I'm assuming this is for the circuit you laid out here

Offline kreyszigTopic starter

  • Regular Contributor
  • *
  • Posts: 131
  • Country: ca
Re: Any current/voltage limiting protection for 74HC165 parallel inputs?
« Reply #8 on: February 10, 2023, 08:31:11 pm »
Are you running the system from a battery, that you are concerned about current draw?

When using the NSS solution to reduce the current make sure to allow enough time for the signals to settle before loading them into the shift registers. I'm assuming this is for the circuit you laid out here

No I would not even run the circuit from a battery (the available 2W DC supply is a bit constraining for the circuit as a whole though), but I don't really see any drawback from the NSS solution, except allowing enough time for the signals to settle, but as I mentioned I would only read the DIP switch positions once at startup so waiting a few additional ms does not matter. Yes it is related to the circuit from that other thread. I would load the values into the shift registers by sending a single high bit value through pulsing MOSI low.
« Last Edit: February 10, 2023, 08:44:01 pm by kreyszig »
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf