You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
nRF52 - First call to showPixels() with neopixel results in wrong color #856
// to avoid pin initialization from causing first LED to have invalid color,// call mWait.mark() to ensure data latches before color data gets sent.startPwmPlayback_InitializePinState();
mWait.mark();
While I couldn't get my scope connected to pin 8 to prove the cause,
it appears to prevent any the first LED color issue, without affecting
later calls to showPixels().
Can you please let me know, whether you don't test it, or the results you get when testing it?
Activity
henrygab commentedon Aug 10, 2019
@masonevans -- Would be willing to validate a potential fix for #856 (first LED wrong color first time only)? See
henrygab@ded19a5.
The potential fix is to add the following four lines (two of which are comments) to file platforms/arm/nrf52/clockless_arm_nrf52.h at function init():
While I couldn't get my scope connected to pin 8 to prove the cause,
it appears to prevent any the first LED color issue, without affecting
later calls to
showPixels().Can you please let me know, whether you don't test it, or the results you get when testing it?
Thanks!
henrygab commentedon Aug 10, 2019
OK, I confirmed this is caused by a lack of setting the pin to the proper state at startup.
You can fix this in your sketch by ensuring (for non-inverted chipsets) that you set the pin
I will also push the preventative measure above.
masonevans commentedon Aug 12, 2019
@henrygab thanks for the update on this one, I am out of town until Friday but I will check on this fix when I get back home
Fixes #856. (#860)