Skip to content

Commit

Permalink
SW-2348 implement not powered air filter screen (#1837)
Browse files Browse the repository at this point in the history
- refactoring ready to laser
- adding af3 not powered screen
- remove old stuff
- fix compressor 0 rpm recover bug
  • Loading branch information
Josef-MrBeam committed Nov 23, 2023
1 parent 350439a commit 4584847
Show file tree
Hide file tree
Showing 11 changed files with 354 additions and 440 deletions.
1 change: 1 addition & 0 deletions octoprint_mrbeam/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2940,6 +2940,7 @@ def get_mrb_state(self):
fan_state=self.dust_manager.get_fan_state(),
fan_rpm=self.dust_manager.get_fan_rpm(),
fan_dust=self.dust_manager.get_dust(),
fan_external_power=self.airfilter.external_power,
compressor_state=self.compressor_handler.get_current_state(),
lid_fully_open=self.lid_handler.is_lid_open(),
interlocks_closed=self.iobeam.is_interlock_closed(),
Expand Down
9 changes: 7 additions & 2 deletions octoprint_mrbeam/iobeam/airfilter.py
Original file line number Diff line number Diff line change
Expand Up @@ -228,6 +228,13 @@ def temperatures(self):
}
return None

@property
def external_power(self):
if self.is_airfilter3():
return self._external_power
else:
return None

def set_airfilter(self, model_id, serial):
"""Sets the air filter.
Expand Down Expand Up @@ -391,8 +398,6 @@ def pressure_drop_prefilter(self):

@property
def connected(self):
if self.is_airfilter3() and not self._external_power:
return False
return self._connected

@connected.setter
Expand Down
2 changes: 2 additions & 0 deletions octoprint_mrbeam/iobeam/compressor_handler.py
Original file line number Diff line number Diff line change
Expand Up @@ -190,6 +190,8 @@ def _handle_dynamic_data(self, payload):
)
else:
self._num_rpm_0 = 0
elif "rpm_actual" in dataset and not self._printer.is_printing():
self._num_rpm_0 = 0
else:
self._logger.warn(
"Received empty compressor_dynamic_data dataset. compressor_dynamic_data: %s",
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit 4584847

Please sign in to comment.