Commit 075af738 authored by MagoKimbra's avatar MagoKimbra

Same fix

parent ae00f247
...@@ -6786,29 +6786,29 @@ inline void gcode_T(uint8_t tmp_extruder) { ...@@ -6786,29 +6786,29 @@ inline void gcode_T(uint8_t tmp_extruder) {
switch(target_extruder) switch(target_extruder)
{ {
case 0: case 0:
WRITE_RELE(E0E2_CHOICE_PIN, 0); WRITE_RELE(E0E2_CHOICE_PIN, LOW);
WRITE_RELE(E1E3_CHOICE_PIN, 0); WRITE_RELE(E1E3_CHOICE_PIN, LOW);
active_driver = 0; active_driver = 0;
delay(500); // 500 microseconds delay for relay delay(500); // 500 microseconds delay for relay
enable_e0(); enable_e0();
break; break;
case 1: case 1:
WRITE_RELE(E0E2_CHOICE_PIN, 0); WRITE_RELE(E0E2_CHOICE_PIN, LOW);
WRITE_RELE(E1E3_CHOICE_PIN, 0); WRITE_RELE(E1E3_CHOICE_PIN, LOW);
active_driver = 1; active_driver = 1;
delay(500); // 500 microseconds delay for relay delay(500); // 500 microseconds delay for relay
enable_e1(); enable_e1();
break; break;
case 2: case 2:
WRITE_RELE(E0E2_CHOICE_PIN, 1); WRITE_RELE(E0E2_CHOICE_PIN, HIGH);
WRITE_RELE(E1E3_CHOICE_PIN, 0); WRITE_RELE(E1E3_CHOICE_PIN, LOW);
active_driver = 0; active_driver = 0;
delay(500); // 500 microseconds delay for relay delay(500); // 500 microseconds delay for relay
enable_e2(); enable_e2();
break; break;
case 3: case 3:
WRITE_RELE(E0E2_CHOICE_PIN, 0); WRITE_RELE(E0E2_CHOICE_PIN, LOW);
WRITE_RELE(E1E3_CHOICE_PIN, 1); WRITE_RELE(E1E3_CHOICE_PIN, HIGH);
active_driver = 1; active_driver = 1;
delay(500); // 500 microseconds delay for relay delay(500); // 500 microseconds delay for relay
enable_e3(); enable_e3();
...@@ -6820,33 +6820,33 @@ inline void gcode_T(uint8_t tmp_extruder) { ...@@ -6820,33 +6820,33 @@ inline void gcode_T(uint8_t tmp_extruder) {
switch(target_extruder) switch(target_extruder)
{ {
case 0: case 0:
WRITE_RELE(E0E1_CHOICE_PIN, 0); WRITE_RELE(E0E1_CHOICE_PIN, LOW);
WRITE_RELE(E0E2_CHOICE_PIN, 0); WRITE_RELE(E0E2_CHOICE_PIN, LOW);
WRITE_RELE(E0E3_CHOICE_PIN, 0); WRITE_RELE(E0E3_CHOICE_PIN, LOW);
active_driver = 0; active_driver = 0;
delay(500); // 500 microseconds delay for relay delay(500); // 500 microseconds delay for relay
enable_e0(); enable_e0();
break; break;
case 1: case 1:
WRITE_RELE(E0E1_CHOICE_PIN, 1); WRITE_RELE(E0E1_CHOICE_PIN, HIGH);
WRITE_RELE(E0E2_CHOICE_PIN, 0); WRITE_RELE(E0E2_CHOICE_PIN, LOW);
WRITE_RELE(E0E3_CHOICE_PIN, 0); WRITE_RELE(E0E3_CHOICE_PIN, LOW);
active_driver = 0; active_driver = 0;
delay(500); // 500 microseconds delay for relay delay(500); // 500 microseconds delay for relay
enable_e0(); enable_e0();
break; break;
case 2: case 2:
WRITE_RELE(E0E1_CHOICE_PIN, 1); WRITE_RELE(E0E1_CHOICE_PIN, HIGH);
WRITE_RELE(E0E2_CHOICE_PIN, 1); WRITE_RELE(E0E2_CHOICE_PIN, HIGH);
WRITE_RELE(E0E3_CHOICE_PIN, 0); WRITE_RELE(E0E3_CHOICE_PIN, LOW);
active_driver = 0; active_driver = 0;
delay(500); // 500 microseconds delay for relay delay(500); // 500 microseconds delay for relay
enable_e0(); enable_e0();
break; break;
case 3: case 3:
WRITE_RELE(E0E1_CHOICE_PIN, 1); WRITE_RELE(E0E1_CHOICE_PIN, HIGH);
WRITE_RELE(E0E2_CHOICE_PIN, 1); WRITE_RELE(E0E2_CHOICE_PIN, HIGH);
WRITE_RELE(E0E3_CHOICE_PIN, 1); WRITE_RELE(E0E3_CHOICE_PIN, HIGH);
active_driver = 0; active_driver = 0;
delay(500); // 500 microseconds delay for relay delay(500); // 500 microseconds delay for relay
enable_e0(); enable_e0();
...@@ -6858,22 +6858,22 @@ inline void gcode_T(uint8_t tmp_extruder) { ...@@ -6858,22 +6858,22 @@ inline void gcode_T(uint8_t tmp_extruder) {
switch(target_extruder) switch(target_extruder)
{ {
case 0: case 0:
WRITE_RELE(E0E2_CHOICE_PIN, 0); WRITE_RELE(E0E2_CHOICE_PIN, LOW);
active_driver = 0; active_driver = 0;
delay(500); // 500 microseconds delay for relay delay(500); // 500 microseconds delay for relay
enable_e0(); enable_e0();
break; break;
case 1: case 1:
WRITE_RELE(E0E2_CHOICE_PIN, 0); WRITE_RELE(E0E2_CHOICE_PIN, LOW);
active_driver = 1; active_driver = 1;
delay(500); // 500 microseconds delay for relay delay(500); // 500 microseconds delay for relay
enable_e1(); enable_e1();
break; break;
case 2: case 2:
WRITE_RELE(E0E2_CHOICE_PIN, 1); WRITE_RELE(E0E2_CHOICE_PIN, HIGH);
active_driver = 0; active_driver = 0;
delay(500); // 500 microseconds delay for relay delay(500); // 500 microseconds delay for relay
enable_e2(); enable_e0();
break; break;
} }
#elif (EXTRUDERS == 3) && HAS(E0E1) && HAS(E0E2) && (DRIVER_EXTRUDERS == 1) #elif (EXTRUDERS == 3) && HAS(E0E1) && HAS(E0E2) && (DRIVER_EXTRUDERS == 1)
...@@ -6882,22 +6882,22 @@ inline void gcode_T(uint8_t tmp_extruder) { ...@@ -6882,22 +6882,22 @@ inline void gcode_T(uint8_t tmp_extruder) {
switch(target_extruder) switch(target_extruder)
{ {
case 0: case 0:
WRITE_RELE(E0E1_CHOICE_PIN, 0); WRITE_RELE(E0E1_CHOICE_PIN, LOW);
WRITE_RELE(E0E2_CHOICE_PIN, 0); WRITE_RELE(E0E2_CHOICE_PIN, LOW);
active_driver = 0; active_driver = 0;
delay(500); // 500 microseconds delay for relay delay(500); // 500 microseconds delay for relay
enable_e0(); enable_e0();
break; break;
case 1: case 1:
WRITE_RELE(E0E1_CHOICE_PIN, 1); WRITE_RELE(E0E1_CHOICE_PIN, HIGH);
WRITE_RELE(E0E2_CHOICE_PIN, 0); WRITE_RELE(E0E2_CHOICE_PIN, LOW);
active_driver = 0; active_driver = 0;
delay(500); // 500 microseconds delay for relay delay(500); // 500 microseconds delay for relay
enable_e0(); enable_e0();
break; break;
case 2: case 2:
WRITE_RELE(E0E1_CHOICE_PIN, 1); WRITE_RELE(E0E1_CHOICE_PIN, HIGH);
WRITE_RELE(E0E2_CHOICE_PIN, 1); WRITE_RELE(E0E2_CHOICE_PIN, HIGH);
active_driver = 0; active_driver = 0;
delay(500); // 500 microseconds delay for relay delay(500); // 500 microseconds delay for relay
enable_e0(); enable_e0();
...@@ -6909,13 +6909,13 @@ inline void gcode_T(uint8_t tmp_extruder) { ...@@ -6909,13 +6909,13 @@ inline void gcode_T(uint8_t tmp_extruder) {
switch(target_extruder) switch(target_extruder)
{ {
case 0: case 0:
WRITE_RELE(E0E1_CHOICE_PIN, 0); WRITE_RELE(E0E1_CHOICE_PIN, LOW);
active_driver = 0; active_driver = 0;
delay(500); // 500 microseconds delay for relay delay(500); // 500 microseconds delay for relay
enable_e0(); enable_e0();
break; break;
case 1: case 1:
WRITE_RELE(E0E1_CHOICE_PIN, 1); WRITE_RELE(E0E1_CHOICE_PIN, HIGH);
active_driver = 0; active_driver = 0;
delay(500); // 500 microseconds delay for relay delay(500); // 500 microseconds delay for relay
enable_e0(); enable_e0();
......
...@@ -672,8 +672,10 @@ ...@@ -672,8 +672,10 @@
#if ENABLED(MKR4) #if ENABLED(MKR4)
#if ENABLED(INVERTED_RELE_PINS) #if ENABLED(INVERTED_RELE_PINS)
#define WRITE_RELE(pin, value) WRITE(pin, !value) #define WRITE_RELE(pin, value) WRITE(pin, !value)
#define OUT_WRITE_RELE(pin, value) OUT_WRITE(pin, !value)
#else #else
#define WRITE_RELE(pin, value) WRITE(pin, value) #define WRITE_RELE(pin, value) WRITE(pin, value)
#define OUT_WRITE_RELE(pin, value) OUT_WRITE(pin, value)
#endif #endif
#endif #endif
......
...@@ -1248,7 +1248,7 @@ ...@@ -1248,7 +1248,7 @@
#define MAX6675_SS 66 // Do not use pin 49 as this is tied to the switch inside the SD card socket to detect if there is an SD card present #define MAX6675_SS 66 // Do not use pin 49 as this is tied to the switch inside the SD card socket to detect if there is an SD card present
#endif #endif
#endif // RAMPS_13_EEB #endif // RAMPS_13_HHB
/****************************************************************************************/ /****************************************************************************************/
...@@ -2533,7 +2533,6 @@ ...@@ -2533,7 +2533,6 @@
#define Z_MIN_PIN 38 // PC6 #define Z_MIN_PIN 38 // PC6
#define Z_MAX_PIN 39 // PC7 #define Z_MAX_PIN 39 // PC7
#define Z_MS1_PIN 44 // PC19 #define Z_MS1_PIN 44 // PC19
#define Z_PROBE_PIN 39 // PC7
// E0 AXIS // E0 AXIS
#define ORIG_E0_STEP_PIN 5 // PC25 #define ORIG_E0_STEP_PIN 5 // PC25
......
...@@ -854,7 +854,6 @@ float junction_deviation = 0.1; ...@@ -854,7 +854,6 @@ float junction_deviation = 0.1;
// Max segement time in us. // Max segement time in us.
#if ENABLED(XY_FREQUENCY_LIMIT) #if ENABLED(XY_FREQUENCY_LIMIT)
#define MAX_FREQ_TIME (1000000.0 / XY_FREQUENCY_LIMIT)
// Check and limit the xy direction change frequency // Check and limit the xy direction change frequency
unsigned char direction_change = block->direction_bits ^ old_direction_bits; unsigned char direction_change = block->direction_bits ^ old_direction_bits;
......
...@@ -940,20 +940,16 @@ void st_init() { ...@@ -940,20 +940,16 @@ void st_init() {
//Choice E0-E1 or E0-E2 or E1-E3 pin //Choice E0-E1 or E0-E2 or E1-E3 pin
#if ENABLED(MKR4) && HAS(E0E1) #if ENABLED(MKR4) && HAS(E0E1)
SET_OUTPUT(E0E1_CHOICE_PIN); OUT_WRITE_RELE(E0E1_CHOICE_PIN, LOW);
WRITE_RELE(E0E1_CHOICE_PIN, 0);
#endif #endif
#if ENABLED(MKR4) && HAS(E0E2) #if ENABLED(MKR4) && HAS(E0E2)
SET_OUTPUT(E0E2_CHOICE_PIN); OUT_WRITE_RELE(E0E2_CHOICE_PIN, LOW);
WRITE_RELE(E0E2_CHOICE_PIN, 0);
#endif #endif
#if ENABLED(MKR4) && HAS(E0E3) #if ENABLED(MKR4) && HAS(E0E3)
SET_OUTPUT(E0E3_CHOICE_PIN); OUT_WRITE_RELE(E0E3_CHOICE_PIN, LOW);
WRITE_RELE(E0E3_CHOICE_PIN, 0);
#endif #endif
#if ENABLED(MKR4) && HAS(E1E3) #if ENABLED(MKR4) && HAS(E1E3)
SET_OUTPUT(E1E3_CHOICE_PIN); OUT_WRITE_RELE(E1E3_CHOICE_PIN, LOW);
WRITE_RELE(E1E3_CHOICE_PIN, 0);
#endif #endif
//endstops and pullups //endstops and pullups
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment