bt-sensors-plugin-sk 1.1.0 → 1.2.0-beta.0.0.2
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/BTSensor.js +285 -107
- package/README.md +8 -10
- package/definitions.json +941 -0
- package/index.js +419 -317
- package/package.json +52 -6
- package/plugin_defaults.json +57 -0
- package/public/159.js +2 -0
- package/public/159.js.LICENSE.txt +14 -0
- package/public/30.js +8 -0
- package/public/30.js.LICENSE.txt +65 -0
- package/public/540.js +2 -0
- package/public/540.js.LICENSE.txt +8 -0
- package/public/893.js +1 -0
- package/public/main.js +1 -0
- package/public/remoteEntry.js +1 -0
- package/sensor_classes/ATC.js +31 -20
- package/sensor_classes/BlackListedDevice.js +4 -0
- package/sensor_classes/DEVELOPMENT.md +1 -6
- package/sensor_classes/GoveeH510x.js +3 -3
- package/sensor_classes/IBeacon.js +2 -3
- package/sensor_classes/Inkbird.js +4 -4
- package/sensor_classes/JBDBMS.js +3 -3
- package/sensor_classes/KilovaultHLXPlus.js +1 -1
- package/sensor_classes/MopekaTankSensor.js +13 -6
- package/sensor_classes/Renogy/RenogySensor.js +15 -6
- package/sensor_classes/UNKNOWN.js +8 -4
- package/sensor_classes/UltrasonicWindMeter.js +1 -1
- package/sensor_classes/Victron/VictronSensor.js +6 -2
- package/sensor_classes/VictronBatteryMonitor.js +9 -7
- package/sensor_classes/VictronDCEnergyMeter.js +1 -1
- package/sensor_classes/VictronInverter.js +1 -1
- package/sensor_classes/VictronInverterRS.js +1 -1
- package/sensor_classes/VictronOrionXS.js +1 -1
- package/sensor_classes/XiaomiMiBeacon.js +18 -9
- package/spec/electrical.json +688 -0
- package/spec/environment.json +401 -0
- package/spec/sensors.json +39 -0
- package/spec/tanks.json +115 -0
- package/src/components/PluginConfigurationPanel.js +368 -0
- package/src/index.js +0 -0
- package/webpack.config.js +71 -0
package/package.json
CHANGED
|
@@ -1,25 +1,71 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "bt-sensors-plugin-sk",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.2.0-beta.0.0.2",
|
|
4
4
|
"description": "Bluetooth Sensors for Signalk -- support for Victron devices, RuuviTag, Xiaomi, ATC and Inkbird, Ultrasonic wind meters, Mopeka tank readers, Renogy Battery and Solar Controllers, Aranet4 environment sensors, SwitchBot temp and humidity sensors, KilovaultHLXPlus smart batteries, and Govee GVH51xx temp sensors",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"dependencies": {
|
|
7
|
+
"@rjsf/core": "^5.24.8",
|
|
8
|
+
"@rjsf/utils": "^5.24.8",
|
|
9
|
+
"@rjsf/validator-ajv8": "^5.24.8",
|
|
10
|
+
"better-sse": "^0.14.1",
|
|
7
11
|
"dbus-next": "^0.10.2",
|
|
8
|
-
"
|
|
9
|
-
"int24":"^0.0.1",
|
|
12
|
+
"int24": "^0.0.1",
|
|
10
13
|
"kaitai-struct": "^0.10.0",
|
|
11
|
-
"
|
|
14
|
+
"node-ble": "^1.13.0",
|
|
15
|
+
"semver": "^7.7.1"
|
|
16
|
+
},
|
|
17
|
+
"devDependencies": {
|
|
18
|
+
"@babel/core": "^7.11.6",
|
|
19
|
+
"@babel/preset-react": "^7.10.4",
|
|
20
|
+
"@fortawesome/fontawesome-free": "^5.15.1",
|
|
21
|
+
"@fortawesome/fontawesome-svg-core": "^6.7.2",
|
|
22
|
+
"@fortawesome/free-solid-svg-icons": "^6.7.2",
|
|
23
|
+
"@fortawesome/react-fontawesome": "^0.2.2",
|
|
24
|
+
"@material-ui/core": "^4.12.4",
|
|
25
|
+
"@material-ui/icons": "^4.11.3",
|
|
26
|
+
"@signalk/server-admin-ui-dependencies": "^1.0.0",
|
|
27
|
+
"babel-loader": "^8.1.0",
|
|
28
|
+
"chai": "^4.2.0",
|
|
29
|
+
"css-loader": "^5.0.0",
|
|
30
|
+
"d3": "^6.2.0",
|
|
31
|
+
"file-loader": "^6.1.1",
|
|
32
|
+
"font-awesome": "^4.7.0",
|
|
33
|
+
"mocha": "^8.0.1",
|
|
34
|
+
"prettier-standard": "^6.0.0",
|
|
35
|
+
"react": "^16.13.1",
|
|
36
|
+
"react-bootstrap": "^2.10.9",
|
|
37
|
+
"react-dom": "^16.13.1",
|
|
38
|
+
"react-markdown": "^4.3.1",
|
|
39
|
+
"react-redux": "^5.1.2",
|
|
40
|
+
"react-select": "^3.1.0",
|
|
41
|
+
"reactstrap": "^5.0.0",
|
|
42
|
+
"recharts": "^1.8.5",
|
|
43
|
+
"redux": "^3.7.2",
|
|
44
|
+
"redux-thunk": "2.3.0",
|
|
45
|
+
"simple-line-icons": "^2.5.5",
|
|
46
|
+
"style-loader": "^2.0.0",
|
|
47
|
+
"webpack": "^5.0.0",
|
|
48
|
+
"webpack-cli": "^4.0.0"
|
|
12
49
|
},
|
|
13
50
|
"scripts": {
|
|
14
|
-
"
|
|
51
|
+
"format": "prettier-standard 'index.js'",
|
|
52
|
+
"test": "echo \"Error: no test specified\" && exit 1",
|
|
53
|
+
"prepublishOnly": "npm run clean && npm run build",
|
|
54
|
+
"dev": "webpack --watch --mode development",
|
|
55
|
+
"build": "webpack --mode=production",
|
|
56
|
+
"clean": "rimraf ./public",
|
|
57
|
+
"bundle-analyzer": "webpack-bundle-analyzer --port 4200 public/stats.json"
|
|
15
58
|
},
|
|
16
59
|
"repository": {
|
|
17
60
|
"type": "git",
|
|
18
61
|
"url": "git+https://github.com/naugehyde/bt-sensors-plugin-sk.git"
|
|
19
62
|
},
|
|
20
63
|
"keywords": [
|
|
21
|
-
"signalk-node-server-plugin",
|
|
64
|
+
"signalk-node-server-plugin",
|
|
65
|
+
"signalk-category-hardware",
|
|
66
|
+
"signalk-plugin-configurator"
|
|
22
67
|
],
|
|
68
|
+
"signalk-plugin-enabled-by-default": true,
|
|
23
69
|
"author": "Andrew Gerngross",
|
|
24
70
|
"license": "ISC",
|
|
25
71
|
"bugs": {
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
{
|
|
2
|
+
"params":{
|
|
3
|
+
"name":{
|
|
4
|
+
"description": "Sensor name"
|
|
5
|
+
},
|
|
6
|
+
"location":{
|
|
7
|
+
"description": "Sensor location",
|
|
8
|
+
"examples": ["inside", "outside", "galley", "freezer", "refrigerator", "head", "cabin", "engine", "deck", "cockpit"]
|
|
9
|
+
}
|
|
10
|
+
},
|
|
11
|
+
"environment":{
|
|
12
|
+
"temperature":
|
|
13
|
+
{
|
|
14
|
+
"unit":"K",
|
|
15
|
+
"default": "environment.{location}.temperature"
|
|
16
|
+
},
|
|
17
|
+
"humidity":
|
|
18
|
+
{
|
|
19
|
+
"unit":"ratio",
|
|
20
|
+
"default":"environment.{location}.humidity"
|
|
21
|
+
}
|
|
22
|
+
},
|
|
23
|
+
"electrical":{
|
|
24
|
+
"current":{
|
|
25
|
+
"unit": "A",
|
|
26
|
+
"default":"electrical.batteries.0.current"
|
|
27
|
+
},
|
|
28
|
+
"voltage":
|
|
29
|
+
{
|
|
30
|
+
"unit": "V",
|
|
31
|
+
"default": "electrical.batteries.0.voltage"
|
|
32
|
+
}
|
|
33
|
+
},
|
|
34
|
+
"sensors":{
|
|
35
|
+
"RSSI":
|
|
36
|
+
{
|
|
37
|
+
"unit":"db",
|
|
38
|
+
"default":"sensors.{macAndName}.RSSI",
|
|
39
|
+
"description": "Sensor signal strength in decibels"
|
|
40
|
+
},
|
|
41
|
+
"batteryStrength":
|
|
42
|
+
{
|
|
43
|
+
"unit":"ratio",
|
|
44
|
+
"default":"sensors.{macAndName}.battery.strength",
|
|
45
|
+
"description":"Sensor battery strength"
|
|
46
|
+
},
|
|
47
|
+
|
|
48
|
+
"batteryVoltage":
|
|
49
|
+
{
|
|
50
|
+
"unit":"V",
|
|
51
|
+
"default":"sensors.{macAndName}.battery.voltage",
|
|
52
|
+
"description":"Sensor battery voltage"
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
}
|
package/public/159.js
ADDED
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
/*! For license information please see 159.js.LICENSE.txt */
|
|
2
|
+
"use strict";(self.webpackChunkbt_sensors_plugin_sk=self.webpackChunkbt_sensors_plugin_sk||[]).push([[159,540],{5228:e=>{var r=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable;e.exports=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var r={},t=0;t<10;t++)r["_"+String.fromCharCode(t)]=t;if("0123456789"!==Object.getOwnPropertyNames(r).map((function(e){return r[e]})).join(""))return!1;var n={};return"abcdefghijklmnopqrst".split("").forEach((function(e){n[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},n)).join("")}catch(e){return!1}}()?Object.assign:function(e,o){for(var u,c,f=function(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}(e),l=1;l<arguments.length;l++){for(var i in u=Object(arguments[l]))t.call(u,i)&&(f[i]=u[i]);if(r){c=r(u);for(var a=0;a<c.length;a++)n.call(u,c[a])&&(f[c[a]]=u[c[a]])}}return f}},5287:(e,r,t)=>{var n=t(5228),o="function"==typeof Symbol&&Symbol.for,u=o?Symbol.for("react.element"):60103,c=o?Symbol.for("react.portal"):60106,f=o?Symbol.for("react.fragment"):60107,l=o?Symbol.for("react.strict_mode"):60108,i=o?Symbol.for("react.profiler"):60114,a=o?Symbol.for("react.provider"):60109,s=o?Symbol.for("react.context"):60110,p=o?Symbol.for("react.forward_ref"):60112,y=o?Symbol.for("react.suspense"):60113,d=o?Symbol.for("react.memo"):60115,h=o?Symbol.for("react.lazy"):60116,b="function"==typeof Symbol&&Symbol.iterator;function v(e){for(var r="https://reactjs.org/docs/error-decoder.html?invariant="+e,t=1;t<arguments.length;t++)r+="&args[]="+encodeURIComponent(arguments[t]);return"Minified React error #"+e+"; visit "+r+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var m={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},_={};function g(e,r,t){this.props=e,this.context=r,this.refs=_,this.updater=t||m}function S(){}function k(e,r,t){this.props=e,this.context=r,this.refs=_,this.updater=t||m}g.prototype.isReactComponent={},g.prototype.setState=function(e,r){if("object"!=typeof e&&"function"!=typeof e&&null!=e)throw Error(v(85));this.updater.enqueueSetState(this,e,r,"setState")},g.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")},S.prototype=g.prototype;var w=k.prototype=new S;w.constructor=k,n(w,g.prototype),w.isPureReactComponent=!0;var j={current:null},O=Object.prototype.hasOwnProperty,C={key:!0,ref:!0,__self:!0,__source:!0};function $(e,r,t){var n,o={},c=null,f=null;if(null!=r)for(n in void 0!==r.ref&&(f=r.ref),void 0!==r.key&&(c=""+r.key),r)O.call(r,n)&&!C.hasOwnProperty(n)&&(o[n]=r[n]);var l=arguments.length-2;if(1===l)o.children=t;else if(1<l){for(var i=Array(l),a=0;a<l;a++)i[a]=arguments[a+2];o.children=i}if(e&&e.defaultProps)for(n in l=e.defaultProps)void 0===o[n]&&(o[n]=l[n]);return{$$typeof:u,type:e,key:c,ref:f,props:o,_owner:j.current}}function E(e){return"object"==typeof e&&null!==e&&e.$$typeof===u}var P=/\/+/g,x=[];function R(e,r,t,n){if(x.length){var o=x.pop();return o.result=e,o.keyPrefix=r,o.func=t,o.context=n,o.count=0,o}return{result:e,keyPrefix:r,func:t,context:n,count:0}}function A(e){e.result=null,e.keyPrefix=null,e.func=null,e.context=null,e.count=0,10>x.length&&x.push(e)}function I(e,r,t,n){var o=typeof e;"undefined"!==o&&"boolean"!==o||(e=null);var f=!1;if(null===e)f=!0;else switch(o){case"string":case"number":f=!0;break;case"object":switch(e.$$typeof){case u:case c:f=!0}}if(f)return t(n,e,""===r?"."+U(e,0):r),1;if(f=0,r=""===r?".":r+":",Array.isArray(e))for(var l=0;l<e.length;l++){var i=r+U(o=e[l],l);f+=I(o,i,t,n)}else if("function"==typeof(i=null===e||"object"!=typeof e?null:"function"==typeof(i=b&&e[b]||e["@@iterator"])?i:null))for(e=i.call(e),l=0;!(o=e.next()).done;)f+=I(o=o.value,i=r+U(o,l++),t,n);else if("object"===o)throw t=""+e,Error(v(31,"[object Object]"===t?"object with keys {"+Object.keys(e).join(", ")+"}":t,""));return f}function q(e,r,t){return null==e?0:I(e,"",r,t)}function U(e,r){return"object"==typeof e&&null!==e&&null!=e.key?function(e){var r={"=":"=0",":":"=2"};return"$"+(""+e).replace(/[=:]/g,(function(e){return r[e]}))}(e.key):r.toString(36)}function F(e,r){e.func.call(e.context,r,e.count++)}function L(e,r,t){var n=e.result,o=e.keyPrefix;e=e.func.call(e.context,r,e.count++),Array.isArray(e)?M(e,n,t,(function(e){return e})):null!=e&&(E(e)&&(e=function(e,r){return{$$typeof:u,type:e.type,key:r,ref:e.ref,props:e.props,_owner:e._owner}}(e,o+(!e.key||r&&r.key===e.key?"":(""+e.key).replace(P,"$&/")+"/")+t)),n.push(e))}function M(e,r,t,n,o){var u="";null!=t&&(u=(""+t).replace(P,"$&/")+"/"),q(e,L,r=R(r,u,n,o)),A(r)}var N={current:null};function D(){var e=N.current;if(null===e)throw Error(v(321));return e}var T={ReactCurrentDispatcher:N,ReactCurrentBatchConfig:{suspense:null},ReactCurrentOwner:j,IsSomeRendererActing:{current:!1},assign:n};r.Children={map:function(e,r,t){if(null==e)return e;var n=[];return M(e,n,null,r,t),n},forEach:function(e,r,t){if(null==e)return e;q(e,F,r=R(null,null,r,t)),A(r)},count:function(e){return q(e,(function(){return null}),null)},toArray:function(e){var r=[];return M(e,r,null,(function(e){return e})),r},only:function(e){if(!E(e))throw Error(v(143));return e}},r.Component=g,r.Fragment=f,r.Profiler=i,r.PureComponent=k,r.StrictMode=l,r.Suspense=y,r.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=T,r.cloneElement=function(e,r,t){if(null==e)throw Error(v(267,e));var o=n({},e.props),c=e.key,f=e.ref,l=e._owner;if(null!=r){if(void 0!==r.ref&&(f=r.ref,l=j.current),void 0!==r.key&&(c=""+r.key),e.type&&e.type.defaultProps)var i=e.type.defaultProps;for(a in r)O.call(r,a)&&!C.hasOwnProperty(a)&&(o[a]=void 0===r[a]&&void 0!==i?i[a]:r[a])}var a=arguments.length-2;if(1===a)o.children=t;else if(1<a){i=Array(a);for(var s=0;s<a;s++)i[s]=arguments[s+2];o.children=i}return{$$typeof:u,type:e.type,key:c,ref:f,props:o,_owner:l}},r.createContext=function(e,r){return void 0===r&&(r=null),(e={$$typeof:s,_calculateChangedBits:r,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null}).Provider={$$typeof:a,_context:e},e.Consumer=e},r.createElement=$,r.createFactory=function(e){var r=$.bind(null,e);return r.type=e,r},r.createRef=function(){return{current:null}},r.forwardRef=function(e){return{$$typeof:p,render:e}},r.isValidElement=E,r.lazy=function(e){return{$$typeof:h,_ctor:e,_status:-1,_result:null}},r.memo=function(e,r){return{$$typeof:d,type:e,compare:void 0===r?null:r}},r.useCallback=function(e,r){return D().useCallback(e,r)},r.useContext=function(e,r){return D().useContext(e,r)},r.useDebugValue=function(){},r.useEffect=function(e,r){return D().useEffect(e,r)},r.useImperativeHandle=function(e,r,t){return D().useImperativeHandle(e,r,t)},r.useLayoutEffect=function(e,r){return D().useLayoutEffect(e,r)},r.useMemo=function(e,r){return D().useMemo(e,r)},r.useReducer=function(e,r,t){return D().useReducer(e,r,t)},r.useRef=function(e){return D().useRef(e)},r.useState=function(e){return D().useState(e)},r.version="16.14.0"},6540:(e,r,t)=>{e.exports=t(5287)}}]);
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/*
|
|
2
|
+
object-assign
|
|
3
|
+
(c) Sindre Sorhus
|
|
4
|
+
@license MIT
|
|
5
|
+
*/
|
|
6
|
+
|
|
7
|
+
/** @license React v16.14.0
|
|
8
|
+
* react.production.min.js
|
|
9
|
+
*
|
|
10
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
11
|
+
*
|
|
12
|
+
* This source code is licensed under the MIT license found in the
|
|
13
|
+
* LICENSE file in the root directory of this source tree.
|
|
14
|
+
*/
|