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

homebridge-rcswitch-gpiomem2

v1.2.2

Published

Siri / HomeKit control of RF switches by way of homebridge. Fork of https://github.com/FWeinb/homebridge-rcswitch

Downloads

14

Readme

homebridge-rcswitch-gpiomem2

http://n8henrie.com/2015/12/control-an-rf-outlet-with-siri-via-homebridge

Control RF outlets with HomeKit / Siri using rcswitch-gpiomem2

Installation

  1. Install WiringPi
  2. Install homebridge: npm install -g homebridge
  3. Install homebridge-rcswitch-gpiomem: npm install --global homebridge-rcswitch-gpiomem
  4. Update your configuration file.

Configuration

See sample-config.json

Either onCode and offCode or systemcode and unitcode are required. My switches use on and off codes, so that's what I recommend and all I can really help with.

  • accessory: Must be RCSwitch (case sensitive)
  • name :: string :: What you want to call the switch. Keep in mind that Siri will prefer anything other than your homebridge switch if there's any confusion, so name it something unique
  • onCode, offCode :: int or string
    • If int: Decimal RF code to turn switch on / off
    • If string: Binary RF code to turn switch on / off
  • systemcode :: string :: RF system code. I don't use this, please refer to other docs.
  • unitcode :: int :: RF unit code. I don't use this, please refer to other docs.
  • pin :: int, optional :: BCM pin connected to 433 mhz transmitter, defaults to 17
  • pulseLength :: int, optional :: RF pulse length, defaults to 190
  • bitLength :: int, optional :: bit length of RF code, only used if using decimal RF code, defaults to 24
  • repeats :: int, optional :: Number of times to repeat the transmission of the code, defaults to 10 (as per the original rcswitch code)

FAQ / Troubleshooting

It seems that the gpiomem system I use and the SysFS method of interacting with the GPIO are not compatible for reasons explained in this issue. Make sure that you aren't also using programs that access the GPIO by way of SysFS or this library may not work.

Changelog

20171003 :: 1.1.5

  • Moved enableTransmit into loop to allow different accessories to use different pins (@foodbag)

20160727 :: 1.1.3

  • Move setRepeatTransmit to just before calling switchOn() to facilitate multiple switches with different desired repeat counts

20160727 :: 1.1.2

  • Move setPulseLength from initialization to just before calling switchOn() to facilitate multiple switches with different pulse lengths (closes #2).