Jump to content

Nodeservers thru ISY on Polisy - Substitution Variables (and REST API) showing integers instead of formatted data


MWareman

Recommended Posts

Posted (edited)

I was setting up the Elk nodeserver on Polisy (when connected to ISY on Polisy in this thread). To investigate further - I have looked at the Time Data nodeserver (https://github.com/ve7gel/Timedata) as it is installed on both Polyglot (RPI) connected to my physical ISY - and Polisy with the ISY process.

I used the REST API to pull the node data for the nodeserver from each install. I would expect the results to be the same (since the time and location is configured identically):

Physical ISY:
http://192.168.1.2/rest/nodes/n013_timedata
image.png.1613ec77435230f6a1bc5456ad97e8f5.png

ISY process on Polisy:
http://192.168.1.3:8080/rest/nodes/n010_timedata
image.png.b6e07bc414983abd5b15eae78c170146.png

For example, GV10 (Season) shows 'Autumn' in the formatted output - but on Polisy the API formatted attribute returns '2'. This appears to be the root of the issue I have at the moment moving things over - the 'ST' value is coming out correctly - but the GV* values are not. I'm guessing this is a bug in ISY 5.1.1. on Polisy. 

Thank you,

Michael.

Edited by MWareman
Added reference to other thread
Posted

It sounds like a problem I had with another nodeserver a long time ago.  The formatted values were staying numeric as you've shown in your second example.  The answer for that particular situation where the data is being converted from a numeric to string value was that it wouldn't do it correctly until the ISY was rebooted/restarted after the nodeserver install.  This is not the normal restart the "admin console" after installing a nodeserver, this is reboot the ISY after installing a nodeserver where the formatted value is a string.

That all boils down to "has ISY been restarted since installation of that particular nodeserver?"  if not, try that.

Posted (edited)

The ISY process running on the Polisy has been restarted several times. I'll try it again to confirm though since I hate second-guessing myself......

Edit:

Confirmed.

I restarted the Polisy completely - and the numeric values were still there. I then tried just restarting the ISY daemon - and the numeric values stayed. 

Edited by MWareman
Posted

@MWareman,

I think, for some reason, the nls files for the node servers are not being installed properly, or, they are not being read properly. I suspect it's case sensitivity issue since ISY is not case sensitive but Polisy, is. 

This is the structure:

/var/isy/FILES/CONF/DEF
f10 <node servers>/i<n>/ (where n is the slot number)
editor/editors.xml
nls/en_us.txt
nodedef/nodedefs.xml

Editors are used to format and present data. The nls tag in editors.xml defines how to present the value. The same tag MUST be defined in nls/en_us.txt. 

If you have time, would you please check that a) nls/en_us.txt exists and b) weekday has the same case sensitivity?

With kind regards,
Michel
 

Posted
7 minutes ago, Michel Kohanim said:

@MWareman,

I think, for some reason, the nls files for the node servers are not being installed properly, or, they are not being read properly. I suspect it's case sensitivity issue since ISY is not case sensitive but Polisy, is. 

This is the structure:

/var/isy/FILES/CONF/DEF
f10 <node servers>/i<n>/ (where n is the slot number)
editor/editors.xml
nls/en_us.txt
nodedef/nodedefs.xml

Editors are used to format and present data. The nls tag in editors.xml defines how to present the value. The same tag MUST be defined in nls/en_us.txt. 

If you have time, would you please check that a) nls/en_us.txt exists and b) weekday has the same case sensitivity?

With kind regards,
Michel
 

nls/en_us.txt exists.

In nls/en_us.txt - it all appears in upper case:
 

WEEKDAY-0 = Monday
WEEKDAY-1 = Tuesday
WEEKDAY-2 = Wednesday
WEEKDAY-3 = Thursday
WEEKDAY-4 = Friday
WEEKDAY-5 = Saturday
WEEKDAY-6 = Sunday

LOGLEVEL-0 = None
LOGLEVEL-10 = Debug
LOGLEVEL-20 = Info
LOGLEVEL-30 = Error
LOGLEVEL-40 = Warning
LOGLEVEL-50 = Critical

MONTH-1 = January
MONTH-2 = February
MONTH-3 = March
MONTH-4 = April
MONTH-5 = May
MONTH-6 = June
MONTH-7 = July
MONTH-8 = August
MONTH-9 = September
MONTH-10 = October
MONTH-11 = November
MONTH-12 = December

SEASON-0 = Spring
SEASON-1 = Summer
SEASON-2 = Autumn
SEASON-3 = Winter

editors.xml (in part) contains this:
 

[root@polisy /var/isy/FILES/CONF/DEF/f10/i10]# vi editor/editors.xml
<editors>
        <editor id="I_NONE">
                <range uom="0" min="0" max="999999"/>
        </editor>
        <editor id="ODDEVEN">
                <range uom="25" subset="1,2" nls="ODDEVEN"/>
        </editor>
        <editor id="SEASON">
                <range uom="25" subset="0-3" nls="SEASON"/>
        </editor>
        <editor id="I_STATE">
                <range uom="25" subset="0,1" nls="STATE" />
        </editor>
        <editor id="I_WEEKDAY">
                <range uom="25" subset="0-6" nls="WEEKDAY" />
        </editor>

CaSe all looks correct and consistent to me...

Thank you!

Michael.

Posted
Just now, Michel Kohanim said:

@MWareman,

Thank you very much. We are going to look into it in the code asap. Definitely something in the code.

With kind regards,
Michel

Thank you Sir!  Please do let me know if there is any additional help I can provide in terms of identifying the root cause.

  • Like 1
Posted
16 hours ago, Michel Kohanim said:

@MWareman,

This should be fixed in the next build.

With kind regards,
Michel

Thank you so much!

  • Like 1
Guest
This topic is now closed to further replies.

×
×
  • Create New...