Skip to content

Fix #842 by increasing compliance with constexpr restrictions - #845

Merged
focalintent merged 1 commit into
FastLED:masterfrom
henrygab:patch-1
Jul 19, 2019
Merged

focalintent merged 1 commit into
FastLED:masterfrom
henrygab:patch-1

Conversation

@henrygab

@henrygab henrygab commented Jul 19, 2019 •

Copy link
Copy Markdown
Contributor

Fix #842

Specifically, cannot cast integer values to pointers in a constexpr,
requiring use of intptr_t in the constexpr. Callers of the constexpr
may then cast it at the non-constexpr location of use.

See https://stackoverflow.com/questions/10369606/constexpr-pointer-value

Specifically, cannot cast integer values to pointers in a constexpr,
requiring use of intptr_t in the constexpr.  Callers of the constexpr
may then cast it at the non-constexpr location of use.

See https://stackoverflow.com/questions/10369606/constexpr-pointer-value
@focalintent
focalintent merged commit 3190e96 into FastLED:master Jul 19, 2019
@henrygab
henrygab deleted the patch-1 branch July 20, 2019 17:50
@JWizlo

JWizlo commented Dec 17, 2019

Copy link
Copy Markdown

@henrygab

I hope I'm writing in the correct space. I am having an issue using FastLED with the nRF52840DK in Segger Embedded Studios. I wanted to start troubleshooting by verifying that your updates for this board are included in the main library.. or are these fixes included only in some special download?

@henrygab

Copy link
Copy Markdown
Contributor Author

@JWizlo -- I don't think FastLED is officially support except under Arduino. In addition, although the pins are defined, it hasn't yet beet tested / verified. It will generate a warning during build stating this.

The variant support for PCA10056 is found at https://github.com/FastLED/FastLED/blob/master/platforms/arm/nrf52/fastpin_arm_nrf52_variants.h

You most likely want to #define ARDUINO_NRF52840_PCA10056.

If you want to try to use Arduino pin numbers (unlikely, given you're using SES), also #define USE_ARDUINO_PIN_NUMBERING. Otherwise, the pins are identity-mapped (PX.YY is pin (X*32) + YY),

If you have issues, open a new issue (don't resurrect closed issues / merged PRs)...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

FastLED no longer compiles against latest Adafruit nRF52 board definitions (gcc 7-2017q4) due to invalid C++ code in FastLED

3 participants