Closed adorobis closed 7 months ago
btw, I've found an example on esphome, here is the filter:
- lambda: !lambda |-
// Fix negative values for now
if (x > 6000) {
return x - 6553.6;
}
return x;
Seems to be working ok :) Not sure if this should be implemented in optolink platform or rather left to the user to configure.
Digging a bit further it is even more simple: the unsigned int has to be converted to short int and here is how it can be done in the filter (on raw data, not divided by 10):
- lambda: !lambda |-
return (short)x;
I've provided proposal to include a warning in the documentation for the Sensor section.
Hi all,
As the temperatures dropped in Europe I've noticed that the outside temperature sensor (0x0800 address in my case) returns very high values, e.g. 65515. It took me a while to realise that it is an unsigned integer that should be converted to a signed integer in esphome. So far I could not figure out how to do it in esphome. Do you have a hint for it?
Many thanks! Adam