Minimum delay for Neopixel sequence?

EL Wire/Tape/Panels, LEDs, pixels and strips, LCDs and TFTs, etc products from Adafruit

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Locked
User avatar
Kokodoko
 
Posts: 32
Joined: Sun Jul 27, 2014 8:50 am

Minimum delay for Neopixel sequence?

Post by Kokodoko »

What is the minimum delay between setting neopixel values, where the pixel has enough time to process?
In this Standtest code I use a delay of 20. Can it do any harm to set it shorter?

Code: Select all

void colorWipe(uint32_t c) {
  for(uint16_t i=0; i<strip.numPixels(); i++) {
    strip.setPixelColor(i, c);
    strip.show();
    delay(20);
  }
}

User avatar
adafruit_support_bill
 
Posts: 88154
Joined: Sat Feb 07, 2009 10:11 am

Re: Minimum delay for Neopixel sequence?

Post by adafruit_support_bill »

No delay is required. If you want the fastest possible update, you can move the show outside the loop too:

Code: Select all

void colorBlast(uint32_t c) 
{
  for(uint16_t i=0; i<strip.numPixels(); i++) 
  {
      strip.setPixelColor(i, c);
  }
  strip.show();
}

Locked
Please be positive and constructive with your questions and comments.

Return to “Glowy things (LCD, LED, TFT, EL) purchased at Adafruit”