Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

node-red-contrib-wled2

NodeRed node for WLED control

node-red, wled

readme

node-red-contrib-wled2

A node for controlling WLED devices from NodeRed. The node supports a single segment, and can control the effect (including speed and intensity), palette, color, and brightness level of the segment.

Additionally a delay can be specified. This causes the LEDs to run the selected effect until the delay expires, then switch to a solid on (or off) state. This is handy for running an effect briefly before turning on to a solid color (or turning off).

The various parameters for the LEDs can also be provided by the incoming payload via a JSON object. Supported JSON properties are:

Property Description Type Example
brightness The brightness for the LEDs. Supported range is 1 to 255. number 128
color1 An RGB array of the first effect color. number[] [255, 128, 4]
color2 An RGB array of the second effect color. number[] [128, 255, 4]
color3 An RGB array of the third effect color. number[] [4, 128, 128]
effect The number for the effect. See GitHub for the valid numbers. number 5
effectIntensity The intensity of the effect. Supported range is 0 to 255. number 128
effectSpeed The speed of the effect. Supported range is 0 to 255. number 128
delay Number of seconds to wait before switching to the Solid effect. number 5
palette The number for the palette. number 5
preset The preset to display. If specified all other properties are ignored. Set to 0 to disable sending a preset to the WLED controller. number 16
seg The segment or array of segments to configure. See the WLED JSON API documentation for information on the supported properties. object
state The state to set the LEDs to. Supported values are on, off, and toggle. string toggle

changelog

Changelog

v2.4.4 - 2021-06-16

v2.4.3 - 2021-05-30

  • Address a security vulnerability in a dependency. Resolves issue 94.

v2.4.2 - 2021-04-01

  • Address a security vulnerability in a dependency. Resolves issue 94.

v2.4.1 - 2020-12-15

  • Address a minor security vulnerability in a dependency. Resolves issue 90.

v2.4.0 - 2020-12-12

  • Presets up to 65535 are now supported. Resolves issue 87.

v2.3.0 - 2020-11-14

  • Presets can now be selected by passing preset as part of the payload or by picking the preset number from the dropdown in the node UI. Resolves issue 81.

v2.2.0 - 2020-10-18

  • Segments can now be set by passing in seg as part of the payload following the JSON format described in the WLED JSON API documentation for segments. Resolves issue 61.
  • Incoming messages without a payload no longer cause an unhandled exception. Resolves issue 73.

v2.1.4 - 2020-10-18

  • Adjust how messages are sent to WLED so all segments are affected instead of just the first. Thanks to Daniel Evans for the bug fix. Resolves issue 72.

v2.1.3 - 2020-09-12

  • Address a security vulnerability in an underlying package used by the node. Resolves issue 68.

v2.1.2 - 2020-08-12

  • Brightness works now. Resolves issue 64.

v2.1.1 - 2020-08-04

  • The off and toggle states can now be set correctly on the node. Resolves issue 62.

v2.1.0 - 2020-07-19

  • Address a low-priority security vulnerability in a 3rd party libary. Resolves issue 59.
  • Add a Connecting and Error state that shows under the node. Resolves issue 53.

v2.0.0 - 2020-07-06

Breaking changes

  • Toggling the lights on/off based on current LED state is now supported. This is done with the new state property which replaces the on property. Valid values are on, off, and toggle. The delay feature is supported for toggling as well and will correctly play the effect for the specified duration before toggling the light state. Resolves issue 52.

v1.4.0 - 2020-07-05

  • All logged warnings now report through NodeRed logging systems instead of console logs. Resolves issue 40.
  • Corrected the name of the node in package.json. Resolves issue 42.
  • Disconnected state shows correctly now. Resolves issue 41.

v1.3.1 - 2020-07-04

  • Clean up an error when retrieving effects and palettes. Resolves issue 35.
  • Clean up an unnecessary error when the node is first created. Resolves issue 37.

v1.3.0 - 2020-07-04

  • Effects and palettes are now properly loaded from the devices, with fallback to defaults. Resolves issue 33.
  • Miscellaneous auto-discovery improvements. Resolves issue 29 and issue 30.

v1.2.1 - 2020-07-03

  • Auto-discovery now works for NodeRed installs hosted inside Home Assistant. Resolves issue 27.

v1.2.0 - 2020-07-03

  • Auto-discovery of WLED devices is now supported. Resolves issue 23.
  • Node name now shows in italics if set to a custom name. Resolves issue 20.

v1.1.0 - 2020-07-02

  • Delay field is now validated to confirm it is a number. Resolves issue 15.
  • A default list of effects and palettes is shown when retrieving the lists from a WLED device fails. Resolves issue 16.