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 🙏

© 2025 – Pkg Stats / Ryan Hefner

@blackstarzes/homebridge-sonoff-basicr3

v0.1.3

Published

Homebridge plugin for the Sonoff BasicR3 DIY switch.

Downloads

13

Readme

Sonoff BasicR3

Usage

Installation

  1. Install Homebridge on your hub

    For example, Raspberry Pi:

    1. Install Raspberry Pi OS

      • Setup headless (ssh, network)
      • ssh into the Pi and change password, hostname using sudo raspi-config
    2. Install Homebridge

  2. Install the @blackstarzes/homebridge-sonoff-basicr3 plugin in Homebridge

  3. Add the Sonoff BasicR3 platform to the configuration:

    {
      "bridge": {
        "name": "Homebridge"
      },
      "accessories": [],
      "platforms": [
        {
          "platform": "SonoffBasicR3"
        }
      ]
    }
  4. Add the Homebridge accessory to HomeKit

Bootstrap

Once ssh-ed into the Pi:

# Update
sudo apt-get update -y
sudo apt-get upgrade -y
sudo apt dist-upgrade -y

# Install Node.js
curl -sL https://deb.nodesource.com/setup_12.x | sudo bash -
sudo apt-get install -y nodejs gcc g++ make python
node -v
sudo npm install -g npm

# Install Homebridge
sudo npm install -g --unsafe-perm homebridge homebridge-config-ui-x
sudo hb-service install --user homebridge

# Install mDNS
sudo apt-get install libavahi-compat-libdnssd-dev -y

Prepare your hardware for DIY mode

  1. Download the eWeLink app on iOS or Android, connect and and upgrade to the latest firmware

    This can be quite tricky the first time.

    1. Without the DIY jumper installed, power on the device. The blue LED should flash ..-.
    2. Press and hold the button until the blue LED flashes . continuously.
    3. Open the eWeLink app and add the device (requires adding it to your network - only 2.4GHz).
      • For firmware >=3.5, use quick pairing mode
      • For firmware <3.5, use compatibility mode
    4. Go into the device settings and upgrade to the latest firmware.
  2. Supply mains power to the Sonoff BasicR3's input - the device should power up.

  3. Press and hold the button until the blue LED flashes ..-.

  4. Press and hold the button until the blue LED flashes . continuously.

  5. Connect to the ITEAD-XXX access point (password is 12345678) and navigate to http://10.10.7.1 and configure this with your SSID and password.

Development

Install homebridge

  1. Follow the instructions at the GitHub Homebridge repository

    sudo npm install -g --unsafe-perm homebridge
  2. In the root directory of this repository, run:

    npm run watch
  3. Add the hub to your home (preferably in a development home), and develop away

  4. Pull requests are welcome!