Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Subsequent position override messages toggle override on and off #421

Closed
nikipore opened this issue Mar 5, 2022 · 8 comments
Closed

Subsequent position override messages toggle override on and off #421

nikipore opened this issue Mar 5, 2022 · 8 comments
Labels
✓ already implemented Issue is already fixed/implemented in a newer Version (this Version is may be not published). 🐛 bug Something isn't working

Comments

@nikipore
Copy link

nikipore commented Mar 5, 2022

Describe the bug
Since I've upgraded (don't remember the prior version) the package to its current version 2.1.1, subsequent position override messages toggle the override of the blind control node on and off:

  1. Initially, the blind position is set to x by a rule or by default. When there is a rule, the option to cancel manual override when the rule becomes active is not activated.
  2. Sending a message {"position": y} into the node lets it the position to y (node status shows "y - overwritten [imp=0]").
  3. Sending another message {"position": y} into the node lets it forget the override and yields the same behavior as step 0.
  4. Sending another message {"position": y} into the node yields the same behavior as step 1.

And so forth: step n yields the same behavior as step n-2.

I tried to set msg.resetOnSameValue explicitly to false or msg.ignoreSameValue to true, but to no avail.

Screenshots
Will do when deemed necessary.

Expected behavior
The position override should remain active until it is explicitly reset by an incoming message or a rule with activated option "reset existing override when activated".

System information (please complete the following information):

  • Node Version 2.1.1
  • Node-Red Version 2.2.2

Additional context
A flow stripped down to the essential (without config node):

[{"id":"3d515f0d4a97f984","type":"tab","label":"Flow 1","disabled":false,"info":"","env":[]},{"id":"33209c61675044f3","type":"blind-control","z":"3d515f0d4a97f984","name":"Test","topic":"","addIdType":"none","addId":"","positionConfig":"a962ddc.fbff22","autoTrigger":false,"autoTriggerTime":"1200000","startDelayTime":"10000","contextStore":"","results":[{"p":"","pt":"msgTopic","v":"","vt":"topic"},{"p":"","pt":"msgPayload","v":"","vt":"level"},{"p":"slat","pt":"msg","v":"","vt":"slat"},{"p":"blindCtrl","pt":"msg","v":"","vt":"ctrlObj"}],"blindIncrement":"0.05","blindOpenPos":"1","blindClosedPos":0,"blindPosDefault":"open (max)","blindPosDefaultType":"levelFixed","slatPosDefault":"","slatPosDefaultType":"none","overwriteExpire":"","rules":[],"sunControlMode":"0","sunFloorLengthType":"num","sunFloorLength":"0.3","sunMinDelta":"","blindPosMin":"25%","blindPosMinType":"levelFixed","blindPosMax":"open (max)","blindPosMaxType":"levelFixed","blindOpenPosOffset":"","blindClosedPosOffset":"","sunSlat":"","sunSlatType":"none","smoothTime":"","sunTopic":"","windowTopType":"num","windowTop":"2.01","windowBottomType":"num","windowBottom":"0.97","windowAzimuthStartType":"numAzimuth","windowAzimuthStart":"-50","windowAzimuthEndType":"numAzimuth","windowAzimuthEnd":"100","oversteers":[],"oversteerTopic":"","x":670,"y":220,"wires":[[],[]]},{"id":"bf2b6cf9e605ac4b","type":"inject","z":"3d515f0d4a97f984","name":"","props":[{"p":"position","v":"0.1","vt":"num"},{"p":"ignoreSameValue","v":"true","vt":"bool"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":510,"y":220,"wires":[["33209c61675044f3"]]},{"id":"47e3e9b95d772f92","type":"inject","z":"3d515f0d4a97f984","name":"","props":[{"p":"position","v":"0.1","vt":"num"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":510,"y":160,"wires":[["33209c61675044f3"]]},{"id":"d6354cc4c53d38b4","type":"inject","z":"3d515f0d4a97f984","name":"","props":[{"p":"position","v":"0.1","vt":"num"},{"p":"resetOnSameValue","v":"false","vt":"bool"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":510,"y":280,"wires":[["33209c61675044f3"]]}]
@Hypnos3
Copy link
Collaborator

Hypnos3 commented Mar 13, 2022

The problem is fixed in the latest version. node-red-contrib-sun-position@2.2.0-beta

Since this version has undergone some changes internally, I have this but still released as beta. That means you can't update it via Node-Red, but only via the command line.

@Hypnos3 Hypnos3 added 🐛 bug Something isn't working ✓ already implemented Issue is already fixed/implemented in a newer Version (this Version is may be not published). labels Mar 13, 2022
@Hypnos3 Hypnos3 reopened this Mar 13, 2022
@nikipore
Copy link
Author

Thanks! I am using Node-RED in Home Assistant (supervised docker image), but I figured out how to override the settings to use your package. A first test looks ok, no idea whether anything else has broken. Will let you know if that's the case. Please let me know in return when I'll be able to return to the standard release.

@hvorragend
Copy link

Hallo Jan,

du kannst es in der Node Red-Konfiguration in Supervisor als zusätzliches npm-package hinzufügen.

Viele Grüße
Carsten

@nikipore
Copy link
Author

Danke! Ja, genau das hatte ich gemeint und auch schon getan:

npm_packages:
  - node-red-contrib-sun-position@2.2.0-beta

Und vorher das Add-On heruntergefahren und aus config/node-red/package.json das übers Node-RED installierte Standardpaket herausgenommen. (Deinstallieren übers GUI geht nicht, weil das Paket ja in Benutzung ist.)

@Hypnos3
Copy link
Collaborator

Hypnos3 commented Mar 14, 2022

Ich habe es mal mit in die Installationsanleitung aufgenommen:
https://github.com/rdmtc/node-red-contrib-sun-position/releases/tag/2.2.0-beta

@Hypnos3
Copy link
Collaborator

Hypnos3 commented Mar 14, 2022

Es wäre gut, wenn ihr berichten könnt, ob mit der neuen Version noch alles genauso läuft wie vorher.

@nikipore
Copy link
Author

Na klar, hatte ich oben ja schon versprochen. Bisher habe keine Auffälligkeiten gefunden. Vielleicht mache ich mir irgendwann mal die Arbeit, die Typos aus den Locales zu entfernen.

@chriss158
Copy link

chriss158 commented Apr 7, 2022

Ich habe es mal mit in die Installationsanleitung aufgenommen: https://github.com/rdmtc/node-red-contrib-sun-position/releases/tag/2.2.0-beta

Und vorher das Add-On heruntergefahren und aus config/node-red/package.json das übers Node-RED installierte Standardpaket herausgenommen. (Deinstallieren übers GUI geht nicht, weil das Paket ja in Benutzung ist.)

@Hypnos3 Vielleicht nimmst du diesen Punkt mit in die Installationsanleitung auf. Ohne das funktioniert die Installation der Beta nicht. 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
✓ already implemented Issue is already fixed/implemented in a newer Version (this Version is may be not published). 🐛 bug Something isn't working
Development

No branches or pull requests

4 participants