#include <NeoPixelBus.h>
const uint16_t PixelCount = 4;
NeoPixelBus<NeoGrbFeature, Neo800KbpsMethod> strip(PixelCount);
void setup() {
// this resets all the neopixels to an off state
strip.Begin();
strip.Show();
}
void loop() {
delay(5000);
strip.SetPixelColor(0, RgbColor(128,0,0));
strip.Show();
delay(5000);
strip.SetPixelColor(0, RgbColor(0));
strip.Show();
}
can someone tell me what i'm doing wrong here?:
packet is "Params: 100|1000|70"
unsigned int initial, pixelDuration, height = 0;
sscanf((const char *)packet, "Params: %d|%d|%d", &initial, &pixelDuration, &height);
Printing the params returns:
0
1073656464
0
== 0
to strncmp :/