Commit 796cdb50 authored by MagoKimbra's avatar MagoKimbra

Bug Fix

parent b3cca544
......@@ -2326,7 +2326,7 @@
* Ramps - FD v1 & v2
****************************************************************************************/
#if MB(RAMPS_FD_V1) || MB(RAMPS_FD_V2)
#define KNOWN_BOARD 1
#define KNOWN_BOARD
#if MB(RAMPS_FD_V1)
#define RAMPS_FD_V1
......
......@@ -6282,23 +6282,23 @@ inline void gcode_M400() { st_synchronize(); }
ECHO_M("\"heads\": {\"current\":[");
firstOccurrence = true;
for (uint8_t h = 0; h < HOTENDS; h++) {
if (!firstOccurrence) ECHO_M(",");
ECHO_V(degHotend(h), 1);
firstOccurrence = false;
if (!firstOccurrence) ECHO_M(",");
ECHO_V(degHotend(h), 1);
firstOccurrence = false;
}
ECHO_M("],\"active\":[");
firstOccurrence = true;
for (uint8_t h = 0; h < HOTENDS; h++) {
if (!firstOccurrence) ECHO_M(",");
ECHO_V(degTargetHotend(h), 1);
firstOccurrence = false;
if (!firstOccurrence) ECHO_M(",");
ECHO_V(degTargetHotend(h), 1);
firstOccurrence = false;
}
ECHO_M("],\"state\":[");
firstOccurrence = true;
for (uint8_t h = 0; h < HOTENDS; h++) {
if (!firstOccurrence) ECHO_M(",");
ECHO_M(degTargetHotend(h) > EXTRUDER_AUTO_FAN_TEMPERATURE ? "2" : "1");
firstOccurrence = false;
if (!firstOccurrence) ECHO_M(",");
ECHO_M(degTargetHotend(h) > EXTRUDER_AUTO_FAN_TEMPERATURE ? "2" : "1");
firstOccurrence = false;
}
ECHO_MV("]}},\"time\":", HAL::timeInMilliseconds());
......@@ -6403,20 +6403,24 @@ inline void gcode_M400() { st_synchronize(); }
ECHO_M(",");
ECHO_V(max_acceleration_units_per_sq_second[Z_AXIS]);
for (uint8_t i = 0; i < EXTRUDERS; i++) {
ECHO_M(",");
ECHO_V(max_acceleration_units_per_sq_second[E_AXIS + i]);
ECHO_M(",");
ECHO_V(max_acceleration_units_per_sq_second[E_AXIS + i]);
}
ECHO_M("],\"currents\":[");
ECHO_V(motor_current[X_AXIS]);
ECHO_M(",");
ECHO_V(motor_current[Y_AXIS]);
ECHO_M(",");
ECHO_V(motor_current[Z_AXIS]);
for (uint8_t i = 0; i < DRIVER_EXTRUDERS; i++) {
ECHO_M("],");
#if MB(ALLIGATOR)
ECHO_M("\"currents\":[");
ECHO_V(motor_current[X_AXIS]);
ECHO_M(",");
ECHO_V(motor_current[Y_AXIS]);
ECHO_M(",");
ECHO_V(motor_current[Z_AXIS]);
for (uint8_t i = 0; i < DRIVER_EXTRUDERS; i++) {
ECHO_M(",");
ECHO_V(motor_current[E_AXIS + i]);
}
ECHO_EM("],");
}
ECHO_EM("],");
#endif
ECHO_M("\"firmwareElectronics\":\"");
#if MB(RAMPS_13_HFB) || MB(RAMPS_13_HHB) || MB(RAMPS_13_HFF) || MB(RAMPS_13_HHF) || MB(RAMPS_13_HHH)
......
......@@ -996,9 +996,6 @@ void tp_init() {
OUT_WRITE(SCK_PIN, LOW);
OUT_WRITE(MOSI_PIN, HIGH);
OUT_WRITE(MISO_PIN, HIGH);
#else
pinMode(SS_PIN, OUTPUT);
digitalWrite(SS_PIN, HIGH);
#endif
OUT_WRITE(MAX6675_SS, HIGH);
......@@ -1290,8 +1287,8 @@ void disable_all_heaters() {
WRITE(MAX6675_SS, 0);
// ensure 100ns delay - a bit extra is fine
asm("nop");//50ns on 20Mhz, 62.5ns on 16Mhz
asm("nop");//50ns on 20Mhz, 62.5ns on 16Mhz
asm("nop"); // 50ns on 20Mhz, 62.5ns on 16Mhz
asm("nop"); // 50ns on 20Mhz, 62.5ns on 16Mhz
// read MSB
SPDR = 0;
......
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