Skip to content

Commit

Permalink
Merge branch 'v3.5-dev' into feature/viewer_quick_color_change
Browse files Browse the repository at this point in the history
  • Loading branch information
Sindarius committed Apr 14, 2023
2 parents bb0129a + 8efd644 commit 56ea0fb
Show file tree
Hide file tree
Showing 8 changed files with 248 additions and 253 deletions.
432 changes: 205 additions & 227 deletions package-lock.json

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "duetwebcontrol",
"version": "3.5.0-beta.3+pre2",
"version": "3.5.0-beta.3",
"author": "Christian Hammacher <christian@duet3d.com> (https://www.duet3d.com)",
"homepage": "https://forum.duet3d.com/category/27/duet-web-control",
"license": "GPL-3.0",
Expand All @@ -25,7 +25,7 @@
"date-fns": "^2.17.0",
"file-saver": "^2.0.5",
"jszip": "^3.6.0",
"monaco-editor": "^0.36.1",
"monaco-editor": "^0.37.1",
"piecon": "^0.5.0",
"qoijs": "^1.0.0",
"register-service-worker": "^1.7.2",
Expand Down
13 changes: 8 additions & 5 deletions src/components/dialogs/IncompatibleVersionsDialog.vue
Original file line number Diff line number Diff line change
Expand Up @@ -52,19 +52,22 @@ export default Vue.extend({
if (mainboardVersion) {
// Check expansion board firmware versions
for (const board of store.state.machine.model.boards) {
if (board.canAddress && semver.compare(mainboardVersion, board.firmwareVersion) !== 0) {
if (board.canAddress && board.firmwareVersion && semver.compare(mainboardVersion, board.firmwareVersion) !== 0) {
console.warn(`Expansion board #${board.canAddress} version mismatch (MB ${mainboardVersion} != EXP ${board.firmwareVersion}`);
versionMismatch = true;
}
}
// Check DSF version
if (!versionMismatch && store.state.machine.model.state.dsfVersion !== null) {
versionMismatch = semver.compare(mainboardVersion, store.state.machine.model.state.dsfVersion) !== 0;
if (!versionMismatch && store.state.machine.model.state.dsfVersion !== null && semver.compare(mainboardVersion, store.state.machine.model.state.dsfVersion) !== 0) {
console.warn(`DSF version mismatch (MB ${mainboardVersion} != DSF ${store.state.machine.model.state.dsfVersion}`);
versionMismatch = true;
}
// Check DWC version
if (!versionMismatch) {
versionMismatch = semver.compare(mainboardVersion, packageInfo.version) !== 0;
if (!versionMismatch && semver.compare(mainboardVersion, packageInfo.version) !== 0) {
console.warn(`DWC version mismatch (MB ${mainboardVersion} != DWC ${packageInfo.version}`);
versionMismatch = true;
}
}
Expand Down
6 changes: 1 addition & 5 deletions src/components/panels/MovementPanel.vue
Original file line number Diff line number Diff line change
Expand Up @@ -45,12 +45,8 @@
<v-icon class="mr-1">mdi-format-vertical-align-center</v-icon>
{{ isDelta ? $t("panel.movement.runDelta") : $t("panel.movement.runBed") }}
</v-list-item>
<v-list-item :disabled="!isCompensationEnabled" @click="sendCode('M561')">
<v-icon class="mr-1">mdi-border-none</v-icon>
{{ $t("panel.movement.disableBedCompensation") }}
</v-list-item>

<v-divider></v-divider>
<v-divider />

<v-list-item :disabled="!canHome" @click="sendCode('G29')">
<v-icon class="mr-1">mdi-grid</v-icon>
Expand Down
17 changes: 11 additions & 6 deletions src/components/panels/SettingsElectronicsPanel.vue
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
<style scoped>
th {
padding: 0 16px;
text-align: left;
}
</style>

<template>
<v-card outlined>
<v-card-title>
Expand Down Expand Up @@ -43,7 +50,7 @@
Duet WiFi Server
</td>
<td>
<!-- n/a -->
{{ $t("generic.noValue") }}
</td>
<td>
{{ wifiVersion }}
Expand Down Expand Up @@ -72,18 +79,16 @@
DWC
</td>
<td :title="$t('panel.settingsAbout.buildDateTime', [buildDateTime])">
{{ dsfVersion }}
{{ dwcVersion }}
</td>
</tr>
</tbody>
<tfoot>
<upload-btn v-if="!isRestConnector || !isDuetFirmware" target="update" color="primary"
class="mt-3 d-flex justify-center" />
</tfoot>
</v-simple-table>
<v-card-text v-else>
{{ $t("panel.settingsElectronics.notConnected") }}
</v-card-text>

<upload-btn v-if="!isRestConnector || !isDuetFirmware" class="my-3 d-flex justify-center" target="update" color="primary" />
</v-card>
</template>

Expand Down
21 changes: 17 additions & 4 deletions src/plugins/InputShaping/InputShapingFileList.vue
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,9 @@
<v-list-item-subtitle class="no-overflow">
{{ profile.subtitle }}
</v-list-item-subtitle>
<v-list-item-subtitle v-if="profile.secondSubtitle" class="no-overflow">
{{ profile.secondSubtitle }}
</v-list-item-subtitle>
</v-list-item-content>
<v-list-item-icon v-if="canDelete" class="align-self-center" @click.stop.prevent="deleteProfile(profile)">
<v-icon>
Expand All @@ -66,6 +69,9 @@
<v-list-item-subtitle class="no-overflow">
{{ profile.subtitle }}
</v-list-item-subtitle>
<v-list-item-subtitle v-if="profile.secondSubtitle" class="no-overflow">
{{ profile.secondSubtitle }}
</v-list-item-subtitle>
</v-list-item-content>
</template>

Expand Down Expand Up @@ -149,7 +155,7 @@ export default {
// Convert files into profile groups with files
const profiles = [], uncategorized = [];
for (let filename of this.files) {
const matches = /^(\d+)-([a-zA-SU-Z]+)(-?\d+\.?\d*)-(-?\d+\.?\d*)-(\d+\.?\d*)-(\w+)-?(\d+\.?\d*)?(Hz)?\.csv/.exec(filename);
const matches = /^(\d+)-([a-zA-SU-Z]+)(-?\d+\.?\d*)-(-?\d+\.?\d*)-(\d+\.?\d*)-(\w+)-?(\d+\.?\d*)?(Hz)?(-(\d+\.?\d*))?\.csv/.exec(filename);
if (matches) {
const title = `Profile #${matches[1]}`;
let run = profiles.find(profile => profile.title === title);
Expand All @@ -164,13 +170,15 @@ export default {
}
const shaperTitle = (matches[6] === 'none') ? 'No Shaping' : ((matches[6] === 'custom') ? 'Custom' : `${matches[6].toUpperCase()} @ ${matches[7]}Hz`);
const dampingFactor = isNaN(matches[9]) ? null : `Damping Factor ${matches[9]}`;
run.files.push({
title: `${matches[2].split('').reduce((a, b) => `${a}+${b}`)} ${matches[3]}-${matches[4]}, accelerometer ${matches[5]}, ${shaperTitle}`,
filename,
shaperTitle
shaperTitle,
dampingFactor
});
} else {
const toolMatches = /^(\d+)-T(\d+)-([a-zA-Z]+)(-?\d+\.?\d*)-(-?\d+\.?\d*)-(\d+\.?\d*)-(\w+)[-]?(\d+\.?\d*)?(Hz)?\.csv/.exec(filename);
const toolMatches = /^(\d+)-T(\d+)-([a-zA-Z]+)(-?\d+\.?\d*)-(-?\d+\.?\d*)-(\d+\.?\d*)-(\w+)[-]?(\d+\.?\d*)?(Hz)?(-(\d+\.?\d*))?\.csv/.exec(filename);
if (toolMatches) {
const title = `Profile #${toolMatches[1]}`;
let run = profiles.find(profile => profile.title === title);
Expand All @@ -185,10 +193,12 @@ export default {
}
const shaperTitle = (toolMatches[7] === 'none') ? 'No Shaping' : ((toolMatches[7] === 'custom') ? 'Custom' : `${toolMatches[7].toUpperCase()} @ ${toolMatches[8]}Hz`);
const dampingFactor = isNaN(matches[10]) ? null : `Damping Factor ${matches[10]}`;
run.files.push({
title: `T${toolMatches[2]}, ${toolMatches[3].split('').reduce((a, b) => `${a}+${b}`)} ${toolMatches[4]}-${toolMatches[5]}, accelerometer ${toolMatches[6]}, ${shaperTitle}`,
filename,
shaperTitle
shaperTitle,
dampingFactor
});
} else {
const filenameMatch = /(.+)\.csv$/.exec(filename);
Expand All @@ -214,8 +224,10 @@ export default {
}
}
profile.subtitle = `${allEqual ? shaperTitles[0] : 'Multiple configs'}, ${profile.files.length} moves`;
profile.secondSubtitle = profile.files[0].dampingFactor;
} else {
profile.subtitle = `${profile.files.length} moves`;
profile.secondSubtitle = null;
}
}
Expand All @@ -225,6 +237,7 @@ export default {
icon: 'mdi-file-multiple',
title: 'Uncategorized',
subtitle: `${uncategorized.length} files`,
secondSubtitle: null,
files: uncategorized
});
}
Expand Down
2 changes: 1 addition & 1 deletion src/plugins/InputShaping/RecordMotionProfileDialog.vue
Original file line number Diff line number Diff line change
Expand Up @@ -475,7 +475,7 @@ export default {
}
filename += `-${move.axis.replace(/\+/g, '')}${move.start}-${move.end}-${move.accelerometer}-${this.move.shaping.type}`;
if (this.move.shaping.type !== 'none' && this.move.shaping.type !== 'custom') {
filename += `-${this.move.shaping.frequency}Hz`;
filename += `-${this.move.shaping.frequency}Hz-${this.move.shaping.damping}`;
}
filename += '.csv';
return filename;
Expand Down
6 changes: 3 additions & 3 deletions src/store/machine/connector/PollConnector.ts
Original file line number Diff line number Diff line change
Expand Up @@ -763,7 +763,7 @@ export default class PollConnector extends BaseConnector {
}

// Send the code to RRF
const response = await this.request("GET", "rr_gcode", { gcode: code });
const seq = this.lastSeqs.reply, response = await this.request("GET", "rr_gcode", { gcode: code });
if (!(response instanceof Object)) {
console.warn(`Received bad response for rr_gcode: ${JSON.stringify(response)}`);
throw new CodeResponseError();
Expand All @@ -777,8 +777,8 @@ export default class PollConnector extends BaseConnector {
}

// Check if a response can be expected
if (!noWait && strippedCode !== "" && strippedCode.toUpperCase().indexOf("M997") === -1 && strippedCode.toUpperCase().indexOf("M999") === -1) {
const pendingCodes = this.pendingCodes, seq = this.lastSeqs.reply;
if (!noWait && seq === this.lastSeqs.reply && strippedCode !== "" && strippedCode.toUpperCase().indexOf("M997") === -1 && strippedCode.toUpperCase().indexOf("M999") === -1) {
const pendingCodes = this.pendingCodes;
return new Promise<string>((resolve, reject) => pendingCodes.push({ seq, resolve, reject }));
}
}
Expand Down

0 comments on commit 56ea0fb

Please sign in to comment.