Comments (4)
That strip you linked to is not RGBW, but rather RGB only if it's truly SK6812 and not SK6812RGBW. They should be the same as WS2812B type.
Try
#define PIXEL_TYPE WS2812B
from particle-neopixel.
It has all 4 LEDs. Setting strip.Color(255, 255, 255) lights all 3 RGB LEDs, strip.Color(0, 0, 0, 255) lights the one W LED and strip.Color(255, 255, 255, 255) lights all 4 LEDs
I'll give WS2812B a try when I get home just to confirm.
from particle-neopixel.
Ok interesting. I created the SK6812RGBW pixel type support with an Adafruit RGBW 24 pixel ring and I'm sure I would have tested the color order. Referencing the datasheet, it says RGBW order which is the same as the code.
It's possible you have a knock off or just a different version and the colors need to be swapped. It would probably be best to incorporate the different pixel color arrangements as in the original library:
https://github.com/adafruit/Adafruit_NeoPixel/blob/master/Adafruit_NeoPixel.h#L52-L89
We would have to do it a bit differently though, since we skewed away from the 400kHz vs 800kHz speed settings and opted for direct pixel type mapping. It would work the same though, like
// IMPORTANT: Set pixel COUNT, PIN and TYPE
#define PIXEL_COUNT 10
#define PIXEL_PIN D2
#define PIXEL_TYPE WS2812B
#define PIXEL_COLOR NEO_GRBW
// Parameter 1 = number of pixels in strip
// note: for some stripes like those with the TM1829, you
// need to count the number of segments, i.e. the
// number of controllers in your stripe, not the number
// of individual LEDs!
// Parameter 2 = pin number (most are valid)
// note: if not specified, D2 is selected for you.
// Parameter 3 = pixel type [ WS2812, WS2812B, WS2812B2, WS2811,
// TM1803, TM1829, SK6812RGBW ]
// note: if not specified, WS2812B is selected for you.
// note: RGB order is automatically applied to WS2811,
// WS2812/WS2812B/WS2812B2/TM1803 is GRB order.
//
// 800 KHz bitstream 800 KHz bitstream (most NeoPixel products
// WS2812 (6-pin part)/WS2812B (4-pin part)/SK6812RGBW (RGB+W) )
//
// 400 KHz bitstream (classic 'v1' (not v2) FLORA pixels, WS2811 drivers)
// (Radio Shack Tri-Color LED Strip - TM1803 driver
// NOTE: RS Tri-Color LED's are grouped in sets of 3)
Adafruit_NeoPixel strip = Adafruit_NeoPixel(PIXEL_COUNT, PIXEL_PIN, PIXEL_COLOR + PIXEL_TYPE);
from particle-neopixel.
So I checked with a friend that is using the same strips and they are GRB pixels. This issue can be closed and I'll poke around to see if I can make those changes work (and send a pull request if I do).
from particle-neopixel.
Related Issues (19)
- 5V supply to the entire circuit HOT 3
- 'PIN_MAP' was not declared in this scope HOT 6
- Particle P1 is not yet supported HOT 2
- redefinition of 'STM32_Pin_Info* PIN_MAP' HOT 2
- initializing argument 1 of 'Adafruit_NeoPixel::Adafruit_NeoPixel(uint16_t, uint8_t, uint8_t)' [-fpermissive] HOT 4
- Version of library web IDE does not support P1 module HOT 5
- PIN_MAP[pin] error HOT 4
- RGBW support HOT 9
- Redbear Duo Platform ID in neopixel library HOT 4
- expected identifier before numeric constant HOT 1
- application.h missing HOT 3
- Removing Copy Ctor? HOT 2
- GRBW support
- APA106 support
- 'HAL_Pin_Map' was not declared in this scope; HOT 2
- SK6812 RGBW support on Photon 2 / P2
- Documentation error: SparkCore *can* output 5v HOT 4
- getPixelColor returning dimmed values HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from particle-neopixel.