Bug Fix
This commit is contained in:
@@ -165,7 +165,10 @@ class EnclosurePlugin(octoprint.plugin.StartupPlugin,
|
||||
|
||||
def handleFilamentDetection(self,channel):
|
||||
if self._printer.is_printing():
|
||||
if ~(self._settings.get(["filamentSensorActiveLow"]) ^ (not GPIO.input(self.filamentSensor.pinNumber))):
|
||||
if self._settings.get(["filamentSensorActiveLow"]) and (not GPIO.input(self.filamentSensor.pinNumber)):
|
||||
self._logger.info("Detected end of filament.")
|
||||
self._printer.toggle_pause_print()
|
||||
elif (not self._settings.get(["filamentSensorActiveLow"])) and GPIO.input(self.filamentSensor.pinNumber):
|
||||
self._logger.info("Detected end of filament.")
|
||||
self._printer.toggle_pause_print()
|
||||
|
||||
|
||||
2
setup.py
2
setup.py
@@ -14,7 +14,7 @@ plugin_package = "octoprint_enclosure"
|
||||
plugin_name = "OctoPrint-Enclosure"
|
||||
|
||||
# The plugin's version. Can be overwritten within OctoPrint's internal data via __plugin_version__ in the plugin module
|
||||
plugin_version = "1.9"
|
||||
plugin_version = "2.0"
|
||||
|
||||
# The plugin's description. Can be overwritten within OctoPrint's internal data via __plugin_description__ in the plugin
|
||||
# module
|
||||
|
||||
Reference in New Issue
Block a user