johnnyt Posted August 12, 2022 Posted August 12, 2022 I have a program that checks for wind direction >=0, which should always be true but is always false. Attached is screenshot of the program showing it's evaluated "false", screenshots of ISY GUI and NS Node value for wind direction. I downloaded the log (attached) but it had no data (at warning level) going back 3 days or so, which seems strange. so I changed level to "debug" and restarted NS, and attached that second log after letting things run for a minute or two. WeatherFlow_8-12-2022_103244_AM.zip WeatherFlow_8-12-2022_102852_AM.zip
johnnyt Posted August 12, 2022 Author Posted August 12, 2022 for the record, I right click and select "Run If" to force the condition check. It does the same thing enabled and disabled.
bpwwer Posted August 12, 2022 Posted August 12, 2022 Fri 08/12/2022 11:02:52 AM : [D2D EVENT ] Event [n001_48711] [WINDDIR] [90] uom=76 prec=0 Fri 08/12/2022 11:02:52 AM : [ n001_48711] WINDDIR 90 (uom=76 prec=0) Fri 08/12/2022 11:02:52 AM : [D2D*CMP 000F] STS [n001_48711] WINDDIR B Cannot convert values (from=0E to=4C) Fri 08/12/2022 11:02:52 AM : [D2D-CMP 000F] STS [n001_48711] WINDDIR op=5 Event(val=90 uom=76 prec=0) >= Condition(val=1 uom=14 prec=0) --> false Fri 08/12/2022 11:02:52 AM : [D2D EVENT ] Event [n001_48711] [GV3] [90] uom=76 prec=0 Fri 08/12/2022 11:02:52 AM : [ n001_48711] GV3 90 (uom=76 prec=0) This is what I see in the Event Viewer. It looks like the IoP isn't handling the comparison of UOM for wind direction properly. @Michel Kohanim, @Chris Jahn The WINDDIR status value is set to UOM 76 (wind direction degrees) but it seems to be comparing against UOM 14 (degrees) and failing. My program is simply doing "if winddir >= 1". Just like @johnnyt's program above.
johnnyt Posted August 12, 2022 Author Posted August 12, 2022 Just caught a "West" report for wind direction that when back to degree on next update. and the variable I try to set refuses to change (stays at 0)
johnnyt Posted August 13, 2022 Author Posted August 13, 2022 I caught the following in the event viewer: Sat 08/13/2022 11:41:54 AM : [ n006_207296] WINDDIR 265 (uom=76 prec=0) Sat 08/13/2022 11:41:54 AM : [D2D*CMP 036F] STS [n006_207296] WINDDIR B Cannot convert values (from=0E to=4C)
johnnyt Posted September 7, 2022 Author Posted September 7, 2022 Hi, I opened a support ticket for this and just got this response back: Quote Chris Jahn wrote: This is a problem with the node server, it should not be using UOM 14 in (generic temperature degree) in the node definition, instead it should be using UOM 76 (wind direction 1-360 deg, 0 means no wind). The ISY attempts to convert compatible UOM's but temperature and wind direction are obviously not compatible.
Solution bpwwer Posted September 7, 2022 Solution Posted September 7, 2022 Fixed in version 3.0.24 of the node server 1
johnnyt Posted September 7, 2022 Author Posted September 7, 2022 1 hour ago, bpwwer said: Fixed in version 3.0.24 of the node server ok, thanks. not seeing 3.0.24 in the node server store. Tried closing and reopening browser still only see:
bpwwer Posted September 8, 2022 Posted September 8, 2022 Use the Refresh Store button to refresh the store listing. Otherwise, it auto updates the list every 8 hours. 1
johnnyt Posted September 8, 2022 Author Posted September 8, 2022 10 hours ago, bpwwer said: Use the Refresh Store button to refresh the store listing. Otherwise, it auto updates the list every 8 hours. There was a message this morning about the new version and that I needed to restart. I did so and am now at the latest version and see that the wind direction is now working. Thanks.
johnnyt Posted September 26, 2022 Author Posted September 26, 2022 I'm seeing the following message in event viewer: Mon 09/26/2022 04:22:07 PM : [ n006_207296] WINDDIR 267 (uom=76 prec=0) Mon 09/26/2022 04:22:07 PM : [D2D*CMP 036F] STS [n006_207296] WINDDIR B Cannot convert values (from=0E to=4C) There is data in the GUI and it matches what the tempest shows so I'm not sure what the second message is all about.
bpwwer Posted September 26, 2022 Posted September 26, 2022 Maybe a program is trying to compare winddir with something it can't convert wind direction into.
johnnyt Posted September 26, 2022 Author Posted September 26, 2022 The only thing I do with wind direction is a program is store it in a state variable, i.e. If 'HVAC / Climate / WeatherFlow / ST-00061544' Wind Direction >= -1° Then $sWeatherStation.WindDirection = 'HVAC / Climate / WeatherFlow / ST-00061544' Wind Direction ° Else $sWeatherStation.WindDirection = -1 That said, I see it isn't working. My state variable is '0' - the init value - and it hasn't changed since last reboot. Could it be because it tries to store the "degree" character too?
bpwwer Posted September 26, 2022 Posted September 26, 2022 I think it complaining that wind direction can't be compared with -1° so it does nothing.
johnnyt Posted September 28, 2022 Author Posted September 28, 2022 On 9/26/2022 at 7:53 PM, bpwwer said: I think it complaining that wind direction can't be compared with -1° so it does nothing. Ok I changed the code and the error doesn't come up anymore, however the variable does not get set when it should. Here's the new program logic (0 is converted to "No Wind") If 'HVAC / Climate / WeatherFlow / ST-00061544' Wind Direction > No Wind Then $sWeatherStation.WindDirection = 'HVAC / Climate / WeatherFlow / ST-00061544' Wind Direction ° Else $sWeatherStation.WindDirection = 0 It evaluates True But the variable has not changed value since last reboot, when if was initialized to 0 Here's a sampling of WINDDIR values over the past few hours - none are 0 Wed 09/28/2022 05:12:34 AM : [ n006_207296 WINDDIR 359 (uom=76 prec=0) Wed 09/28/2022 05:17:32 AM : [ n006_207296 WINDDIR 352 (uom=76 prec=0) Wed 09/28/2022 05:19:30 AM : [ n006_207296 WINDDIR 350 (uom=76 prec=0) Wed 09/28/2022 05:25:27 AM : [ n006_207296 WINDDIR 352 (uom=76 prec=0) Wed 09/28/2022 05:27:27 AM : [ n006_207296 WINDDIR 359 (uom=76 prec=0) Wed 09/28/2022 05:28:30 AM : [ n006_207296 WINDDIR 337 (uom=76 prec=0) Wed 09/28/2022 05:33:23 AM : [ n006_207296 WINDDIR 348 (uom=76 prec=0) Wed 09/28/2022 05:39:21 AM : [ n006_207296 WINDDIR 348 (uom=76 prec=0) Wed 09/28/2022 05:40:20 AM : [ n006_207296 WINDDIR 335 (uom=76 prec=0) Wed 09/28/2022 05:43:47 AM : [ n006_207296 WINDDIR 344 (uom=76 prec=0) Wed 09/28/2022 05:53:43 AM : [ n006_207296 WINDDIR 358 (uom=76 prec=0) Wed 09/28/2022 06:02:37 AM : [ n006_207296 WINDDIR 357 (uom=76 prec=0) Wed 09/28/2022 06:06:35 AM : [ n006_207296 WINDDIR 343 (uom=76 prec=0) Wed 09/28/2022 06:10:38 AM : [ n006_207296 WINDDIR 352 (uom=76 prec=0) Wed 09/28/2022 06:12:32 AM : [ n006_207296 WINDDIR 335 (uom=76 prec=0) Wed 09/28/2022 06:18:29 AM : [ n006_207296 WINDDIR 358 (uom=76 prec=0) Wed 09/28/2022 06:35:20 AM : [ n006_207296 WINDDIR 352 (uom=76 prec=0) Wed 09/28/2022 07:14:38 AM : [ n006_207296 WINDDIR 343 (uom=76 prec=0) Wed 09/28/2022 07:19:34 AM : [ n006_207296 WINDDIR 357 (uom=76 prec=0) Wed 09/28/2022 07:22:34 AM : [ n006_207296 WINDDIR 339 (uom=76 prec=0) Wed 09/28/2022 07:26:31 AM : [ n006_207296 WINDDIR 346 (uom=76 prec=0) Wed 09/28/2022 07:30:21 AM : [ n006_207296 WINDDIR 335 (uom=76 prec=0)
hart2hart Posted September 28, 2022 Posted September 28, 2022 Is your weather flow set to measure the wind every 3 or 15 seconds?Try removing the else clause and see if the value is going back to 0 between actual samples.
johnnyt Posted September 28, 2022 Author Posted September 28, 2022 55 minutes ago, hart2hart said: Is your weather flow set to measure the wind every 3 or 15 seconds? where do I see / change that? I looked through the settings but didn't find one for this. It looks like it's every 3 seconds just from watching changes. 55 minutes ago, hart2hart said: Try removing the else clause and see if the value is going back to 0 between actual samples. Ok I did that and ran it (if) which ran true and stayed true with no change to the variable. I think if this had been the issue, the timestamp for the variable would not still be the time from the last reboot 8 days ago.
hart2hart Posted September 28, 2022 Posted September 28, 2022 (edited) Does running Then record a value? The every 15 seconds is a battery saver feature. Its under settings stations stations "your station name" Manage Devices Sky Advanced Power Save Mode turn it on. You may have temptest where sky and air are in one device together so it may be a little different In iOs app... Edited September 28, 2022 by hart2hart
Bumbershoot Posted September 28, 2022 Posted September 28, 2022 8 minutes ago, johnnyt said: where do I see / change that? I looked through the settings but didn't find one for this. It looks like it's every 3 seconds just from watching changes. You set this value in the node server configuration page. In the Custom Configuration Parameters section, set Rapid Wind to true or false. 10 minutes ago, johnnyt said: Ok I did that and ran it (if) which ran true and stayed true with no change to the variable. FWIW, I wrote a program identical to yours quoted above, and the variable updates as expected. Maybe there's something specific with your installation of the node server.
johnnyt Posted September 28, 2022 Author Posted September 28, 2022 1 hour ago, hart2hart said: Does running Then record a value? The every 15 seconds is a battery saver feature. Its under settings stations stations "your station name" Manage Devices Sky Advanced Power Save Mode turn it on. You may have temptest where sky and air are in one device together so it may be a little different In iOs app... No, running then is no different than runnin if. I have an all in one unit and looked again. don't see any option to change anything related to frequency of wind reports. I do know if the battery goes low, it will reduce itself to conserve energy from 3 secs to 6 secs to 1 min to 5 mins. https://help.weatherflow.com/hc/en-us/articles/360048877194-Solar-Power-Rechargeable-Battery
johnnyt Posted September 28, 2022 Author Posted September 28, 2022 1 hour ago, Bumbershoot said: You set this value in the node server configuration page. In the Custom Configuration Parameters section, set Rapid Wind to true or false. The NS config 'Rapid Wind' option is/has been false. I set to true and restarted NS. The wind reports certainly accelerated as seen in NS log updates but the variable doesn't change either automatically or when I 'run then' using this config.
johnnyt Posted September 28, 2022 Author Posted September 28, 2022 So I created a new program from scratch (no copying) to do the same thing and it works fine. There's actually a visible discrepancy between the old and the new "action" statement Here's the original action: $sWeatherStation.WindDirection = 'HVAC / Climate / WeatherFlow / ST-00061544' Wind Direction ° And here's the action for the new program: Check out the difference in last character. $sWeatherStation.WindDirection = 'HVAC / Climate / WeatherFlow / ST-00061544' Wind Direction So then I created a copy of the original program and it had the extra character too but when I changed the equation to a different data element and back again, the extra character was no longer there. Guessing this is a 1 in a million occurrence so won't both opening a ticket with UDI support but next time I have difficult to reconcile program logic I'll definitely look for this issue.
johnnyt Posted September 28, 2022 Author Posted September 28, 2022 I should add that I originally had the units (in Tempest) as "cardinal", e.g. NW, W, etc. and changed them to degrees without actually changing the action statement so maybe that's what caused this.
Recommended Posts