Bump version to 0.1.3
This commit is contained in:
parent
3aedb009ff
commit
1fcbf7a667
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@vvzvlad/node-red-contrib-rn-combined-nodes",
|
"name": "@vvzvlad/node-red-contrib-rn-combined-nodes",
|
||||||
"version": "0.1.2",
|
"version": "0.1.3",
|
||||||
"description": "",
|
"description": "",
|
||||||
"main": "index.js",
|
"main": "index.js",
|
||||||
"keywords": [
|
"keywords": [
|
||||||
|
@ -45,6 +45,19 @@ module.exports = function(RED) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
node.on('input', function(msg) {
|
||||||
|
let topic = msg.topic
|
||||||
|
let payload = msg.payload
|
||||||
|
|
||||||
|
let control_mode = context.get("control_mode") || "auto" //auto, on, off
|
||||||
|
let current_temp = context.get("current_temp")
|
||||||
|
let target_temp = context.get("target_temp") || 19
|
||||||
|
let window_state = context.get("window_state") || "close" //open, close
|
||||||
|
let window_mode = context.get("window_mode") || "cool" //heat, cool, off
|
||||||
|
let heater_status = null
|
||||||
|
|
||||||
|
|
||||||
function logic() {
|
function logic() {
|
||||||
if (control_mode === "off") {
|
if (control_mode === "off") {
|
||||||
heater_status = 0
|
heater_status = 0
|
||||||
@ -110,16 +123,8 @@ module.exports = function(RED) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
node.on('input', function(msg) {
|
|
||||||
let topic = msg.topic
|
|
||||||
let payload = msg.payload
|
|
||||||
|
|
||||||
let control_mode = context.get("control_mode") || "auto" //auto, on, off
|
|
||||||
let current_temp = context.get("current_temp")
|
|
||||||
let target_temp = context.get("target_temp") || 19
|
|
||||||
let window_state = context.get("window_state") || "close" //open, close
|
|
||||||
let window_mode = context.get("window_mode") || "cool" //heat, cool, off
|
|
||||||
let heater_status = null
|
|
||||||
|
|
||||||
debug_text(`W-mode: ${window_mode}`)
|
debug_text(`W-mode: ${window_mode}`)
|
||||||
if (topic === "window_mode_control" && (payload === "cool" || payload === "heat" || payload === "off")) {
|
if (topic === "window_mode_control" && (payload === "cool" || payload === "heat" || payload === "off")) {
|
||||||
|
Loading…
Reference in New Issue
Block a user