You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Looking at the code i see this operates in One Shot Mode as described in the (datasheet)[https://www.st.com/resource/en/datasheet/hts221.pdf] Page 23 ONE_SHOT Page
Line i2cWrite(HTS221_CTRL1_REG, 0x84); in begin function sets ODR1 & ODR2 to ONE_SHOT mode
The data sheet also indicates (page 21, register AV_CONF - 0x10) how to change the number of individual readings contributing to a single data gathered from the HTS221. Changing this number affects the response time somewhat (more individual readings = less speed). I made no precise measurements, but this could have some impact on your application.
Also: it is true the HTS221 can work in stream mode (the opposite of single-shot), but as far as I've seen using the chip, in stream mode you are responsible to ensure the reads made from the MCU are made at a rate equal or slower than the chip's. Overall, adopting the single-shot mode potentially allows to reach the maximum data rate compatible with the averaging depth selected in AV_CONF.
It is true the implementation of single-shot data reads in Arduino_HTS221 library is blocking, but a non-blocking version could be easily implemented in my feeling. Nevertheless, the simplicity of a blocking approach is, to me and my applications, a value.
The spreadsheet of the sensor states the following:
However, I could not see any code regarding this.
Is there any default value? What is current sensor frequency?
The text was updated successfully, but these errors were encountered: