Sfoglia il codice sorgente

🩹 Fix TFT tImage struct packing

Scott Lahteine 3 anni fa
parent
commit
e84de791ab
1 ha cambiato i file con 7 aggiunte e 1 eliminazioni
  1. 7
    1
      Marlin/src/lcd/tft/tft_image.h

+ 7
- 1
Marlin/src/lcd/tft/tft_image.h Vedi File

@@ -114,7 +114,13 @@ enum colorMode_t : uint8_t {
114 114
 
115 115
 typedef colorMode_t ColorMode;
116 116
 
117
-typedef struct __attribute__((__packed__)) {
117
+#ifdef __AVR__
118
+  #define PACKED __attribute__((__packed__))
119
+#else
120
+  #define PACKED
121
+#endif
122
+
123
+typedef struct PACKED {
118 124
   void *data;
119 125
   uint16_t width;
120 126
   uint16_t height;

Loading…
Annulla
Salva