-
-
Notifications
You must be signed in to change notification settings - Fork 46
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
4 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
5f46863
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
pls explain why do you remove ATTRID_MS_PRESSURE_MEASUREMENT_SCALED_VALUE. Now it worked correct, and it is necessary for sls gateway for example.
we dealed with other that it will. if you have an issue please report it.
5f46863
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This feature didn't work as expected, caused many troubles. This is why I've deprecated it.
5f46863
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pls provide some infornation. Now I see here https://github.com/presslab-us/ZigBee_SensorTag2 for example has the same implementation. And I tested it in my environment in z2m where scale is used, and in SLS, where it required. Nobody explain even one bug with scaled. But It may be overflow on pow. I removed it, and mean that scale always equal -1. If error will appeared I will research it and will fix.
5f46863
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The main issue is that scaled value is always equals to measured value
5f46863
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is not issue, but it is not the same.
there are heave some differences.
lets see
zclApp_Sensors.BME280_PressureSensor_ScaledValue = bme_results.pressure / 10.0 ...
zclApp_Sensors.BME280_PressureSensor_MeasuredValue = zclApp_Sensors.BME280_PressureSensor_ScaledValue / 10.0;
so scaled greater than not scaled in 10 times.
And
{PRESSURE, {ATTRID_MS_PRESSURE_MEASUREMENT_SCALED_VALUE, ZCL_INT16, ...
{PRESSURE, {ATTRID_MS_PRESSURE_MEASUREMENT_MEASURED_VALUE, ZCL_INT16,
so
scaled pressure looks like 10184
measured 1018
in z2m if scaled present
result = scaled/scale = 1018,4
if not
result = measured = 1018.0
so fraction part is lost.
for instance, if I will do additional operations convert into mmhg if will have lose last digit.
it will happend after two rounds. so I will have additional +-0,5 to mmhg accuracy.
in case of using scaled value only +-0,05.
1018,4 / 133 = 765,7 = 766
1018,0 / 133 = 765,4 = 765
The second, some devices such as sls gateway required scaled value for pressure. it does not show pressure. we check it together with sls gateway author.
for me it is not important, I using sls only for check my devices, but when I show my version, i receive feedbacks that sls gateway pressure become to be broken.
The third, other project use scaled. and it is fit to specification of domains zigbee.
Pressure has scaled value, but some others not.
I think that in this case much more convenient to be fit to specification and ask others to fit within specification too.
the forth, I ready to spent time to fix issues related to pressure.
so, please, lets returns scaled values.
5f46863
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nothing wrong with using the measured value, it's 100% according to zcl6 spec
5f46863
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, but noting wrong by using scaled too.
5f46863
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Scaled value proved it's self as buggy stuff, I've wasted enough time on this. Fraction of precision doesn't worth more of time
5f46863
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I ready to spent time to fix such bugs. do you have bugs artifacts?
I see that in my version in z2m pressure is stable for a long time.
in sls i see correct value, but not check it for a long time, but without scaled, sls is not show pressure.
5f46863
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let sls developer fix it's code and settle down with this. Even if you'll spend time on fixing, I would have to validate the changes, which would consume my time.
5f46863
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
do you have plans to remove support of scaled measure from z2m converter in the z2m codebase?
5f46863
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just replace scaled value with measured by reporting configuration from converter, everything else shall remain intact. I've already raised PR