Problem with WifiPixel

WifiPixles = Wifi unit that can control a bunch of addressable RGB leds... :)
Post Reply
oism
Posts: 2
Joined: Sat Oct 08, 2016 4:23 pm

Problem with WifiPixel

Post by oism » Sat Oct 08, 2016 4:34 pm

I have purchased the WifiPixel board and it worked without problem with the initial sketch.

I wanted the try the example sketch
https://github.com/Protoneer/WifiPixels ... de_RGB.ino

but the interface of the NeoPixelBus library has changed significantly meanwhile.

I have tried to change the example code and I can upload and run my sketch with the Adafruit Huzzah Board configuration,
but the WS2812 leds never light up.

Here's the source code I have:
#include <NeoPixelBus.h>

#define pixelCount 16
#define pixelPin 12

RgbColor Red = {128, 0, 0};
RgbColor Green = {0 , 128, 0};
RgbColor Blue = {0 , 0, 128};
RgbColor Black = {0 , 0, 0};

//NeoPixelBus strip = NeoPixelBus(pixelCount, pixelPin);
//NeoPixelBus<NeoGrbFeature, NeoEsp8266Uart800KbpsMethod> strip(pixelCount);
//NeoPixelBus<NeoGrbFeature, NeoEsp8266BitBang800KbpsMethod> strip(pixelCount, pixelPin);
NeoPixelBus<NeoGrbFeature, NeoEsp8266BitBang800KbpsMethod> strip(pixelCount, pixelPin);

void setup()
{
strip.Begin();
strip.Show();
}

void loop()
{
Fade(Black , Red);
Fade(Red , Black);
Fade(Black , Green);
Fade(Green , Black);
Fade(Black , Blue);
Fade(Blue , Black);
}

void SetAll(RgbColor colour) {
for (int K = 0; K < pixelCount; K++) {
strip.SetPixelColor(K, colour);
}
}

void Fade(RgbColor rgb1, RgbColor rgb2) {
for (int k = 0; k < 255; k++) {
RgbColor rgb = rgb.LinearBlend(rgb1, rgb2, k);
SetAll(rgb);
strip.Show();
delay(5);
}
}



Here are my questions:
0. What I am doing wrong here? Is the Adafruit Huzzah board the correct board type?
1. Could you please update the example code on github accordingly, please?
2. Looking at the board layout files, did the output pin change from pin 2 to pin 12 in hardware layout version 1.30?

Thanks
oism

Bertus Kruger
Site Admin
Posts: 1357
Joined: Wed Feb 03, 2016 10:26 pm
Location: Wellington , New Zealand
Contact:

Re: Problem with WifiPixel

Post by Bertus Kruger » Sun Oct 09, 2016 8:42 am

Hi Oism,

The V1.3 uses pin 4 for the LED's and I use the Generic ESP8266 in Arduino.

The following is the test code that ships with the current version : https://gist.github.com/Protoneer/27d7a ... 9d4125198d

oism
Posts: 2
Joined: Sat Oct 08, 2016 4:23 pm

Re: Problem with WifiPixel

Post by oism » Sat Oct 22, 2016 4:47 pm

Thanks for the answer.

It works like a charm now.

Thank you for product, I love it.
oism

Bertus Kruger
Site Admin
Posts: 1357
Joined: Wed Feb 03, 2016 10:26 pm
Location: Wellington , New Zealand
Contact:

Re: Problem with WifiPixel

Post by Bertus Kruger » Mon Oct 24, 2016 7:19 pm

Thanks for the feedback....

Have fun... :)

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest