mirror of
https://github.com/meshtastic/firmware.git
synced 2025-09-10 21:19:07 +00:00
Trunk fmt
This commit is contained in:
parent
40d82faace
commit
9ab22c04cd
@ -73,14 +73,13 @@ bool ascending = true;
|
||||
#define ASCII_BELL 0x07
|
||||
|
||||
struct ExternalNotificationModule::RGB {
|
||||
constexpr RGB(uint8_t red, uint8_t green,uint8_t blue)
|
||||
: red{red}, green{green}, blue{blue}
|
||||
{}
|
||||
constexpr RGB(uint8_t red, uint8_t green, uint8_t blue) : red{red}, green{green}, blue{blue} {}
|
||||
|
||||
#define SCALE_ALPHA(COLOR, ALPHA) (uint8_t)((((uint16_t)COLOR) * ALPHA) / (uint16_t)255)
|
||||
constexpr RGB(uint8_t red, uint8_t green, uint8_t blue, uint8_t alpha)
|
||||
: red{SCALE_ALPHA(red, alpha)}, green{SCALE_ALPHA(green, alpha)}, blue{SCALE_ALPHA(blue, alpha)}
|
||||
{}
|
||||
{
|
||||
}
|
||||
#undef SCALE_ALPHA
|
||||
|
||||
uint8_t red = 0;
|
||||
@ -144,7 +143,8 @@ int32_t ExternalNotificationModule::runOnce()
|
||||
if (externalTurnedOn[2] + (moduleConfig.external_notification.output_ms ? moduleConfig.external_notification.output_ms
|
||||
: EXT_NOTIFICATION_MODULE_OUTPUT_MS) <
|
||||
millis()) {
|
||||
LOG_DEBUG("EXTERNAL 2 %d compared to %d", externalTurnedOn[2]+moduleConfig.external_notification.output_ms, millis());
|
||||
LOG_DEBUG("EXTERNAL 2 %d compared to %d", externalTurnedOn[2] + moduleConfig.external_notification.output_ms,
|
||||
millis());
|
||||
setExternalState(2, !getExternal(2));
|
||||
}
|
||||
#ifdef HAS_LED
|
||||
|
Loading…
Reference in New Issue
Block a user