LED Strip - LEDテープ

LEDテープ

DotStar (APA101, APA102 base)

Adafruit DotStar

  • Dotstars APA102 datasheet
    • SPI方式
    • 信号がクロック同期なので、WS281xよりも安定している。
    • APA101 は調光値100%より下で0bit目が1のとき、チラつく不具合があるっぽい?(APA102は改良型か)

Import programDotStar

APA102 (Adafruit DotStar LED Strip) see: https://developer.mbed.org/users/okini3939/notebook/led_strip/

schematic

	-----+
	mbed |                       +-----
	     |VU(+5V)----------------|+5V
	   11|MOSI-----|>O---|>O-----|DI
	   13|SCK------|>O---|>O-----|CI    LED Strip
	     |GND--------------------|GND
	     |        74VHC04(5V)    +-----
	-----+

NeoPixels (WS2813, WS2812, WS2811 base)

Adafruit NeoPixel

  • WS2812 datasheet
    • 独自のシリアル方式
    • 信号タイミングの依存性が高い。
    • SPIインターフェースを10bitモードにして、シリアルデータの0,1を表現。
    • 安定化させるためには DMA を使ってSPIデータを送信したほうがいい。
    • WS2812は電源線よりも先に信号線に電圧がかかると壊れる不具合がある?

Import programLEDTape_WS2812

see: http://mbed.org/users/okini3939/notebook/led_strip/

signal

	        0.35us   0.8us    (+-150ns)
	0:     |^^^^^|__________|
	
	           0.7us   0.6us  (+-150ns)
	1:     |^^^^^^^^^^|_____|
	
	             >50us
	RESET: |________________|

schematic

	-----+
	mbed |                 +-----
	     |VU(+5V)----------|+5V
	   11|MOSI-----|>O-----|DI    LED Strip
	     |GND--------------|GND
	     |        7S04     +-----
	-----+        (5V)

※ MOSIとDIの間に Not gate (7S04) があることに注意してください。 LowとHighを反転し、さらに5Vへのレベルコンバーターとして使用しています。 (高速に動作するICが望ましいです。RS485のドライバICでもいいです)

Information

WS2812B の場合は信号のタイミングが少し違うため以下のように修正します。

LEDStrip_WS2812.cpp

        if (data[addr] & bit) {
            // 1
            _ssp->DR = 0x007;
        } else {

信号線の5VへのレベルコンバーターとLEDの間に300~500Ω程度の抵抗器をはさんでおきます。

schematic

	   MOSI-----|>O---[300ohm]-----|DI  WS2812B

UCS1903 base

Import programLEDTape_UCS1903

UCS1903 tape led

  • UCS1903 datasheet (Chinese)
    • 独自のシリアル方式
    • SPIインターフェースを5bitモードにして、シリアルデータの0,1を表現。

schematic

	-----+
	mbed |                 +-----
	     |              ---|+12V
	   11|MOSI-----|>O-----|DI    LED Strip
	     |GND--------------|GND
	     |        7S04     +-----
	-----+        (5V)

HL1606 base

Import programLEDTape_HL1606

see: http://mbed.org/users/okini3939/notebook/led_strip/

schematic

	-----+
	mbed |                       +-----
	     |VU(+5V)----------------|+5V
	   11|MOSI-----|>O---|>O-----|DI
	   13|SCK------|>O---|>O-----|Clock    LED Strip
	   14|---------|>O---|>O-----|Latch
	     |GND--------------------|GND
	     |        74VHC04(5V)    +-----
	-----+


8 comments on LED Strip - LEDテープ:

11 Aug 2013

How hard would it be To adapt the LEDTape_WS2812 to the Freescale kl25z?

12 Aug 2013

It is possible, but not the easiest. If you don't have one yet I would get one which just uses a shift register (I don't know which different kinds there are, but probably the 1606 is one of them).

02 Oct 2013

Thank you erik, I have been able to get them to work with my propeller, and arduino, but just cant get it to work with the kl25z

22 Nov 2013

Is there any reason the 74S series is used for WS2812. I was wondering if 74ALS or even 74HCT would be OK. I realise it's doing a level translation so needs to be TTL compatible thresholds.

06 Dec 2013

Beside the level translation, speed is also needed.

08 Jan 2014

I have written a multiple-strip library for the FRDM-KL25Z driving the WS2812/WS2811 http://mbed.org/users/bikeNomad/code/Multi_WS2811/

By changing the timings from 800kHz to 400kHz and changing BGR to RGB order, you could drive the UCS1903 with it as well.

Also, the 74HCT series is fine for level translation, having TTL input thresholds and able to be run from 5V. My code doesn't want to have any inversion; I'm using a CD4504B to do translation because I had a few lying around.

06 Mar 2014

if you don't mind me asking, what is the use of the inverter? why do you need to invert the data input? I'm trying to program the WS2812 using mbed, so i'm wondering whether the inverter is necessary.

04 May 2017

Thanks for information. You know ws2815 12v individually/addressable breakpoint led strip?it have the advantages of ws2812b and ws2813. If you want to learn it,you can contact me by the email:Alvin@witop-tech.com.

Please log in to post comments.