mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-25 01:05:27 +03:00
Allow thrust color to be combined with throttle.
This commit is contained in:
parent
0fd7a2568c
commit
5512ff08c3
2 changed files with 2 additions and 2 deletions
|
@ -178,7 +178,7 @@ Note: Armed State cannot be used with Flight Mode.
|
||||||
|
|
||||||
This mode fades the LED current LED color to the previous/next color in the HSB color space depending on throttle stick position. When the
|
This mode fades the LED current LED color to the previous/next color in the HSB color space depending on throttle stick position. When the
|
||||||
throttle is in the middle position the color is unaffected, thus it can be mixed with orientation colors to indicate orientation and throttle at
|
throttle is in the middle position the color is unaffected, thus it can be mixed with orientation colors to indicate orientation and throttle at
|
||||||
the same time.
|
the same time. Thrust should normally be combined with Color or Mode/Orientation.
|
||||||
|
|
||||||
#### Thrust ring state
|
#### Thrust ring state
|
||||||
|
|
||||||
|
|
|
@ -771,7 +771,7 @@ void applyLedThrottleLayer()
|
||||||
|
|
||||||
int scaled = scaleRange(rcData[THROTTLE], PWM_RANGE_MIN, PWM_RANGE_MAX, -60, +60);
|
int scaled = scaleRange(rcData[THROTTLE], PWM_RANGE_MIN, PWM_RANGE_MAX, -60, +60);
|
||||||
scaled += HSV_HUE_MAX;
|
scaled += HSV_HUE_MAX;
|
||||||
color.h = scaled % HSV_HUE_MAX;
|
color.h = (color.h + scaled) % HSV_HUE_MAX;
|
||||||
setLedHsv(ledIndex, &color);
|
setLedHsv(ledIndex, &color);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue