Skip to content

Commit

Permalink
🎨 Tweak TMC software serial pins
Browse files Browse the repository at this point in the history
  • Loading branch information
thinkyhead committed Sep 13, 2021
1 parent 0be98b9 commit 0aa87af
Show file tree
Hide file tree
Showing 48 changed files with 235 additions and 299 deletions.
3 changes: 0 additions & 3 deletions Marlin/src/pins/lpc1768/pins_BTT_SKR_V1_3.h
Original file line number Diff line number Diff line change
Expand Up @@ -164,9 +164,6 @@
//#define E3_HARDWARE_SERIAL Serial1
//#define E4_HARDWARE_SERIAL Serial1

//
// Software serial
//
#define X_SERIAL_TX_PIN P4_29
#define X_SERIAL_RX_PIN P1_17

Expand Down
13 changes: 5 additions & 8 deletions Marlin/src/pins/lpc1768/pins_BTT_SKR_V1_4.h
Original file line number Diff line number Diff line change
Expand Up @@ -220,23 +220,20 @@
//#define E3_HARDWARE_SERIAL Serial1
//#define E4_HARDWARE_SERIAL Serial1

//
// Software serial
//
#define X_SERIAL_TX_PIN P1_10
#define X_SERIAL_RX_PIN P1_10
#define X_SERIAL_RX_PIN X_SERIAL_TX_PIN

#define Y_SERIAL_TX_PIN P1_09
#define Y_SERIAL_RX_PIN P1_09
#define Y_SERIAL_RX_PIN Y_SERIAL_TX_PIN

#define Z_SERIAL_TX_PIN P1_08
#define Z_SERIAL_RX_PIN P1_08
#define Z_SERIAL_RX_PIN Z_SERIAL_TX_PIN

#define E0_SERIAL_TX_PIN P1_04
#define E0_SERIAL_RX_PIN P1_04
#define E0_SERIAL_RX_PIN E0_SERIAL_TX_PIN

#define E1_SERIAL_TX_PIN P1_01
#define E1_SERIAL_RX_PIN P1_01
#define E1_SERIAL_RX_PIN E1_SERIAL_TX_PIN

// Reduce baud rate to improve software serial reliability
#define TMC_BAUD_RATE 19200
Expand Down
6 changes: 3 additions & 3 deletions Marlin/src/pins/lpc1768/pins_BTT_SKR_common.h
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@
#define E2_CS_PIN EXP1_05_PIN
#if HAS_TMC_UART
#define E2_SERIAL_TX_PIN EXP1_05_PIN
#define E2_SERIAL_RX_PIN EXP1_05_PIN
#define E2_SERIAL_RX_PIN E2_SERIAL_TX_PIN
#endif
#endif

Expand All @@ -185,7 +185,7 @@
#define E3_CS_PIN EXP1_07_PIN
#if HAS_TMC_UART
#define E3_SERIAL_TX_PIN EXP1_07_PIN
#define E3_SERIAL_RX_PIN EXP1_07_PIN
#define E3_SERIAL_RX_PIN E3_SERIAL_TX_PIN
#endif
#else
#define E3_ENABLE_PIN EXP2_04_PIN
Expand All @@ -200,7 +200,7 @@
#define E4_CS_PIN EXP1_09_PIN
#if HAS_TMC_UART
#define E4_SERIAL_TX_PIN EXP1_09_PIN
#define E4_SERIAL_RX_PIN EXP1_09_PIN
#define E4_SERIAL_RX_PIN E4_SERIAL_TX_PIN
#endif
#else
#define E4_ENABLE_PIN EXP2_04_PIN
Expand Down
17 changes: 11 additions & 6 deletions Marlin/src/pins/lpc1768/pins_GMARSH_X6_REV1.h
Original file line number Diff line number Diff line change
Expand Up @@ -82,17 +82,22 @@
//
#if HAS_TMC_UART
#define X_SERIAL_TX_PIN P1_00
#define X_SERIAL_RX_PIN P1_00
#define X_SERIAL_RX_PIN X_SERIAL_TX_PIN

#define Y_SERIAL_TX_PIN P1_09
#define Y_SERIAL_RX_PIN P1_09
#define Y_SERIAL_RX_PIN Y_SERIAL_TX_PIN

#define Z_SERIAL_TX_PIN P1_16
#define Z_SERIAL_RX_PIN P1_16
#define Z_SERIAL_RX_PIN Z_SERIAL_TX_PIN

#define E0_SERIAL_TX_PIN P0_04
#define E0_SERIAL_RX_PIN P0_04
#define E0_SERIAL_RX_PIN E0_SERIAL_TX_PIN

