-
Notifications
You must be signed in to change notification settings - Fork 93
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(led_strip): Support more pixel orders of 3 colors (IEC-126) #344
feat(led_strip): Support more pixel orders of 3 colors (IEC-126) #344
Conversation
5e93906
to
65e14f5
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not a reviewer, so addressing my input isn't required.
I do have some ideas on performance (don't recompute per pixel what you can compute at construction time) as well as some maintainability/readability feedback just from a drive-by on this code.
Thank you for making it more awesome
65e14f5
to
ee682b8
Compare
ee682b8
to
a77d1c5
Compare
a77d1c5
to
60c1426
Compare
After all that, you silently withdraw the PR? I get that it's been open for a month while being ignored by the maintainers, but IMO this is work worth picking up and if you're just exhausted trying to get it in, I may run with it (adding a second white channel) but based on my recent experience trying to change IDF, I'm not at all sure that I wouldn't just rather fork it and maintain it myself and bypass the reviewer clique. Why was this dropped? |
0f5696b
to
3c33ebf
Compare
Sorry, I didn't really mean to close it, it was a mistake on my part. I've re-pushed it. Thank you for your attention. |
led_strip/examples/led_strip_spi_ws2812/main/led_strip_spi_ws2812_main.c
Outdated
Show resolved
Hide resolved
led_strip/examples/led_strip_spi_ws2812/main/led_strip_spi_ws2812_main.c
Outdated
Show resolved
Hide resolved
led_strip/examples/led_strip_spi_ws2812/main/led_strip_spi_ws2812_main.c
Outdated
Show resolved
Hide resolved
ad5231d
to
aa2630c
Compare
led_strip/examples/led_strip_rmt_ws2812/main/led_strip_rmt_ws2812_main.c
Outdated
Show resolved
Hide resolved
led_strip/examples/led_strip_rmt_ws2812/main/led_strip_rmt_ws2812_main.c
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for giving this approach a try, LGTM overall. @Kainarx
54ae110
to
0680770
Compare
1ab7622
to
0501326
Compare
5314606
to
1539f0d
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
clang-tidy found more than 20 potential problems in the proposed changes. Check the Files changed tab for more details.
1539f0d
to
31585c8
Compare
__led_strip_spi_bit(0, &spi_strip->pixel_buf[start + SPI_BYTES_PER_COLOR_BYTE * 3]); | ||
uint8_t *pixel_buf = spi_strip->pixel_buf; | ||
led_color_component_format_t component_fmt = spi_strip->component_fmt; | ||
memset(pixel_buf + start, 0, spi_strip->bytes_per_pixel * SPI_BYTES_PER_COLOR_BYTE); |
Check warning
Code scanning / clang-tidy
Call to function 'memset' is insecure as it does not provide security checks introduced in the C11 standard. Replace with analogous functions that support length arguments or provides boundary checks such as 'memset_s' in case of C11 [clang-analyzer-security.insecureAPI.DeprecatedOrUnsafeBufferHandling] Warning
__led_strip_spi_bit(blue, &spi_strip->pixel_buf[start + SPI_BYTES_PER_COLOR_BYTE * 2]); | ||
__led_strip_spi_bit(white, &spi_strip->pixel_buf[start + SPI_BYTES_PER_COLOR_BYTE * 3]); | ||
uint8_t *pixel_buf = spi_strip->pixel_buf; | ||
memset(pixel_buf + start, 0, spi_strip->bytes_per_pixel * SPI_BYTES_PER_COLOR_BYTE); |
Check warning
Code scanning / clang-tidy
Call to function 'memset' is insecure as it does not provide security checks introduced in the C11 standard. Replace with analogous functions that support length arguments or provides boundary checks such as 'memset_s' in case of C11 [clang-analyzer-security.insecureAPI.DeprecatedOrUnsafeBufferHandling] Warning
Checklist
url
field definedChange description
Closes #341