코드3 키패드 #include #define ROWS 4 #define COLS 4 //const char kp4x4Keys[ROWS][COLS] = {{'F', 'B', '8', '4'}, {'E', 'A', '7', '3'}, {'D', '0', '6', '2'}, {'C', '9', '5', '1'}}; const char kp4x4Keys[ROWS][COLS] = {{'1', '2', '3', '4'}, {'5', '6', '7', '8'}, {'9', '0', 'A', 'B'}, {'C', 'D', 'E', 'F'}}; byte rowKp4x4Pin [4] = {9, 8, 7, 6}; byte colKp4x4Pin [4] = {5, 4, 3, 2}; Keypad kp4x4 = Keypad(makeKeymap(.. 아두이노 2022. 1. 18. 초음파센서 // --------------------------------------------------------------------------- // Example NewPing library sketch that does a ping about 20 times per second. // --------------------------------------------------------------------------- #include #define TRIGGER_PIN 12 // Arduino pin tied to trigger pin on the ultrasonic sensor. #define ECHO_PIN 11 // Arduino pin tied to echo pin on the ultrasonic.. 아두이노 2022. 1. 18. 포토럽트 아두이노 2022. 1. 18. 이전 1 다음