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.
1.97k stars 1.97k forks source link

Will SKR mini E3 support Ender 3 V2? #424

Open HYC23 opened 3 years ago

HYC23 commented 3 years ago

I recently got an Ender 3 V2, but one of the stepper motor drivers on the motherboard is broken. I have an old ender 3 running SKR mini E3 board and works pretty well, so is the new SKR mini E3 V2 board support the new Ender 3 V2 printer, eg. the screen?

Jexkin commented 3 years ago

Hey, I thought I'll describe my "journey" so far. I'm trying to get a working firmware for about 1 week now and my current firmware (an edited Hemera firmware for the Ender 3 V2) lets me successfully do a bed level with my BLTouch but I can't get a print to work (neither via the sdcard or Octoprint). I always get the same error "Changing monitoring state from "Error: Printer halted. kill() called!" to "Offline (Error: Printer halted. kill() called!)"", checked it via Octoprint terminal. I already tried to start from scratch but that didn't work out. Then I saw that jernejp21 posted a link to their fork, I successfully compiled it but I got stuck in a boot loop. I already checked and compared all the configuration.h and configuration_adv.h files with each other and I didn't see any differences (I'm fairly new to 3d printing so I for sure might be missing something). The edited Hemera firmware seems to work the best so far but I honestly don't know why I get that error. As for the display: everything seems to work, I was able to get the connections correct. So I'd assume there is no problem with the display. I for sure would appreciate any kind of help!

So, I finally got the firmware to work. Thought I will give y'all an update (maybe someone finds it useful). In the _configurationadv.h file I had to disable #define POWER_LOSS_RECOVERY and once I did that I was able to start a print without my printer to fail. Very glad this thread exists!

Tommi649 commented 3 years ago

Hi so i bought this board and found out later I should have read more about compatibility. So my question is it will be easier to buy some other board with the btt touch screen or buy the screen for this? Some other board would be nice though because I could get the dual z.

rubesworkshop commented 3 years ago

I finally got around to building an adapter for my display and plugged it in without making any of the firmware updates. Without the adapter the display will remain blank, but glow and beep continuously. With the adapter, the display stays completely black as if it's not getting any power at all. I used the diagram that @Damquis posted above, double checked the pinouts and verified continuity, so I think the adapter is good. I tried to update the display firmware with and without the adapter in place and neither appeared to make any difference. Maybe the board firmware needs to be updated first?

I'm also working on compiling the firmware for the new board. Of course, the compile is generating errors using the current bugfix-2.0.x branch -

Marlin/src/HAL/STM32F1/../../inc/../HAL/./STM32F1/../../core/serial_hook.h:215:56: error: request for member 'write' in '((MultiSerial<ForwardSerial, int, 0>*)this)->MultiSerial<ForwardSerial, int, 0>::serial1', which is of non-class type 'int'

I downloaded the @jernejp21 fork without any changes and it compiled without no problem. That just confirms that I missed something along the way, I don't know what though.

Any suggestions would be greatly appreciated. Andy

kubiakoo commented 3 years ago

Unfortunately, I was unable to compile my own Marlin modification. So I downloaded the @jernejp21 branch 2.0.x firmware. The firmware is compiling, but after uploading to the Ender-3 V2 with the SKR mini E3 V2 motherboard, the screen still does not work. Additionally, I cannot connect via Octoprint and USB. I can connect to my firmware without any problems and print from Octoprint (without a working screen, of course). Cable made according to the @Damquis scheme, I checked the correctness of connections several times.

wiring

My firmware is a minimally modified last official Bugfix2.0.x with an example Ender-3 pro / BigTreeTech SKR Mini E3 2.0 configuration. I used all @jernejp21 guidelines from the first post, only when I enable #define DWIN_CREALITY_LCD it won't compile. The problem message is shown below.

request for member 'write' in '((MultiSerial<ForwardSerial<USBSerial>, int, 0>*)this)->MultiSerial<ForwardSerial<USBSerial>, int, 0>::serial1', which is of non-class type 'int'

request for member 'flush' in '((MultiSerial<ForwardSerial<USBSerial>, int, 0>*)this)->MultiSerial<ForwardSerial<USBSerial>, int, 0>::serial1', which is of non-class type 'int'

My firmware is available at: https://github.com/kubiakoo/Marlin-bugfix-2.0.7--Ender-3-V2-SKR-3-Mini-v2.0 This is a version that compiles, without enabled line #define DWIN_CREALITY_LCD

Where to look for the cause of the problem? Why does the @jernejp21 firmware not work on my Ender3v2?

rubesworkshop commented 3 years ago

I've given up on the display for now and am trying to get it working well enough to use OctoPrint. OctoPrint will connect to the SKR mini e3 v2 using the stock SKR firmware, but when I upload my latest compile using the STM32F103RC_btt_512K_USB environment, OctoPrint will not connect. What part of the code would affect wether OctoPrint connects or not?

davthomaspilot commented 3 years ago

Can you connect to the octoprint servre using ssh? On Monday, April 5, 2021, 03:12:46 PM EDT, maddawgmax @.***> wrote:

I've given up on the display for now and am trying to get it working well enough to use OctoPrint. OctoPrint will connect to the SKR mini e3 v2 using the stock SKR firmware, but when I upload my latest compile using the STM32F103RC_btt_512K_USB environment, OctoPrint will not connect. What part of the code would affect wether OctoPrint connects or not?

— You are receiving this because you commented. Reply to this email directly, view it on GitHub, or unsubscribe.

rubesworkshop commented 3 years ago

@davthomaspilot,