#define E1_SERIAL_TX_PIN P2_02
#define E1_SERIAL_RX_PIN P2_02
#define E1_SERIAL_RX_PIN E1_SERIAL_TX_PIN

#define E2_SERIAL_TX_PIN P2_06
#define E2_SERIAL_RX_PIN P2_06
#define E2_SERIAL_RX_PIN E2_SERIAL_TX_PIN

// Reduce baud rate to improve software serial reliability
#define TMC_BAUD_RATE 19200
Expand Down
3 changes: 3 additions & 0 deletions Marlin/src/pins/lpc1768/pins_MKS_SBASE.h
Original file line number Diff line number Diff line change
Expand Up @@ -327,10 +327,13 @@
*/
#define X_SERIAL_TX_PIN P1_22 // J8-2
#define X_SERIAL_RX_PIN P2_12 // J8-4 Interrupt Capable

#define Y_SERIAL_TX_PIN P1_23 // J8-3
#define Y_SERIAL_RX_PIN P2_11 // J8-5 Interrupt Capable

#define Z_SERIAL_TX_PIN P2_12 // J8-4
#define Z_SERIAL_RX_PIN P0_25 // TH3

#define E0_SERIAL_TX_PIN P4_28 // J8-6
#define E0_SERIAL_RX_PIN P0_26 // TH4

Expand Down
4 changes: 0 additions & 4 deletions Marlin/src/pins/lpc1768/pins_MKS_SGEN_L.h
Original file line number Diff line number Diff line change
Expand Up @@ -163,10 +163,6 @@
//#define E3_HARDWARE_SERIAL Serial1
//#define E4_HARDWARE_SERIAL Serial1

//
// Software serial
//

#define X_SERIAL_TX_PIN P1_04
#define X_SERIAL_RX_PIN P1_01

Expand Down
11 changes: 4 additions & 7 deletions Marlin/src/pins/lpc1768/pins_RAMPS_RE_ARM.h
Original file line number Diff line number Diff line change
Expand Up @@ -119,9 +119,6 @@
* If undefined software serial is used according to the pins below
*/

//
// Software serial
//

// P2_08 E1-Step
// P2_13 E1-Dir
Expand All @@ -130,28 +127,28 @@
#define X_SERIAL_TX_PIN P0_01
#endif
#ifndef X_SERIAL_RX_PIN
#define X_SERIAL_RX_PIN P0_01
#define X_SERIAL_RX_PIN X_SERIAL_TX_PIN
#endif

#ifndef Y_SERIAL_TX_PIN
#define Y_SERIAL_TX_PIN P0_00
#endif
#ifndef Y_SERIAL_RX_PIN
#define Y_SERIAL_RX_PIN P0_00
#define Y_SERIAL_RX_PIN Y_SERIAL_TX_PIN
#endif

#ifndef Z_SERIAL_TX_PIN
#define Z_SERIAL_TX_PIN P2_13
#endif
#ifndef Z_SERIAL_RX_PIN
#define Z_SERIAL_RX_PIN P2_13
#define Z_SERIAL_RX_PIN Z_SERIAL_TX_PIN
#endif

#ifndef E0_SERIAL_TX_PIN
#define E0_SERIAL_TX_PIN P2_08
#endif
#ifndef E0_SERIAL_RX_PIN
#define E0_SERIAL_RX_PIN P2_08
#define E0_SERIAL_RX_PIN E0_SERIAL_TX_PIN
#endif

// Reduce baud rate to improve software serial reliability
Expand Down
13 changes: 5 additions & 8 deletions Marlin/src/pins/lpc1769/pins_BTT_SKR_E3_TURBO.h
Original file line number Diff line number Diff line change
Expand Up @@ -129,23 +129,20 @@
* If undefined software serial is used according to the pins below
*/

//
// Software serial
//
#define X_SERIAL_TX_PIN P1_01
#define X_SERIAL_RX_PIN P1_01
#define X_SERIAL_RX_PIN X_SERIAL_TX_PIN

#define Y_SERIAL_TX_PIN P1_10
#define Y_SERIAL_RX_PIN P1_10
#define Y_SERIAL_RX_PIN Y_SERIAL_TX_PIN

#define Z_SERIAL_TX_PIN P1_17
#define Z_SERIAL_RX_PIN P1_17
#define Z_SERIAL_RX_PIN Z_SERIAL_TX_PIN

#define E0_SERIAL_TX_PIN P0_05
#define E0_SERIAL_RX_PIN P0_05
#define E0_SERIAL_RX_PIN E0_SERIAL_TX_PIN

#define E1_SERIAL_TX_PIN P0_22
#define E1_SERIAL_RX_PIN P0_22
#define E1_SERIAL_RX_PIN E1_SERIAL_TX_PIN

// Reduce baud rate to improve software serial reliability
#define TMC_BAUD_RATE 19200
Expand Down
12 changes: 6 additions & 6 deletions Marlin/src/pins/lpc1769/pins_FLY_CDY.h
Original file line number Diff line number Diff line change
Expand Up @@ -104,22 +104,22 @@

#if HAS_TMC_UART
#define X_SERIAL_TX_PIN P1_04
#define X_SERIAL_RX_PIN P1_04
#define X_SERIAL_RX_PIN X_SERIAL_TX_PIN

#define Y_SERIAL_TX_PIN P1_10
#define Y_SERIAL_RX_PIN P1_10
#define Y_SERIAL_RX_PIN Y_SERIAL_TX_PIN

#define Z_SERIAL_TX_PIN P1_16
#define Z_SERIAL_RX_PIN P1_16
#define Z_SERIAL_RX_PIN Z_SERIAL_TX_PIN

#define E0_SERIAL_TX_PIN P4_28
#define E0_SERIAL_RX_PIN P4_28
#define E0_SERIAL_RX_PIN E0_SERIAL_TX_PIN

#define E1_SERIAL_TX_PIN P2_12
#define E1_SERIAL_RX_PIN P2_12
#define E1_SERIAL_RX_PIN E1_SERIAL_TX_PIN

#define E2_SERIAL_TX_PIN P0_10
#define E2_SERIAL_RX_PIN P0_10
#define E2_SERIAL_RX_PIN E2_SERIAL_TX_PIN

// Reduce baud rate to improve software serial reliability
#define TMC_BAUD_RATE 19200
Expand Down
15 changes: 9 additions & 6 deletions Marlin/src/pins/lpc1769/pins_MKS_SGEN.h
Original file line number Diff line number Diff line change
Expand Up @@ -38,17 +38,20 @@
/**
* TMC2208/TMC2209 stepper drivers
*/

#define X_SERIAL_TX_PIN P1_22 // J8-2
#define X_SERIAL_RX_PIN P1_22 // J8-2
#define X_SERIAL_RX_PIN X_SERIAL_TX_PIN

#define Y_SERIAL_TX_PIN P1_23 // J8-3
#define Y_SERIAL_RX_PIN P1_23 // J8-3
#define Y_SERIAL_RX_PIN Y_SERIAL_TX_PIN

#define Z_SERIAL_TX_PIN P2_12 // J8-4
#define Z_SERIAL_RX_PIN P2_12 // J8-4
#define Z_SERIAL_RX_PIN Z_SERIAL_TX_PIN

#define E0_SERIAL_TX_PIN P2_11 // J8-5
#define E0_SERIAL_RX_PIN P2_11 // J8-5
#define E0_SERIAL_RX_PIN E0_SERIAL_TX_PIN

#define E1_SERIAL_TX_PIN P4_28 // J8-6
#define E1_SERIAL_RX_PIN P4_28 // J8-6
#define E1_SERIAL_RX_PIN E1_SERIAL_TX_PIN

// Reduce baud rate to improve software serial reliability
#define TMC_BAUD_RATE 19200
Expand Down
17 changes: 9 additions & 8 deletions Marlin/src/pins/lpc1769/pins_MKS_SGEN_L_V2.h
Original file line number Diff line number Diff line change
Expand Up @@ -173,19 +173,20 @@
//#define E3_HARDWARE_SERIAL Serial1
//#define E4_HARDWARE_SERIAL Serial1

//
// Software serial
//
#define X_SERIAL_TX_PIN P1_01
#define X_SERIAL_RX_PIN P1_01
#define X_SERIAL_RX_PIN X_SERIAL_TX_PIN

#define Y_SERIAL_TX_PIN P1_08
#define Y_SERIAL_RX_PIN P1_08
#define Y_SERIAL_RX_PIN Y_SERIAL_TX_PIN

#define Z_SERIAL_TX_PIN P1_10
#define Z_SERIAL_RX_PIN P1_10
#define Z_SERIAL_RX_PIN Z_SERIAL_TX_PIN

#define E0_SERIAL_TX_PIN P1_15
#define E0_SERIAL_RX_PIN P1_15
#define E0_SERIAL_RX_PIN E0_SERIAL_TX_PIN

#define E1_SERIAL_TX_PIN P1_17
#define E1_SERIAL_RX_PIN P1_17
#define E1_SERIAL_RX_PIN E1_SERIAL_TX_PIN

