signalk-polar-performance-plugin 0.0.53 → 0.0.54

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "signalk-polar-performance-plugin",
3
- "version": "0.0.53",
3
+ "version": "0.0.54",
4
4
  "description": "A plugin that calculates performance information based on a (CSV) polar diagram.",
5
5
  "main": "plugin/index.js",
6
6
  "scripts": {
package/plugin/index.js CHANGED
@@ -19,11 +19,6 @@ module.exports = function (app) {
19
19
  var schema = {
20
20
  // The plugin schema
21
21
  properties: {
22
- trueWindSpeedPath: {
23
- type: 'string',
24
- default: 'environment.wind.speedTrue',
25
- title: 'Wind speed path (TWS) to use'
26
- },
27
22
  useTWSsource: {
28
23
  type: 'string',
29
24
  default: '',
@@ -144,7 +139,7 @@ module.exports = function (app) {
144
139
  minPeriod: 500
145
140
  },
146
141
  {
147
- path: trueWindSpeedPath,
142
+ path: 'environment.wind.speedTrue',
148
143
  policy: 'instant',
149
144
  minPeriod: 500
150
145
  },
@@ -210,10 +205,10 @@ module.exports = function (app) {
210
205
  } else if (delta.path == 'navigation.headingTrue') {
211
206
  HDG = delta.value
212
207
  // app.debug('heading (HDG): %d', HDG)
213
- } else if (delta.path == trueWindSpeedPath) {
208
+ } else if (delta.path == 'environment.wind.speedTrue') {
214
209
  if (options.useTWSsource == '' || source == options.useTWSsource) {
215
210
  TWS = applyDamping(delta.value, 'TWS', options.dampingTWS || 0)
216
- // app.debug('%s (TWS): %d applyDamping: %d', trueWindSpeedPath, delta.value, TWS)
211
+ // app.debug('(TWS): %d applyDamping: %d', delta.value, TWS)
217
212
  // app.debug('TWS: %d TWA: %d BSP: %d', msToKts(TWS), radToDeg(TWA)*port, msToKts(BSP))
218
213
  sendUpdates(getPerformanceData(TWS, TWA, BSP))
219
214
  }