Can you connect to the octoprint servre using ssh? On Monday, April 5, 2021, 03:12:46 PM EDT, maddawgmax @.***> wrote: I've given up on the display for now and am trying to get it working well enough to use OctoPrint. OctoPrint will connect to the SKR mini e3 v2 using the stock SKR firmware, but when I upload my latest compile using the STM32F103RC_btt_512K_USB environment, OctoPrint will not connect. What part of the code would affect wether OctoPrint connects or not? — You are receiving this because you commented. Reply to this email directly, view it on GitHub, or unsubscribe.

I can connect to the OctoPrint server without an issue, but I cannot connect the OctoPrint server to the SKR Mini. If I revert back to the default firmware that came on the board OctoPrint can connect.

jernejp21 commented 3 years ago

@kubiakoo You are using bugfix marlin? Don't use bugfix. Use 2.0.x branch. Bugfix branch has a lot of modifications including serial communication, which is not compatible with 2.0.7.2 version of Marlin.

kubiakoo commented 3 years ago

@jernejp21 Ok, when i create my own firmwer next time i will make it based on pure 2.0.7 Marlin. The question is why the firmware downloaded from your GitHub, without any modifications, cannot connect to octoprint? And why on your firmware the screen only shows a black image if the cable is properly made? Where to look for the cause?

CZDanol commented 3 years ago

Guys I got it to work on the latest Marlin 2 bugfix firmware (the Extensible UI branch for the E3V2 display).

The trick is to comment out the SERIAL_PORT_2 in the Config.j and change LCD_SERIAL_PORT in Conditionals_LCD.h from 3 to 1

The config I'm using with BLTouch here: https://github.com/CZDanol/Marlin/tree/E3V2-EXTUI-BLT-SKRMini3V2

davthomaspilot commented 3 years ago

CZDanol

Did you try connecting to Octoprint?

CZDanol commented 3 years ago

CZDanol

Did you try connecting to Octoprint?

Nope, I don't care about that.

davthomaspilot commented 3 years ago

Ok, I guess it still might not work for that.

jernejp21

Could the bugfix changes made for serial communication impact Octoprint's ability to connect to the SKR Mini? I know the connection to the RPI is over USB, but maybe there is a serial to USB driver in the stack?

jottr commented 3 years ago

@CZDanol @davthomaspilot would you mind keeping it strictly on-topic here? Github issues are not a chat. Lots of people are following this topic. Please keep this in mind.

If you want to exchange general experience, please don't pollute the ticket for everyone else. I can recommend the off-topic section on the Marlin discord if you want to continue your conversation. Thanks!

rubesworkshop commented 3 years ago

Guys I got it to work on the latest Marlin 2 bugfix firmware (the Extensible UI branch for the E3V2 display).

The trick is to comment out the SERIAL_PORT_2 in the Config.j and change LCD_SERIAL_PORT in Conditionals_LCD.h from 3 to 1

The config I'm using with BLTouch here: https://github.com/CZDanol/Marlin/tree/E3V2-EXTUI-BLT-SKRMini3V2

@CZDanol ,

I'm trying to use your config to get my printer back up and running. I struggled with reconfiguring the DWIN display for much too long so finally gave up and ordered the TFT35. That I think is the only difference in hardware between your setup and mine.

What I've done so far is comment out these lines in configuration.h -

and defined this one -

Changed the serial ports to the recommendations from BTT found here -

Then I replaced these files with the originals from Marlin's 2.0.7.2 bugfix -

