forked from Makuna/NeoPixelBus
DotStar and NoPin NeoPixel
removed the need to provide the pin argument for Esp8266 NeoPixelBus where it was ignored. Added another DotStar color feature. Fixed DotStar color features to use RgbColor when there is no need for RgbwColor.
This commit is contained in:
@@ -26,14 +26,13 @@ const uint16_t PixelCount = 4; // make sure to set this to the number of pixels
|
||||
const uint8_t PixelPin = 2; // make sure to set this to the correct pin, ignored for Esp8266
|
||||
|
||||
NeoPixelBus<NeoGrbFeature, Neo800KbpsMethod> strip(PixelCount, PixelPin);
|
||||
// For Esp8266, the Pin is ignored and it uses GPIO3.
|
||||
// For Esp8266, the Pin is omitted and it uses GPIO3 due to DMA hardware use.
|
||||
// There are other Esp8266 alternative methods that provide more pin options, but also have
|
||||
// other side effects.
|
||||
//NeoPixelBus<NeoGrbFeature, NeoEsp8266Uart800KbpsMethod> strip(PixelCount, PixelPin);
|
||||
// NeoEsp8266Uart800KbpsMethod also ignores the pin parameter and uses GPI02
|
||||
//NeoPixelBus<NeoGrbFeature, NeoEsp8266BitBang800KbpsMethod> strip(PixelCount, PixelPin);
|
||||
// NeoEsp8266Uart800KbpsMethod will work with all but pin 16, but is not stable with WiFi
|
||||
// being active
|
||||
//NeoPixelBus<NeoGrbFeature, Neo800KbpsMethod> strip(PixelCount);
|
||||
//
|
||||
// NeoEsp8266Uart800KbpsMethod uses GPI02 instead
|
||||
|
||||
|
||||
// NeoPixel animation time management object
|
||||
NeoPixelAnimator animations(PixelCount, NEO_CENTISECONDS);
|
||||
|
||||
@@ -24,6 +24,8 @@ const uint16_t PixelPin = 2;
|
||||
const uint16_t AnimCount = 1; // we only need one
|
||||
|
||||
NeoPixelBus<MyPixelColorFeature, Neo800KbpsMethod> strip(PixelCount, PixelPin);
|
||||
// for esp8266 omit the pin
|
||||
//NeoPixelBus<MyPixelColorFeature, Neo800KbpsMethod> strip(PixelCount);
|
||||
NeoPixelAnimator animations(AnimCount); // NeoPixel animation management object
|
||||
|
||||
// our NeoBitmapFile will use the same color feature as NeoPixelBus and
|
||||
|
||||
@@ -23,6 +23,8 @@ const uint16_t PixelPin = 2;
|
||||
const uint16_t AnimCount = 1; // we only need one
|
||||
|
||||
NeoPixelBus<MyPixelColorFeature, Neo800KbpsMethod> strip(PixelCount, PixelPin);
|
||||
// for esp8266 omit the pin
|
||||
//NeoPixelBus<MyPixelColorFeature, Neo800KbpsMethod> strip(PixelCount);
|
||||
NeoPixelAnimator animations(AnimCount); // NeoPixel animation management object
|
||||
|
||||
// sprite sheet stored in progmem using the same pixel feature as the NeoPixelBus
|
||||
|
||||
@@ -15,6 +15,8 @@ const uint8_t PixelPin = 2; // make sure to set this to the correct pin, ignore
|
||||
const RgbColor CylonEyeColor(HtmlColor(0x7f0000));
|
||||
|
||||
NeoPixelBus<NeoGrbFeature, Neo800KbpsMethod> strip(PixelCount, PixelPin);
|
||||
// for esp8266 omit the pin
|
||||
//NeoPixelBus<NeoGrbFeature, Neo800KbpsMethod> strip(PixelCount);
|
||||
|
||||
NeoPixelAnimator animations(2); // only ever need 2 animations
|
||||
|
||||
|
||||
@@ -13,14 +13,12 @@ const uint8_t PixelPin = 2; // make sure to set this to the correct pin, ignore
|
||||
const uint8_t AnimationChannels = 1; // we only need one as all the pixels are animated at once
|
||||
|
||||
NeoPixelBus<NeoGrbFeature, Neo800KbpsMethod> strip(PixelCount, PixelPin);
|
||||
// For Esp8266, the Pin is ignored and it uses GPIO3.
|
||||
// For Esp8266, the Pin is omitted and it uses GPIO3 due to DMA hardware use.
|
||||
// There are other Esp8266 alternative methods that provide more pin options, but also have
|
||||
// other side effects.
|
||||
//NeoPixelBus<NeoGrbFeature, NeoEsp8266Uart800KbpsMethod> strip(PixelCount, PixelPin);
|
||||
// NeoEsp8266Uart800KbpsMethod also ignores the pin parameter and uses GPI02
|
||||
//NeoPixelBus<NeoGrbFeature, NeoEsp8266BitBang800KbpsMethod> strip(PixelCount, PixelPin);
|
||||
// NeoEsp8266Uart800KbpsMethod will work with all but pin 16, but is not stable with WiFi
|
||||
// being active
|
||||
//NeoPixelBus<NeoGrbFeature, Neo800KbpsMethod> strip(PixelCount);
|
||||
//
|
||||
// NeoEsp8266Uart800KbpsMethod uses GPI02 instead
|
||||
|
||||
NeoPixelAnimator animations(AnimationChannels); // NeoPixel animation management object
|
||||
|
||||
|
||||
@@ -26,14 +26,12 @@ const uint16_t NextPixelMoveDuration = 1000 / PixelCount; // how fast we move th
|
||||
NeoGamma<NeoGammaTableMethod> colorGamma; // for any fade animations, best to correct gamma
|
||||
|
||||
NeoPixelBus<NeoGrbFeature, Neo800KbpsMethod> strip(PixelCount, PixelPin);
|
||||
// For Esp8266, the Pin is ignored and it uses GPIO3.
|
||||
// For Esp8266, the Pin is omitted and it uses GPIO3 due to DMA hardware use.
|
||||
// There are other Esp8266 alternative methods that provide more pin options, but also have
|
||||
// other side effects.
|
||||
//NeoPixelBus<NeoGrbFeature, NeoEsp8266Uart800KbpsMethod> strip(PixelCount, PixelPin);
|
||||
// NeoEsp8266Uart800KbpsMethod also ignores the pin parameter and uses GPI02
|
||||
//NeoPixelBus<NeoGrbFeature, NeoEsp8266BitBang800KbpsMethod> strip(PixelCount, PixelPin);
|
||||
// NeoEsp8266BitBang800KbpsMethod will work with all but pin 16, but is not stable with WiFi
|
||||
// being active
|
||||
//NeoPixelBus<NeoGrbFeature, Neo800KbpsMethod> strip(PixelCount);
|
||||
//
|
||||
// NeoEsp8266Uart800KbpsMethod uses GPI02 instead
|
||||
|
||||
// what is stored for state is specific to the need, in this case, the colors and
|
||||
// the pixel to animate;
|
||||
|
||||
@@ -11,14 +11,12 @@ const uint16_t PixelCount = 16; // make sure to set this to the number of pixels
|
||||
const uint8_t PixelPin = 2; // make sure to set this to the correct pin, ignored for Esp8266
|
||||
|
||||
NeoPixelBus<NeoGrbFeature, Neo800KbpsMethod> strip(PixelCount, PixelPin);
|
||||
// For Esp8266, the Pin is ignored and it uses GPIO3.
|
||||
// For Esp8266, the Pin is omitted and it uses GPIO3 due to DMA hardware use.
|
||||
// There are other Esp8266 alternative methods that provide more pin options, but also have
|
||||
// other side effects.
|
||||
//NeoPixelBus<NeoGrbFeature, NeoEsp8266Uart800KbpsMethod> strip(PixelCount, PixelPin);
|
||||
// NeoEsp8266Uart800KbpsMethod also ignores the pin parameter and uses GPI02
|
||||
//NeoPixelBus<NeoGrbFeature, NeoEsp8266BitBang800KbpsMethod> strip(PixelCount, PixelPin);
|
||||
// NeoEsp8266Uart800KbpsMethod will work with all but pin 16, but is not stable with WiFi
|
||||
// being active
|
||||
//NeoPixelBus<NeoGrbFeature, Neo800KbpsMethod> strip(PixelCount);
|
||||
//
|
||||
// NeoEsp8266Uart800KbpsMethod uses GPI02 instead
|
||||
|
||||
NeoPixelAnimator animations(PixelCount); // NeoPixel animation management object
|
||||
|
||||
|
||||
@@ -16,6 +16,8 @@ const uint16_t PixelCount = 16; // make sure to set this to the number of pixels
|
||||
const uint8_t PixelPin = 2; // make sure to set this to the correct pin, ignored for Esp8266
|
||||
|
||||
NeoPixelBus<NeoGrbFeature, Neo800KbpsMethod> strip(PixelCount, PixelPin);
|
||||
// for esp8266 omit the pin
|
||||
//NeoPixelBus<NeoGrbFeature, Neo800KbpsMethod> strip(PixelCount);
|
||||
|
||||
// uncomment only one of these to compare memory use or speed
|
||||
//
|
||||
|
||||
@@ -36,8 +36,8 @@ NeoMosaic <MyPanelLayout> mosaic(
|
||||
TileHeight);
|
||||
|
||||
NeoPixelBus<NeoGrbFeature, Neo800KbpsMethod> strip(PixelCount, PixelPin);
|
||||
//NeoPixelBus<NeoRgbFeature, Neo800KbpsMethod> strip(PixelCount, PixelPin);
|
||||
//NeoPixelBus<NeoRgbwFeature, Neo800KbpsMethod> strip(PixelCount, PixelPin);
|
||||
// for esp8266 omit the pin
|
||||
//NeoPixelBus<NeoGrbFeature, Neo800KbpsMethod> strip(PixelCount);
|
||||
|
||||
RgbColor red(128, 0, 0);
|
||||
RgbColor green(0, 128, 0);
|
||||
|
||||
@@ -19,7 +19,8 @@ const float MaxLightness = 0.4f; // max lightness at the head of the tail (0.5f
|
||||
NeoGamma<NeoGammaTableMethod> colorGamma; // for any fade animations, best to correct gamma
|
||||
|
||||
NeoPixelBus<NeoGrbFeature, Neo800KbpsMethod> strip(PixelCount, PixelPin);
|
||||
//NeoPixelBus<NeoGrbwFeature, Neo800KbpsMethod> strip(PixelCount, PixelPin);
|
||||
// for esp8266 omit the pin
|
||||
//NeoPixelBus<NeoGrbFeature, Neo800KbpsMethod> strip(PixelCount);
|
||||
|
||||
NeoPixelAnimator animations(AnimCount); // NeoPixel animation management object
|
||||
|
||||
|
||||
@@ -22,6 +22,13 @@ const uint8_t PixelPin = 2; // make sure to set this to the correct pin, ignore
|
||||
NeoPixelBus<NeoGrbFeature, Neo800KbpsMethod> strip(PixelCount, PixelPin);
|
||||
//NeoPixelBus<NeoRgbFeature, Neo400KbpsMethod> strip(PixelCount, PixelPin);
|
||||
|
||||
// For Esp8266, the Pin is omitted and it uses GPIO3 due to DMA hardware use.
|
||||
// There are other Esp8266 alternative methods that provide more pin options, but also have
|
||||
// other side effects.
|
||||
//NeoPixelBus<NeoGrbFeature, Neo800KbpsMethod> strip(PixelCount);
|
||||
//
|
||||
// NeoEsp8266Uart800KbpsMethod uses GPI02 instead
|
||||
|
||||
// You can also use one of these for Esp8266,
|
||||
// each having their own restrictions
|
||||
//
|
||||
|
||||
@@ -42,6 +42,8 @@ NeoTiles <MyPanelLayout, MyTilesLayout> tiles(
|
||||
NeoPixelBus<NeoGrbFeature, Neo800KbpsMethod> strip(PixelCount, PixelPin);
|
||||
//NeoPixelBus<NeoRgbFeature, Neo800KbpsMethod> strip(PixelCount, PixelPin);
|
||||
//NeoPixelBus<NeoRgbwFeature, Neo800KbpsMethod> strip(PixelCount, PixelPin);
|
||||
// for esp8266 omit the pin
|
||||
//NeoPixelBus<NeoGrbFeature, Neo800KbpsMethod> strip(PixelCount);
|
||||
|
||||
RgbColor red(128, 0, 0);
|
||||
RgbColor green(0, 128, 0);
|
||||
|
||||
@@ -31,6 +31,8 @@ NeoTopology<MyPanelLayout> topo(PanelWidth, PanelHeight);
|
||||
NeoPixelBus<NeoGrbFeature, Neo800KbpsMethod> strip(PixelCount, PixelPin);
|
||||
//NeoPixelBus<NeoRgbFeature, Neo800KbpsMethod> strip(PixelCount, PixelPin);
|
||||
//NeoPixelBus<NeoRgbwFeature, Neo800KbpsMethod> strip(PixelCount, PixelPin);
|
||||
// for esp8266 omit the pin
|
||||
//NeoPixelBus<NeoGrbFeature, Neo800KbpsMethod> strip(PixelCount);
|
||||
|
||||
RgbColor red(128, 0, 0);
|
||||
RgbColor green(0, 128, 0);
|
||||
|
||||
Reference in New Issue
Block a user