• 0

UART disable Start bit? (for NeoPixel LEDs)



I'm trying to implement a custom protocol for NeoPixel LED arrays using a script. I need to represent the 0 and 1 data bits as signals of 0.4us high + 0.85us low and 0.8us high + 0.45us low respectively.

I implemented the custom protocol with a script already, the data pulse widths look alright and I thought I could use UART and its Protocol.UART.Send(uartMessage,true) method, but I had to realize that I can't disable UART's Start bit so the receiver will misunderstand my data.

Is there a way to disable the Start bit in the Digital Protocol?



Also, when I was investigating the bus, I used the Logic Analyzer and I found something interesting: when I tried to set the rate to 3.2 MHz it always jumped back to 3.125 MHz. Is this normal?





Share this post

Link to post
Share on other sites

2 answers to this question

Recommended Posts

  • 1

Szia @Andras

The UART is not suitable for RGB LED control.

You can use a custom Patterns signal and script like this to build the data sequence for WS2812 RGB LEDs.
Here you have the project: WS2812.dwf3work

The default Analog Discovery configuration allocates 1k samples for each Patterns channel with this you can control 14 LED array (1024/24/3).
With the 4th AD device configuration you will have 16k samples and can control 227 LEDs. With Digital Discovery 32k 455 LEDs...

The supported frequencies are positive integer divisions of 100MHz base frequency: 100MHz, 50M, 33.3M, ... ~3.226M, 3.125M ...



Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now