Search found 31 matches

by flyboy74
Tue May 05, 2020 11:24 pm
Forum: Projects
Topic: [F4] Neopixel driver using hardware timers
Replies: 50
Views: 31318

Re: [F4] Neopixel driver using hardware timers

+1 @flyboy74 this is really nice, i've wanted to mess with timers doing something basically this & you have been there done that :D i think playing with ARR is a good way, of course another way may be to play with the output compare registers which would enable messing in 4 channels. If you whe...
by flyboy74
Tue May 05, 2020 11:00 pm
Forum: Projects
Topic: [F4] Neopixel driver using hardware timers
Replies: 50
Views: 31318

Re: [F4] Neopixel driver using hardware timers

That has triggered on the rising edge - trigger point in the centre, where the solid vertical cursor is. You can't see at that scale, but trust me, there is a pulse there that it triggered on, around 780 microseconds before the main body of pulses. At first I thought this was just some weird glitch...
by flyboy74
Tue May 05, 2020 11:09 am
Forum: Projects
Topic: [F4] Neopixel driver using hardware timers
Replies: 50
Views: 31318

Re: [F4] Neopixel driver using hardware timers

I don't see anything there to say that you must have the total time for high + low different for zero and one bits? I will have to put my MCU on back on the scope and check the signal train timing and might need to updat my code slightly to work better. From that link in last post Capture.JPG You c...
by flyboy74
Mon May 04, 2020 9:00 am
Forum: Projects
Topic: [F4] Neopixel driver using hardware timers
Replies: 50
Views: 31318

Re: [F4] Neopixel driver using hardware timers

I took your code, and with a bit of tweaking, I got it to generate a good looking pulse train, but so far I have not actually connected any LEDs. Some observations: I note you set ARPE for buffered write to ARR, but not OC1PE for buffered write to CCR1. Given you are writing to both ARR and CCR1 in...
by flyboy74
Sun Apr 26, 2020 1:25 pm
Forum: Projects
Topic: [F4] Neopixel driver using hardware timers
Replies: 50
Views: 31318

Re: [F4] Neopixel driver using hardware timers

No, for the STM32 core this is not this method which is used. https://github.com/adafruit/Adafruit_NeoPixel/blob/766f7fba6bb48081eaf861933a94a25524bd7be1/Adafruit_NeoPixel.cpp#L1902 It uses the systick. I agreed your way is probably best, did you used DMA? It is a little hard for me to tell exactly...
by flyboy74
Sun Apr 26, 2020 11:34 am
Forum: Projects
Topic: [F4] Neopixel driver using hardware timers
Replies: 50
Views: 31318

Re: [F4] Neopixel driver using hardware timers

Note that the Adafruit neopixel library is compatible with the STM32 core and so the matrix one is also compatible If you look at the code they have used on each board to achieve the timings it just shows how much of a pain in the butt it is to create these timings. On most boards they literally ju...
by flyboy74
Sun Apr 26, 2020 10:06 am
Forum: Projects
Topic: [F4] Neopixel driver using hardware timers
Replies: 50
Views: 31318

Re: [F4] Neopixel driver using hardware timers

I think we have to thank to @flyboy74 because he shared his code. On the other hand, a short description of the environment limitations (which core, with or w/o HAL) under the code works to be included in the readme would be helpful for the reader. Steve if you can give me suggestions of what shoul...
by flyboy74
Sun Apr 26, 2020 6:30 am
Forum: Projects
Topic: [F4] Neopixel driver using hardware timers
Replies: 50
Views: 31318

Re: Neopixel driver using hardware timers

Arduino is both an experience and a programming syntax. The ArduinoIDE is the default code editor, the wrapper for the compiler & linker, and the upload to device enabler... an environment. Ray This is correct I just haven't spent the time to learn the wrapper that Ardunio is, much the same way...
by flyboy74
Sun Apr 26, 2020 6:22 am
Forum: Projects
Topic: [F4] Neopixel driver using hardware timers
Replies: 50
Views: 31318

Re: Neopixel driver using hardware timers

it's nice you shared it here, but it's not a proper place for code like yours imho, most users here will not be able to use your driver (no matter how fast and brilliant your code is) Although not technically Ardunio code it is standard C code. I have rarely used Ardunio so am not familiar with it'...
by flyboy74
Sun Apr 26, 2020 1:05 am
Forum: Projects
Topic: [F4] Neopixel driver using hardware timers
Replies: 50
Views: 31318

Re: Neopixel driver using hardware timers

it's nice you shared it here, but it's not a proper place for code like yours imho, most users here will not be able to use your driver (no matter how fast and brilliant your code is) Although not technically Ardunio code it is standard C code. I have rarely used Ardunio so am not familiar with it'...

Go to advanced search