Node-red-node-pi-neopixel - Control multiple LEDs at same time (not in succession)

#1

I'm playing around with a WS2812B LED strip. I have it working from following the fantastic guide located here. What I can't figure out how to do though is control multiple LEDs at the same time. For example, I wan to turn the entire strip blue. I can send "0,0,255" and it will turn all of the LEDs blue or I could send "1,10,0,0,255" to make the first 10 LEDs blue but it turns the first one blue, then the second one, etc. Is there a way to turn them all (or selected LEDs) blue at the same time?

I know this can be done with FastLED on arduino but can't seem to find how to do that same thing with this node.

#2

What have you set the wipe time to ?

#3

I have it set to 0. On my one meter strand, it almost looks like they come on at the same time but on a longer strand (I plan on using a 5-6 meter strand), I think it would be pretty obvious that they aren't.

#4

Are you using a Raspberry Pi? If so, it has been my experience that they cannot really control lots of Neopixels quickly. Instead of bit-banging with (semi) precise timing like with an Arduino or similar (Teensy, clones, ESPXXYY), the RPi uses a pulse-width modulation scheme to generate the bit stream to the pixels. Quoting from the Adafruit Neopixel Advanced Coding Guide:

The Raspberry Pi running Linux is a multitasking system, and control may switch among multiple running programs at any time. As such, it’s impossible to guarantee the strict 800 KHz signal required by NeoPixels. You may be able to fudge it for short intervals, but it’s not something that can be counted upon.

I had a project where I needed to control a strip about 10ft long and I programmed up an Arduino Nano clone to drive the pixels with the patterns I wanted and then switching between them by fiddling GPIO pins in parallel.

#5

I think the main reason for this is due to this code

def setPixels(strip, s, e, color, wait_ms=30):
    """Set pixels from s(tart) to e(nd)"""
    for i in range(s, e+1):
        strip.setPixelColor(i, color)
        strip.show()
        time.sleep(wait_ms/1000.0)

in the main python prog.

It updates and re-displays all the pixels each time
It can probably be speeded up considerably by explicitly checking for a wait_ms time of 0 so that all the pixel values are updated and only one refresh performed at the end

def setPixels(strip, s, e, color, wait_ms=30):
    """Set pixels from s(tart) to e(nd)"""
    if (wait_ms == 0):
        for i in range(s, e+1):
            strip.setPixelColor(i, color)
        strip.show()
    else:
        for i in range(s, e+1):
            strip.setPixelColor(i, color)
            strip.show()
            time.sleep(wait_ms/1000.0)

I'll test it out and issue a PR

Simon

2 Likes
#6

I have an experimental version that uses a native node JS library (as opposed to Python) which has been working pretty good for me. It expects a full buffer for each frame in the payload so you will need to manage individual pixels upstream. You can find it here:

5 Likes
#7

Thanks @CaptClaude. I am using a Raspberry Pi (I meant to mention that in the original post). I could switch to Arduino if needed. I'll see if Simon's solution works.

#8

Thanks @nlecaude. I'll play around with that one a big as well.

#9

Thanks Simon. I'm curious what you'll find out.

#10

60 Neopixel strip showing start of strip and end of strip

Before speedup

After

1 Like
#11

Simon,,
happy to just grab your code from above if you like (or wait for a PR :-). up to you.

(Also - I think same fix should also be applied to the wipe and 2 shift functions.)

#12

(Also - I think same fix should also be applied to the wipe and 2 shift functions.)

yep - just done and tested that

Saves me a lot of effort :slight_smile:

#!/usr/bin/python

# Import library functions we need
import sys
import time
try:
   from rpi_ws281x import __version__, PixelStrip, Adafruit_NeoPixel, Color
except ImportError:
   from neopixel import Adafruit_NeoPixel as PixelStrip, Color
   __version__ = "legacy"

try:
   raw_input          # Python 2
except NameError:
   raw_input = input  # Python 3

