Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] can't disable SDSUPPORT with DWIN_CREALITY_LCD #22716

Closed
electronicm opened this issue Sep 5, 2021 · 10 comments
Closed

[BUG] can't disable SDSUPPORT with DWIN_CREALITY_LCD #22716

electronicm opened this issue Sep 5, 2021 · 10 comments

Comments

@electronicm
Copy link

Did you test the latest bugfix-2.0.x code?

Yes, and the problem still exists.

Bug Description

When I disable SDSUPPORT and want to use DWIN_CREALITY_LCD, I get the following error message when compiling:

Compiling .pio\build\STM32F103RET6_creality\src\src\lcd\marlinui.cpp.o
Marlin\src\lcd\e3v2\creality\dwin.cpp: In function 'uint16_t nr_sd_menu_items()':
Marlin\src\lcd\e3v2\creality\dwin.cpp:406:10: error: 'card' was not declared in this scope
  406 |   return card.get_num_Files() + !card.flag.workDirIsRoot;
      |          ^~~~
Compiling .pio\build\STM32F103RET6_creality\src\src\libs\BL24CXX.cpp.o
Marlin\src\lcd\e3v2\creality\dwin.cpp:1251:23: error: 'card' was not declared in this scope
 1251 |   char * const name = card.longest_filename();
      |                       ^~~~
Compiling .pio\build\STM32F103RET6_creality\src\src\libs\buzzer.cpp.o
Marlin\src\lcd\e3v2\creality\dwin.cpp: In function 'void make_name_without_ext(char*, char*, size_t)':
Marlin\src\lcd\e3v2\creality\dwin.cpp:1784:23: error: 'card' was not declared in this scope
 1784 |   char * const name = card.longest_filename();
      |                       ^~~~
Marlin\src\lcd\e3v2\creality\dwin.cpp: In function 'void HMI_SDCardInit()':
Marlin\src\lcd\e3v2\creality\dwin.cpp:1806:25: error: 'card' was not declared in this scope
 1806 | void HMI_SDCardInit() { card.cdroot(); }
Compiling .pio\build\STM32F103RET6_creality\src\src\libs\hex_print.cpp.o
      |                         ^~~~
Marlin\src\lcd\e3v2\creality\dwin.cpp: In function 'void Draw_SDItem(uint16_t, int16_t)':
Marlin\src\lcd\e3v2\creality\dwin.cpp:1843:27: error: 'card' was not declared in this scope
 1843 |   const bool is_subdir = !card.flag.workDirIsRoot;
      |                           ^~~~
compilation terminated due to -fmax-errors=5.
*** [.pio\build\STM32F103RET6_creality\src\src\lcd\e3v2\creality\dwin.cpp.o] Error 1

Bug Timeline

No response

Expected behavior

No response

Actual behavior

No response

Steps to Reproduce

Compile FW for #define MOTHERBOARD BOARD_CREALITY_V4 with //#define SDSUPPORT and #define DWIN_CREALITY_LCD.

Version of Marlin Firmware

bugfix-2.0.x (2021-09-05)

Printer model

Creality Ender 3v2

Electronics

No response

Add-ons

No response

Bed Leveling

UBL Bilinear mesh

Your Slicer

No response

Host Software

OctoPrint

Additional information & file uploads

Configuration.zip

VSCode with Auto Build Marlin v2.1.34 & PlatformIO IDE v2.3.3

@ellensp
Copy link
Contributor

ellensp commented Sep 5, 2021

Since that LCD runs its own firmware, it cannot be reconfigured on the fly. Thus it has requirements. One is you NEED to have support enabled.

@electronicm
Copy link
Author

@mriscoc: is that someting for you?
#21942

@electronicm
Copy link
Author

Since that LCD runs its own firmware, it cannot be reconfigured on the fly. Thus it has requirements. One is you NEED to have support enabled.

I've been testing @The-EG's work #22211 for months and it's never been a problem. Only when I switched back to CrealityUI did it become a problem.

When I use DWIN_MARLINUI_* everything works.

@The-EG
Copy link
Contributor

The-EG commented Sep 5, 2021

When I use DWIN_MARLINUI_* everything works.

The MarlinUI and 'Creality'UI implementations are completely separate. It would appear that the CrealityUI assumes that SDSupport always exists, where the MarlinUI implementation does not.

@mriscoc
Copy link
Contributor

mriscoc commented Sep 5, 2021

@mriscoc: is that someting for you?
#21942

The CrealityUI assumes that you have a 3D printer from them, but could be easy for someone to put some #ifdef to disable the menus and functionalities not available without a SD card. The PR #22211 uses the native MarlinUI implementation used in normal LCD display, which is more generic, and can work without a SD card. Maybe your requirement is more a "Feature Request" than a Bug.

@ellensp
Copy link
Contributor

ellensp commented Sep 5, 2021

You can disable the need for sdsupport in marlin, but all the SDsupport related icons and features will still be on screen. Resulting in bug reports that the icons/features don't work!

@thisiskeithb
Copy link
Member

There's now a sanity check to alert users of the required settings: b0a9107

#error "DWIN_CREALITY_LCD requires SDSUPPORT to be enabled."

@thinkyhead
Copy link
Member

The better options for maximum flexibility are DWIN_MARLINUI_PORTRAIT or DWIN_MARLINUI_LANDSCAPE.

@electronicm
Copy link
Author

electronicm commented Sep 8, 2021

The better options for maximum flexibility are DWIN_MARLINUI_PORTRAIT or DWIN_MARLINUI_LANDSCAPE.

As for flexibility, I totally agree with you.
However, the look of the CrealityUI appeals to me more and it has other advantages for me:

  • In order to move the axes, the speed does not have to be selected in advance.
  • Permanent visibility of some system information (position, temperature, status text)

Could they be transferred to the MarlinUI?

@github-actions
Copy link

github-actions bot commented Nov 7, 2021

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked and limited conversation to collaborators Nov 7, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

6 participants