NEWS
Datenpunkt von ioBroker nach Variable in CCU schreiben
-
Hallo paul53
Die Fehlermeldung kommt auch nur bei einem Bindeblock.14:20:01.795 warn javascript.0 at Object.<anonymous> (script.js.common.Test.Weatherman1:5:5)
14:21:02.162 warn javascript.0 at Object.<anonymous> (script.js.common.Test.Weatherman1:5:5)
14:21:02.165 warn javascript.0 at Object.<anonymous> (script.js.common.Test.Weatherman1:5:5)
14:21:15.506 warn javascript.0 at Object.<anonymous> (script.js.common.Test.Weatherman1:5:5)
14:21:15.511 warn javascript.0 at Object.<anonymous> (script.js.common.Test.Weatherman1:5:5)
14:21:15.512 warn javascript.0 at Object.<anonymous> (script.js.common.Test.Weatherman1:5:5)Hier der Blockly-Code:
on({id: "wiffi-wz.0.root.192_168_1_13.Systeminfo.zeitpunkt"/*zeitpunkt*/, change: "any"}, function (obj) { var value = obj.state.val; var oldValue = obj.oldState.val; on({id: 'wiffi-wz.0.root.192_168_1_13.w_lux', change: "ne"}, function (obj) { setState('hm-rega.0.3716', obj.state.val); });});Hast Du eventuell einen Tipp?
Ich würde es gerne auch in JS schreiben, doch es sind 28 Datenpunkte die überprüft werde sollen und nur die jeweiligen Änderung auf die CCU geschrieben werden. Der Datenpunkt Zeitpunkt wird immer aktuallisiert und soll der Trigger sein.
-
Hallo paul53
Die Fehlermeldung kommt auch nur bei einem Bindeblock.14:20:01.795 warn javascript.0 at Object.<anonymous> (script.js.common.Test.Weatherman1:5:5)
14:21:02.162 warn javascript.0 at Object.<anonymous> (script.js.common.Test.Weatherman1:5:5)
14:21:02.165 warn javascript.0 at Object.<anonymous> (script.js.common.Test.Weatherman1:5:5)
14:21:15.506 warn javascript.0 at Object.<anonymous> (script.js.common.Test.Weatherman1:5:5)
14:21:15.511 warn javascript.0 at Object.<anonymous> (script.js.common.Test.Weatherman1:5:5)
14:21:15.512 warn javascript.0 at Object.<anonymous> (script.js.common.Test.Weatherman1:5:5)Hier der Blockly-Code:
on({id: "wiffi-wz.0.root.192_168_1_13.Systeminfo.zeitpunkt"/*zeitpunkt*/, change: "any"}, function (obj) { var value = obj.state.val; var oldValue = obj.oldState.val; on({id: 'wiffi-wz.0.root.192_168_1_13.w_lux', change: "ne"}, function (obj) { setState('hm-rega.0.3716', obj.state.val); });});Hast Du eventuell einen Tipp?
Ich würde es gerne auch in JS schreiben, doch es sind 28 Datenpunkte die überprüft werde sollen und nur die jeweiligen Änderung auf die CCU geschrieben werden. Der Datenpunkt Zeitpunkt wird immer aktuallisiert und soll der Trigger sein.
-
Habe ich jetzt versucht, doch es kommen immer noch Warnmeldungen...
Hier der Blockly-Code:

on({id: 'wiffi-wz.0.root.192_168_1_13.w_ip', change: "ne"}, function (obj) { setState('hm-rega.0.4026', obj.state.val); }); on({id: 'wiffi-wz.0.root.192_168_1_13.w_temperatur', change: "ne"}, function (obj) { setState('hm-rega.0.3707', obj.state.val); }); on({id: 'wiffi-wz.0.root.192_168_1_13.w_feuchte_rel', change: "ne"}, function (obj) { setState('hm-rega.0.3708', obj.state.val); }); on({id: 'wiffi-wz.0.root.192_168_1_13.w_barometer', change: "ne"}, function (obj) { setState('hm-rega.0.3709', obj.state.val); }); on({id: 'wiffi-wz.0.root.192_168_1_13.w_wind_mittel', change: "ne"}, function (obj) { setState('hm-rega.0.3710', obj.state.val); }) -
Habe ich jetzt versucht, doch es kommen immer noch Warnmeldungen...
Hier der Blockly-Code:

