|
LightHub 4.6.0
Open-source smart home controller firmware
|
#include <Arduino.h>Go to the source code of this file.
Macros | |
| #define | BRIGHT_LINEAR |
| Default brightness curve: linear mapping of percent to 8-bit value. | |
Functions | |
| uint8_t | getBright255 (uint8_t percent255) |
| Convert a 0..255 brightness percentage to an 8-bit output value. | |
| #define BRIGHT_LINEAR |
Default brightness curve: linear mapping of percent to 8-bit value.
| uint8_t getBright255 | ( | uint8_t | percent255 | ) |
Convert a 0..255 brightness percentage to an 8-bit output value.
Uses the active brightness curve: a straight passthrough when BRIGHT_LINEAR is set, otherwise a perceptual (log/step) lookup table so low brightness steps feel smoother to the eye.
| percent255 | Brightness percentage in 0..255. |