mirror of
https://github.com/Doodle3D/Doodle3D-Slicer.git
synced 2024-11-22 05:37:55 +01:00
add idle check for doodle3d printer
This commit is contained in:
parent
21bd6c4714
commit
67b4084e55
@ -156,8 +156,8 @@ export async function slice(target, name, mesh, settings, updateProgress) {
|
|||||||
break;
|
break;
|
||||||
case 'WIFI':
|
case 'WIFI':
|
||||||
if (settings.printer === 'doodle3d_printer') {
|
if (settings.printer === 'doodle3d_printer') {
|
||||||
// const { state } = await getMalyanStatus(settings.ip);
|
const { state } = await getMalyanStatus(settings.ip);
|
||||||
// if (state !== 'idle') throw { message: 'printer must be idle before starting a print', code: 0 };
|
if (state !== 'idle') throw { message: 'printer must be idle before starting a print', code: 0 };
|
||||||
} else {
|
} else {
|
||||||
wifiBox = new Doodle3DBox(settings.ip);
|
wifiBox = new Doodle3DBox(settings.ip);
|
||||||
if (!await wifiBox.checkAlive()) throw { message: `can't connect to printer`, code: 4 }
|
if (!await wifiBox.checkAlive()) throw { message: `can't connect to printer`, code: 4 }
|
||||||
|
Loading…
Reference in New Issue
Block a user