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

node-red-contrib-andinooled

v0.3.0

Published

A Node Red node that enables processing of text for the AndinoIO OLED display.

Downloads

23

Readme

Andino IO / Raspberry Pi: OLED display control nodes (Adafruit SSD1306)

A Node Red node that enables processing of text for the AndinoIO OLED display (Adafruit SSD1306).

Andino IO

Andino boards, like the Andino IO, Andino X2 and Andino X1 enable the usage of the Raspberry Pi in industrial environments by providing a housing, several digital inputs and relay outputs.

For more information, please refer to:


Node documentation

Requirements / Prerequisites

This node allows for easy control of the OLED display of Andino IO boards via Node-Red. The node needs Adafruit Python SSD1306 as well as the custom Python script for Andino IO displays to be installed. For a detailed installation guide, see here.

Usage

TCP node configuration

The communication between the Node-Red component and the python script takes place via TCP. To establish a connection, start the TCP server as described in the installation tutorial, then drag a tcp out node to the main screen of Node-Red and connect it to the output side of the AndinoOLED node. Double click the TCP node and set the properties to: Connect to, port 2961 and enter the hostname localhost. Click Done to finish the node configuration.

TCP node propertiers

Note: By default, the TCP server only listens on localhost, this can be changed by editing the python script (look for HOST = 'localhost' at the very bottom of the script if needed.

AndinoOLED node configuration

Double click the AndinoOLED node to start the configuration. Here, the output mode can be selected. Firstly, choose how many columns (one or two) the output text should have.

Afterwards, select the mode for both columns. The modes can be differentiated by the amount of lines and number of characters that fit on the screen. Chars always refers to the number of characters that fit on the screen when 1 column is selected as the type, if 2 columns is selected, only half of the listed number of characters will fit into the column.

1 column mode properties

2 column mode properties

Note: When selecting 1 column as the type, all configuration and inputs for column 2 will be ignored.

Depending on the configuration, these are some possible output formats:

display example 1 display example 2 display example 3

AndinoOLED node input

The AndinoOLED node is triggered every time it receives an input. It expects two arrays with 6 Strings for both columns, these must be named msg.lines1 for column 1 and msg.lines2 respectively. Every object in the array will be printed as a new line on the display, if a mode with less than 6 lines is chosen in the node properties, the extra Strings will be disregarded.

As a simple way to test the node, the arrays can be created using a function node. Double click the function node and enter the following code under the function tab:

var lines1 = ["test1", "test2", "test3", "test4", "test5", "test6"]
var lines2 = ["test7", "test8", "test9", "test10", "test11", "test12"]
msg.lines1 = lines1;
msg.lines2 = lines2;
return msg;

Click Done and connect the function node to the AndinoOLED node and an inject node:

Sample flow

When clicking the button on the inject node, the array messages should now appear on the display.

Sample flows