PortC.(x) = LOW, pressing switch PortB.(x) goes LOW
I assume you're still using the schematic shown in mexi-trainmatrix.jpg from post #71.
Probably a bad assumption on my part but that's all I've got to work with.
Assuming you have the portB(x) pin pulled high, when the switch is NOT pressed you'll read a high
on the portB(x) pin from the pullup when the PortC(x) pin is either high or low. So far so good.
Now, set portC(x) = 0. Press the switch. The diode now has 0V on the positive side and +5V from the pullup on the negative side.
That's called reverse-biased... the diode doesn't conduct. So as far as the matrix is concerned you could just pull it
out of the circuit. What's on the portB(x) pin? The 5V from the pullup, so the portB(x) pin again reads high.
As shown the portB pins can NEVER read low (unless you decide to start writing to the input ports again).
Once you get the matrix stright, you do realize that at the same time you're scanning the keys you'll have to scan the LED outputs as well,
right? If you start adding the typical "delayms(500)" calls the LEDs are going to blink all over the place.
It's all doable but not until 30 pages of posts and no conclusion
That might be overly optimistic, Mike. I'm figuring 20-30 pages just to get the switches scanned. Then, lighting the leds will take...