FastLED 3.10.8
Loading...
Searching...
No Matches

◆ setMaxPowerInMilliWatts()

void CFastLED::setMaxPowerInMilliWatts ( fl::u32 milliwatts)
inline

Set the maximum power to be used, given in milliwatts.

Parameters
milliwattsthe max power draw desired, in milliwatts

Definition at line 1686 of file FastLED.h.

1686 {
1687 mNPowerData = milliwatts;
1688#if FL_COLOR_PIPELINE_SHARED
1689 fl::activeFramePowerDispatch() = fl::framePowerDispatch();
1690 mPPowerFunc = fl::activeFramePowerDispatch()->showBrightness;
1691#else
1693#endif
1694 }
power_func mPPowerFunc
function for overriding brightness when using FastLED.show();
Definition FastLED.h:731
fl::u32 mNPowerData
max power use parameter
Definition FastLED.h:730
fl::u8(* power_func)(fl::u8 scale, fl::u32 data)
Typedef for a power consumption calculation function.
Definition FastLED.h:646
fl::u8 calculate_max_brightness_for_power_mW(const CRGB *ledbuffer, fl::u16 numLeds, fl::u8 target_brightness, fl::u32 max_power_mW) FL_NO_EXCEPT
Determines the highest brightness level you can use and still stay under the specified power budget f...

References calculate_max_brightness_for_power_mW(), FL_NO_EXCEPT, mNPowerData, and mPPowerFunc.

Referenced by setMaxPowerInVoltsAndMilliamps().

+ Here is the call graph for this function:
+ Here is the caller graph for this function: