Hi toolbag33,
I assume you meant to say bit numbers and not pins.
Please avoid switching input pins directly to +5V. Even though it shouldn't cause damage it should be avoided.
When the switch opens it will leave the pin unconnected and floating so it will be in an indeterminate state. A pull up or down resistor is needed.
You might consider using the first 8 inputs on JP4 or JP6 which have pull down resistors and switch them to 3.3V
KFLOP IO default to being inputs. There is no need to configure them as inputs.
Regards
TK
http://dynomotion.com
Hi toolbag33,
I'm not sure what you mean. Normally outputs are described as being able to sink or source (or both) current. I suppose you mean to say should they be connected to sinking or sourcing outputs?
KFLOP inputs are very high impedance (many meg ohms) mosfet voltage sensitive inputs. They must be actively driven high (>2.0V) and actively driven low (<0.4V).
That is why a pull down or pull up resistor is required when interfacing with a simple switch. Otherwise when the switch is open nothing will be actively driving the input and the pin may float to any random voltage depending on parasitic capacitance to other signals or leakage currents.
HTH
Regards
TK
http://dynomotion.com
Actively driven as in current from the 5 volt source to the input when the switch is closed, and pulled low with a resistor when open. J7 inputs have internal resistors.
Sent from my SM-G900V using Tapatalk
Hi toolbag33,
I'm having difficulty understanding.
I already recommended to not switch 5V directly to any KFLOP inputs. Are you still doing this?
JP7 does not have any pull down resistors. Have you added some?
Regards
TK
http://dynomotion.com
Tom Kerekes,
If you not going to answer my questions in a correct and helpful way, just don't Post anything!
Sent from my SM-G900V using Tapatalk
There's got to be a ground in there some where right? So 5v to switch, to input, to ground. Current flow when the switch is closed, driving the input high. 10k ohm between the switch and ground to drive input low when switch is open.
Sent from my SM-G900V using Tapatalk
ToolBag, what you are proposing would work, however as Tom has already said, it's not ideal to connect the inputs directly to 5V.
What would be better is if your switches are at 5V, is connect a 10K resistor between the KFlop input pin and 0V, then wire a 5K resistor in series between the switch and input pin. That way when the switch is open, the 10K resistor pulls the input to 0V, but when the switch is closed and the 5V connected via the 5K resistor, the two resistors act as a voltage divider, so the input pin sees 3.3V.
I've used those values as an example, however I'd probably use lower values, as the 15k at 5V, means only 0.33mA of current flows, which could make things susceptible to noise. I'd personally aim for at least 5mA of current flowing, which means using a total resistance of just 1000ohm. But that would mean using 330ohm and 770ohm resistor, which might not be that common (without looking at a catalogue, I'm not sure if those are common values or not!). The key thing is to aim for the 2:1 ratio between the resistors, so you still get around 3.3V.
M_C,
This is just getting better! I ran chose to use j4 which have the pull down resistors when the switch is open, and ran 3.3 volts to one side of of all my limits and the other to the inputs, on j4 and it cooked my board! Godaamnit! Even though the manual said these were 3.3 volt tolerant, when I plug my board in no more lights. Oh well. I'm sure I did something wrong. But how? Did I need a ground on the input side as well?
Thanks