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 🙏

© 2024 – Pkg Stats / Ryan Hefner

rbn-pi

v0.0.8

Published

Supervisor and updater for raspberry pis

Downloads

21

Readme

rbn

This is a bit of software that was built for the raspberry pi, but should work on any linux box. It's good at doing things like passing data from bluetooth low energy devices over a websocket connection, or sending data from a connected arduino up to firebase. It consists of two parts - interfaces and transports.

Interfaces

Interfaces allow the pi to collect data from other devices. Currently, the following interfaces are supported:

To add an interface, just add the interface's name in the dependancies section of your package.json file and run rbn-base.js. Make sure to use latest for the version if you want the package to auto-update. If your interface has options you can configure, you can set them in config.json.

Transports

Got some data from an interface? Awesome. Transports let you send that data somewhere on the internet.

The process for adding a transport is the same as that for an interface.

Easy Mode

  1. Install raspbian on your Pi.
  2. SSH onto your pi.
  3. Run curl -h http://...
  4. Run sudo node rbn-pi.js

Configuration

To add or remove interfaces and transports, and configure the behavior of the grid, change the options in config.json. By default, config.json looks like this:

{
  "autoUpdate": false,
  "runOnBoot": true,
  "transports": {
    "rbn-websocket": {
        "endpoint": "http://robin-grid.omrdev.com"
    }
  },
  "interfaces": {
    "rbn-rfid": {}
  }
}

Besides the interfaces and transports objects, the supported options are:

  • autoUpdate - update all modules automagically when a new version is released (default: true)
  • runOnBoot - run the grid automatically when the OS boots up using forever (default: true)

Streaming logs and debugging

Every module emits logs on a debug namespace equal to the name of the module. There is also a base namespace with the most general logs. To listen on a namespace, run pass a DEBUG argument to node, like so:

sudo DEBUG=base,websocket,ble node rbn-pi.js

If you're looking to stream logs out to a service, you should write a transport to do so!

Contributing

The Robin OS is designed to make it easy to add custom modules.

(finish this)

Creating an interface

Your module should export a single class. Your constructor will be called