make sure to cast the incoming value to its configured type, if it was configured earlier.
NOTE: The first incoming value is always stored as string. This is beacause MQTT orders the retained messages with the same QoS by subtypes (seperated by /). Less subtypes result in earlier handling of that message. All subsquent messages are handled accordingly to the configured type.
Since Node properties are not validated or set in any matter, we can ignore them for now. I noticed during testing that some of the node's properties were handled as if it were the containing value. This exposed internal information and cluttered the Thing with properties, the user is not interested in.
This is only f771fd2
To test this, just add a device with float values:
Hey there,
this PR incaludes two changes and affect #10
/
). Less subtypes result in earlier handling of that message. All subsquent messages are handled accordingly to the configured type.To test this, just add a device with float values:
The first value will set as string. All subsquent messages are set as
Number
. This can be observed in the logs, when the device's property is added.