These are chat archives for Makuna/NeoPixelBus

6th
Jul 2015
Michael Miller
@Makuna
Jul 06 2015 22:49

@probonopd I reviewed it, and I have a few suggestions/answers around the neopixel stuff.
1) Use the "NeoPixelAnimator" branch, it has some improvements that will help clean up the loop in your code.
2) With the above branch, your loop becomes

loop() { 
 // FIXME: This seems to block everything while a request is being processed which takes about 2 seconds 
// Can we run this in a separate thread, in "the background"? 
 HTTP.handleClient(); 
  SSDP.update(); 

   stripAnimator.UpdateAnimations(); 
   strip.Show(); 
 }

3) I have a task library that "helps" manage non-preemptive tasks, but it would require that HTTP.handleClient() and/or SSDP.update() be modified to do less in a loop at one time. You might bring this question up on the esp8266/arduino chat to see if there is support to thread off the networking stuff; but in general, we don't have a multitasking core.