// Reduce baud rate to improve software serial reliability
#define TMC_BAUD_RATE 19200
Expand Down
4 changes: 3 additions & 1 deletion Marlin/src/pins/lpc1769/pins_TH3D_EZBOARD.h
Original file line number Diff line number Diff line change
Expand Up @@ -75,14 +75,16 @@
#if HAS_TMC_UART
//
// TMC220x stepper drivers
// Software serial
//
#define X_SERIAL_TX_PIN P0_04
#define X_SERIAL_RX_PIN P0_05

#define Y_SERIAL_TX_PIN P0_10
#define Y_SERIAL_RX_PIN P0_11

#define Z_SERIAL_TX_PIN P0_19
#define Z_SERIAL_RX_PIN P0_20

#define E0_SERIAL_TX_PIN P0_22
#define E0_SERIAL_RX_PIN P0_21

Expand Down
26 changes: 13 additions & 13 deletions Marlin/src/pins/ramps/pins_FYSETC_F6_13.h
Original file line number Diff line number Diff line change
Expand Up @@ -124,42 +124,42 @@
* Software serial communication pins.
* At the moment, F6 rx pins are not pc interrupt pins
*/
#ifndef X_SERIAL_RX_PIN
#define X_SERIAL_RX_PIN -1 // 71
#endif
#ifndef X_SERIAL_TX_PIN
#define X_SERIAL_TX_PIN 72
#endif
#ifndef Y_SERIAL_RX_PIN
#define Y_SERIAL_RX_PIN -1 // 73
#ifndef X_SERIAL_RX_PIN
#define X_SERIAL_RX_PIN -1 // 71
#endif
#ifndef Y_SERIAL_TX_PIN
#define Y_SERIAL_TX_PIN 75
#endif
#ifndef Z_SERIAL_RX_PIN
#define Z_SERIAL_RX_PIN -1 // 78
#ifndef Y_SERIAL_RX_PIN
#define Y_SERIAL_RX_PIN -1 // 73
#endif
#ifndef Z_SERIAL_TX_PIN
#define Z_SERIAL_TX_PIN 79
#endif
#ifndef E0_SERIAL_RX_PIN
#define E0_SERIAL_RX_PIN -1 // 76
#ifndef Z_SERIAL_RX_PIN
#define Z_SERIAL_RX_PIN -1 // 78
#endif
#ifndef E0_SERIAL_TX_PIN
#define E0_SERIAL_TX_PIN 77
#endif
#ifndef E1_SERIAL_RX_PIN
#define E1_SERIAL_RX_PIN -1 // 80
#ifndef E0_SERIAL_RX_PIN
#define E0_SERIAL_RX_PIN -1 // 76
#endif
#ifndef E1_SERIAL_TX_PIN
#define E1_SERIAL_TX_PIN 81
#endif
#ifndef E2_SERIAL_RX_PIN
#define E2_SERIAL_RX_PIN -1 // 22
#ifndef E1_SERIAL_RX_PIN
#define E1_SERIAL_RX_PIN -1 // 80
#endif
#ifndef E2_SERIAL_TX_PIN
#define E2_SERIAL_TX_PIN 82
#endif
#ifndef E2_SERIAL_RX_PIN
#define E2_SERIAL_RX_PIN -1 // 22
#endif
#endif

//
Expand Down
17 changes: 11 additions & 6 deletions Marlin/src/pins/ramps/pins_FYSETC_F6_14.h
Original file line number Diff line number Diff line change
Expand Up @@ -33,18 +33,23 @@
/**
* TMC2208/TMC2209 stepper drivers
*/
#define X_SERIAL_RX_PIN 72
#define X_SERIAL_TX_PIN 71
#define Y_SERIAL_RX_PIN 73
#define X_SERIAL_RX_PIN 72

#define Y_SERIAL_TX_PIN 78
#define Z_SERIAL_RX_PIN 75
#define Y_SERIAL_RX_PIN 73

#define Z_SERIAL_TX_PIN 79
#define E0_SERIAL_RX_PIN 77
#define Z_SERIAL_RX_PIN 75

#define E0_SERIAL_TX_PIN 81
#define E1_SERIAL_RX_PIN 76
#define E0_SERIAL_RX_PIN 77

#define E1_SERIAL_TX_PIN 80
#define E2_SERIAL_RX_PIN 62
#define E1_SERIAL_RX_PIN 76

#define E2_SERIAL_TX_PIN 82
#define E2_SERIAL_RX_PIN 62
#endif

#include "pins_FYSETC_F6_13.h"
Loading

0 comments on commit 0aa87af

Please sign in to comment.