Prusa MINI Firmware overview
|
Go to the documentation of this file.
28 #include "../../inc/MarlinConfigPre.h"
32 #if ENABLED(NEOPIXEL_LED)
36 #define HAS_WHITE_LED EITHER(RGBW_LED, NEOPIXEL_LED)
45 #if ENABLED(NEOPIXEL_LED)
55 ,
i(NEOPIXEL_BRIGHTNESS)
80 ,
i(NEOPIXEL_BRIGHTNESS)
86 r = rgbw[0];
g = rgbw[1];
b = rgbw[2];
94 if (
this != &right) memcpy(
this, &right,
sizeof(
LEDColor));
99 if (
this == &right)
return true;
100 return 0 == memcmp(
this, &right,
sizeof(
LEDColor));
118 #if ENABLED(NEOPIXEL_LED)
119 #define MakeLEDColor(R,G,B,W,I) LEDColor(R, G, B, W, I)
121 #define MakeLEDColor(R,G,B,W,I) LEDColor(R, G, B, W)
124 #define MakeLEDColor(R,G,B,W,I) LEDColor(R, G, B)
127 #define LEDColorOff() LEDColor( 0, 0, 0)
128 #define LEDColorRed() LEDColor(255, 0, 0)
129 #if ENABLED(LED_COLORS_REDUCE_GREEN)
130 #define LEDColorOrange() LEDColor(255, 25, 0)
131 #define LEDColorYellow() LEDColor(255, 75, 0)
133 #define LEDColorOrange() LEDColor(255, 80, 0)
134 #define LEDColorYellow() LEDColor(255, 255, 0)
136 #define LEDColorGreen() LEDColor( 0, 255, 0)
137 #define LEDColorBlue() LEDColor( 0, 0, 255)
138 #define LEDColorIndigo() LEDColor( 0, 255, 255)
139 #define LEDColorViolet() LEDColor(255, 0, 255)
141 #define LEDColorWhite() LEDColor( 0, 0, 0, 255)
143 #define LEDColorWhite() LEDColor(255, 255, 255)
154 ,
bool isSequence=
false
166 ,
bool isSequence=
false
180 #if ENABLED(LED_COLOR_PRESETS)
181 static const LEDColor defaultLEDColor;
182 static inline void set_default() {
set_color(defaultLEDColor); }
191 #if ENABLED(PRINTER_EVENT_LEDS)
195 #if EITHER(LED_CONTROL_MENU, PRINTER_EVENT_LEDS)
197 static bool lights_on;
200 #if ENABLED(LED_CONTROL_MENU)
201 static void toggle();
202 static inline void update() {
set_color(color); }
205 #ifdef LED_BACKLIGHT_TIMEOUT
209 static inline void reset_timeout(
const millis_t &ms) {
210 led_off_time = ms + LED_BACKLIGHT_TIMEOUT;
211 if (!lights_on) set_default();
213 static void update_timeout(
const bool power_on);
static void set_color(const LEDColor &color)
LEDColor & operator=(const LEDColor &right)
Definition: leds.h:93
#define MakeLEDColor(R, G, B, W, I)
Definition: leds.h:124
void blinkm_set_led_color(const LEDColor &color)
void set_color(uint8_t r, uint8_t g, uint8_t b)
Definition: leds.h:158
static uint32_t Color(uint8_t r, uint8_t g, uint8_t b, uint8_t w)
Definition: neopixel.h:115
uint8_t r
Definition: leds.h:42
static void set_brightness(const uint8_t b)
Definition: neopixel.h:88
#define LEDColorOrange()
Definition: leds.h:133
#define LEDColorGreen()
Definition: leds.h:136
#define LEDColorRed()
Definition: leds.h:128
#define LEDColorBlue()
Definition: leds.h:137
bool operator==(const LEDColor &right)
Definition: leds.h:98
#define NEO_WHITE
Definition: neopixel.h:47
static void set_white()
Definition: leds.h:178
static void set_pixel_color(const uint16_t n, const uint32_t c)
Definition: neopixel.h:81
#define SET_PWM(IO)
Definition: fastio.h:103
LEDColor(const uint8_t(&rgbw)[4])
Definition: leds.h:76
uint8_t i
Definition: screen_test_graph.c:72
static uint16_t pixels()
Definition: neopixel.h:113
uint32_t millis(void)
Definition: wiring_time.c:29
#define SET_OUTPUT(IO)
Definition: fastio.h:101
bool is_off() const
Definition: leds.h:105
static void set_off()
Definition: leds.h:176
bool PWM_PIN(const pin_t p)
bool operator!=(const LEDColor &right)
Definition: leds.h:103
LEDLights()
Definition: leds.h:148
uint8_t b
Definition: leds.h:42
LEDColor(uint8_t r, uint8_t g, uint8_t b)
Definition: leds.h:60
#define RGB_LED_R_PIN
Definition: pins_FYSETC_F6_13.h:243
LEDColor()
Definition: leds.h:51
#define LEDColorYellow()
Definition: leds.h:134
#define RGB_LED_G_PIN
Definition: pins_FYSETC_F6_13.h:246
#define HAS_WHITE_LED
Definition: leds.h:36
#define LEDColorWhite()
Definition: leds.h:143
#define LEDColorIndigo()
Definition: leds.h:138
#define LEDColorViolet()
Definition: leds.h:139
if(size<=((png_alloc_size_t) -1) - ob)
Definition: pngwrite.c:2176
static void show()
Definition: neopixel.h:95
#define ELAPSED(NOW, SOON)
Definition: millis_t.h:29
const uint8_t[]
Definition: 404_html.c:3
#define RGB_LED_W_PIN
Definition: pins_FYSETC_F6_13.h:252
LEDColor & operator=(const uint8_t(&rgbw)[4])
Definition: leds.h:85
#define RGB_LED_B_PIN
Definition: pins_FYSETC_F6_13.h:249
#define LEDColorOff()
Definition: leds.h:127
uint8_t g
Definition: leds.h:42
list b
Definition: createSpeedLookupTable.py:30
static void set_green()
Definition: leds.h:177
void pca9632_set_led_color(const LEDColor &color)
static void set_color(const uint32_t c)
uint32_t millis_t
Definition: millis_t.h:26
#define ENABLED(V...)
Definition: macros.h:177