Welcome! Log In Create A New Profile

Advanced

Marlin does not compile for SKR Mini with TMC2209

Posted by daninet 
Marlin does not compile for SKR Mini with TMC2209
February 17, 2023 06:24PM
Hello!

I'm building a pen plotter machine, very simple 2 axes, 3 stepper motor (I have 2 X). So basically all 3d printer function undefined.
When I'm compiling Marlin I get the following error:

Marlin\src\module\stepper\../../inc/../pins/pins_postprocess.h:566:21: error: 'E0_SERIAL_TX_PIN' was not declared in this scope; did you mean 'X2_SERIAL_TX_PIN'?

I have checked the SKR Mini v2 config files and I couldnt figure out where is this, what it should be set to, where it should be set to.
The conf_adv.h does mentions the following on line 2798:

Quote

Set *_SERIAL_TX_PIN and *_SERIAL_RX_PIN to match for all drivers
on the same serial port, either here or in your board's pins file.

config.h
config_adv.h

error log

Any suggestion welcome
Re: Marlin does not compile for SKR Mini with TMC2209
February 17, 2023 06:55PM
Firstly I get this error.
299 | #error "SD CUSTOM_CABLE is not compatible with SKR Mini E3."

After that....

You have disabled all extruders with #define EXTRUDERS 0

You also have X2

The stepper driver auto reallocation script doesn't support hardware UARTS, so when it tries to re allocate E0 as X2, it getting confused. (this may have been fixed in newer code,)

Add this to your config.

#define X2_HARDWARE_SERIAL MSerial4

Edited 2 time(s). Last edit at 02/17/2023 07:17PM by Dust.
Re: Marlin does not compile for SKR Mini with TMC2209
February 18, 2023 02:41AM
The SD CUSTOM_CABLE error is really weird. It is clearly defined that my SD type is ONBOARD and I still get this error. Feel like this might be a bug. I have removed the CUSTOM_CABLE option in file BTT_SKR_MINI_E3_common.h at line 298 from the if statement and only the onboard and LCD option remained. This way the error is gone.

looks like this now:
#ifndef SDCARD_CONNECTION
  #define SDCARD_CONNECTION              ONBOARD
#endif

#if SD_CONNECTION_IS(ONBOARD)
  #define SD_DETECT_PIN                     PC4
#elif SD_CONNECTION_IS(LCD) && (BOTH(TOUCH_UI_FTDI_EVE, LCD_FYSETC_TFT81050) || IS_TFTGLCD_PANEL)
  #define SD_DETECT_PIN                     PB5
  #define SD_SS_PIN                         PA10
#endif



Adding #define X2_HARDWARE_SERIAL MSerial4 did solve the issue and with a ton of warning for missing extruder now the code compiled.
Thank you very much.
Re: Marlin does not compile for SKR Mini with TMC2209
February 18, 2023 04:55AM
Line 1547 of the provided Configuration_adv.h "#define SDCARD_CONNECTION CUSTOM_CABLE"
[pastebin.com]
Re: Marlin does not compile for SKR Mini with TMC2209
February 18, 2023 05:55AM
Thank you, on point. I did not realized it was defined in two separate location.
Sorry, only registered users may post in this forum.

Click here to login