on({id: 'wiffi-wz.0.root.192_168_1_13.w_ip', change: "ne"}, function (obj) { setState('hm-rega.0.4026', obj.state.val); }); on({id: 'wiffi-wz.0.root.192_168_1_13.w_temperatur', change: "ne"}, function (obj) { setState('hm-rega.0.3707', obj.state.val); }); on({id: 'wiffi-wz.0.root.192_168_1_13.w_feuchte_rel', change: "ne"}, function (obj) { setState('hm-rega.0.3708', obj.state.val); }); on({id: 'wiffi-wz.0.root.192_168_1_13.w_barometer', change: "ne"}, function (obj) { setState('hm-rega.0.3709', obj.state.val); }); on({id: 'wiffi-wz.0.root.192_168_1_13.w_wind_mittel', change: "ne"}, function (obj) { setState('hm-rega.0.3710', obj.state.val); }) -
Jep, die Daten werden geschrieben.
Hier die Datenpunkte im ioBroker:

In der CCU sind alle SV als Zahl ausser...
Zeichenkette = w_barotrend und w_windrichtung
Logikwert = w_regenmelder und w_sonne_scheint -
Hier die Daten vom Datenpunkt w_barometer:
{
"from": "system.adapter.wiffi-wz.0",
"ts": 1557058406498,
"common": {
"name": 3,
"desc": "nn_luftdruck",
"unit": "mb",
"role": "value.pressure",
"id": "w_barometer",
"type": "number",
"read": true,
"write": false
},
"native": {},
"acl": {
"object": 1638,
"owner": "system.user.admin",
"ownerGroup": "system.group.administrator",
"state": 1638
},
"_id": "wiffi-wz.0.root.192_168_1_13.w_barometer",
"type": "state"
} -
Hier die Daten vom Datenpunkt w_barometer:
{
"from": "system.adapter.wiffi-wz.0",
"ts": 1557058406498,
"common": {
"name": 3,
"desc": "nn_luftdruck",
"unit": "mb",
"role": "value.pressure",
"id": "w_barometer",
"type": "number",
"read": true,
"write": false
},
"native": {},
"acl": {
"object": 1638,
"owner": "system.user.admin",
"ownerGroup": "system.group.administrator",
"state": 1638
},
"_id": "wiffi-wz.0.root.192_168_1_13.w_barometer",
"type": "state"
} -
javascript.0 2019-05-05 17:55:53.656 warn at TCP.onread (net.js:601:20) javascript.0 2019-05-05 17:55:53.656 warn at Socket.Readable.push (_stream_readable.js:208:10) javascript.0 2019-05-05 17:55:53.656 warn at readableAddChunk (_stream_readable.js:250:11) javascript.0 2019-05-05 17:55:53.656 warn at addChunk (_stream_readable.js:263:12) javascript.0 2019-05-05 17:55:53.656 warn at Socket.emit (events.js:211:7) javascript.0 2019-05-05 17:55:53.656 warn at emitOne (events.js:116:13) javascript.0 2019-05-05 17:55:53.656 warn at Socket._ultron.on (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/ws/lib/WebSocket.js:138:22) javascript.0 2019-05-05 17:55:53.656 warn at Receiver.add (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/ws/lib/Receiver.js:139:10) javascript.0 2019-05-05 17:55:53.656 warn at Receiver.startLoop (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/ws/lib/Receiver.js:165:16) javascript.0 2019-05-05 17:55:53.656 warn at Receiver.getData (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/ws/lib/Receiver.js:330:12) javascript.0 2019-05-05 17:55:53.656 warn at Receiver.dataMessage (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/ws/lib/Receiver.js:389:14) javascript.0 2019-05-05 17:55:53.656 warn at Receiver._receiver.onmessage (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/ws/lib/WebSocket.js:141:47) javascript.0 2019-05-05 17:55:53.656 warn at WebSocket.emit (events.js:211:7) javascript.0 2019-05-05 17:55:53.656 warn at emitOne (events.js:116:13) javascript.0 2019-05-05 17:55:53.656 warn at WebSocket.onMessage (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/ws/lib/EventTarget.js:99:16) javascript.0 2019-05-05 17:55:53.656 warn at WebSocket.ws.onmessage (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/engine.io-client/lib/transports/websocket.js:147:10) javascript.0 2019-05-05 17:55:53.656 warn at WS.Transport.onData (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/engine.io-client/lib/transport.js:137:8) javascript.0 2019-05-05 17:55:53.656 warn at WS.Transport.onPacket (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/engine.io-client/lib/transport.js:145:8) javascript.0 2019-05-05 17:55:53.656 warn at WS.Emitter.emit (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/component-emitter/index.js:133:20) javascript.0 2019-05-05 17:55:53.656 warn at WS.<anonymous> (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/engine.io-client/lib/socket.js:273:10) javascript.0 2019-05-05 17:55:53.656 warn at Socket.onPacket (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/engine.io-client/lib/socket.js:456:14) javascript.0 2019-05-05 17:55:53.656 warn at Socket.Emitter.emit (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/component-emitter/index.js:133:20) javascript.0 2019-05-05 17:55:53.655 warn at Socket.<anonymous> (/opt/iobroker/node_modules/component-bind/index.js:21:15) javascript.0 2019-05-05 17:55:53.655 warn at Manager.ondata (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/socket.io-client/lib/manager.js:335:16) javascript.0 2019-05-05 17:55:53.655 warn at Decoder.add (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/socket.io-parser/index.js:251:12) javascript.0 2019-05-05 17:55:53.655 warn at Decoder.Emitter.emit (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/component-emitter/index.js:133:20) javascript.0 2019-05-05 17:55:53.655 warn at Decoder.<anonymous> (/opt/iobroker/node_modules/component-bind/index.js:21:15) javascript.0 2019-05-05 17:55:53.655 warn at Manager.ondecoded (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/socket.io-client/lib/manager.js:345:8) javascript.0 2019-05-05 17:55:53.655 warn at Manager.Emitter.emit (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/component-emitter/index.js:133:20) javascript.0 2019-05-05 17:55:53.655 warn at Manager.<anonymous> (/opt/iobroker/node_modules/component-bind/index.js:21:15) javascript.0 2019-05-05 17:55:53.655 warn at Socket.onpacket (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/socket.io-client/lib/socket.js:236:12) javascript.0 2019-05-05 17:55:53.655 warn at Socket.onevent (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/socket.io-client/lib/socket.js:278:10) javascript.0 2019-05-05 17:55:53.655 warn at Socket.Emitter.emit (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/component-emitter/index.js:133:20) javascript.0 2019-05-05 17:55:53.655 warn at Socket.<anonymous> (/opt/iobroker/node_modules/iobroker.js-controller/lib/states/statesInMemClient.js:52:30) javascript.0 2019-05-05 17:55:53.655 warn at Object.change (/opt/iobroker/node_modules/iobroker.js-controller/lib/adapter.js:3425:37) javascript.0 2019-05-05 17:55:53.655 warn at Object.stateChange (/opt/iobroker/node_modules/iobroker.javascript/main.js:364:25) javascript.0 2019-05-05 17:55:53.655 warn at Object.callback (/opt/iobroker/node_modules/iobroker.javascript/lib/sandbox.js:963:38) javascript.0 2019-05-05 17:55:53.655 warn at Object.<anonymous> (script.js.common.Test.nach_CCU:2:3) javascript.0 2019-05-05 17:55:53.655 warn at setState (/opt/iobroker/node_modules/iobroker.javascript/lib/sandbox.js:1258:20) javascript.0 2019-05-05 17:55:53.655 warn Wrong type of hm-rega.0.3709: "string". Please fix, while deprecated and will not work in next versions. -
javascript.0 2019-05-05 17:55:53.656 warn at TCP.onread (net.js:601:20) javascript.0 2019-05-05 17:55:53.656 warn at Socket.Readable.push (_stream_readable.js:208:10) javascript.0 2019-05-05 17:55:53.656 warn at readableAddChunk (_stream_readable.js:250:11) javascript.0 2019-05-05 17:55:53.656 warn at addChunk (_stream_readable.js:263:12) javascript.0 2019-05-05 17:55:53.656 warn at Socket.emit (events.js:211:7) javascript.0 2019-05-05 17:55:53.656 warn at emitOne (events.js:116:13) javascript.0 2019-05-05 17:55:53.656 warn at Socket._ultron.on (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/ws/lib/WebSocket.js:138:22) javascript.0 2019-05-05 17:55:53.656 warn at Receiver.add (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/ws/lib/Receiver.js:139:10) javascript.0 2019-05-05 17:55:53.656 warn at Receiver.startLoop (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/ws/lib/Receiver.js:165:16) javascript.0 2019-05-05 17:55:53.656 warn at Receiver.getData (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/ws/lib/Receiver.js:330:12) javascript.0 2019-05-05 17:55:53.656 warn at Receiver.dataMessage (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/ws/lib/Receiver.js:389:14) javascript.0 2019-05-05 17:55:53.656 warn at Receiver._receiver.onmessage (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/ws/lib/WebSocket.js:141:47) javascript.0 2019-05-05 17:55:53.656 warn at WebSocket.emit (events.js:211:7) javascript.0 2019-05-05 17:55:53.656 warn at emitOne (events.js:116:13) javascript.0 2019-05-05 17:55:53.656 warn at WebSocket.onMessage (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/ws/lib/EventTarget.js:99:16) javascript.0 2019-05-05 17:55:53.656 warn at WebSocket.ws.onmessage (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/engine.io-client/lib/transports/websocket.js:147:10) javascript.0 2019-05-05 17:55:53.656 warn at WS.Transport.onData (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/engine.io-client/lib/transport.js:137:8) javascript.0 2019-05-05 17:55:53.656 warn at WS.Transport.onPacket (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/engine.io-client/lib/transport.js:145:8) javascript.0 2019-05-05 17:55:53.656 warn at WS.Emitter.emit (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/component-emitter/index.js:133:20) javascript.0 2019-05-05 17:55:53.656 warn at WS.<anonymous> (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/engine.io-client/lib/socket.js:273:10) javascript.0 2019-05-05 17:55:53.656 warn at Socket.onPacket (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/engine.io-client/lib/socket.js:456:14) javascript.0 2019-05-05 17:55:53.656 warn at Socket.Emitter.emit (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/component-emitter/index.js:133:20) javascript.0 2019-05-05 17:55:53.655 warn at Socket.<anonymous> (/opt/iobroker/node_modules/component-bind/index.js:21:15) javascript.0 2019-05-05 17:55:53.655 warn at Manager.ondata (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/socket.io-client/lib/manager.js:335:16) javascript.0 2019-05-05 17:55:53.655 warn at Decoder.add (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/socket.io-parser/index.js:251:12) javascript.0 2019-05-05 17:55:53.655 warn at Decoder.Emitter.emit (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/component-emitter/index.js:133:20) javascript.0 2019-05-05 17:55:53.655 warn at Decoder.<anonymous> (/opt/iobroker/node_modules/component-bind/index.js:21:15) javascript.0 2019-05-05 17:55:53.655 warn at Manager.ondecoded (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/socket.io-client/lib/manager.js:345:8) javascript.0 2019-05-05 17:55:53.655 warn at Manager.Emitter.emit (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/component-emitter/index.js:133:20) javascript.0 2019-05-05 17:55:53.655 warn at Manager.<anonymous> (/opt/iobroker/node_modules/component-bind/index.js:21:15) javascript.0 2019-05-05 17:55:53.655 warn at Socket.onpacket (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/socket.io-client/lib/socket.js:236:12) javascript.0 2019-05-05 17:55:53.655 warn at Socket.onevent (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/socket.io-client/lib/socket.js:278:10) javascript.0 2019-05-05 17:55:53.655 warn at Socket.Emitter.emit (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/component-emitter/index.js:133:20) javascript.0 2019-05-05 17:55:53.655 warn at Socket.<anonymous> (/opt/iobroker/node_modules/iobroker.js-controller/lib/states/statesInMemClient.js:52:30) javascript.0 2019-05-05 17:55:53.655 warn at Object.change (/opt/iobroker/node_modules/iobroker.js-controller/lib/adapter.js:3425:37) javascript.0 2019-05-05 17:55:53.655 warn at Object.stateChange (/opt/iobroker/node_modules/iobroker.javascript/main.js:364:25) javascript.0 2019-05-05 17:55:53.655 warn at Object.callback (/opt/iobroker/node_modules/iobroker.javascript/lib/sandbox.js:963:38) javascript.0 2019-05-05 17:55:53.655 warn at Object.<anonymous> (script.js.common.Test.nach_CCU:2:3) javascript.0 2019-05-05 17:55:53.655 warn at setState (/opt/iobroker/node_modules/iobroker.javascript/lib/sandbox.js:1258:20) javascript.0 2019-05-05 17:55:53.655 warn Wrong type of hm-rega.0.3709: "string". Please fix, while deprecated and will not work in next versions. -
Erst mal Danke für den Tipp.
Muss mal im Forum schauen wie ich dieses umwandeln kann, hoffe ich finde etwas.

