My Marlin configs for Fabrikator Mini and CTC i3 Pro B
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

dwin_defines.h 4.1KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128
  1. /**
  2. * Marlin 3D Printer Firmware
  3. * Copyright (c) 2021 MarlinFirmware [https://github.com/MarlinFirmware/Marlin]
  4. *
  5. * Based on Sprinter and grbl.
  6. * Copyright (c) 2011 Camiel Gubbels / Erik van der Zalm
  7. *
  8. * This program is free software: you can redistribute it and/or modify
  9. * it under the terms of the GNU General Public License as published by
  10. * the Free Software Foundation, either version 3 of the License, or
  11. * (at your option) any later version.
  12. *
  13. * This program is distributed in the hope that it will be useful,
  14. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  15. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  16. * GNU General Public License for more details.
  17. *
  18. * You should have received a copy of the GNU General Public License
  19. * along with this program. If not, see <https://www.gnu.org/licenses/>.
  20. *
  21. */
  22. #pragma once
  23. /**
  24. * DWIN general defines and data structs for PRO UI
  25. * Author: Miguel A. Risco-Castillo (MRISCOC)
  26. * Version: 3.11.2
  27. * Date: 2022/02/28
  28. */
  29. //#define DEBUG_DWIN 1
  30. //#define NEED_HEX_PRINT 1
  31. #include "../../../inc/MarlinConfigPre.h"
  32. #include <stddef.h>
  33. #define HAS_ESDIAG 1
  34. #define HAS_PIDPLOT 1
  35. #define HAS_GCODE_PREVIEW 1
  36. #if defined(__STM32F1__) || defined(STM32F1)
  37. #define DASH_REDRAW 1
  38. #endif
  39. #include "../common/dwin_color.h"
  40. #if ENABLED(LED_CONTROL_MENU)
  41. #include "../../../feature/leds/leds.h"
  42. #endif
  43. #define Def_Background_Color RGB( 1, 12, 8)
  44. #define Def_Cursor_color RGB(20, 49, 31)
  45. #define Def_TitleBg_color RGB( 0, 23, 16)
  46. #define Def_TitleTxt_color Color_White
  47. #define Def_Text_Color Color_White
  48. #define Def_Selected_Color Select_Color
  49. #define Def_SplitLine_Color RGB( 0, 23, 16)
  50. #define Def_Highlight_Color Color_White
  51. #define Def_StatusBg_Color RGB( 0, 23, 16)
  52. #define Def_StatusTxt_Color Color_Yellow
  53. #define Def_PopupBg_color Color_Bg_Window
  54. #define Def_PopupTxt_Color Popup_Text_Color
  55. #define Def_AlertBg_Color Color_Bg_Red
  56. #define Def_AlertTxt_Color Color_Yellow
  57. #define Def_PercentTxt_Color Percent_Color
  58. #define Def_Barfill_Color BarFill_Color
  59. #define Def_Indicator_Color Color_White
  60. #define Def_Coordinate_Color Color_White
  61. #define Def_Button_Color RGB( 0, 23, 16)
  62. #define HAS_ESDIAG 1
  63. #if BOTH(LED_CONTROL_MENU, HAS_COLOR_LEDS)
  64. #define Def_Leds_Color 0xFFFFFFFF
  65. #endif
  66. #if ENABLED(CASELIGHT_USES_BRIGHTNESS)
  67. #define Def_CaseLight_Brightness 255
  68. #endif
  69. typedef struct {
  70. // Color settings
  71. uint16_t Background_Color = Def_Background_Color;
  72. uint16_t Cursor_color = Def_Cursor_color;
  73. uint16_t TitleBg_color = Def_TitleBg_color;
  74. uint16_t TitleTxt_color = Def_TitleTxt_color;
  75. uint16_t Text_Color = Def_Text_Color;
  76. uint16_t Selected_Color = Def_Selected_Color;
  77. uint16_t SplitLine_Color = Def_SplitLine_Color;
  78. uint16_t Highlight_Color = Def_Highlight_Color;
  79. uint16_t StatusBg_Color = Def_StatusBg_Color;
  80. uint16_t StatusTxt_Color = Def_StatusTxt_Color;
  81. uint16_t PopupBg_color = Def_PopupBg_color;
  82. uint16_t PopupTxt_Color = Def_PopupTxt_Color;
  83. uint16_t AlertBg_Color = Def_AlertBg_Color;
  84. uint16_t AlertTxt_Color = Def_AlertTxt_Color;
  85. uint16_t PercentTxt_Color = Def_PercentTxt_Color;
  86. uint16_t Barfill_Color = Def_Barfill_Color;
  87. uint16_t Indicator_Color = Def_Indicator_Color;
  88. uint16_t Coordinate_Color = Def_Coordinate_Color;
  89. // Temperatures
  90. #if HAS_HOTEND && defined(PREHEAT_1_TEMP_HOTEND)
  91. int16_t HotendPidT = PREHEAT_1_TEMP_HOTEND;
  92. #endif
  93. #if HAS_HEATED_BED && defined(PREHEAT_1_TEMP_BED)
  94. int16_t BedPidT = PREHEAT_1_TEMP_BED;
  95. #endif
  96. #if HAS_HOTEND || HAS_HEATED_BED
  97. int16_t PidCycles = 10;
  98. #endif
  99. #if ENABLED(PREVENT_COLD_EXTRUSION)
  100. int16_t ExtMinT = EXTRUDE_MINTEMP;
  101. #endif
  102. #if BOTH(HAS_HEATED_BED, PREHEAT_BEFORE_LEVELING)
  103. int16_t BedLevT = LEVELING_BED_TEMP;
  104. #endif
  105. #if ENABLED(BAUD_RATE_GCODE)
  106. bool Baud115K = false;
  107. #endif
  108. bool FullManualTramming = false;
  109. // Led
  110. #if ENABLED(MESH_BED_LEVELING)
  111. float ManualZOffset = 0;
  112. #endif
  113. #if BOTH(LED_CONTROL_MENU, HAS_COLOR_LEDS)
  114. uint32_t LED_Color = Def_Leds_Color;
  115. #endif
  116. } HMI_data_t;
  117. static constexpr size_t eeprom_data_size = sizeof(HMI_data_t);
  118. extern HMI_data_t HMI_data;