We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
Hello,
in school we are programming a microcontroller. We have now a homework, that we have to learn how to controll the 4x4 Matrix Keyboard on the Microcontroller.
Here how it looks like:
P6.4 P6.5 P6.6 P6.7 P8.3 A1 A2 A3 A4 P8.2 B1 B2 B3 B4 P8.1 C1 C2 C3 C4 P8.0 D1 D2 D3 D4
For example if A1 is pressed P8.3 = 0 and P6.4 = 0.
I try it on many ways to controll it, when someone press a button, but i cant find out how it work.
I use for example this Code.
Thanks for help
if ((P6 & 0x01F)== 0x0E0 && (P8 & 0x0F8) == 0x07) {
.....
}
Hi there, I have moved your question to the architectures and processors forum. Many thanks.