npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

homebridge-bme280-piotr

v2.0.1

Published

BME280 temperature/humidity/barometric-pressure sensor accessory for Homebridge, modernised for current hap-nodejs (ES6-class characteristics) and Node 18+. Fork of homebridge-bme280.

Readme

homebridge-bme280-piotr

Bosch BME280 temperature / humidity / barometric-pressure sensor accessory for Homebridge.

This is a modernised fork of homebridge-bme280 (originally by RXSeger / NorthernMan54). The original plugin (v1.2.6, ~2020) crashed on current Homebridge with:

TypeError: Class constructor Characteristic cannot be invoked without 'new'

because it defined its custom HomeKit characteristics with the pre-ES6 Characteristic.call(this, …) + util.inherits() pattern. Modern hap-nodejs ships Characteristic and Service as ES6 classes, which cannot be invoked without new. This fork rewrites those definitions as proper class … extends Characteristic, preserving every UUID, format, unit and permission. It also drops the unmaintained Google Sheets logging dependency for a lighter install. Verified on Node 18+ / Raspberry Pi running Ubuntu Server 24.04 LTS.

  • Reports temperature, humidity and barometric pressure from a BME280 over I²C.
  • Supports the Eve app history graphs (via fakegato-history).

Uses bme280-sensor.

Prerequisites — enable I²C

The BME280 talks over I²C, so the bus must be enabled and the Homebridge user must have access to it.

  1. Enable the I²C interface and load the kernel module:
    sudo apt-get update
    sudo apt-get install -y i2c-tools
    sudo modprobe i2c-dev
    echo i2c-dev | sudo tee -a /etc/modules     # load on every boot
    On Raspberry Pi OS use raspi-config → Interface Options → I2C. On Ubuntu the i2c-dev module above is the equivalent step.
  2. Give the Homebridge service user access to the bus:
    sudo usermod -aG i2c homebridge
    Restart the Homebridge service (or reboot) for the group change to take effect.
  3. Confirm the sensor is visible (address is usually 0x76 or 0x77):
    sudo i2cdetect -y 1

Installation

  1. Install Homebridge: npm install -g homebridge
  2. Install the native build prerequisites (the i2c-bus dependency compiles a native addon):
    sudo apt-get install -y build-essential python3
  3. Install this plugin: sudo npm install -g homebridge-bme280-piotr

Configuration

  • accessory: "BME280" (unchanged — existing configs keep working)
  • name: descriptive name
  • name_temperature (optional): name for the temperature sensor
  • name_humidity (optional): name for the humidity sensor
  • refresh (optional): refresh interval in seconds, default 60
  • storage (optional): fakegato history storage, fs (default) or googleDrive
  • options: options passed to bme280-sensor

Example:

"accessories": [
    {
        "accessory": "BME280",
        "name": "Sensor",
        "name_temperature": "Temperature",
        "name_humidity": "Humidity",
        "options": {
            "i2cBusNo": 1,
            "i2cAddress": "0x76"
        }
    }
]

If you get an I/O error, check the I²C address (0x76 vs 0x77, jumper-dependent) and that i2cdetect sees the device.

This plugin creates two services: TemperatureSensor and HumiditySensor (with an Atmospheric Pressure characteristic on the temperature service, as the Eve app expects).

Changes from the original

  • Custom characteristics/services rewritten as ES6 classes for current hap-nodejs.
  • Removed mcuiot-logger (Google Sheets logging) and moment dependencies.
  • engines raised to Node >= 18, Homebridge >= 1.6; marked linux-only.
  • Bumped i2c-bus/bme280-sensor/fakegato-history to current ranges.

Credits

  • RXSeger — original author and creator
  • NorthernMan54 — barometric pressure and device polling
  • simont77 — history service (fakegato)
  • Modernisation fork maintained by piotranonimowy

License

MIT (unchanged from the original)