mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-23 16:25:31 +03:00
Renamed min, max and abs macros to MIN MAX and ABS.
This commit is contained in:
parent
616c40a827
commit
be03ed95fa
15 changed files with 42 additions and 42 deletions
|
@ -775,10 +775,10 @@ void updateLedStrip(void)
|
|||
|
||||
if (indicatorFlashNow) {
|
||||
|
||||
uint8_t rollScale = abs(rcCommand[ROLL]) / 50;
|
||||
uint8_t pitchScale = abs(rcCommand[PITCH]) / 50;
|
||||
uint8_t scale = max(rollScale, pitchScale);
|
||||
nextIndicatorFlashAt = now + (LED_STRIP_5HZ / max(1, scale));
|
||||
uint8_t rollScale = ABS(rcCommand[ROLL]) / 50;
|
||||
uint8_t pitchScale = ABS(rcCommand[PITCH]) / 50;
|
||||
uint8_t scale = MAX(rollScale, pitchScale);
|
||||
nextIndicatorFlashAt = now + (LED_STRIP_5HZ / MAX(1, scale));
|
||||
|
||||
if (indicatorFlashState == 0) {
|
||||
indicatorFlashState = 1;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue