MarlinFirmware / Marlin

Marlin is an optimized firmware for RepRap 3D printers based on the Arduino platform. Many commercial 3D printers come with Marlin installed. Check with your vendor if you need source code for your specific machine.
https://marlinfw.org
GNU General Public License v3.0
16.22k stars 19.22k forks source link

[BUG] MKS MINI12864 Not working with SKR1.4/t #22720

Closed GrzegorzManiak closed 3 years ago

GrzegorzManiak commented 3 years ago

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

Yes, and the problem still exists.

Bug Description

I defined my display of choice, the mks mini 12864, Partnered with an SKR1.4T with TMC2130's drivers running in SPI mode, I've tried to reverse the connectors, All that I get is the screen glowing white as it getting fed the 5v it needs, It seems to be buzzing every time I click the Pot, but shows no characters, I verified that the display is functional by hooking it up to a TriGorilla 1.3 board and the Mks Gen L v1.0.

Configuration.h

#define CONFIGURATION_H_VERSION 02000901   
#define MKS_MINI_12864

pins_BTT_SKR_V1_4.h

#if ENABLED(MKS_MINI_12864)
  #define DOGLCD_CS            EXP1_05_PIN
  #define DOGLCD_A0            EXP1_04_PIN
  #define DOGLCD_SCK           EXP2_09_PIN
  #define DOGLCD_MOSI          EXP2_05_PIN
  #define FORCE_SOFT_SPI
#endif

Bug Timeline

Today, as I tried to attach the screen to reuse it

Expected behavior

The display is expected to, you know, display stuff.

Actual behavior

2-3 Second buzzing noise when plugged in, the backlight turns on, audible noise when the pot is turned/clicked, seems like its working, just not displaying.it's

Steps to Reproduce

  1. TMC2130 SPI Paired with an SKR 1.4
  2. Compile marlin with the #define MKS_MINI_12864 display defined.
  3. Flash.

Version of Marlin Firmware

02000901

Printer model

Tevo Tarantula Pro

Electronics

TMC 2130's, Dual Z, 24v, SKR 1.4 Turbo, stock display

Add-ons

No response

Bed Leveling

UBL Bilinear mesh

Your Slicer

Cura

Host Software

Cura

Additional information & file uploads

No response

ellensp commented 3 years ago

"tried to reverse the connectors" that's a shame. That kills one of the io lines on the SKR1.4/t nearly every single time.

GrzegorzManiak commented 3 years ago

"tried to reverse the connectors" that's a shame. That kills one of the io lines on the SKR1.4/t nearly every single time.

Any quick way of testing that?

ellensp commented 3 years ago

No easy way I know of.

Start from the beginning. Check the following.

Skr 1.4 (note cable key is on the left)

/**              ------                             ------
 *  BEEPER 1.30 |10  9 | 0.28 BTN_ENC         0.17 |10  9 | 0.15 SCK
 *         1.18 | 8  7 | 1.19         BTN_EN2 3.26 | 8  7 | 0.16 SDSS
 *         1.20   6  5 | 1.21 CS      BTN_EN1 3.25   6  5 | 0.18 MOSI
 *      A0 1.22 | 4  3 | 1.23          SD_DET 1.31 | 4  3 | RESET
 *          GND | 2  1 | 5V                    GND | 2  1 | NC
 *               ------                            ------
 *                EXP1                              EXP2
*/

MKS mini (note cable keys are on right)

So according to this you need to rotate the plugs around 180 degrees at one end.. while keeping exp1 going to exp1 and exp2 going to exp2.

While off and unplugged from usb and power. Plug in the lcd the way you think it should be With a multi meter check continuity from controller gnd to lcd gnd (normally the metal sd card holder on the board to the lcd sd card is good for this) Then check 5v on controller is connected to 5v on lcd.
If those are fine, it should be safe to power up and try again

GrzegorzManiak commented 3 years ago

Thank you, Ill check it out

GrzegorzManiak commented 3 years ago

Yep, I verified that It GND => GND and 5V => 5V, But still no text, The display seems like it's trying to refresh them as there's a bit of scrolling text at the bottom in mariln

thisiskeithb commented 3 years ago

Which LCD revision do you have? If you could get a picture of the back, that’d help.

I’ll see which revs I have and will toss them on an SKR 1.4.

GrzegorzManiak commented 3 years ago

Sure,

Snapchat-1797095734 Snapchat-1801944008

ellensp commented 3 years ago

