0.0.2
only report chamber temp if printer profile has it enabled
This commit is contained in:
		@@ -463,6 +463,11 @@ class BambuPrinter:
 | 
				
			|||||||
            self._pauseSdPrint()
 | 
					            self._pauseSdPrint()
 | 
				
			||||||
        return True
 | 
					        return True
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    def _gcode_M524(self, data: str) -> bool:
 | 
				
			||||||
 | 
					        if self._sdCardReady:
 | 
				
			||||||
 | 
					            self._cancelSdPrint()
 | 
				
			||||||
 | 
					        return False
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    def _gcode_M26(self, data: str) -> bool:
 | 
					    def _gcode_M26(self, data: str) -> bool:
 | 
				
			||||||
        self._logger.debug("ignoring M26 command.")
 | 
					        self._logger.debug("ignoring M26 command.")
 | 
				
			||||||
        self._send("M26 disabled for Bambu")
 | 
					        self._send("M26 disabled for Bambu")
 | 
				
			||||||
@@ -682,6 +687,13 @@ class BambuPrinter:
 | 
				
			|||||||
            else:
 | 
					            else:
 | 
				
			||||||
                self._logger.info("print pause failed")
 | 
					                self._logger.info("print pause failed")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    def _cancelSdPrint(self):
 | 
				
			||||||
 | 
					        if self.bambu.connected:
 | 
				
			||||||
 | 
					            if self.bambu.publish(commands.STOP):
 | 
				
			||||||
 | 
					                self._logger.info("print cancelled")
 | 
				
			||||||
 | 
					            else:
 | 
				
			||||||
 | 
					                self._logger.info("print cancel failed")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    def _setSdPos(self, pos):
 | 
					    def _setSdPos(self, pos):
 | 
				
			||||||
        self._newSdFilePos = pos
 | 
					        self._newSdFilePos = pos
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@@ -694,9 +706,9 @@ class BambuPrinter:
 | 
				
			|||||||
    def _generateTemperatureOutput(self) -> str:
 | 
					    def _generateTemperatureOutput(self) -> str:
 | 
				
			||||||
        template = "{heater}:{actual:.2f}/ {target:.2f}"
 | 
					        template = "{heater}:{actual:.2f}/ {target:.2f}"
 | 
				
			||||||
        temps = collections.OrderedDict()
 | 
					        temps = collections.OrderedDict()
 | 
				
			||||||
        heater = "T"
 | 
					        temps["T"] = (self.temp[0], self.targetTemp[0])
 | 
				
			||||||
        temps[heater] = (self.temp[0], self.targetTemp[0])
 | 
					 | 
				
			||||||
        temps["B"] = (self.bedTemp, self.bedTargetTemp)
 | 
					        temps["B"] = (self.bedTemp, self.bedTargetTemp)
 | 
				
			||||||
 | 
					        if self._printer_profile_manager.get_current().get("heatedChamber"):
 | 
				
			||||||
            temps["C"] = (self.chamberTemp, self.chamberTargetTemp)
 | 
					            temps["C"] = (self.chamberTemp, self.chamberTargetTemp)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        output = " ".join(
 | 
					        output = " ".join(
 | 
				
			||||||
 
 | 
				
			|||||||
							
								
								
									
										2
									
								
								setup.py
									
									
									
									
									
								
							
							
						
						
									
										2
									
								
								setup.py
									
									
									
									
									
								
							@@ -14,7 +14,7 @@ plugin_package = "octoprint_bambu_printer"
 | 
				
			|||||||
plugin_name = "OctoPrint-BambuPrinter"
 | 
					plugin_name = "OctoPrint-BambuPrinter"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# The plugin's version. Can be overwritten within OctoPrint's internal data via __plugin_version__ in the plugin module
 | 
					# The plugin's version. Can be overwritten within OctoPrint's internal data via __plugin_version__ in the plugin module
 | 
				
			||||||
plugin_version = "0.0.1"
 | 
					plugin_version = "0.0.2"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# The plugin's description. Can be overwritten within OctoPrint's internal data via __plugin_description__ in the plugin
 | 
					# The plugin's description. Can be overwritten within OctoPrint's internal data via __plugin_description__ in the plugin
 | 
				
			||||||
# module
 | 
					# module
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user