bigtreetech / BIGTREETECH-SKR-mini-E3

BIGTREETECH SKR-mini-E3 motherboard is a ultra-quiet, low-power, high-quality 3D printing machine control board. It is launched by the 3D printing team of Shenzhen BIGTREE technology co., LTD. This board is specially tailored for Ender 3 printer, perfectly replacing the original Ender3 printer motherboard.
2k stars 1.98k forks source link

BTT SKR MINI E3 V2 with BTT MINI12864 V1.0 - only backlight working #686

Open Legiotech opened 1 year ago

Legiotech commented 1 year ago

Hi I'm trying to connect SKR MINI V2 with Mini12864, but best I can get is backlight working. I've made a custom cable to connect display to the board - then i checked 10 times if i made it right (according to #650/info in Marlin files). I have also followed recomendations for commenting/uncommenting different lines from #650 topic. I have set the contrast in _Marlin\src\lcd\dogm\marlinuiDOGM.cpp to 255: void MarlinUI::_set_contrast() { u8g.setContrast(255); } IMG_20220929_174446

If I am correct my cable is working fine, otherwise i wouldn't get backlight (at least gnd, +5 and one more cable are fine). Do you know any way to make my screen work?

radek8 commented 1 year ago

If I look at the pin file for your board, there is something I don't like...

Legiotech commented 1 year ago

I checked it and indeed there is two pins in mainboard, that are different than in Marlin files. Sadly i don't see any pins for PA9 and PA10 on mainboard. Does it mean that it won't work? skrminie3v2

radek8 commented 1 year ago

I didn't mean this. PA9 and PA10 is fine

image

I don't have the SKR mini E3 board, nor the BTT MINI12864 display. That's why I can't test the settings. Send me your configuration files and I'll try to suggest changes if you want to test them. configuration.h configuration_adv.h pins_BTT_SKR_MINI_E3_common.h

radek8 commented 1 year ago

The swap is here

image

RX2 = PA3 TX2 = PA2 According to the pin file, it's the other way around.

image

radek8 commented 1 year ago

Some pins ( PA9 , PA3) are defined twice. That won't be good either. I would try to comment on these items:

define LCD_PINS_RS PA9

define LCD_PINS_ENABLE PA3

define LCD_RESET_PIN PA10

image

Legiotech commented 1 year ago

Thank you very much! I made changes that you talked about and it's working fine!!!

IMG_20221002_130841

radek8 commented 1 year ago

Congratulations. That's great. So what have you changed? I would suggest changing it in Marlin so that it works for others and they don't have to look for a problem as well.

Legiotech commented 1 year ago

Modyfications in Marlin that I have done:

-pins (Marlin\src\pins\stm32f1\pins_BTT_SKR_MINI_E3_common.h): after #elif ENABLED(FYSETC_MINI_12864_2_1) i've added #define NO_CONTROLLER_CUSTOM_WIRING_WARNING and i've commented three lines:

    //#define LCD_PINS_RS                     PA9     // CS
    //#define LCD_PINS_ENABLE                 PA3     // MOSI
    #define LCD_BACKLIGHT_PIN               -1
    #define NEOPIXEL_PIN                    PB8
    #define LCD_CONTRAST                    255
    //#define LCD_RESET_PIN                   PA10

From the Marlin files that was it i guess. In wiring i swapped two wires in TFT connector: Bez tytułu3

I think it was all. Thank you very much once again.

radek8 commented 1 year ago

@Legiotech I suggested the Marlin modification. Thisiskeithb says no need to edit the file Marlin\src\lcd\dogm\marlinui_DOGM.cpp If no characters appear on the display, it is said that resetting the EEPROM is sufficient. Can you please compile Marlin without this modification and try it? Thank you

Legiotech commented 1 year ago

I have compiled Marlin without changes in marlinui_DOGM.cpp and as it was before, there was no characters on the screen. I have plugged the usb cable and tried to connect to the board using Pronterface, but it haven't worked. After that I've installed a driver from https://github.com/bigtreetech/BIGTREETECH-SKR-mini-E3/tree/master/firmware/mapleDrv-USBdriver and it haven't worked as well. I have also mount mainboard into the printer and it turned out that the screen work only when i power the board via usb (but it may be solved by reseting eeprom as Thisiskeithb said). When i power it from the usb and then turn on power supply it works fine and i can use screen normally.

Sporkforce commented 1 year ago

Hello, I am also trying to use the BTT Mini 12864 V1.0 on a BTT SKR Mini E3 V2.0. I am using the Marlin 2.0.8.2x SKR Mini E3 V2.0 Firmware and there is no

elif ENABLED(FYSETC_MINI_12864_2_1

Entry in Marlin\src\pins\stm32f1\pins_BTT_SKR_MINI_E3_common.h

Do I manually insert that entry along with

//#define LCD_PINS_RS PA9 // CS //#define LCD_PINS_ENABLE PA3 // MOSI

define LCD_BACKLIGHT_PIN -1

#define NEOPIXEL_PIN                    PB8
#define LCD_CONTRAST                    255
//#define LCD_RESET_PIN                   PA10

?

I'm no stranger to rewiring connectors or tweaking firmware, but for some reason I can't get my head around this one. Thanks for any help.

Legiotech commented 1 year ago

I had the same issue at first, so I decided to use Marlin 2.1.x and used WinMerge to rewrite configuration.h and configuration_adv.h. It was quite fast operation. I don't know if adding some lines by hand will help, but probably not. You can try it and report if it worked. BTW I still have problem with connecting via usb to the mainboard, I will try to solve it, but now I have to put it aside for a bit.

Sporkforce commented 1 year ago

I got Marlin 2.1.1 and updated its Config/Config_adv, along with the pins_BTT_SKR_MINI_E3_common.h and marlinui_DOGM.cpp. Havn't found anyone yet able to use USB connectivity though, after prowling the googles for a good bit. Otherwise everything is accounted for and seems ready to go, custom cable is made, but for the life of me I can't get it to compile. It claims the wrong board is defined in Configuration.h . I read this may be a platformio board definition mismatch but Im still in the process of tracking this issue down. Were you able to get your firmware compiled without any fuss?

Legiotech commented 1 year ago

Yes, I compiled my firmware without issues. I can't check my settings now, but if you won't solve the issue till wednesday I can check it for you. I was looking for some information about usb connection too and it seems to be not working.

radek8 commented 1 year ago

@sporkforce, send the exact wording of the error. Send all the files you edited: configuration.h, configurtion_adv.h, pin file and more...

Sporkforce commented 1 year ago

Oh thanks! I used Winmerge to copy over the custom settings. The printer is a uniqe setup so misc sizes and hotend/thermistor/extruder wont match a typical Ender 3 or CR10 Full error message after attempt to compile: buildroot/share/PlatformIO/scripts/../../../../Marlin/src/inc/../pins/stm32f1/pins_BTT_SKR_MINI_E3_common.h:247:8: error: #error "CAUTION! FYSETC_MINI_12864_2_1 / MKS_MINI_12864_V3 / BTT_MINI_12864_V1 requires wiring modifications. See 'pins_BTT_SKR_MINI_E3_common.h' for details. (Define NO_CONTROLLER_CUSTOM_WIRING_WARNING to suppress this warning.)" 247 | #error "CAUTION! FYSETC_MINI_12864_2_1 / MKS_MINI_12864_V3 / BTT_MINI_12864_V1 requires wiring modifications. See 'pins_BTT_SKR_MINI_E3_common.h' for details. (Define NO_CONTROLLER_CUSTOM_WIRING_WARNING to suppress this warning.)"
| ^~~~~ buildroot/share/PlatformIO/scripts/../../../../Marlin/src/inc/../pins/stm32f1/pins_BTT_SKR_MINI_E3_common.h:315:2: error: #endif without #if 315 | #endif // HAS_WIRED_LCD | ^~~~~ Error: MOTHERBOARD is not defined in Configuration.h Marlin 2.1.1 Edited Files.zip

radek8 commented 1 year ago

The error says that you have used a display that requires a special connection cable. You have made the cable, now you need to accept this warning and comment out this line in the pin file:

image

radek8 commented 1 year ago

Attention! Your pin file appears to be corrupted.

define NO_CONTROLLER_CUSTOM_WIRING_WARNING

is the wrong definition.

It should be right

ifndef NO_CONTROLLER_CUSTOM_WIRING_WARNING

radek8 commented 1 year ago

Use this pin file pins_BTT_SKR_MINI_E3_common.zip

Also check the cable connection there was a wiring error in the original pin file.

image

Sporkforce commented 1 year ago

@radek8 I appreciate the help! With your file it compiled just fine and I was able to flash the firmware without issue. The screen still doesnt work unfortunately. I attached DSCF1252 a photo of the pinout I am using. The encoder LED Lights as does the LCD backlight, but the screen is completely blacked out by the LCD. I changed the contrast from 255 to 125, but the blacked-out LCD does not change.

@Legiotech I did get USB connectivity working with pronterface. I had to go into Device Manager, into "Ports (COM&LPT) and I found the STMicroelectronics Virtual COM Port that showed up when I connected the board. I went into "Properties" with a right click, and then to the "Port Settings" Tab at the top. I switched the Bits per Second from 9600 to 115200. It was detected in pronterface just fine after that. Verified connectivity by moving a stepper back and forth. I was not able to upload firmware to it via USB though.

Sporkforce commented 1 year ago

UPDATE: It is fully functional! I can't thank you guys enough. I had incorrectly put the RESET pin on Board Connector EXP1-4 to the Display's RESET pin EXP2-3 as seen in the previous post, It should go to LCD_RST EXP1-6. My final Pinout is as pictured. DSCF1253 I also had forgotten to enable support for the Neopixel LED Driver on PB8 in Marlin 2.1.1 Configuration.h: Line 3267 //#define NEOPIXEL_LED

if ENABLED(NEOPIXEL_LED)

define NEOPIXEL_TYPE NEO_GRBW

Was changed to:

define NEOPIXEL_LED

if ENABLED(NEOPIXEL_LED)

define NEOPIXEL_TYPE NEO_RGB

Everything seem to be good, I'll test for a while and see. So far I'm thrilled. Thanks again

Legiotech commented 1 year ago

UPDATE: I have connected my screen as @Sporkforce showed in last post and now im after week of testing and all is working fine. When i wired my screen correctly even USB communication started to work. Thank you both very much for help!

stilkata8888 commented 1 year ago

UPDATE: It is fully functional! I can't thank you guys enough. I had incorrectly put the RESET pin on Board Connector EXP1-4 to the Display's RESET pin EXP2-3 as seen in the previous post, It should go to LCD_RST EXP1-6. My final Pinout is as pictured. DSCF1253 I also had forgotten to enable support for the Neopixel LED Driver on PB8 in Marlin 2.1.1 Configuration.h: Line 3267 //#define NEOPIXEL_LED #if ENABLED(NEOPIXEL_LED) #define NEOPIXEL_TYPE NEO_GRBW Was changed to: #define NEOPIXEL_LED #if ENABLED(NEOPIXEL_LED) #define NEOPIXEL_TYPE NEO_RGB

Everything seem to be good, I'll test for a while and see. So far I'm thrilled. Thanks again

i wired up like this dude and again i dont have anything on display every setting i change like him and still dont have display.Can someone help me ??

radek8 commented 1 year ago

@stilkata8888 What version of the display and SKR do you have? What version of Marli do you have?

stilkata8888 commented 1 year ago

@radek8 e3 v2

stilkata8888 commented 1 year ago

and the version of the display is v1.0

radek8 commented 1 year ago

BTT MINI12864 V1.0?

stilkata8888 commented 1 year ago

yes !

radek8 commented 1 year ago

Send me your Marlin configuration files that you used to compile. configuration.h configuration_adv.h pins_BTT_SKR_MINI_E3_V2_0.h pins_BTT_SKR_MINI_E3_common.h

stilkata8888 commented 1 year ago

like zip files is it okay ?

radek8 commented 1 year ago

ok

stilkata8888 commented 1 year ago

files.zip there we go

radek8 commented 1 year ago

I have to go, I'll check it out later.

radek8 commented 1 year ago

The configuration looks fine. Check if you have cables connected to the management.

stilkata8888 commented 1 year ago

i check the cables 5-6 times and its connected correctly to the display i only get backlight and nothing on the screen ;(

radek8 commented 1 year ago

So you can still try to edit this file. And recompile.

V Marlin\src\lcd\dogm\marlinui_DOGM.cpp:

void MarlinUI::_set_contrast() { u8g.setContrast(contrast); }

Rewrite to

void MarlinUI::_set_contrast() { u8g.setContrast(255); }

stilkata8888 commented 1 year ago

i edit this file and show me error.The error is:#error "Please select only one LCD controller option." and i can't compile it.

radek8 commented 1 year ago

This modification should not cause this error. Haven't you made another adjustment yet?

stilkata8888 commented 1 year ago

can the versions of the marlin can cause these errors ?

radek8 commented 1 year ago

If you use all files of the same version, then no

stilkata8888 commented 1 year ago

okay im gonna make the change you speak about and im gonna update you what happend.

stilkata8888 commented 1 year ago

again the same nothing on display and no backlights 😞

radek8 commented 1 year ago

@stilkata8888 I found one more error in your configuration. You have to enable it in Configuration.h

define NEOPIXEL_LED

and

define NEOPIXEL_TYPE NEO_GRBW

Was changed to:

define NEOPIXEL_TYPE NEO_RGB

stilkata8888 commented 1 year ago

man its okay everything i fixed it the display is running up perfectly and everything is just fine.Later im gonna upload the things i edited in firmware.

P1ayer2 commented 1 year ago

Hello all! After trying to use the BTT V1.0 12864 display on the newest marlin version (2.1.2) I discovered that the (Marlin-2.1.x-V1/Marlin/src/pins/stm32f1/pins_BTT_SKR_MINI_E3_common.h) file is completely different compared to the file referenced in this thread. I have found that DOGLCD_CS should be what was previously known as LCD_PINS_RS and DOGLCD_MOSI what was LCD_PINS_ENABLE. These had the PA9 and PA3 values respectively, and has been commented as it is supposed to be. However, I can not find the equivalent of LCD_RESET_PIN PA10. In fact, I can not find a PA10 command at all in this version. Is it something I should ignore? Have I commented the correct things otherwise? I am pretty new to marlin and I am doing a completely custom build so any help is much appreciated. Thanks in advance! // Navil.

stilkata8888 commented 1 year ago

does your display is turning on ? Have you got something on the display ?

P1ayer2 commented 1 year ago

does your display is turning on ? Have you got something on the display ?

Hey! Thanks for your reply. I haven't received the display yet, I'm just doing the configuration of the board right now to use directly after receiving it. Do you want be to reply once I have it and can test? It is hopefully arriving this Monday.

EDIT: I now realize that my OG comment made it seem like I had it already. Sorry for being unclear.

stilkata8888 commented 1 year ago

which board are you using for your build ?

P1ayer2 commented 1 year ago

I am using the BTT SKR MINI E3 V2.0 for my rebuild with the BTT Mini 12864 V1.0 Display as mentioned before :D

stilkata8888 commented 1 year ago

okay im gonna make u shematic of wiring and im gonna tell you which things u need to change in the firmware to make the display work :)