# LED strip configuration:
LED_COUNT      = 8      # Number of LED pixels.
LED_PIN        = 18      # GPIO pin connected to the pixels (must support PWM!).
LED_FREQ_HZ    = 800000  # LED signal frequency in hertz (usually 800khz)
LED_DMA        = 10      # DMA channel to use for generating signal (try 10)
LED_BRIGHTNESS = 255     # Set to 0 for darkest and 255 for brightest
LED_INVERT     = False   # True to invert the signal (when using NPN transistor level shift)
LED_CHANNEL    = 0       # PWM channel
LED_GAMMA = [
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2,
2, 2, 2, 3, 3, 3, 3, 3, 4, 4, 4, 4, 5, 5, 5, 5,
6, 6, 6, 7, 7, 7, 8, 8, 8, 9, 9, 9, 10, 10, 11, 11,
11, 12, 12, 13, 13, 13, 14, 14, 15, 15, 16, 16, 17, 17, 18, 18,
19, 19, 20, 21, 21, 22, 22, 23, 23, 24, 25, 25, 26, 27, 27, 28,
29, 29, 30, 31, 31, 32, 33, 34, 34, 35, 36, 37, 37, 38, 39, 40,
40, 41, 42, 43, 44, 45, 46, 46, 47, 48, 49, 50, 51, 52, 53, 54,
55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70,
71, 72, 73, 74, 76, 77, 78, 79, 80, 81, 83, 84, 85, 86, 88, 89,
90, 91, 93, 94, 95, 96, 98, 99,100,102,103,104,106,107,109,110,
111,113,114,116,117,119,120,121,123,124,126,128,129,131,132,134,
135,137,138,140,142,143,145,146,148,150,151,153,155,157,158,160,
162,163,165,167,169,170,172,174,176,178,179,181,183,185,187,189,
191,193,194,196,198,200,202,204,206,208,210,212,214,216,218,220,
222,224,227,229,231,233,235,237,239,241,244,246,248,250,252,255]


LED_COUNT = max(0,int(sys.argv[1]))
WAIT_MS = max(0,int(sys.argv[2]))
MODE = sys.argv[3]
LED_BRIGHTNESS = min(255,int(max(0,float(sys.argv[4])) * 255 / 100))
if (sys.argv[5].lower() != "true"):
   LED_GAMMA = range(256)

def getRGBfromI(RGBint):
   blue =  RGBint & 255
   green = (RGBint >> 8) & 255
   red =   (RGBint >> 16) & 255
   return red, green, blue

# Define functions which animate LEDs in various ways.
def setPixel(strip, i, color):
   """Set a single pixel"""
   strip.setPixelColor(i, color)
   strip.show()

def setPixels(strip, s, e, color, wait_ms=30):
   """Set pixels from s(tart) to e(nd)"""
   if (wait_ms > 0):
       for i in range(s, e+1):
           strip.setPixelColor(i, color)
           strip.show()
           time.sleep(wait_ms/1000.0)
   else:
       for i in range(s, e+1):
           strip.setPixelColor(i, color)
       strip.show()

def setBrightness(strip, brightness, wait_ms=30):
   """Set overall brighness"""
   strip.setBrightness(brightness)
   strip.show()
   time.sleep(wait_ms/1000.0)

def colorWipe(strip, color, wait_ms=30):
   """Wipe color across display a pixel at a time."""
   if (wait_ms > 0):
       for i in range(strip.numPixels()):
           strip.setPixelColor(i, color)
           strip.show()
           time.sleep(wait_ms/1000.0)
   else:
       for i in range(strip.numPixels()):
           strip.setPixelColor(i, color)
       strip.show()
   
def shiftUp(strip, color, wait_ms=30):
   """Shift all pixels one way."""
   oldcolour = strip.getPixelColor(0)
   strip.setPixelColor(0, color)
   strip.show()
   if (wait_ms > 0):
       time.sleep(wait_ms/1000.0)
       for i in range(1,LED_COUNT):
           newcolour = oldcolour
           oldcolour = strip.getPixelColor(i)
           strip.setPixelColor(i, newcolour)
           strip.show()
           time.sleep(wait_ms/1000.0)
   else:
       for i in range(1,LED_COUNT):
           newcolour = oldcolour
           oldcolour = strip.getPixelColor(i)
           strip.setPixelColor(i, newcolour)
       strip.show()