With that, it will successfully compile, but with warnings - Compiling .pio/build/STM32F103RC_btt_512K/src/src/lcd/dogm/u8g_dev_st7920_128x64_HAL.cpp.o Compiling .pio/build/STM32F103RC_btt_512K/src/src/lcd/dogm/u8g_dev_tft_upscale_from_128x64.cpp.o Marlin/src/lcd/dogm/status_screen_DOGM.cpp: In static member function 'static void MarlinUI::draw_status_screen()': Marlin/src/lcd/dogm/status_screen_DOGM.cpp:415:6: warning: '%02hu' directive writing between 2 and 5 bytes into a region of size between 0 and 4 [-Wformat-overflow=] void MarlinUI::draw_status_screen() { ^~~~ Marlin/src/lcd/dogm/status_screen_DOGM.cpp:415:6: note: using the range [0, 65535] for directive argument In file included from /Users/Andy/.platformio/packages/framework-arduinoststm32-maple/STM32F1/cores/maple/WString.h:29:0, from /Users/Andy/.platformio/packages/framework-arduinoststm32-maple/STM32F1/cores/maple/wirish.h:47, from /Users/Andy/.platformio/packages/framework-arduinoststm32-maple/STM32F1/cores/maple/Arduino.h:30, from Marlin/src/lcd/dogm/../../inc/../HAL/./STM32F1/../shared/Marduino.h:36, from Marlin/src/lcd/dogm/../../inc/../HAL/./STM32F1/HAL.h:32, from Marlin/src/lcd/dogm/../../inc/../HAL/HAL.h:30, from Marlin/src/lcd/dogm/../../inc/MarlinConfig.h:31, from Marlin/src/lcd/dogm/dogm_Statusscreen.h:31, from Marlin/src/lcd/dogm/status_screen_DOGM.cpp:32: /Users/Andy/.platformio/packages/framework-arduinoststm32-maple/STM32F1/cores/maple/avr/pgmspace.h:29:37: note: 'sprintf' output between 9 and 16 bytes into a destination of size 10

define sprintf_P(s, f, ...) sprintf((s), (f), __VA_ARGS__)

                          ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~

Marlin/src/lcd/dogm/../../module/../libs/duration_t.h:159:7: note: in expansion of macro 'sprintf_P' sprintf_P(buffer, PSTR("%hud %02hu:%02hu"), d, h % 24, m); ^~~~~ Compiling .pio/build/STM32F103RC_btt_512K/src/src/lcd/dogm/u8g_dev_uc1701_mini12864_HAL.cpp.o Compiling .pio/build/STM32F103RC_btt_512K/src/src/lcd/dogm/u8g_fontutf8.cpp.o

I was hoping the last bit to finish up would be reversing these changes that you mentioned -

The trick is to comment out the SERIAL_PORT_2 in the Config.j and change LCD_SERIAL_PORT in Conditionals_LCD.h from 3 to 1 but could not find the "config.j" or "Conditionals_LCD.h" files.

I'm hoping that you have time to offer a few hints that will help me finish this up.

Thanks, Andy

CZDanol commented 3 years ago

Guys I got it to work on the latest Marlin 2 bugfix firmware (the Extensible UI branch for the E3V2 display). The trick is to comment out the SERIAL_PORT_2 in the Config.j and change LCD_SERIAL_PORT in Conditionals_LCD.h from 3 to 1 The config I'm using with BLTouch here: https://github.com/CZDanol/Marlin/tree/E3V2-EXTUI-BLT-SKRMini3V2

@CZDanol ,

I'm trying to use your config to get my printer back up and running. I struggled with reconfiguring the DWIN display for much too long so finally gave up and ordered the TFT35. That I think is the only difference in hardware between your setup and mine.

What I've done so far is comment out these lines in configuration.h -

* //#define DWIN_CREALITY_TOUCHLCD

* //#define CREALITY_DWIN_EXTUI

* //#define DWIN_CREALITY_LCD

and defined this one -

* #define CR10_STOCKDISPLAY

Changed the serial ports to the recommendations from BTT found here -

* #define SERIAL_PORT 2

* #define SERIAL_PORT_2 -1

Then I replaced these files with the originals from Marlin's 2.0.7.2 bugfix -

* "buttons.h" in the LCD folder

* "pins_BTT_SKR_MINI_E3_common.h" in the pins/stm32f1 folder

With that, it will successfully compile, but with warnings - Compiling .pio/build/STM32F103RC_btt_512K/src/src/lcd/dogm/u8g_dev_st7920_128x64_HAL.cpp.o Compiling .pio/build/STM32F103RC_btt_512K/src/src/lcd/dogm/u8g_dev_tft_upscale_from_128x64.cpp.o Marlin/src/lcd/dogm/status_screen_DOGM.cpp: In static member function 'static void MarlinUI::draw_status_screen()': Marlin/src/lcd/dogm/status_screen_DOGM.cpp:415:6: warning: '%02hu' directive writing between 2 and 5 bytes into a region of size between 0 and 4 [-Wformat-overflow=] void MarlinUI::draw_status_screen() { ^~~~ Marlin/src/lcd/dogm/status_screen_DOGM.cpp:415:6: note: using the range [0, 65535] for directive argument In file included from /Users/Andy/.platformio/packages/framework-arduinoststm32-maple/STM32F1/cores/maple/WString.h:29:0, from /Users/Andy/.platformio/packages/framework-arduinoststm32-maple/STM32F1/cores/maple/wirish.h:47, from /Users/Andy/.platformio/packages/framework-arduinoststm32-maple/STM32F1/cores/maple/Arduino.h:30, from Marlin/src/lcd/dogm/../../inc/../HAL/./STM32F1/../shared/Marduino.h:36, from Marlin/src/lcd/dogm/../../inc/../HAL/./STM32F1/HAL.h:32, from Marlin/src/lcd/dogm/../../inc/../HAL/HAL.h:30, from Marlin/src/lcd/dogm/../../inc/MarlinConfig.h:31, from Marlin/src/lcd/dogm/dogm_Statusscreen.h:31, from Marlin/src/lcd/dogm/status_screen_DOGM.cpp:32: /Users/Andy/.platformio/packages/framework-arduinoststm32-maple/STM32F1/cores/maple/avr/pgmspace.h:29:37: note: 'sprintf' output between 9 and 16 bytes into a destination of size 10

define sprintf_P(s, f, ...) sprintf((s), (f), VA_ARGS)


Marlin/src/lcd/dogm/../../module/../libs/duration_t.h:159:7: note: in expansion of macro 'sprintf_P'
sprintf_P(buffer, PSTR("%hud %02hu:%02hu"), d, h % 24, m);
^~~~~~~~~
Compiling .pio/build/STM32F103RC_btt_512K/src/src/lcd/dogm/u8g_dev_uc1701_mini12864_HAL.cpp.o
Compiling .pio/build/STM32F103RC_btt_512K/src/src/lcd/dogm/u8g_fontutf8.cpp.o

I was hoping the last bit to finish up would be reversing these changes that you mentioned -

> The trick is to comment out the `SERIAL_PORT_2` in the `Config.j` and change `LCD_SERIAL_PORT` in `Conditionals_LCD.h` from `3` to `1`
> but could not find the "config.j" or "Conditionals_LCD.h" files.

I'm hoping that you have time to offer a few hints that will help me finish this up.

Thanks,
Andy

If you forked by github repo, it is based from a fork of Marlin with changes done specifically for the DWIN display. So just take the Config and Config.adv files and patch them over the official Marlin 2 bugfix repository.

rubesworkshop commented 3 years ago

If you forked by github repo, it is based from a fork of Marlin with changes done specifically for the DWIN display. So just take the Config and Config.adv files and patch them over the official Marlin 2 bugfix repository.

@CZDanol, Yeah, that makes sense. I went about it bassakwards didn't I? I'll give it a try when I get home tonight.

Thanks for the reply! Andy

jurson8204 commented 3 years ago

// Emergency Parser needs at least one serial with HardwareSerial or USBComposite. // The USBSerial maple don't allow any hook to implement EMERGENCY_PARSER. // And copy all USBSerial code to marlin space to support EMERGENCY_PARSER, when we have another options, don't worth it.

if ENABLED(EMERGENCY_PARSER) && !defined(USE_USB_COMPOSITE) && ((SERIAL_PORT == -1 && !defined(SERIAL_PORT_2)) || (SERIAL_PORT_2 == -1 && !defined(SERIAL_PORT)))

error "EMERGENCY_PARSER is only supported by HardwareSerial or USBComposite in HAL/STM32F1."

endif

How do I can fix this?

CZDanol commented 3 years ago

Dusable emargancy patzer

jurson8204 commented 3 years ago

SO I have another problem. I gave up and ordered tft35 btt and I am trying to compile Marlin... " "message": "#error \"Please select only one LCD controller option.\" in sanity check. I've did what you have written @CZDanol "* //#define DWIN_CREALITY_TOUCHLCD

CZDanol commented 3 years ago

@jurson8204 that branch is made specifically for the E3V2 display. For other displays, use main Marlin distro.

rubesworkshop commented 3 years ago

@ jurson8204

I ran into the same problem when compiling mine. Make sure that all of these are disabled and only the one for CR10 is enabled.

define CR10_STOCKDISPLAY

//#define DWIN_CREALITY_TOUCHLCD //#define CREALITY_DWIN_EXTUI //#define DWIN_CREALITY_LCD //#define EXTENSIBLE_UI

Andy

From: jurson8204 @.> Sent: Tuesday, May 4, 2021 1:26 PM To: bigtreetech/BIGTREETECH-SKR-mini-E3 @.> Cc: Maxey, Andy @.>; Mention @.> Subject: Re: [bigtreetech/BIGTREETECH-SKR-mini-E3] Will SKR mini E3 support Ender 3 V2? (#424)

CAUTION: This email originated from outside of the organization. Do not click links or open attachments unless you recognize the sender and know the content is safe

SO I have another problem. I gave up and ordered tft35 btt and I am trying to compile Marlin... " "message": "#error "Please select only one LCD controller option." in sanity check. I've did what you have written @CZDanolhttps://nam04.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2FCZDanol&data=04%7C01%7Candy.maxey%40okstate.edu%7C92f5ce62e4da40e085aa08d90f2a19a3%7C2a69c91de8494e34a230cdf8b27e1964%7C0%7C0%7C637557495766829150%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=PS5YBj2dWneiNNYc4yQUMcRmVZsG6tyhgfuCRMgkSz4%3D&reserved=0 "* //#define DWIN_CREALITY_TOUCHLCD

- You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://nam04.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fbigtreetech%2FBIGTREETECH-SKR-mini-E3%2Fissues%2F424%23issuecomment-832150556&data=04%7C01%7Candy.maxey%40okstate.edu%7C92f5ce62e4da40e085aa08d90f2a19a3%7C2a69c91de8494e34a230cdf8b27e1964%7C0%7C0%7C637557495766839105%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=BFzrpkmO0O6%2FIf0kPLpH%2FRSBGlo6E0fCFXA1k%2BmC2AQ%3D&reserved=0, or unsubscribehttps://nam04.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FANA3ECG6U4S2PUYKFTJTSKLTMA34LANCNFSM4SLUCEGQ&data=04%7C01%7Candy.maxey%40okstate.edu%7C92f5ce62e4da40e085aa08d90f2a19a3%7C2a69c91de8494e34a230cdf8b27e1964%7C0%7C0%7C637557495766844082%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=DbPdVsqpYfCY1ZIiFZ3ytuBjEkt65IiwdXnjRRzVeEc%3D&reserved=0.

bholzer commented 3 years ago

Guys I got it to work on the latest Marlin 2 bugfix firmware (the Extensible UI branch for the E3V2 display).

The trick is to comment out the SERIAL_PORT_2 in the Config.j and change LCD_SERIAL_PORT in Conditionals_LCD.h from 3 to 1

The config I'm using with BLTouch here: https://github.com/CZDanol/Marlin/tree/E3V2-EXTUI-BLT-SKRMini3V2

I am back at this because while I was able to get my printer running, I can not get the nozzle close enough to the bed to print properly. I can autohome and then move my z axis to 0 and it's right where I want it, but then it refuses to get that close during a print. May be unrelated to firmware, but I decided to try this anyway. However, I can't get this fork to work @CZDanol. When I build, I receive an error:

Marlin\src\lcd\extui\lib\creality_dwin\creality_dwin.cpp: In member function 'void CrealityDWINClass::Menu_Item_Handler(uint8_t, uint8_t, bool)':
Marlin\src\lcd\extui\lib\creality_dwin\creality_dwin.cpp:2009:50: error: 'bed_info_t {aka struct HeaterInfo}' has no member named 'pid'
               Draw_Float(thermalManager.temp_bed.pid.Kp, row, false, 100);
                                                  ^~~
Marlin\src\lcd\extui\lib\creality_dwin\creality_dwin.cpp:2012:52: error: 'bed_info_t {aka struct HeaterInfo}' has no member named 'pid'
               Modify_Value(thermalManager.temp_bed.pid.Kp, 0, 5000, 100, thermalManager.updatePID);
                                                    ^~~
In file included from Marlin\src\lcd\extui\lib\creality_dwin\creality_dwin.cpp:38:0:
Marlin\src\lcd\extui\lib\creality_dwin\creality_dwin.cpp:2018:63: error: 'bed_info_t {aka struct HeaterInfo}' has no member named 'pid'
               Draw_Float(unscalePID_i(thermalManager.temp_bed.pid.Ki), row, false, 100);
                                                               ^
Marlin\src\HAL\STM32F1/../../module/temperature.h:169:35: note: in definition of macro 'unscalePID_i'
   #define unscalePID_i(i) ( float(i) / PID_dT )
                                   ^
Marlin\src\lcd\extui\lib\creality_dwin\creality_dwin.cpp:2021:52: error: 'bed_info_t {aka struct HeaterInfo}' has no member named 'pid'
               Modify_Value(thermalManager.temp_bed.pid.Ki, 0, 5000, 100, thermalManager.updatePID);
                                                    ^~~
In file included from Marlin\src\lcd\extui\lib\creality_dwin\creality_dwin.cpp:38:0:
Marlin\src\lcd\extui\lib\creality_dwin\creality_dwin.cpp:2027:63: error: 'bed_info_t {aka struct HeaterInfo}' has no member named 'pid'
               Draw_Float(unscalePID_d(thermalManager.temp_bed.pid.Kd), row, false, 100);
                                                               ^
Marlin\src\HAL\STM32F1/../../module/temperature.h:171:35: note: in definition of macro 'unscalePID_d'
   #define unscalePID_d(d) ( float(d) * PID_dT )
TheYarkin commented 3 years ago

@bholzer I got the same error when trying to compile it too, so I went back to the previous version (https://github.com/CZDanol/Marlin/tree/941dc65e8e891d968454b4b2696ea958b492de09) and it's working great with the rerouted display cable. Thanks @CZDanol!

CZDanol commented 3 years ago

Sorry, haven't noticed it. Fixed the problem and updated to the newest EXTUI commit while I was at it.

ellensp commented 3 years ago

use current marlin 2.0.8.1 and these configs. Configuration.zip Configs are standard Ender 3 V2 configs modified for this motherboard. No need to edit your boards pins.h file. Is all in Configuration.h

rubesworkshop commented 3 years ago

No need to edit your boards pins.h file. Is all in Configuration.h @ellensp

Do I assume correctly that the ribbon cable would still need to be modified?

4slash1977 commented 3 years ago

Hi, Can any one tell me how pins are defined, I have SKR E3 DIP 1.1 and would like to use it with Creality Dwin display in my Endre 3 V2. Pinout on the bord is:

              _____ 
        5V | 1  2 | GND
      PB7 | 3  4 | PB8
      PB9 | 5  6   PA10
      RST | 7  8 | PA9
      PB6 | 9 10| PA15
            -----
            EXP1

How should I define - BTN_ENC, BTN_EN1, BTN_EN2 and BEEPER_PIN? Also how to prepare ribbon cable?

CZDanol commented 3 years ago

How should I define - BTN_ENC, BTN_EN1, BTN_EN2 and BEEPER_PIN? Also how to prepare ribbon cable?

See https://github.com/CZDanol/Marlin/tree/E3V2-EXTUI-BLT-SKRMini3V2 . In the readme there's a link to pinout config and what is the easiest way to change the pinout.

4slash1977 commented 3 years ago

I seen this but as my pinout on board is little different - how can I be sure that TX and RX on board are on the same place as in SKR mini v2?

CZDanol commented 3 years ago

Oh sorry I haven't realized you were talking about a different board. You can find the pinout config for your board here, so you can cross check it: https://github.com/CZDanol/Marlin/blob/E3V2-EXTUI-BLT-SKRMini3V2/Marlin/src/pins/stm32f1/pins_BTT_SKR_E3_DIP.h

4slash1977 commented 3 years ago

Still don't see with are TX and RX pins for my board :-(

jurson8204 commented 3 years ago

So I finally installed skr mini e3 v2 with tft 35 display... everything works fine, except two or three things. First screen shows BLT failed bed leveling just when I run the printer, probe goes out and then it's hiding, when levelin it is not going out. 2nd and 3rd thing is that when I try to autohome it works fine, but when I move bed manually direction is reversed. When I reverse Y_dir in marlin, manually it is working, but then homing is going opposite direction. I am trying to fight with bl, but with this autohome and Y direction I have no idea what to change

Damquis commented 3 years ago

Unfortunately, I was unable to compile my own Marlin modification. So I downloaded the @jernejp21 branch 2.0.x firmware. The firmware is compiling, but after uploading to the Ender-3 V2 with the SKR mini E3 V2 motherboard, the screen still does not work. Additionally, I cannot connect via Octoprint and USB. I can connect to my firmware without any problems and print from Octoprint (without a working screen, of course). Cable made according to the @Damquis scheme, I checked the correctness of connections several times.

wiring

My firmware is a minimally modified last official Bugfix2.0.x with an example Ender-3 pro / BigTreeTech SKR Mini E3 2.0 configuration. I used all @jernejp21 guidelines from the first post, only when I enable #define DWIN_CREALITY_LCD it won't compile. The problem message is shown below.

request for member 'write' in '((MultiSerial<ForwardSerial<USBSerial>, int, 0>*)this)->MultiSerial<ForwardSerial<USBSerial>, int, 0>::serial1', which is of non-class type 'int'

request for member 'flush' in '((MultiSerial<ForwardSerial<USBSerial>, int, 0>*)this)->MultiSerial<ForwardSerial<USBSerial>, int, 0>::serial1', which is of non-class type 'int'

My firmware is available at: https://github.com/kubiakoo/Marlin-bugfix-2.0.7--Ender-3-V2-SKR-3-Mini-v2.0 This is a version that compiles, without enabled line #define DWIN_CREALITY_LCD

Where to look for the cause of the problem? Why does the @jernejp21 firmware not work on my Ender3v2?

I had the same problem and I managed to solve it. Replace #define SERIAL_PORT_2 1 with #define LCD_SERIAL_PORT 1 in Configuration.h

I successfully compiled the latest Jyers firmware. (https://github.com/Jyers/Marlin)

blazewicz commented 3 years ago

TLDR: This board DOES support Ender 3 V2 with its stock display, I've opened a request to add it to mainstream Marlin here:

blazewicz commented 3 years ago

Ender 3 V2 display support on BTT SKR Mini E3 boards is now available in mainstream Marlin. No more need to reconfigure pins and serial ports.

Stalkeros000 commented 2 years ago

Sorry, BTT SKR E3 RRF (with esp8266 module) will work with our display?

mrbrdo commented 2 years ago

Guys I am confused, is the hardware rewire still needed or not for the E3v2 display? If yes, could someone just show a photo or something on which wires need to be swapped? The ascii pinout in the comment is not clear enough. Need to know which wires to switch on the ribbon cable itself, relative to the red line on the cable.

rubesworkshop commented 2 years ago

@mrbrdo

Guys I am confused, is the hardware rewire still needed or not for the E3v2 display? If yes, could someone just show a photo or something on which wires need to be swapped? The ascii pinout in the comment is not clear enough. Need to know which wires to switch on the ribbon cable itself, relative to the red line on the cable.

See if the wiring diagram on this page helps - https://github.com/MarlinFirmware/Configurations/issues/535

Andy

manpres2 commented 2 years ago

Hi,

Please excuse me if its already taken care of but i am trying to enable the stock LCD with ender3V2 on SKR e3 mini v2 board and getting error message "error: #error "EMERGENCY_PARSER is only supported by HardwareSerial or USBComposite in HAL/STM32F1"

I am compiling the firmware for the first time so please point me to a thread which describe exactly what needs to be done as i might not be able to follow instructions which has some obvious steps for an intermediate level but for me those will be tough.

Thank you

davthomaspilot commented 2 years ago

Edited on Mar 28 2021

This is tested on Marlin version 2.0.7. New Marlin version has changed SERIAL_PORT definition and a lot of other stuff. You can use my fork for speeding the process. This version works without a bootloader! If you you are using a bootloader, uncomment lines 752 and 753 in platformio.ini https://github.com/jernejp21/Marlin

Use Marlin's Ender 3 V2 Configuration.h and Configuration_adv.h files.

You need to import this code into pins_BTT_SKR_MINI_E3_common.h file. I pasted this part of code below USB connect control. This code can be found in pins_CREALITY_V4.h.

/**
 *        Ender 3 V2 display                         SKR Mini E3 V2.0
 *                _____                                     _____
 *            5V | 1 2 | GND                            5V | 1 2 | GND
 *   (BTN_E1) A  | 3 4 | B (BTN_E2)         (BTN_EN1) PB15 | 3 4 | PB8 (BTN_E2)
 *          BEEP | 5 6   ENT (BTN_ENC)                PB9  | 5 6   RX1
 *  (SKR_RX1) TX | 7 8 | RX (SKR_TX1)                RESET | 7 8 | TX1
 *            NC | 9 10| NC                  (BEEPER) PA15 | 9 10| PB5  (BTN_ENC)
 *                -----                                     -----
 *                EXP1                                      EXP1
 */
#if ENABLED(DWIN_CREALITY_LCD)

  // RET6 DWIN ENCODER LCD
  #define BTN_ENC                           PB5
  #define BTN_EN1                           PB15
  #define BTN_EN2                           PB8

  #ifndef BEEPER_PIN
    #define BEEPER_PIN                      PA15
    #undef SPEAKER
  #endif
#endif

Commented picture shows pinout for display and SKR board.

CAUTION!!! You have to create new ribbon cable. Connect SKR RX to display TX pin and SKR TX to display RX pin! This is the most important part (and setting the correct serial port in Marlin).

You can connect other pins as you like, just make sure you define correct pins in Marlin (you can connect display A to SKR's PB9 etc.).

Pinout for Ender 3 V2 display is printed on display's PCB. If you remove the back cover, you will see the connector marked.

After you have copied this code, adjusted pins on display and adjusted pins in Marlin for button and beeper, change also Configuration.h file.

  • set #define SERIAL_PORT -1, #define SERIAL_PORT_2 1.
  • set #define MOTHERBOARD BOARD_BTT_SKR_MINI_E3_V2_0
  • set #define X_DRIVER_TYPE TMC2209. Do this also fro X, Y and E0.
  • set #define INVERT_X_DIR true
  • set #define INVERT_Y_DIR true
  • set #define INVERT_Z_DIR false -set #define INVERT_E0_DIR true
  • set #define DWIN_CREALITY_LCD and comment out current display you are using.

Configuration_adv.h file.

  • set #define SDCARD_CONNECTION ONBOARD
  • under #if HAS_TRINAMIC_CONFIG, change motor current. I found out that 580 mA for X, Y and Z is ok. And 700 for E. You can play with this settings.
  • a little bit lower, change slave addresses for serial TX, RX.

    • define X_SLAVE_ADDRESS 0

    • define Y_SLAVE_ADDRESS 2

    • define Z_SLAVE_ADDRESS 1

    • define E0_SLAVE_ADDRESS 3

  • set #define CHOPPER_TIMING CHOPPER_DEFAULT_24V if you are using 24V power supply

Make sure you also change platformio.ini . Change default_envs = STM32F103RC_btt_512K. You are now using SKR board, not Ender.

From here on you can change Marlin to use BL Touch, sensorless homing etc.

The code jernejp21 references here:

https://github.com/jernejp21/Marlin

has BEEPER_PIN on PB9. But the ascii picture in his github post for this issue shows it on PA15.

The pretty wiring diagrams show BEEPER_PIN on PA15.

Do the wiring diagrams in this issue need to be updated to be consistent with https://github.com/jernejp21/Marlin, or is there a another branch that should be used that IS consistent with wiring diagram in this issue?

Will0201 commented 2 years ago

Edited on Mar 28 2021

This is tested on Marlin version 2.0.7. New Marlin version has changed SERIAL_PORT definition and a lot of other stuff. You can use my fork for speeding the process. This version works without a bootloader! If you you are using a bootloader, uncomment lines 752 and 753 in platformio.ini https://github.com/jernejp21/Marlin

Use Marlin's Ender 3 V2 Configuration.h and Configuration_adv.h files.

You need to import this code into pins_BTT_SKR_MINI_E3_common.h file. I pasted this part of code below USB connect control. This code can be found in pins_CREALITY_V4.h.

/**
 *        Ender 3 V2 display                         SKR Mini E3 V2.0
 *                _____                                     _____
 *            5V | 1 2 | GND                            5V | 1 2 | GND
 *   (BTN_E1) A  | 3 4 | B (BTN_E2)         (BTN_EN1) PB15 | 3 4 | PB8 (BTN_E2)
 *          BEEP | 5 6   ENT (BTN_ENC)                PB9  | 5 6   RX1
 *  (SKR_RX1) TX | 7 8 | RX (SKR_TX1)                RESET | 7 8 | TX1
 *            NC | 9 10| NC                  (BEEPER) PA15 | 9 10| PB5  (BTN_ENC)
 *                -----                                     -----
 *                EXP1                                      EXP1
 */
#if ENABLED(DWIN_CREALITY_LCD)

  // RET6 DWIN ENCODER LCD
  #define BTN_ENC                           PB5
  #define BTN_EN1                           PB15
  #define BTN_EN2                           PB8

  #ifndef BEEPER_PIN
    #define BEEPER_PIN                      PA15
    #undef SPEAKER
  #endif
#endif

Commented picture shows pinout for display and SKR board.

CAUTION!!! You have to create new ribbon cable. Connect SKR RX to display TX pin and SKR TX to display RX pin! This is the most important part (and setting the correct serial port in Marlin).

You can connect other pins as you like, just make sure you define correct pins in Marlin (you can connect display A to SKR's PB9 etc.).

Pinout for Ender 3 V2 display is printed on display's PCB. If you remove the back cover, you will see the connector marked.

After you have copied this code, adjusted pins on display and adjusted pins in Marlin for button and beeper, change also Configuration.h file.

  • set #define SERIAL_PORT -1, #define SERIAL_PORT_2 1.
  • set #define MOTHERBOARD BOARD_BTT_SKR_MINI_E3_V2_0
  • set #define X_DRIVER_TYPE TMC2209. Do this also fro X, Y and E0.
  • set #define INVERT_X_DIR true
  • set #define INVERT_Y_DIR true
  • set #define INVERT_Z_DIR false -set #define INVERT_E0_DIR true
  • set #define DWIN_CREALITY_LCD and comment out current display you are using.

Configuration_adv.h file.

  • set #define SDCARD_CONNECTION ONBOARD
  • under #if HAS_TRINAMIC_CONFIG, change motor current. I found out that 580 mA for X, Y and Z is ok. And 700 for E. You can play with this settings.
  • a little bit lower, change slave addresses for serial TX, RX.

    • define X_SLAVE_ADDRESS 0

    • define Y_SLAVE_ADDRESS 2

    • define Z_SLAVE_ADDRESS 1

    • define E0_SLAVE_ADDRESS 3

  • set #define CHOPPER_TIMING CHOPPER_DEFAULT_24V if you are using 24V power supply

Make sure you also change platformio.ini . Change default_envs = STM32F103RC_btt_512K. You are now using SKR board, not Ender.

From here on you can change Marlin to use BL Touch, sensorless homing etc.

I am extremely new to all of this, and I was wondering if anyone could answer a few questions. They are probably very basic, but like I said, I'm new to it all. 1) Where are these files and how do I get to them? 2) Once found, do I edit them using software such as Visual Studios? 3) Not really a question, but in general, a lot of this is confusing, but I'm sure super helpful, so if anyone wouldn't mind kind of explaining it to me like I'm 10, it would be greatly appreciated.

Thanks in advance.

jernejp21 commented 2 years ago

@davthomaspilot Pinout in discription if different because I made different cable and forgot to make changes to description. I have fixed this. Thank you.

@Will0201

  1. Search for file name in repository. Clone repository and use search function on your desktop.
  2. You can use any text editor, but it is recommended to use VS Code and PlatformIO to compile the code.
  3. You need to learn C programming language. You also need to learn how microcontrollers work. This post isn't meant as tutorial on how to compile and download new code to your printer.
davthomaspilot commented 2 years ago

@jernejp21

Step by step guides like this:

https://www.smith3d.com/skr-mini-e3-v2-v3-on-ender-3-v2-ender-3-s1-lcd-dwin-knob-screen/?replytocom=14630#respond

and wiring diagrams in this issue assume a configuration.h like your original post-- BEEP on pin 9 of SKR Mini EXP1 connector. So, I think cables already built won't work with the code you changed for a new cable.

I think later posts in this thread say your changes are now in the main line Marlin?

What version of the cable should be expected for compatibility with the latest Marlin release and future releases? Will cables built using the diagrams in this issue (and copied many places) have to be redone for compatibility with newer Marlin software?

Sorry if this sounds negative--it's not intended to be. You did a great job in getting this working and documenting. I'm just trying to save headaches for others that stumble on this thread or use other web resources and later Marlin releases.

Thanks!

Which version of the cable should be built if we want hardware to be compatible with the latest (and future) releases?

jernejp21 commented 2 years ago

@davthomaspilot I have check Marlin's code and my code. It looks like the pinout is the same. I think that Marlin will not change pinout anymore. You can make custom flat cable or use standard cable and make PCB adapter.

Marlin's code

#if HAS_DWIN_E3V2 || IS_DWIN_MARLINUI
  /**
   *        ------                ------                ------
   * (ENT) |10  9 | (BEEP)       |10  9 |              |10  9 |
   *  (RX) | 8  7 |         (RX) | 8  7 | (TX)      RX | 8  7 | TX
   *  (TX)   6  5 |        (ENT)   6  5 | (BEEP)   ENT | 6  5 | BEEP
   *   (B) | 4  3 | (A)      (B) | 4  3 | (A)        B | 4  3 | A
   *   GND | 2  1 | (VCC)    GND | 2  1 | VCC      GND | 2  1 | VCC
   *        ------                ------                ------
   *         EXP1                  DWIN               DWIN (plug)
   *
   * All pins are labeled as printed on DWIN PCB. Connect TX-TX, A-A and so on.
   */

  #error "Ender-3 V2 display requires a custom cable, see diagram above this line. Comment out this line to continue."

  #define BEEPER_PIN                      EXP1_9
  #define BTN_EN1                         EXP1_3
  #define BTN_EN2                           PB8
  #define BTN_ENC                           PB5

My code

/**
 *        Ender 3 V2 display                         SKR Mini E3 V2.0
 *                _____                                     _____
 *            5V | 1 2 | GND                            5V | 1 2 | GND
 *   (BTN_E1) A  | 3 4 | B (BTN_E2)         (BTN_EN1) PB15 | 3 4 | PB8 (BTN_E2)
 *          BEEP | 5 6   ENT (BTN_ENC)       (BEEPER) PB9  | 5 6   RX1
 *  (SKR_RX1) TX | 7 8 | RX (SKR_TX1)                RESET | 7 8 | TX1
 *            NC | 9 10| NC                 (BTN_ENC) PA15 | 9 10| PB5  
 *                -----                                     -----
 *                EXP1                                      EXP1
 */
#if ENABLED(DWIN_CREALITY_LCD)

  // RET6 DWIN ENCODER LCD
  #define BTN_ENC                           PA15
  #define BTN_EN1                           PB15
  #define BTN_EN2                           PB8

  #ifndef BEEPER_PIN
    #define BEEPER_PIN                      PB9
    #undef SPEAKER
  #endif
#endif

I would recommend you use official Marlin's code and check the pinout. My code is outdated. It was meant as a fix, because Marlin didn't have the implementation yet and at the time, they didn't have interest in including support for SKR mini E3 V2 on Ender 3 V2. But now there is full support in Marlin and you should use it, because Marlin gets regular updates. This issue should also be closed, because it is fixed in Marlin now.

jernejp21 commented 2 years ago

@HYC23 Please close this issue with comment:

SKR mini E3 support for Ender 3 V2 is implemented in Marlin since https://github.com/MarlinFirmware/Configurations/issues/535. Please use official Marlin FW (don't use @jernejp21 fork anymore). For cable configuration see pins config file - src/pins/stm32f1/pins_BTT_SKR_MINI_E3_common.h

davthomaspilot commented 2 years ago

Just wanted to say another success!

Haven't done a long print yet to make sure I don't get the hangs (I changed to single buffer), but display works and Octoprint connects.

Thanks for all those who posted.

davthomaspilot commented 2 years ago

For those who may be worried about making the cable so the stock Ender 3 V2 display can be used

I made two cables, both worked.

I made first cable by cutting a ribbon cable from Amazon, cutting the ribbon and splicing wires:

https://www.amazon.com/dp/B07JNH6J2C?psc=1&ref=ppx_yo2ov_dt_b_product_details

Five of the wires go straight through (black, white, grey, purple, and orange, two from the SKR Mini aren't needed (red and brown, and three need to connect to different color in the ribbon. I just used soldered the wires that need to swap with heat shrink tubing.

image

It worked fine, but looked messy, especially when I added RTV for strain relief.

A better way, IMHO, is to splice no wires, but just use a new connector. I got a bag of them from Amazon:

https://www.amazon.com/dp/B07S1NFG4S?psc=1&ref=ppx_yo2ov_dt_b_product_details

Then, just arrange the wires in the new connector before using a vise to squeeze the connector onto the ribbon cable. It looks like this:

SKR2EnderV2

Important!

The display end of the connector is shown

NathanBerglas commented 2 years ago

I have a question. Can you re-arrange the pins of the rainbow cable through the firmware? Instead of mangling my only cable, I tried this.

In pins_BTT_SKR_E3_common.h, I switched

// RET6 DWIN ENCODER LCD
  #define BTN_ENC                           PB5
  #define BTN_EN1                           PB15
  #define BTN_EN2                           PB8

  #ifndef BEEPER_PIN
    #define BEEPER_PIN                      PA15
    #undef SPEAKER
  #endif
#endif

With

 // RET6 DWIN ENCODER LCD
  #define BTN_E1                            PB15 // 3 --> 3 
  #define BTN_EN2                           PB8  // 4 --> 4
  #define BTN_ENC                           PB5  // 5 --> 9
  #define SKR_RX1                           RX1  // 7 --> 6
  #define SKR_TX1                           TX1  // 8 --> 8
  //#define NC                                PB9  // 9 --> 5 (NC)
  //#define NC                                RESET // 10 --> 7 (NC)

  #ifndef BEEPER_PIN
    #define BEEPER_PIN                      PA15 // 6 --> 10
    #undef SPEAKER
  #endif
#endif

When I flashed it, the screen did nothing, but no beeping noise. Is this idea not possible, or am I making a small mistake?

jernejp21 commented 2 years ago

@NathanBerglas Not possible. Marlin doesn't support SW UART. RX and TX pins must be the correct pins to use HW UART. Also if Marlin supported SW UART, I don't think it would be feasible, since it would consume too much resources. Because RX and TX pins are different on DWIN screen, you need custom cable or adapter. You can also make PCB that mixes signals instead of mixing wires of the cable.