#define SERIAL_BAUD 115200 #define MAX_CODE_LEN 64 #define KB_DEBOUNCE_DELAY 100 #define BUZZ_OPEN 1000 #define BUZZ_WRONG 700 #define BUZZ_NUM 1200 #define BUZZ_CLEAR 900 #define PINOUT_KBM7 4 #define PINOUT_KBM6 5 #define PINOUT_KBM5 6 #define PINOUT_KBM4 7 #define PINOUT_KBM3 12 #define PINOUT_KBM2 8 #define PINOUT_KBM1 9 #define PINOUT_LED_Y A5 #define PINOUT_LED_R A4 #define PINOUT_LED_G A3 #define PINOUT_BUZZ A2 #define PINOUT_SET A1 #define PINOUT_RELAIS A0 #define KB_ROW_1 PINOUT_KBM2 #define KB_ROW_2 PINOUT_KBM3 #define KB_ROW_3 PINOUT_KBM5 #define KB_ROW_4 PINOUT_KBM7 #define KB_COL_1 PINOUT_KBM1 #define KB_COL_2 PINOUT_KBM4 #define KB_COL_3 PINOUT_KBM6 #define KB_KEY_1 0 #define KB_KEY_2 1 #define KB_KEY_3 2 #define KB_KEY_4 3 #define KB_KEY_5 4 #define KB_KEY_6 5 #define KB_KEY_7 6 #define KB_KEY_8 7 #define KB_KEY_9 8 #define KB_KEY_C 9 #define KB_KEY_0 10 #define KB_KEY_E 11 #define KB_KEY_SET 12