Make sure we don't have the printer waiting for position before it is connected.
This commit is contained in:
parent
3c571b562a
commit
a206586736
1 changed files with 5 additions and 2 deletions
|
|
@ -2692,7 +2692,9 @@ namespace MatterHackers.MatterControl.PrinterCommunication
|
|||
else
|
||||
{
|
||||
int waitTimeInMs = 60000; // 60 seconds
|
||||
if (waitingForPosition.IsRunning && waitingForPosition.ElapsedMilliseconds < waitTimeInMs)
|
||||
if (waitingForPosition.IsRunning
|
||||
&& waitingForPosition.ElapsedMilliseconds < waitTimeInMs
|
||||
&& PrinterIsConnected)
|
||||
{
|
||||
// we are waiting for a position response don't print more
|
||||
return;
|
||||
|
|
@ -2706,7 +2708,8 @@ namespace MatterHackers.MatterControl.PrinterCommunication
|
|||
string[] splitOnSemicolon = currentSentLine.Split(';');
|
||||
string trimedLine = splitOnSemicolon[0].Trim().ToUpper();
|
||||
|
||||
if (currentSentLine.Contains("M114"))
|
||||
if (currentSentLine.Contains("M114")
|
||||
&& PrinterIsConnected)
|
||||
{
|
||||
waitingForPosition.Restart();
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue