Git Product home page Git Product logo

sgpc3-rs's Introduction

Sensirion SGPC3 driver

Embedded hal based Rust Sensirion Sgpc3 driver

Build status Crates.io Version Crates.io Downloads No Std

Platform agnostic Rust driver for Sensirion SGPC3 gas sensor using the embedded-hal traits.

Sensirion SGPC3

Sensirion SGPC is a low-power accurate gas sensor for air quality application. The sensor has different sampling rates to optimize power-consumption per application bases as well as ability save and set the baseline for faster start-up accuracy. The sensor uses I²C interface and measures TVOC (Total Volatile Organic Compounds)

Datasheet: https://www.sensirion.com/file/datasheet_sgpc3

Development status

The sensor is feature complete and the future development evolves:

  • Moving into using Embedded-hal 1.x
  • Fixed-crate 2.x migration
  • Rust compiler 2021 changes

The package is 1.0.0 now. Major number is changed when non-backwards compatible changes are made. The first minor number 1.x.0 is changed when new backwards compatible feature is added. The second minor number 1.0.x is changed when fix without any feature changes have been made.

It is generally recommendated to set only the major number to get the future bug-fixes.

License

Licensed under either of

Contributing

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.

sgpc3-rs's People

Contributors

eflukx avatar mjaakkol avatar

Stargazers

 avatar

Watchers

 avatar  avatar

Forkers

eflukx

sgpc3-rs's Issues

Call to `f32::exp()` prevents crate to compile on `no_std`

The f32::exp() method is part of the f32 primitive in std and unfortunately not part of core. It breaks compilation on my target (Arm Cortex, nRF52833). Removing the call to .exp() fixes compilation, so it seems this is the only place where a std function is called.

   Compiling sgpc3 v0.0.2
error[E0599]: no method named `exp` found for type `f32` in the current scope
   --> /home/eflukx/.cargo/registry/src/github.com-1ecc6299db9ec823/sgpc3-0.0.2/src/lib.rs:415:69
    |
415 |             * (rh * 61.12_f32 * ((17.62_f32 * t / (243.12_f32 + t)).exp()) / (273.15_f32 + t));
    |                                                                     ^^^ method not found in `f32`

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.