Fix RGB to u32 conversion order in rmt_neopixel example (#505)

* Update rmt_neopixel.rs

* Update rmt_neopixel.rs

* Update CHANGELOG.md
This commit is contained in:
lonesometraveler 2025-01-06 09:36:44 -05:00 committed by GitHub
parent 90384c66ac
commit 8a11ef463e
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 6 additions and 1 deletions

View File

@ -5,6 +5,11 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
## Unreleased
### Fixed
- Fix RGB to u32 conversion order in rmt_neopixel example (#505)
## [0.45.0] - 2025-01-02
### Deprecated

View File

@ -121,7 +121,7 @@ mod example {
/// 7 0 7 0 7 0
/// 00000010 00000001 00000100
fn from(rgb: Rgb) -> Self {
((rgb.r as u32) << 16) | ((rgb.g as u32) << 8) | rgb.b as u32
((rgb.g as u32) << 16) | ((rgb.r as u32) << 8) | rgb.b as u32
}
}
}