Question
Extension. . Perform a 4x4 keyboard decoder, rearrange the key values to get the hexadecimal numbering and display the code in 4 LED's Programation: #include
Extension. . Perform a 4x4 keyboard decoder, rearrange the key values to get the hexadecimal numbering and display the code in 4 LED's
Programation:
#include const byte Filas = 4; //Cuatro filas const byte Cols = 4; //Cuatro columnas byte Pins_Filas[] = {6, 7, 8, 9}; //Pines Arduino a los que contamos las filas. byte Pins_Cols[] = { 2, 3, 4, 5}; // Pines Arduino a los que contamos las columnas. char Teclas [ Filas ][ Cols ] = { {'1','2','3','A'}, {'4','5','6','B'}, {'7','8','9','C'}, {'*','0','#','D'} }; Keypad Teclado1 = Keypad(makeKeymap(Teclas), Pins_Filas, Pins_Cols, Filas, Cols); void setup(){ Serial.begin(9600); } void loop(){ char pulsacion = Teclado1.getKey() ; if (pulsacion != 0) // Si el valor es 0 es que no se ha pulsado ninguna tecla Serial.println(pulsacion); }
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started