This page https://www.aliexpress.com/item/32870541074.html says it should be set to a MINIPANEL not a MKS_MINI_12864

thisiskeithb commented 3 years ago

This page https://www.aliexpress.com/item/32870541074.html says it should be set to a MINIPANEL not a MKS_MINI_12864

It’s also outdated.

GrzegorzManiak commented 3 years ago

Yeah, I couldn't find much on the V2.0, Marlin has V1.0 and V3.0(bugfix branch) but no V2.0

GrzegorzManiak commented 3 years ago

Also, If I try compile for the MINIPANEL, I get a nice message from marlin, In the bugfix branch and the release


  225 |     #define U8G_PARAM DOGLCD_CS, DOGLCD_A0                      // HW-SPI
      |                       ^~~~~~~~~
Marlin\src\lcd\dogm\marlinui_DOGM.cpp:262:14: note: in expansion of macro 'U8G_PARAM'
  262 |     u8g.init(U8G_PARAM);
      |              ^~~~~~~~~
Compiling .pio\build\LPC1769\src\src\lcd\extui\ui_api.cpp.o
Marlin\src\lcd\dogm\marlinui_DOGM.h:225:34: error: 'DOGLCD_A0' was not declared in this scope; did you mean 'DOGLCD_SCK'?
  225 |     #define U8G_PARAM DOGLCD_CS, DOGLCD_A0                      // HW-SPI
      |                                  ^~~~~~~~~
Marlin\src\lcd\dogm\marlinui_DOGM.cpp:262:14: note: in expansion of macro 'U8G_PARAM'
  262 |     u8g.init(U8G_PARAM);```
ellensp commented 3 years ago

No pin definitions for MINIPANEL for skr 1.4

change #if ENABLED(MKS_MINI_12864) to #if EITHER(MKS_MINI_12864, MINIPANEL) In Marlin/src/pins/lpc1768/pins_BTT_SKR_V1_4.h It now compiles

Edit this was wrong... got wrong lcd... corrected

GrzegorzManiak commented 3 years ago

Flashed it, still just a white screen, the Nob works, and so dose the reset button, Just nothing gets displayed

GrzegorzManiak commented 3 years ago

nope, Do i just give up and buy a new display

thisiskeithb commented 3 years ago

MKS_MINI_12864 does other things like set the contrast and defines MINIPANEL, so just defining MINIPANEL won’t work.

GrzegorzManiak commented 3 years ago

So what do you suggest? Enable MKS_MINI_12864 and reconfigure the pins from minipanel to MKS_MINI_12864? Also running TMC2130'S In spy doesn't affect the display right?

GrzegorzManiak commented 3 years ago

Its so so strange, I ran G28 than G29 And I have a manual probe and the display beeps and all

thisiskeithb commented 3 years ago

I’ve managed to temporarily lose my MKS Mini V2 screens in my pile-o-hardware, but I’m sure we can get this LCD working since it works fine on the SKR 1.3.

thisiskeithb commented 3 years ago

So I have an MKS Mini 12864 V1.0 and V2.1.

Both of these work on an SKR 1.4 Turbo with 5160s (also in SPI mode) but the 1.0 seems to need different contrast settings.

Can you try setting your LCD contrast using g-code? M250 C155 or M250 C195 will change the LCD contrast.

GrzegorzManiak commented 3 years ago

I'll grab my printer and check

GrzegorzManiak commented 3 years ago

Clicked the wrong button, I can now change the contrast as beforehand M250 CXXX Would not change the contrast, It would just stay the same, Are you using the stock Pin out of the board, I have a feeling this is a SKR1.4 Thing as my friends 1.3 works fine with his mks mini12864 v2. And to add to the confusion, the board works with a Reprap discount smart controller of my kossel, and the MKS Mini12864 v2 works as when I plug it into the Mks Gen L V1.0 it works as expected.

thisiskeithb commented 3 years ago

I can now change the contrast as beforehand M250 CXXX Would not change the contrast, It would just stay the same

So it's fixed? A bad contrast value could have been stored in EEPROM making the screen unreadable.

Are you using the stock Pin out of the board, I have a feeling this is a SKR1.4

Stock SKR 1.4 Turbo, cables (rotated one end of each cable 180 degrees), LCDs. The SKR 1.4 and 1.4 Turbo are the same board except for the MCU (LPC1768 vs. LPC1769).

github-actions[bot] commented 2 years ago

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.