Add debug message, reduce ram usage to avoid comm corruption from stack

This commit is contained in:
InsanityAutomation
2023-02-26 15:22:37 -05:00
parent 3a4d705308
commit ab427804ac
3 changed files with 10 additions and 9 deletions
+2 -2
View File
@@ -2084,7 +2084,7 @@
// Gradually reduce leveling correction until a set height is reached,
// at which point movement will be level to the machine's XY plane.
// The height can be set with M420 Z<height>
#define ENABLE_LEVELING_FADE_HEIGHT
//#define ENABLE_LEVELING_FADE_HEIGHT
#if ENABLED(ENABLE_LEVELING_FADE_HEIGHT)
#define DEFAULT_LEVELING_FADE_HEIGHT 00.0 // (mm) Default fade height.
#endif
@@ -2529,7 +2529,7 @@
*
* View the current statistics with M78.
*/
#define PRINTCOUNTER
//#define PRINTCOUNTER
#if ENABLED(PRINTCOUNTER)
#define PRINTCOUNTER_SAVE_INTERVAL 60 // (minutes) EEPROM save interval during print
#endif
+2 -2
View File
@@ -1214,7 +1214,7 @@
// Backlash Compensation
// Adds extra movement to axes on direction-changes to account for backlash.
//
#define BACKLASH_COMPENSATION
//#define BACKLASH_COMPENSATION
#if ENABLED(BACKLASH_COMPENSATION)
// Define values for backlash distance and correction.
// If BACKLASH_GCODE is enabled these values are the defaults.
@@ -2459,7 +2459,7 @@
// For debug-echo: 128 bytes for the optimal speed.
// Other output doesn't need to be that speedy.
// :[0, 2, 4, 8, 16, 32, 64, 128, 256]
#define TX_BUFFER_SIZE 128
#define TX_BUFFER_SIZE 64
// Host Receive Buffer Size
// Without XON/XOFF flow control (see SERIAL_XON_XOFF below) 32 bytes should be enough.
@@ -580,10 +580,10 @@ int RTSSHOW::RTS_RecData()
recdat.addr = vp;
recdat.len = tmp[2];
for(unsigned int i = 0;i < dlen; i+=2)
{
recdat.data[i/2]= tmp[3+i];
recdat.data[i/2]= (recdat.data[i/2] << 8 )| tmp[4+i];
}
{
recdat.data[i/2]= tmp[3+i];
recdat.data[i/2]= (recdat.data[i/2] << 8 )| tmp[4+i];
}
SERIAL_ECHOLNPGM("VP received: ", vp , " - len ", tmp[2]);
@@ -598,6 +598,7 @@ int RTSSHOW::RTS_RecData()
// discard anything else
rx_datagram_state = DGUS_IDLE;
return -1;
}
}
return -1;
@@ -801,7 +802,7 @@ void RTSSHOW::RTS_HandleData()
SERIAL_ECHOLNPGM_P(PSTR(" *******RTS_HandleData******** "));
if (waitway > 0) //for waiting
{
SERIAL_ECHOLNPGM("waitway ==", (int)waitway);
SERIAL_ECHOLNPGM("handle waitway ==", (int)waitway);
memset(&recdat, 0, sizeof(recdat));
recdat.head[0] = FHONE;
recdat.head[1] = FHTWO;