virtual_sdcard: register sd static path

Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
This commit is contained in:
Arksine 2020-08-09 08:36:02 -04:00 committed by KevinOConnor
parent 0c7faa978c
commit e4f3f60ea6
1 changed files with 3 additions and 0 deletions

View File

@ -35,6 +35,9 @@ class VirtualSD:
self.gcode.register_command(
"SDCARD_PRINT_FILE", self.cmd_SDCARD_PRINT_FILE,
desc=self.cmd_SDCARD_PRINT_FILE_help)
# Register sd path
webhooks = printer.lookup_object('webhooks')
webhooks.register_static_path("sd_path", self.sdcard_dirname)
def handle_shutdown(self):
if self.work_timer is not None:
self.must_pause_work = True