hauju / scd4x-rs

Rust driver for the Sensirion SCD4x sensors.
Apache License 2.0
5 stars 12 forks source link

Add non-blocking single-shot measurement #8

Closed t-moe closed 10 months ago

t-moe commented 10 months ago

...useful for async code.

Although the measure_single_shot cmd has an execution time of 5 secs, we can do other stuff in the meantime and come back to collect the sample after 5 seconds. This should be legal according to the chip datasheet, and seems to work in my test setup here.

t-moe commented 10 months ago

@hauju Do you mind pushing v0.2.2 to crates.io?