def shiftDown(strip, color, wait_ms=30):
   """Shift all pixels the other way."""
   oldcolour = strip.getPixelColor(LED_COUNT-1)
   strip.setPixelColor(LED_COUNT-1, color)
   strip.show()
   if (wait_ms > 0):
       time.sleep(wait_ms/1000.0)
       for i in range(LED_COUNT-2,-1,-1):
           newcolour = oldcolour
           oldcolour = strip.getPixelColor(i)
           strip.setPixelColor(i, newcolour)
           strip.show()
           time.sleep(wait_ms/1000.0)
   else:
       for i in range(LED_COUNT-2,-1,-1):
           newcolour = oldcolour
           oldcolour = strip.getPixelColor(i)
           strip.setPixelColor(i, newcolour)
       strip.show()

def wheel(pos):
   """Generate rainbow colors across 0-255 positions."""
   if pos < 85:
       return Color(pos * 3, 255 - pos * 3, 0)
   elif pos < 170:
       pos -= 85
       return Color(255 - pos * 3, 0, pos * 3)
   else:
       pos -= 170
       return Color(0, pos * 3, 255 - pos * 3)

def rainbow(strip, wait_ms=20, iterations=2):
   """Draw rainbow that fades across all pixels at once."""
   for j in range(256*iterations):
       for i in range(strip.numPixels()):
           strip.setPixelColor(i, wheel((i+j) & 255))
       strip.show()
       time.sleep(wait_ms/1000.0)

def rainbowCycle(strip, wait_ms=20, iterations=2):
   """Draw rainbow that uniformly distributes itself across all pixels."""
   for j in range(256*iterations):
       for i in range(strip.numPixels()):
           strip.setPixelColor(i, wheel(((i * 256 / strip.numPixels()) + j) & 255))
       strip.show()
       time.sleep(wait_ms/1000.0)

# Main loop:
if __name__ == '__main__':
   # Create NeoPixel object with appropriate configuration.
   #strip = Adafruit_NeoPixel(LED_COUNT, LED_PIN, LED_FREQ_HZ, LED_DMA, LED_INVERT, LED_BRIGHTNESS)
   if __version__ == "legacy":
       strip = PixelStrip(LED_COUNT, LED_PIN, LED_FREQ_HZ, LED_DMA, LED_INVERT, LED_BRIGHTNESS, LED_CHANNEL)
   else:
       strip = PixelStrip(LED_COUNT, LED_PIN, LED_FREQ_HZ, LED_DMA, LED_INVERT, LED_BRIGHTNESS, LED_CHANNEL, LED_GAMMA)# Intialize the library (must be called once before other functions).

   strip.begin()

   ## Color wipe animations.
   colorWipe(strip, Color(127, 0, 0), WAIT_MS)  # Red wipe
   colorWipe(strip, Color(0, 127, 0), WAIT_MS)  # Green wipe
   colorWipe(strip, Color(0, 0, 127), WAIT_MS)  # Blue wipe
   colorWipe(strip, Color(0, 0, 0), WAIT_MS)  # Off wipe

   ## Rainbow animations.
   #rainbow(strip)
   #rainbowCycle(strip)
   #colorWipe(strip, Color(0, 0, 0))  # Off wipe

   while True:
       try:
           data = raw_input()
           bits = data.split(',')
           if len(bits) == 2:
               if bits[0] == "brightness":
                   setBrightness(strip, min(255,max(0,int(bits[1]))), WAIT_MS)
           if len(bits) == 3:
               if MODE == "shiftu":
                   shiftUp(strip, Color(int(bits[0]), int(bits[1]), int(bits[2])), WAIT_MS)
               elif MODE == "shiftd":
                   shiftDown(strip, Color(int(bits[0]), int(bits[1]), int(bits[2])), WAIT_MS)
               else:
                   colorWipe(strip, Color(int(bits[0]), int(bits[1]), int(bits[2])), WAIT_MS)
           if (MODE[0] == 'p' and len(bits) == 4):
               setPixel(strip, int(bits[0]), Color(int(bits[1]), int(bits[2]), int(bits[3]) ))
           if (MODE[0] == 'p' and len(bits) == 5):
               setPixels(strip, int(bits[0]), int(bits[1]), Color(int(bits[2]), int(bits[3]), int(bits[4]) ), WAIT_MS)
       except (EOFError, SystemExit):  # hopefully always caused by us sigint'ing the program
           sys.exit(0)
       except Exception as ex:
           print("bad data: "+data)
           print(ex)

