Sensors/ KY-0xx module

ESP32 Compatible KY-0xx module Sensors

Every KY-0xx module sensor in the catalog, each with wiring, specs and code for the ESP32.

42 sensors Wiring diagrams Code for 5 frameworks

All KY-0xx module sensors

42 sensors
KY-001 Temperature Sensor ModuleKY-001 Temperature Sensor Module 1-Wire$3 KY-002 Vibration Switch ModuleKY-002 Vibration Switch Module Digital$2 KY-003 Hall Magnetic Sensor ModuleKY-003 Hall Magnetic Sensor Module Digital$2 KY-004 Key Switch ModuleKY-004 Key Switch Module Digital$1 KY-005 Infrared Transmitter ModuleKY-005 Infrared Transmitter Module Infrared$1 KY-006 Passive Buzzer ModuleKY-006 Passive Buzzer Module PWM$1 KY-008 Laser Transmitter ModuleKY-008 Laser Transmitter Module Digital$1 KY-009 RGB Full Color LED SMD ModuleKY-009 RGB Full Color LED SMD Module PWM$1 KY-010 Photo Interrupter ModuleKY-010 Photo Interrupter Module Digital$1 KY-011 Two-Color LED ModuleKY-011 Two-Color LED Module Digital$1 KY-012 Active Buzzer ModuleKY-012 Active Buzzer Module Digital$1 KY-013 Analog Temperature Sensor ModuleKY-013 Analog Temperature Sensor Module Analog$1 KY-015 Temperature and Humidity Sensor ModuleKY-015 Temperature and Humidity Sensor Module 1-Wire$2 KY-016 RGB Full Color LED ModuleKY-016 RGB Full Color LED Module PWM$1 KY-017 Mercury Tilt Switch ModuleKY-017 Mercury Tilt Switch Module Digital$1 KY-018 Photoresistor ModuleKY-018 Photoresistor Module Analog$1 KY-019 5V Relay ModuleKY-019 5V Relay Module Digital$2 KY-020 Tilt Switch ModuleKY-020 Tilt Switch Module Digital$1 KY-021 Mini Magnetic Reed Switch ModuleKY-021 Mini Magnetic Reed Switch Module Digital$1 KY-022 Infrared Receiver ModuleKY-022 Infrared Receiver Module Infrared$1 KY-023 Dual Axis Joystick ModuleKY-023 Dual Axis Joystick Module Analog$2 KY-024 Linear Magnetic Hall Sensor ModuleKY-024 Linear Magnetic Hall Sensor Module Analog · Digital$2 KY-025 Reed Switch ModuleKY-025 Reed Switch Module Analog · Digital$2 KY-026 Flame Sensor ModuleKY-026 Flame Sensor Module Analog · Digital$2 KY-027 Magic Light Cup ModuleKY-027 Magic Light Cup Module Digital$2 KY-028 Digital Temperature Sensor ModuleKY-028 Digital Temperature Sensor Module Analog · Digital$2 KY-029 Dual Color LED ModuleKY-029 Dual Color LED Module Digital$1 KY-031 Knock Sensor ModuleKY-031 Knock Sensor Module Digital$1 KY-032 Infrared Obstacle Avoidance Sensor ModuleKY-032 Infrared Obstacle Avoidance Sensor Module Digital$2 KY-033 Line Tracking Sensor ModuleKY-033 Line Tracking Sensor Module Digital$2 KY-034 Automatic Flashing Color LED ModuleKY-034 Automatic Flashing Color LED Module Digital$1 KY-035 Analog Hall Magnetic Sensor ModuleKY-035 Analog Hall Magnetic Sensor Module Analog$2 KY-036 Metal Touch Sensor ModuleKY-036 Metal Touch Sensor Module Analog · Digital$2 KY-037 High Sensitivity Sound Detection ModuleKY-037 High Sensitivity Sound Detection Module Analog · Digital$2 KY-038 Microphone Sound Sensor ModuleKY-038 Microphone Sound Sensor Module Analog · Digital$2 KY-039 Heartbeat Sensor ModuleKY-039 Heartbeat Sensor Module Analog$2 KY-040 Rotary Encoder ModuleKY-040 Rotary Encoder Module Digital$2 KY-050 Ultrasonic Distance Sensor ModuleKY-050 Ultrasonic Distance Sensor Module Digital$3 KY-051 Voltage Translator / Level ShifterKY-051 Voltage Translator / Level Shifter Digital$3 KY-052 Pressure and Temperature Sensor ModuleKY-052 Pressure and Temperature Sensor Module I2C$3 KY-053 Analog Digital Converter ModuleKY-053 Analog Digital Converter Module I2C$3 KY-054 Phototransistor ModuleKY-054 Phototransistor Module Analog$3

About KY-0xx module sensors

The KY series is the "37 sensors in one box" kit that ships under many brand names - buttons, joysticks, tilt and vibration switches, hall sensors, sound and flame detectors, LEDs and lasers. Each module does one simple thing and outputs it as a digital line, an analog level, or both, so they need little or no library support and wire up in minutes. That makes them ideal for learning the ESP32's GPIO, ADC and interrupt basics before committing to more serious parts.

Every KY page here documents the pinout, safe ESP32 wiring and working code, because the kit leaflets rarely do. Two practical notes: the analog outputs need the ESP32's ADC1 pins, and build quality varies between kit vendors, so a flaky module is sometimes just a flaky module.

At a glance
Sensors42
MostlyDigital (27 of 42)
Also1-Wire · Analog · I2C · Infrared · PWM
Typical price$1 - $3