From 93a7594dec6a9abc10ffe866e6834e200ca4328a Mon Sep 17 00:00:00 2001 From: Joseph Coffland Date: Thu, 23 Aug 2018 17:42:19 -0700 Subject: [PATCH] Increased display precision of position and motor config. --- CHANGELOG.md | 3 +++ package.json | 2 +- src/jade/templates/control-view.jade | 2 +- src/js/templated-input.js | 4 ++-- 4 files changed, 7 insertions(+), 4 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index b7293e3..f0c8e08 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,9 @@ Buildbotics CNC Controller Firmware Changelog ============================================== +## v0.3.29 + - Increased display precision of position and motor config. + ## v0.3.28 - Show step rate on motor configuration page. - Limit motor max-velocity such that step rate cannot exceed 250k. diff --git a/package.json b/package.json index aa5b3cd..5992cd8 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "bbctrl", - "version": "0.3.28", + "version": "0.3.29", "homepage": "http://buildbotics.com/", "repository": "https://github.com/buildbotics/bbctrl-firmware", "license": "GPL-3.0+", diff --git a/src/jade/templates/control-view.jade b/src/jade/templates/control-view.jade index d4e0963..9eae06f 100644 --- a/src/jade/templates/control-view.jade +++ b/src/jade/templates/control-view.jade @@ -47,7 +47,7 @@ script#control-view-template(type="text/x-template") th.name #{axis} td.position unit-value(:value="state.#{axis}p + get_offset('#{axis}')", - precision="3") + precision="4") td.absolute: unit-value(:value="state.#{axis}p", precision="3") td.offset: unit-value(:value="get_offset('#{axis}')", precision="3") th.actions diff --git a/src/js/templated-input.js b/src/js/templated-input.js index 7509806..a775934 100644 --- a/src/js/templated-input.js +++ b/src/js/templated-input.js @@ -60,14 +60,14 @@ module.exports = { methods: { set_view: function () { if (this.template.scale && !this.metric) - this.view = (this.model / this.template.scale).toFixed(2); + this.view = (this.model / this.template.scale).toFixed(3); else this.view = this.model; }, change: function () { if (this.template.scale && !this.metric) - this.model = 1 * (this.view * this.template.scale).toFixed(3); + this.model = 1 * (this.view * this.template.scale).toFixed(4); else this.model = this.view; this.$dispatch('input-changed'); -- 2.27.0