Replies: 2 comments
-
The sensor API provides normalized values. A conforming implementation provides the value in the specified units. The goal is to provide developers with consistency so that they aren't surprised by unit changes when switching components. This matches the approach taken by W3C Sensors. If the client of the sensor wants different units, it should perform the conversion. The |
Beta Was this translation helpful? Give feedback.
-
I understand the need for a standard unit. I misread the standard, it says "type of data" not "data type" and in my mind data in g's vs. m/s^2 are two different types... |
Beta Was this translation helpful? Give feedback.
-
Per ECMA 419 the ADC returns values in the range 0 .. (1<<resolution)-1, yet I need it in millivolts, and ESP-IDF actually reports in millivolts.
Per ECMA 419 an accelerometer reports values in m/s^2 but I need them in g and the accelerometer I'm using (BMI160) also reports in g.
If I want to "fix these up" is the right process to use the format property? E.g.
adc.format = "millivolt"
andaccel.format = "g"
?Beta Was this translation helpful? Give feedback.
All reactions