SergiuToporjinschi / node-red-contrib-heater-controller

Heater controller for node-red dashboard
GNU General Public License v3.0
18 stars 17 forks source link

heater controler still work without sensor. #41

Closed devifast closed 4 years ago

devifast commented 4 years ago

I noticed that after removing the connection to the sensor in node red, heater is still work. after restart, too. After restart shows the last temperature that was measured. This indicates that if the sensor fails, the controller will run continuously which is not a good option. sorry for bad english.

SergiuToporjinschi commented 4 years ago

Hi, this is not a bug. See the documentation

Inputs This controller accepts one main input which has to have topic as "currentTemp" and payload needs to be a float The entire control is not functional until this message is received The heater status is recalculated when this message received, or when the user is changing the target temperature.

so if it does not receive anymore any message with currentTemp topic, the entire process is blocked; This not does not uses any timeouts. It relays on messages with topic "currentTemp" it calculates the status when it receives the message. No message, no recalculation, process is freezing until next currentTemp is received;

devifast commented 4 years ago

After removing the sensor physically, does the controller continue to operate?

SergiuToporjinschi commented 4 years ago

What do you mean by removing sensor physically? If you remove the sensor I suppose that the message with topic currentTemp is will not come anymore and this node will not send any other messages by it self, it keeps last received temperature so if you want to change the status lower the temperature from dashboard, and it will send the new status based on the new temperature set by you

devifast commented 4 years ago

I mean that if the sensor gets physically damaged, it still lights a candle. The cool thing is how to get around the calendar.

SergiuToporjinschi commented 4 years ago

I understand, but I cannot make a difference if your sensor died or is just not the case to switch the status.... you can do this but adding a function node before this node, and if the sensor died, then send a message, with topic currentTemp and value +100; this will make the controller think that there is enough heat and send the an off status; or you can make that function node to send a similar message like the heater-controller but with status off

devifast commented 4 years ago

I'm glad we think the same way, but in the absence of an inlet temperature the controller should be turned off at 100%. now i just pulled the sensor off the board and it still works?

devifast commented 4 years ago

I use 18b20 sensor

SergiuToporjinschi commented 4 years ago

Does not matter what sensor are you using. What's the message that you are sending to this node when the sensor is pulled out?

devifast commented 4 years ago

Can I send you a stream to look at it?