TomaxMe
(Tomax Me)
January 18, 2019, 11:16am
1
Not able to read corect format data coming from Network Binding for “latency” (number) and “lastseen” (datetime), but a simple hyphen only. In HABmin/Thing/ all data can be read. So I supposed that it’s a simple code formating issue.
Items:
Switch ArduinoSwitchInverter {channel = "network:pingdevice:network_pingdevice_192_168_1_10:online"}
Number ArduinoSwitchInverterResponseTime {channel ="network:pingdevice:network_pingdevice_192_168_1_10:latency"}
DateTime ArduinoSwitchInverterLastSeen {channel ="network:pingdevice:network_pingdevice_192_168_1_10:lastseen"}
Sitemap:
Frame label=""{
Group item=Under label="Development"{
Text item=ArduinoSwitchInverter label="Arduino Wemos Board [%s]"
Text item=ArduinoSwitchInverterResponseTime label="Device Response Time is [%s]"
Text item=ArduinoSwitchInverterLastSeen label="Last Seen: [%s]"
}
}
vzorglub
(Vincent Regaud)
January 18, 2019, 11:21am
2
What do the logs say about these 3 items?
TomaxMe
(Tomax Me)
January 18, 2019, 11:23am
3
2019-01-18 13:21:25.251 [vent.ItemStateChangedEvent] - network_pingdevice_192_168_1_10_latency changed from 102.0 to 83.0
2019-01-18 13:21:25.283 [vent.ItemStateChangedEvent] - network_pingdevice_192_168_1_10_lastseen changed from 2019-01-18T13:20:25.101+0200 to 2019-01-18T13:21:25.226+0200
2019-01-18 13:22:25.298 [vent.ItemStateChangedEvent] - network_pingdevice_192_168_1_10_latency changed from 83.0 to 24.0
2019-01-18 13:22:25.344 [vent.ItemStateChangedEvent] - network_pingdevice_192_168_1_10_lastseen changed from 2019-01-18T13:21:25.226+0200 to 2019-01-18T13:22:25.278+0200
2019-01-18 13:22:48.645 [ome.event.ItemCommandEvent] - Item 'network_pingdevice_192_168_1_10_online' received command REFRESH
2019-01-18 13:22:48.680 [ome.event.ItemCommandEvent] - Item 'network_pingdevice_192_168_1_10_latency' received command REFRESH
2019-01-18 13:22:48.715 [ome.event.ItemCommandEvent] - Item 'network_pingdevice_192_168_1_10_lastseen' received command REFRESH
2019-01-18 13:22:51.212 [ome.event.ItemCommandEvent] - Item 'network_pingdevice_192_168_1_10_online' received command REFRESH
2019-01-18 13:22:51.246 [ome.event.ItemCommandEvent] - Item 'network_pingdevice_192_168_1_10_latency' received command REFRESH
2019-01-18 13:22:51.278 [ome.event.ItemCommandEvent] - Item 'network_pingdevice_192_168_1_10_lastseen' received command REFRESH
2019-01-18 13:22:53.582 [ome.event.ItemCommandEvent] - Item 'network_pingdevice_192_168_1_10_online' received command REFRESH
2019-01-18 13:22:53.619 [ome.event.ItemCommandEvent] - Item 'network_pingdevice_192_168_1_10_latency' received command REFRESH
2019-01-18 13:22:53.650 [ome.event.ItemCommandEvent] - Item 'network_pingdevice_192_168_1_10_lastseen' received command REFRESH
2019-01-18 13:22:53.717 [vent.ItemStateChangedEvent] - network_pingdevice_192_168_1_10_online changed from ON to OFF
2019-01-18 13:22:53.729 [vent.ItemStateChangedEvent] - network_pingdevice_192_168_1_10_latency changed from 24.0 to -1.0
2019-01-18 13:22:53.757 [vent.ItemStateChangedEvent] - network_pingdevice_192_168_1_10_latency changed from -1.0 to UNDEF
2019-01-18 13:22:53.764 [me.event.ThingUpdatedEvent] - Thing 'network:pingdevice:192_168_1_100' has been updated.
2019-01-18 13:22:56.940 [ome.event.ItemCommandEvent] - Item 'network_pingdevice_192_168_1_10_online' received command REFRESH
2019-01-18 13:22:56.974 [ome.event.ItemCommandEvent] - Item 'network_pingdevice_192_168_1_10_latency' received command REFRESH
2019-01-18 13:22:57.004 [ome.event.ItemCommandEvent] - Item 'network_pingdevice_192_168_1_10_lastseen' received command REFRESH
2019-01-18 13:22:57.892 [ome.event.ItemCommandEvent] - Item 'network_pingdevice_192_168_1_10_online' received command REFRESH
2019-01-18 13:22:57.928 [ome.event.ItemCommandEvent] - Item 'network_pingdevice_192_168_1_10_latency' received command REFRESH
2019-01-18 13:22:57.956 [ome.event.ItemCommandEvent] - Item 'network_pingdevice_192_168_1_10_lastseen' received command REFRESH
2019-01-18 13:23:02.019 [vent.ItemStateChangedEvent] - network_pingdevice_192_168_1_10_latency changed from UNDEF to -1.0
2019-01-18 13:23:02.038 [vent.ItemStateChangedEvent] - network_pingdevice_192_168_1_10_latency changed from -1.0 to UNDEF
2019-01-18 13:23:18.351 [me.event.ThingUpdatedEvent] - Thing 'network:pingdevice:ArduinoSwitchInverter' has been updated.
vzorglub
(Vincent Regaud)
January 18, 2019, 11:30am
4
Any rules involved that send that REFRESH command? I have never seen that before
TomaxMe
(Tomax Me)
January 18, 2019, 11:32am
5
Nothing at all. I’ve just finished to configure HABmin and edit “items” and “sitemap”. And play with connect and disconnect of the Arduino board.
vzorglub
(Vincent Regaud)
January 18, 2019, 11:37am
6
Remove those spaces:
Switch ArduinoSwitchInverter { channel="network:pingdevice:network_pingdevice_192_168_1_10:online" }
Number ArduinoSwitchInverterResponseTime { channel="network:pingdevice:network_pingdevice_192_168_1_10:latency" }
DateTime ArduinoSwitchInverterLastSeen { channel="network:pingdevice:network_pingdevice_192_168_1_10:lastseen" }
vzorglub
(Vincent Regaud)
January 18, 2019, 11:50am
8
the ones around the =
after channel
Your items are not in the log which mean they don’t exist
Can you post the whole items file, please
Also what to the openhab.log show when you save that file?
TomaxMe
(Tomax Me)
January 18, 2019, 12:45pm
9
I found the issue: the name of the Thing in HABmin should be exactly with the one used in “items” file. I used a different one - that was the mistake. Now everything is working well.
Correct defined items wich works well:
Switch ArduinoSwitchInverter {channel = "network:pingdevice:ArduinoSwitchInverter:online"}
Number ArduinoSwitchInverterResponseTime {channel ="network:pingdevice:ArduinoSwitchInverter:latency"}
DateTime ArduinoSwitchInverterLastSeen {channel ="network:pingdevice:ArduinoSwitchInverter:lastseen"}