BH1750 Digital Light Intensity Sensor
Overview
A high-resolution light intensity sensor with a built-in 16-bit ADC that detects and outputs light brightness in Lux units. It uses I2C interface.

Specifications
- Power Supply: 2.4V-3.6V (typically 3.0V)
- Less current consumption: 0.12mA
- Measuring Range: 1-65535lx
- Communication: I2C bus
- Accuracy: +/-20%
- Built in A/D converter for converting analog illuminance in the digital data.
- Very small effect of IR radiation
- Highly responsive near to human eye.
Supported GPIO
- Raspberry Pi 0~4
- Raspberry Pi 5
- BeagleBone Black/Green
- Jetson Nano
- FT232H, FT2232H, FT4232H
- MCP2221
Commands
[CONFIG]
Sets the measurement mode.
Item | Type | Description |
---|---|---|
Measurement Mode * | WRITE | Select the measurement mode. (Continuous-High Resolution, Continuous-High Resolution2, Continuous-Low Resolution, One Time-High Resolution, One Time-High Resolution2, One Time-Low Resolution) |
* For descriptions of each measurement mode, refer to page 5 of the datasheet.
[READ_LIGHT_LEVEL]
Reads the measured light intensity.
Item | Type | Description |
---|---|---|
Light Intensity(lux) | READ | Measured light intensity (brightness). |
[MEAS_READY]
Determines whether a new measurement value is available.
Item | Type | Description |
---|---|---|
Max Wait | WRITE | Whether to apply a maximum wait time for waiting for new measurement values. |
Measurement Ready | READ | Returns true if a new measurement value is available, false otherwise. |
[SET_MT_REG]
Sets the value of MTreg (Measurement Time Register).
Item | Type | Description |
---|---|---|
MTreg Value * | WRITE | Sets the value of the Measurement Time Register. Values between 31 and 254 can be entered, with a default value of 69. This register controls the sensor’s sensitivity, with higher values increasing sensitivity. |
* For example, if the sensor is installed inside an opaque cover as shown in the image below, and the cover’s light transmittance is 50%, setting the MTreg value to twice the default value can compensate for the interference caused by the cover.

Example
Objective
Display measured light intensity on dashboard widgets.
Parts
Part | Quantity |
---|---|
Raspberry Pi 4 * | 1 |
BH1750 | 1 |
* Other hardware can also be used. Refer to Supported GPIO.
Wiring
Connect each component to the corresponding connection as listed in each row below.
BH1750 | GPIO |
---|---|
VIN | 3.3V |
GND | GND |
SCL | 3 (I2C1 SCL) |
SDA | 2 (I2C1 SDA) |
ADDR * | GND |
* If connected to GND, I2C address is 0x23, if connected to 3.3V it is 0x5C. (May vary depending on module manufacturer.)
