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

@redplc/node-red-rpi-gpio

v2.0.7

Published

Node-RED nodes for Raspberry Pi gpio using with redPlc nodes.

Downloads

289

Readme

@redplc/node-red-rpi-gpio

platform platform platform

Node-RED nodes for Raspberry Pi GPIO using with redPlc nodes.

Nodes

  • rpi-gpio-in: Reads GPIO inputs and store in boolean array.
  • rpi-gpio-out: Sets GPIO outputs from boolean array.
  • rpi-gpio-pwm: Sets GPIO pwm duty cycles from number array.
  • rpi-gpio-cnt: Counts GPIO inputs pulse and store in number array.

Usage

  • Install redPlc nodes.
  • Use redPlc s-inject node for trigger update.
  • Connect to first output on s-inject node.
  • Daisy chain nodes in series.
  • For logical operations use redPlc nodes.
  • Data is exchanged with global context variable arrays.
  • Array index is equal gpio number for easy handling.
  • Select different gpio pins for input, output and pwm.
  • For open inputs select pull down/up resistors.
  • This node works on Raspberry Pi with 32bit or 64bit OS.
  • Check with raspi-config for alternate functions on GPIO.

Array Index Mapping

|Index|Funct.|Pin|Pin|Funct.|Index| |:--|:---- |:-:|:-:|:-----|:--| ||3V3|1|2|5V|| |2|GPIO02|3|4|5V|| |3|GPIO03|5|6|GND|| |4|GPIO04|7|8|GPIO14|14| ||GND|9|10|GPIO15|15| |17|GPIO17|11|12|GPIO18|18| |27|GPIO27|13|14|GND|| |22|GPIO22|15|16|GPIO23|23| ||3V3|17|18|GPIO24|24| |10|GPIO10|19|20|GND|| |9|GPIO09|21|22|GPIO25|25| |11|GPIO11|23|24|GPIO08|8| ||GND|25|26|GPIO07|7| |||27|28||| |5|GPIO05|29|30|GND|| |6|GPIO06|31|32|GPIO12|12| |13|GPIO13|33|34|GND|| |19|GPIO19|35|36|GPIO16|15| |26|GPIO26|37|38|GPIO20|20| ||GND|39|40|GPIO21|21|

Examples

Example 1

This example is a self holding circuit used for push buttons. Led turns on, if switch GPIO21 is closed. Led turns off, if switch GPIO20 is closed.

  • Connect LED with resistor (~220 Ohms) to GPIO26 and ground pin.
  • Connect switches to GPIO20 and GPIO21 and ground pin.
  • Select GPIO20 and GPIO21 as pullup inputs.
  • Select GPIO26 as output.

Example 2

This example sets led brightness to 25%, 50% or 100% with switches.

  • Connect LED with resistor (~220 Ohms) to GPIO26 and ground pin.
  • Connect switches to GPIO16, GPIO20 and GPIO21 and ground pin.
  • Select GPIO16, GPIO20 and GPIO21 as pullup inputs.
  • Select GPIO26 as pwm.