You can now set LED_MAX_MILLIAMPS if your power supply is limited.
This commit is contained in:
parent
f8c696c384
commit
ca980b0c9f
@ -18,6 +18,7 @@
|
|||||||
#define COLOR_ORDER GRB // Order of the colors of the LEDs. If you get unexpected colors, you should change this.
|
#define COLOR_ORDER GRB // Order of the colors of the LEDs. If you get unexpected colors, you should change this.
|
||||||
#define BRIGHTNESS 20 // Default brightness of the LEDs. 1 (lowest)-255 (brightest)
|
#define BRIGHTNESS 20 // Default brightness of the LEDs. 1 (lowest)-255 (brightest)
|
||||||
#define TEMPORAL_DITHERING 0 // Use temporal dithering. Can lead to flickering.
|
#define TEMPORAL_DITHERING 0 // Use temporal dithering. Can lead to flickering.
|
||||||
|
#define LED_MAX_MILLIAMPS 0 // If your power supply is too small, you can set this to a maximum mA value. FastLED should then honor this. Setting it to 0 disables this limit.
|
||||||
|
|
||||||
#define NTP_SERVER "pool.ntp.org" // NTP server to use to fetch the current time
|
#define NTP_SERVER "pool.ntp.org" // NTP server to use to fetch the current time
|
||||||
#define NTP_INTERVAL 300000 // Interval in ms to update the time from the NTP server. 300000 ms = 5 minutes
|
#define NTP_INTERVAL 300000 // Interval in ms to update the time from the NTP server. 300000 ms = 5 minutes
|
||||||
|
@ -6,4 +6,7 @@ void fastled_setup() {
|
|||||||
FastLED.addLeds<LED_TYPE,DATA_PIN,COLOR_ORDER>(leds, LED_COUNT).setCorrection(TypicalLEDStrip);
|
FastLED.addLeds<LED_TYPE,DATA_PIN,COLOR_ORDER>(leds, LED_COUNT).setCorrection(TypicalLEDStrip);
|
||||||
FastLED.setBrightness(BRIGHTNESS);
|
FastLED.setBrightness(BRIGHTNESS);
|
||||||
FastLED.setDither(TEMPORAL_DITHERING);
|
FastLED.setDither(TEMPORAL_DITHERING);
|
||||||
|
if (LED_MAX_MILLIAMPS > 0) {
|
||||||
|
FastLED.setMaxPowerInVoltsAndMilliamps(5, LED_MAX_MILLIAMPS);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user