#13

Hmm - apart from the fact you have changed all the indentation... so now I have a load of effort :frowning:

#14

For some reason - it just didn't paste properly :frowning:
I've raised PR instead but awaiting checks

#15

too late... :slight_smile:

#16

it must have been the Github God's sending us a message about not taking shorcuts :slight_smile:
Just pasting again to see what happens this time

#!/usr/bin/python

# Import library functions we need
import sys
import time
try:
    from rpi_ws281x import __version__, PixelStrip, Adafruit_NeoPixel, Color
except ImportError:
    from neopixel import Adafruit_NeoPixel as PixelStrip, Color
    __version__ = "legacy"

try:
    raw_input          # Python 2
except NameError:
    raw_input = input  # Python 3

# LED strip configuration:
LED_COUNT      = 8      # Number of LED pixels.
LED_PIN        = 18      # GPIO pin connected to the pixels (must support PWM!).
LED_FREQ_HZ    = 800000  # LED signal frequency in hertz (usually 800khz)
LED_DMA        = 10      # DMA channel to use for generating signal (try 10)
LED_BRIGHTNESS = 255     # Set to 0 for darkest and 255 for brightest
LED_INVERT     = False   # True to invert the signal (when using NPN transistor level shift)
LED_CHANNEL    = 0       # PWM channel
LED_GAMMA = [
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2,
2, 2, 2, 3, 3, 3, 3, 3, 4, 4, 4, 4, 5, 5, 5, 5,
6, 6, 6, 7, 7, 7, 8, 8, 8, 9, 9, 9, 10, 10, 11, 11,
11, 12, 12, 13, 13, 13, 14, 14, 15, 15, 16, 16, 17, 17, 18, 18,
19, 19, 20, 21, 21, 22, 22, 23, 23, 24, 25, 25, 26, 27, 27, 28,
29, 29, 30, 31, 31, 32, 33, 34, 34, 35, 36, 37, 37, 38, 39, 40,
40, 41, 42, 43, 44, 45, 46, 46, 47, 48, 49, 50, 51, 52, 53, 54,
55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70,
71, 72, 73, 74, 76, 77, 78, 79, 80, 81, 83, 84, 85, 86, 88, 89,
90, 91, 93, 94, 95, 96, 98, 99,100,102,103,104,106,107,109,110,
111,113,114,116,117,119,120,121,123,124,126,128,129,131,132,134,
135,137,138,140,142,143,145,146,148,150,151,153,155,157,158,160,
162,163,165,167,169,170,172,174,176,178,179,181,183,185,187,189,
191,193,194,196,198,200,202,204,206,208,210,212,214,216,218,220,
222,224,227,229,231,233,235,237,239,241,244,246,248,250,252,255]


LED_COUNT = max(0,int(sys.argv[1]))
WAIT_MS = max(0,int(sys.argv[2]))
MODE = sys.argv[3]
LED_BRIGHTNESS = min(255,int(max(0,float(sys.argv[4])) * 255 / 100))
if (sys.argv[5].lower() != "true"):
    LED_GAMMA = range(256)

def getRGBfromI(RGBint):
    blue =  RGBint & 255
    green = (RGBint >> 8) & 255
    red =   (RGBint >> 16) & 255
    return red, green, blue

# Define functions which animate LEDs in various ways.
def setPixel(strip, i, color):
    """Set a single pixel"""
    strip.setPixelColor(i, color)
    strip.show()

def setPixels(strip, s, e, color, wait_ms=30):
    """Set pixels from s(tart) to e(nd)"""
    if (wait_ms > 0):
        for i in range(s, e+1):
            strip.setPixelColor(i, color)
            strip.show()
            time.sleep(wait_ms/1000.0)
    else:
        for i in range(s, e+1):
            strip.setPixelColor(i, color)
        strip.show()

def setBrightness(strip, brightness, wait_ms=30):
    """Set overall brighness"""
    strip.setBrightness(brightness)
    strip.show()
    time.sleep(wait_ms/1000.0)

def colorWipe(strip, color, wait_ms=30):
    """Wipe color across display a pixel at a time."""
    if (wait_ms > 0):
        for i in range(strip.numPixels()):
            strip.setPixelColor(i, color)
            strip.show()
            time.sleep(wait_ms/1000.0)
    else:
        for i in range(strip.numPixels()):
            strip.setPixelColor(i, color)
        strip.show()
    
def shiftUp(strip, color, wait_ms=30):
    """Shift all pixels one way."""
    oldcolour = strip.getPixelColor(0)
    strip.setPixelColor(0, color)
    strip.show()
    if (wait_ms > 0):
        time.sleep(wait_ms/1000.0)
        for i in range(1,LED_COUNT):
            newcolour = oldcolour
            oldcolour = strip.getPixelColor(i)
            strip.setPixelColor(i, newcolour)
            strip.show()
            time.sleep(wait_ms/1000.0)
    else:
        for i in range(1,LED_COUNT):
            newcolour = oldcolour
            oldcolour = strip.getPixelColor(i)
            strip.setPixelColor(i, newcolour)
        strip.show()

def shiftDown(strip, color, wait_ms=30):
    """Shift all pixels the other way."""
    oldcolour = strip.getPixelColor(LED_COUNT-1)
    strip.setPixelColor(LED_COUNT-1, color)
    strip.show()
    if (wait_ms > 0):
        time.sleep(wait_ms/1000.0)
        for i in range(LED_COUNT-2,-1,-1):
            newcolour = oldcolour
            oldcolour = strip.getPixelColor(i)
            strip.setPixelColor(i, newcolour)
            strip.show()
            time.sleep(wait_ms/1000.0)
    else:
        for i in range(LED_COUNT-2,-1,-1):
            newcolour = oldcolour
            oldcolour = strip.getPixelColor(i)
            strip.setPixelColor(i, newcolour)
        strip.show()

def wheel(pos):
    """Generate rainbow colors across 0-255 positions."""
    if pos < 85:
        return Color(pos * 3, 255 - pos * 3, 0)
    elif pos < 170:
        pos -= 85
        return Color(255 - pos * 3, 0, pos * 3)
    else:
        pos -= 170
        return Color(0, pos * 3, 255 - pos * 3)

def rainbow(strip, wait_ms=20, iterations=2):
    """Draw rainbow that fades across all pixels at once."""
    for j in range(256*iterations):
        for i in range(strip.numPixels()):
            strip.setPixelColor(i, wheel((i+j) & 255))
        strip.show()
        time.sleep(wait_ms/1000.0)

def rainbowCycle(strip, wait_ms=20, iterations=2):
    """Draw rainbow that uniformly distributes itself across all pixels."""
    for j in range(256*iterations):
        for i in range(strip.numPixels()):
            strip.setPixelColor(i, wheel(((i * 256 / strip.numPixels()) + j) & 255))
        strip.show()
        time.sleep(wait_ms/1000.0)

# Main loop:
if __name__ == '__main__':
    # Create NeoPixel object with appropriate configuration.
    #strip = Adafruit_NeoPixel(LED_COUNT, LED_PIN, LED_FREQ_HZ, LED_DMA, LED_INVERT, LED_BRIGHTNESS)
    if __version__ == "legacy":
        strip = PixelStrip(LED_COUNT, LED_PIN, LED_FREQ_HZ, LED_DMA, LED_INVERT, LED_BRIGHTNESS, LED_CHANNEL)
    else:
        strip = PixelStrip(LED_COUNT, LED_PIN, LED_FREQ_HZ, LED_DMA, LED_INVERT, LED_BRIGHTNESS, LED_CHANNEL, LED_GAMMA)# Intialize the library (must be called once before other functions).

    strip.begin()

    ## Color wipe animations.
    colorWipe(strip, Color(127, 0, 0), WAIT_MS)  # Red wipe
    colorWipe(strip, Color(0, 127, 0), WAIT_MS)  # Green wipe
    colorWipe(strip, Color(0, 0, 127), WAIT_MS)  # Blue wipe
    colorWipe(strip, Color(0, 0, 0), WAIT_MS)  # Off wipe

    ## Rainbow animations.
    #rainbow(strip)
    #rainbowCycle(strip)
    #colorWipe(strip, Color(0, 0, 0))  # Off wipe

    while True:
        try:
            data = raw_input()
            bits = data.split(',')
            if len(bits) == 2:
                if bits[0] == "brightness":
                    setBrightness(strip, min(255,max(0,int(bits[1]))), WAIT_MS)
            if len(bits) == 3:
                if MODE == "shiftu":
                    shiftUp(strip, Color(int(bits[0]), int(bits[1]), int(bits[2])), WAIT_MS)
                elif MODE == "shiftd":
                    shiftDown(strip, Color(int(bits[0]), int(bits[1]), int(bits[2])), WAIT_MS)
                else:
                    colorWipe(strip, Color(int(bits[0]), int(bits[1]), int(bits[2])), WAIT_MS)
            if (MODE[0] == 'p' and len(bits) == 4):
                setPixel(strip, int(bits[0]), Color(int(bits[1]), int(bits[2]), int(bits[3]) ))
            if (MODE[0] == 'p' and len(bits) == 5):
                setPixels(strip, int(bits[0]), int(bits[1]), Color(int(bits[2]), int(bits[3]), int(bits[4]) ), WAIT_MS)
        except (EOFError, SystemExit):  # hopefully always caused by us sigint'ing the program
            sys.exit(0)
        except Exception as ex:
            print("bad data: "+data)
            print(ex)

And of course it works this time..... :slight_smile:

#17

@dceejay has updated the node to 0.0.23 - its available on npm or can be upgraded via manage palette in the menu (you need to restart Node-RED after the install)

Try it out and see if its fast enough for you

1 Like
#18

Thanks @cymplecy and @dceejay for working on this. I upgraded to 0.0.23 but now the NeoPixel node shows OK for a split second when deploying a flow or restarting Node-RED and then just shows "stopped".

image

If I revert back to 0.0.22 then it still works fine. Here is the log showing starting with Node-RED starting using 0.0.22 and then upgrading it to 0.0.23 using Palette Manager, stopping and starting Node-RED. I'm assuming the issue has to do with the very last line (session closed for user root) as that doesn't happen when using 0.0.22. I have even restarted my RPi but that didn't change anything. Lastly, I uninstalled it again and tried installing it from command line but still no change. I'm just not sure why it is happening or if there is another log I can look at.

Started Node-RED graphical event wiring tool.
25 Nov 22:36:48 - [info]
Welcome to Node-RED
===================
25 Nov 22:36:48 - [info] Node-RED version: v0.19.4
25 Nov 22:36:48 - [info] Node.js version: v8.12.0
25 Nov 22:36:48 - [info] Linux 4.14.79+ arm LE
25 Nov 22:36:51 - [info] Loading palette nodes
25 Nov 22:37:07 - [info] Dashboard version 2.11.0 started at /ui
25 Nov 22:37:11 - [info] Settings file : /home/pi/.node-red/settings.js
25 Nov 22:37:11 - [info] Context store : 'default' [module=memory]
25 Nov 22:37:11 - [info] User directory : /home/pi/.node-red
25 Nov 22:37:11 - [warn] Projects disabled : editorTheme.projects.enabled=false
25 Nov 22:37:11 - [info] Flows file : /home/pi/.node-red/flows_RPiZeroW.json
25 Nov 22:37:11 - [info] Server now running at http://127.0.0.1:1880/
25 Nov 22:37:11 - [warn]
---------------------------------------------------------------------
Your flow credentials file is encrypted using a system-generated key.
If the system-generated key is lost for any reason, your credentials
file will not be recoverable, you will have to delete it and re-enter
your credentials.
You should set your own key using the 'credentialSecret' option in
your settings file. Node-RED will then re-encrypt your credentials
file using your chosen key the next time you deploy a change.
---------------------------------------------------------------------
25 Nov 22:37:11 - [info] [GenericBLE] Start BLE scanning
25 Nov 22:37:12 - [info] Starting flows
25 Nov 22:37:12 - [info] [GenericBLE] Start BLE scanning
25 Nov 22:37:12 - [info] Started flows
pi : TTY=unknown ; PWD=/home/pi ; USER=root ; COMMAND=/usr/bin/python -u /home/pi/.node-red/node_modules/node-red-node-pi-neopixel/neopix.py 60 0 pixels 30 true
pam_unix(sudo:session): session opened for user root by (uid=0)
25 Nov 22:39:10 - [info] Upgrading module: node-red-node-pi-neopixel to version: 0.0.23
25 Nov 22:39:55 - [info] Upgraded module: node-red-node-pi-neopixel. Restart Node-RED to use the new version
Stopping Node-RED graphical event wiring tool...
25 Nov 22:40:46 - [info] Stopping flows
pam_unix(sudo:session): session closed for user root
nodered.service: Main process exited, code=exited, status=1/FAILURE
Stopped Node-RED graphical event wiring tool.
nodered.service: Unit entered failed state.
nodered.service: Failed with result 'exit-code'.
Started Node-RED graphical event wiring tool.
25 Nov 22:41:11 - [info]
Welcome to Node-RED
===================
25 Nov 22:41:11 - [info] Node-RED version: v0.19.4
25 Nov 22:41:11 - [info] Node.js version: v8.12.0
25 Nov 22:41:11 - [info] Linux 4.14.79+ arm LE
25 Nov 22:41:15 - [info] Loading palette nodes
25 Nov 22:41:30 - [info] Dashboard version 2.11.0 started at /ui
25 Nov 22:41:34 - [info] Settings file : /home/pi/.node-red/settings.js
25 Nov 22:41:34 - [info] Context store : 'default' [module=memory]
25 Nov 22:41:34 - [info] User directory : /home/pi/.node-red
25 Nov 22:41:34 - [warn] Projects disabled : editorTheme.projects.enabled=false
25 Nov 22:41:34 - [info] Flows file : /home/pi/.node-red/flows_RPiZeroW.json
25 Nov 22:41:34 - [info] Server now running at http://127.0.0.1:1880/
25 Nov 22:41:34 - [warn]
---------------------------------------------------------------------
Your flow credentials file is encrypted using a system-generated key.
If the system-generated key is lost for any reason, your credentials
file will not be recoverable, you will have to delete it and re-enter
your credentials.
You should set your own key using the 'credentialSecret' option in
your settings file. Node-RED will then re-encrypt your credentials
file using your chosen key the next time you deploy a change.
---------------------------------------------------------------------
25 Nov 22:41:34 - [info] [GenericBLE] Start BLE scanning
25 Nov 22:41:35 - [info] Starting flows
25 Nov 22:41:35 - [info] [GenericBLE] Start BLE scanning
25 Nov 22:41:35 - [info] Started flows
pi : TTY=unknown ; PWD=/home/pi ; USER=root ; COMMAND=/usr/bin/python -u /home/pi/.node-red/node_modules/node-red-node-pi-neopixel/neopix.py 60 0 pixels 30 true
pam_unix(sudo:session): session opened for user root by (uid=0)
pam_unix(sudo:session): session closed for user root

#19

I just checked this morning and I'm getting the same :frowning:

Just working out how to roll back to previous version

PS - I'm not getting this on my system - do you have extra logging info switched on somewhere?

#20

Found out - just posting for future reference :slight_smile:
npm install node-red-node-pi-neopixel@0.0.22