Skip to content

Commit

Permalink
Merge latest Desuuuu/bugfix
Browse files Browse the repository at this point in the history
  • Loading branch information
thinkyhead committed Sep 6, 2021
1 parent c6e6af4 commit 5ae554e
Show file tree
Hide file tree
Showing 6 changed files with 17 additions and 24 deletions.
2 changes: 1 addition & 1 deletion Marlin/src/lcd/extui/dgus/dgus_extui.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -159,4 +159,4 @@ namespace ExtUI {
void onSteppersEnabled() {}
}

#endif // HAS_DGUS_LCD
#endif // HAS_DGUS_LCD_CLASSIC
3 changes: 2 additions & 1 deletion Marlin/src/lcd/extui/dgus_reloaded/DGUSDisplay.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -392,7 +392,8 @@ bool DGUS_PopulateVP(const DGUS_Addr addr, DGUS_VP * const buffer) {
const DGUS_VP *ret = vp_list;

do {
const uint16_t addrcheck = pgm_read_word(&ret->addr);
const uint16_t *paddr = (uint16_t *)(&ret->addr);
const uint16_t addrcheck = pgm_read_word(paddr);
if (addrcheck == 0) break;
if ((DGUS_Addr)addrcheck == addr) {
memcpy_P(buffer, ret, sizeof(*ret));
Expand Down
2 changes: 2 additions & 0 deletions Marlin/src/lcd/extui/dgus_reloaded/DGUSScreenHandler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -360,6 +360,8 @@ void DGUSScreenHandler::FilamentRunout(const ExtUI::extruder_t extruder) {
case ExtUI::PID_DONE:
SetStatusMessagePGM(GET_TEXT(MSG_PID_AUTOTUNE_DONE));
break;
default:
return;
}

dgus_display.PlaySound(3);
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/**
* Marlin 3D Printer Firmware
* Copyright (c) 2020 MarlinFirmware [https://github.com/MarlinFirmware/Marlin]
* Copyright (c) 2021 MarlinFirmware [https://github.com/MarlinFirmware/Marlin]
*
* Based on Sprinter and grbl.
* Copyright (c) 2011 Camiel Gubbels / Erik van der Zalm
Expand All @@ -21,17 +21,15 @@
*/

/**
* extui_dgus_lcd.cpp
*
* DGUS implementation for Marlin by coldtobi, Feb-May 2019
* lcd/extui/dgus_reloaded/dgus_reloaded_extui.cpp
*/

#include "../../inc/MarlinConfigPre.h"
#include "../../../inc/MarlinConfigPre.h"

#if ENABLED(DGUS_LCD_UI_RELOADED)

#include "ui_api.h"
#include "dgus_reloaded/DGUSScreenHandler.h"
#include "../ui_api.h"
#include "DGUSScreenHandler.h"

namespace ExtUI {

Expand All @@ -52,17 +50,9 @@ namespace ExtUI {
dgus_screen_handler.PrinterKilled(error, component);
}

void onMediaInserted() {
TERN_(SDSUPPORT, dgus_screen_handler.SDCardInserted());
}

void onMediaError() {
TERN_(SDSUPPORT, dgus_screen_handler.SDCardError());
}

void onMediaRemoved() {
TERN_(SDSUPPORT, dgus_screen_handler.SDCardRemoved());
}
void onMediaInserted() { TERN_(SDSUPPORT, dgus_screen_handler.SDCardInserted()); }
void onMediaError() { TERN_(SDSUPPORT, dgus_screen_handler.SDCardError()); }
void onMediaRemoved() { TERN_(SDSUPPORT, dgus_screen_handler.SDCardRemoved()); }

void onPlayTone(const uint16_t frequency, const uint16_t duration) {
dgus_screen_handler.PlayTone(frequency, duration);
Expand Down Expand Up @@ -108,9 +98,7 @@ namespace ExtUI {
dgus_screen_handler.LoadSettings(buff);
}

void onPostprocessSettings() {
// Called after loading or resetting stored settings
}
void onPostprocessSettings() {}

void onConfigurationStoreWritten(bool success) {
dgus_screen_handler.ConfigurationStoreWritten(success);
Expand Down
3 changes: 2 additions & 1 deletion ini/features.ini
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,8 @@ HAS_MENU_TRAMMING = src_filter=+<src/lcd/menu/menu_tramming
HAS_MENU_UBL = src_filter=+<src/lcd/menu/menu_ubl.cpp>
ANYCUBIC_LCD_CHIRON = src_filter=+<src/lcd/extui/anycubic_chiron>
ANYCUBIC_LCD_I3MEGA = src_filter=+<src/lcd/extui/anycubic_i3mega>
HAS_DGUS_LCD = src_filter=+<src/lcd/extui/dgus>
HAS_DGUS_LCD_CLASSIC = src_filter=+<src/lcd/extui/dgus>
DGUS_LCD_UI_RELOADED = src_filter=+<src/lcd/extui/dgus_reloaded>
DGUS_LCD_UI_FYSETC = src_filter=+<src/lcd/extui/dgus/fysetc>
DGUS_LCD_UI_HIPRECY = src_filter=+<src/lcd/extui/dgus/hiprecy>
DGUS_LCD_UI_MKS = src_filter=+<src/lcd/extui/dgus/mks>
Expand Down
1 change: 1 addition & 0 deletions platformio.ini
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@ default_src_filter = +<src/*> -<src/config> -<src/HAL> +<src/HAL/shared>
-<src/lcd/extui/anycubic_chiron>
-<src/lcd/extui/anycubic_i3mega>
-<src/lcd/extui/dgus> -<src/lcd/extui/dgus/fysetc> -<src/lcd/extui/dgus/hiprecy> -<src/lcd/extui/dgus/mks> -<src/lcd/extui/dgus/origin>
-<src/lcd/extui/dgus_reloaded>
-<src/lcd/extui/example>
-<src/lcd/extui/ftdi_eve_touch_ui>
-<src/lcd/extui/malyan>
Expand Down

0 comments on commit 5ae554e

Please sign in to comment.