diff --git a/CHANGELOG.md b/CHANGELOG.md index 26c2b0ad..475a6b7a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,10 @@ ## [Unreleased] - ReleaseDate +### Added + +- [#183](https://github.com/jamwaffles/ssd1306/pull/183) `Brightness::custom()` is now publicly available. + ### Fixed - [#177](https://github.com/jamwaffles/ssd1306/pull/177) Fixed a few spelling mistakes. diff --git a/src/brightness.rs b/src/brightness.rs index 2c2b28ed..028ba680 100644 --- a/src/brightness.rs +++ b/src/brightness.rs @@ -39,7 +39,7 @@ impl Brightness { /// /// `contrast` sets the value used in the `0x81 Set Contrast Control` command and must be /// between 0 and 255. See section 10.1.7 of the SSD1306 datasheet for more information. - const fn custom(precharge: u8, contrast: u8) -> Self { + pub const fn custom(precharge: u8, contrast: u8) -> Self { debug_assert!( 0 < precharge && precharge <= 15, "Precharge value must be between 1 and 15"