mirror of
https://github.com/node-red/node-red-nodes.git
synced 2025-03-01 10:37:43 +00:00
Update core nodes to pull common msgs from node-red ns
This commit is contained in:
@@ -30,8 +30,8 @@
|
||||
</select>
|
||||
</div>
|
||||
<div class="form-row">
|
||||
<label for="node-input-name"><i class="fa fa-tag"></i> <span data-i18n="common.label.name"></span></label>
|
||||
<input type="text" id="node-input-name" data-i18n="[placeholder]common.label.name">
|
||||
<label for="node-input-name"><i class="fa fa-tag"></i> <span data-i18n="node-red:common.label.name"></span></label>
|
||||
<input type="text" id="node-input-name" data-i18n="[placeholder]node-red:common.label.name">
|
||||
</div>
|
||||
<div class="form-tips"><span data-i18n="[html]arduino.tip.io"></span></div>
|
||||
</script>
|
||||
@@ -86,8 +86,8 @@
|
||||
</select>
|
||||
</div>
|
||||
<div class="form-row">
|
||||
<label for="node-input-name"><i class="fa fa-tag"></i> <span data-i18n="common.label.name"></span></label>
|
||||
<input type="text" id="node-input-name" data-i18n="[placeholder]common.label.name">
|
||||
<label for="node-input-name"><i class="fa fa-tag"></i> <span data-i18n="node-red:common.label.name"></span></label>
|
||||
<input type="text" id="node-input-name" data-i18n="[placeholder]node-red:common.label.name">
|
||||
</div>
|
||||
<div class="form-tips"><span data-i18n="[html]arduino.tip.io"></span></div>
|
||||
</script>
|
||||
|
@@ -75,9 +75,9 @@ module.exports = function(RED) {
|
||||
if (typeof this.serverConfig === "object") {
|
||||
this.board = this.serverConfig.board;
|
||||
var node = this;
|
||||
node.status({fill:"red",shape:"ring",text:RED._("common.status.connecting")});
|
||||
node.status({fill:"red",shape:"ring",text:RED._("node-red:common.status.connecting")});
|
||||
node.board.on('connect', function() {
|
||||
node.status({fill:"green",shape:"dot",text:RED._("common.status.connected")});
|
||||
node.status({fill:"green",shape:"dot",text:RED._("node-red:common.status.connected")});
|
||||
//console.log("i",node.state,node.pin);
|
||||
if (node.state == "ANALOG") {
|
||||
node.board.on('analogChange', function(e) {
|
||||
@@ -122,10 +122,10 @@ module.exports = function(RED) {
|
||||
if (typeof this.serverConfig === "object") {
|
||||
this.board = this.serverConfig.board;
|
||||
var node = this;
|
||||
node.status({fill:"red",shape:"ring",text:RED._("common.status.connecting")});
|
||||
node.status({fill:"red",shape:"ring",text:RED._("node-red:common.status.connecting")});
|
||||
|
||||
node.board.on('connect', function() {
|
||||
node.status({fill:"green",shape:"dot",text:RED._("common.status.connected")});
|
||||
node.status({fill:"green",shape:"dot",text:RED._("node-red:common.status.connected")});
|
||||
//console.log("o",node.state,node.pin);
|
||||
node.board.pinMode(node.pin, node.state);
|
||||
node.on("input", function(msg) {
|
||||
|
Reference in New Issue
Block a user