GY-302 BH1750 Digital Light Sensor Module for Arduino 3V-5V
GY-302 BH1750 Digital Light Sensor Module
High-Precision Ambient Light Sensing for Arduino Projects
Introduction
The GY-302 BH1750 is a digital ambient light sensor that measures illuminance in lux (lx) with high resolution (1-65535 lx). This I2C interface module operates from 3V to 5V and is ideal for automatic brightness adjustment in displays, smart lighting systems, and environmental monitoring.
Key Features
Wide Range
1-65535 lx measurement range
High Resolution
1 lx resolution at low light levels
Low Power
0.12mA active current (0.01μA standby)
Spectral Response
Close to human eye sensitivity
Technical Specifications
| Measurement Range | 1 – 65535 lx |
|---|---|
| Resolution | 1 lx (at 0-5461 lx range) |
| Accuracy | ±20% (typical) |
| Supply Voltage | 2.4V – 3.6V (5V tolerant I/O) |
| I2C Address | 0x23 (default) or 0x5C (ADDR pin high) |
| Interface | I2C (up to 400kHz) |
Pin Configuration

| Pin | Label | Description | Arduino Connection |
|---|---|---|---|
| 1 | VCC | Power (3.3V recommended) | 3.3V |
| 2 | GND | Ground | GND |
| 3 | SCL | I2C Clock | A5 (Uno) or SCL |
| 4 | SDA | I2C Data | A4 (Uno) or SDA |
| 5 | ADDR | Address Select | GND (0x23) or VCC (0x5C) |
Note: Module includes pull-up resistors for I2C lines
Wiring Diagram (Arduino Uno)
// Basic Connections: // VCC → 3.3V (or 5V with level shifting) // GND → GND // SCL → A5 (or SCL) // SDA → A4 (or SDA) // ADDR → GND (for default address 0x23)
Basic Light Measurement
#include
#include
BH1750 lightMeter;
void setup() {
Serial.begin(9600);
Wire.begin();
lightMeter.begin(BH1750::CONTINUOUS_HIGH_RES_MODE);
Serial.println("BH1750 Test");
}
void loop() {
float lux = lightMeter.readLightLevel();
Serial.print("Light: ");
Serial.print(lux);
Serial.println(" lx");
delay(1000);
}
Library Required: Install “BH1750” by Christopher Laws via Arduino Library Manager
Advanced Configuration
Measurement Modes
// Set different measurement modes
lightMeter.begin(BH1750::CONTINUOUS_HIGH_RES_MODE); // Default
// Other options:
// CONTINUOUS_HIGH_RES_MODE_2
// CONTINUOUS_LOW_RES_MODE
// ONE_TIME_HIGH_RES_MODE
// ONE_TIME_LOW_RES_MODE
Address Selection
// Use alternate I2C address (ADDR pin to VCC)
BH1750 lightMeter(0x5C);
Measurement Timing
// Adjust measurement time (69 default)
lightMeter.adjustMtreg(138); // Double sensitivity
// Range: 31 (min) to 254 (max)
Power Saving
// Power down sensor between readings
lightMeter.begin(BH1750::ONE_TIME_HIGH_RES_MODE);
// Takes measurement then auto-powers down
Troubleshooting
No Readings
- Verify I2C connections (SDA/SCL)
- Check with I2C scanner sketch
- Confirm power supply (3.3V recommended)
Incorrect Values
- Ensure proper measurement mode selected
- Check for light leaks or shadows
- Calibrate against known light source
Communication Errors
- Add 4.7kΩ pull-up resistors if missing
- Reduce I2C clock speed if using long wires
- Check for address conflicts
Related Posts
IC 74173 – 4-Bit D-Type Register with 3-State Outputs
IC 74173 - 4-Bit D-Type Register with 3-State Outputs
TTL Quad D Flip-Flop with Asynchronous Clear and Output ...
DIY Metal Detector Kit
DIY Metal Detector Kit
DC 3V-5V Non-Contact Sensor Module with 60mm Detection Range
Introduc...
CNC V3 Shield with 4 A4988 Drivers
CNC V3 Shield with 4 A4988 Drivers
Complete Arduino-compatible CNC controller for 3D printers and mi...
CN3791 12V MPPT Solar Charger Module
CN3791 12V MPPT Solar Charger Module
Maximum Power Point Tracking Solar Charge Controller for Lead-Acid/Lithiu...
CJMCU-TRRS 3.5mm Jack AV Stereo Module
CJMCU-TRRS 3.5mm Jack AV Stereo Module
Compact breakout board for audio/video signal interfacing with TRRS con...
TTP223 Capacitive Touch Sensor Module (Red)
TTP223 Capacitive Touch Sensor Module (Red)
Single-Key Touch Detection with Digital Output for Arduino and DIY...
Capacitive Soil Moisture Sensor
Capacitive Soil Moisture Sensor
Corrosion-Resistant Humidity Detection for Plants and Agricultural Application...
VHM-314 Bluetooth Audio Receiver Board Module
VHM-314 Bluetooth Audio Receiver Board Module
High-fidelity stereo audio receiver with Bluetooth 5.0 and 3.5mm...
BD243 DIY Mini Tesla Coil Prototyping Kit
BD243 DIY Mini Tesla Coil Prototyping Kit
High-Voltage Wireless Power Demonstration - Build Your Own Spark Gap...
BF120-3AA Precision Strain Gauges (120Ω)
BF120-3AA Precision Strain Gauges (120Ω)
High-precision foil strain gauges for load cell applications with 120...
AI Thinker ESP32-CAM Development Board
AI Thinker ESP32-CAM Development Board
WiFi + Bluetooth with OV2640 Camera Module - Arduino Compatib...

Recent Comments