PERL WARNING, attr peerIDs with no value

Begonnen von fruit, 06 November 2014, 08:51:36

Vorheriges Thema - Nächstes Thema

fruit

Last November I added a HM-WDS100-C6-O weather station to my system (with hmusb adapter) and it has been working well ever since.

Recent fhem.pl updates had been logging similar to

2014.11.04 10:44:44 1: PERL WARNING: Use of uninitialized value $val in substitution (s///) at fhem.pl line 1382.
2014.11.04 10:44:44 1: PERL WARNING: Use of uninitialized value $val in substitution (s///) at fhem.pl line 1383.
2014.11.04 10:44:44 1: PERL WARNING: Use of uninitialized value $val in concatenation (.) or string at fhem.pl line 1384.


at every save Config

I have managed to track this down to an attribute with no value.

define WeatherStation CUL_HM 1FCD3A
attr WeatherStation .devInfo 3F0100
attr WeatherStation .stc 70
attr WeatherStation IODev hmusb
attr WeatherStation actCycle 000:10
attr WeatherStation actStatus alive
attr WeatherStation autoReadReg 4_reqStatus
attr WeatherStation expert 1_on
attr WeatherStation firmware 1.4
attr WeatherStation fp_MyPlan 30,1100,1,
attr WeatherStation model HM-WDS100-C6-O
attr WeatherStation peerIDs
attr WeatherStation room WeatherStation
attr WeatherStation serialNr KEQ0241679
attr WeatherStation subType THSensor


By chance I have a saved cfg from the day following the weather station installation. It also has the empty attr so I suspect it was autocreated. Of course that behaviour may no longer be the case.

Deleting attr WeatherStation peerIDs resolves the save Config errors, the weather station has been behaving as before.

I have just tried to add attr WeatherStation peerIDs in order to provide more logging - but it has created

attr WeatherStation peerIDs 1

and shows no errors on save Config so seems resolved but...

discussion in http://forum.fhem.de/index.php/topic,28673.0.html suggests the empty peerIds should be converted internally to 1 (and I guess should not error) or be deleted.

I suspect I could force an empty value if the logs would help
Feel free to follow up in German if you prefer

martinp876

Peerids are always 8 char values separated by comma. 1 is illegal. Do you know how you managed to put in a 1 ?
It should not be added by internal operation such as getconfig.
User should not change the value manually. Therefore i am interested in its creation

fruit

#2
Tanks for the reply

As stated I had been running the weatherstation with an empty PeerIDs value since installation, I can only guess that it was autocreated as empty.

Recent fhem.pl updates showed an error on save Config that I eventually tracked to the empty attribute value. Deleting the empty attribute removed the save Config error

Out of interest I later tried adding attr PeerIDs to see what happened - and a 1 appeared in the value field after setting.

I've just checked again and it has no value! So, let's try once more...

Delete
attr WeatherStation peerIDs
Add
attr WeatherStation peerIDs
with no value set, this appears as
PeerIDS 1
under Attributes

I hope that makes some sense, please let me know if you need any more information.

I have deleted the attr WeatherStation peerIDs - I'm not sure what else to do with it :-\

Edit: 12.11.2014

On Monday I completely rebuilt my fhem.cfg from a bare file.
I noted that adding back my HM-PB-2-WM55 and HM-LC-SW2-FM devices, peerIDs for each appeared in the 8 char and comma format but nothing for the HM-WDS100-C6-O this time - and I won't be adding one!
Feel free to follow up in German if you prefer

martinp876


fruit

Yes, I'm fine, and all seems to be working as expected thanks
Feel free to follow up in German if you prefer