Commit graph

64 commits

Author SHA1 Message Date
b261eb61a2 remove doctest from lib 2024-02-25 19:54:59 +02:00
9a6893f326 rename calc to calculation 2024-02-25 11:46:35 +02:00
ccfcf8bd32 update embedded-hal and linux-embedded-hal to latest stable versions 2024-02-25 11:31:24 +02:00
Sikkema, Isaac
4fd1a72812 Fix optional definition of FieldData 2023-06-19 19:18:32 +02:00
Sikkema, Isaac
ddaa99c209 Add optional serde support for FieldData 2023-06-17 11:03:00 +02:00
marcelbuesing
4b87e3c2f7
Migrate to embedded-hal=1.0.0-alpha.5 2021-11-16 15:39:57 +01:00
marcelbuesing
3c81f71770
Cleanup clippy warnings 2021-05-06 22:22:53 +02:00
Jan Gosmann
1e9986d41c
Add missing sleep to example
One has to sleep for the duration of the configured profile to read
proper data.

Closes #23.
2021-05-06 21:33:16 +02:00
Jan Gosmann
f531e617d6 Expose gas_valid and heat_stab
The BME680 datasheet recommends to check these values to ensure that a
gas reading is valid. To do so, they must be exposed by the library.
2021-05-06 21:24:25 +02:00
huntc
500dbd9811 Pass the delayer around mutabily
This is as opposed to retaining ownership of it
2021-05-06 21:21:22 +02:00
huntc
c97894f84c Cater for non-Linux environments
Doctests can be run using `cargo test --doc`. The examples still require Linux.
2021-05-06 21:21:22 +02:00
Marc Poulhiès
e10fa1a35a Trivial typo fix in documentation 2020-11-24 22:10:39 +01:00
Adrian Stanciu
05a6643b1a Remove warnings
`unused_parens` is now on by default:

```
warning: unnecessary parentheses around const expression
   --> src\lib.rs:777:35
    |
777 |         let mut coeff_array: [u8; (BME680_COEFF_ADDR1_LEN + BME680_COEFF_ADDR2_LEN)] =
    |                                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses
    |
    = note: `#[warn(unused_parens)]` on by default

warning: unnecessary parentheses around const expression
   --> src\lib.rs:778:17
    |
778 |             [0; (BME680_COEFF_ADDR1_LEN + BME680_COEFF_ADDR2_LEN)];
    |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these parentheses

warning: 2 warnings emitted
```
2020-08-24 09:21:27 +02:00
marcelbuesing
379442bea6
Cleanup clippy warnings 2020-04-05 21:20:40 +02:00
marcelbuesing
06af0d61b2
Remove remaining pre 2018 artifacts 2019-11-27 11:07:15 +01:00
marcelbuesing
ad8d0798ed
Migrate to futures-0.3 and tokio-0.2 2019-11-27 11:00:31 +01:00
Chris
79955a19be Fix the no_std f32 errors 2019-01-16 16:56:59 +01:00
marcelbuesing
0c90c96a85
Return temperature offset in get_sensor_settings (#12) 2019-01-05 20:20:03 +01:00
marcelbuesing
38bfe30acc
Fix temperature offset to be of type f32, closes #11 2018-12-22 10:02:35 +01:00
marcelbuesing
faec5049e4
#11 Add optional temperature offset 2018-12-14 21:22:21 +01:00
marcelbuesing
5c1de2a1d3
Rustfmt code 2018-10-17 22:10:55 +02:00
marcelbuesing
1682f433ab
Always set gas sensor settings when setting any gas related setting, regards #3 2018-06-06 18:53:24 +02:00
marcelbuesing
722e054f58
Actually set provided gas config, closes #3.
Failure to set the provided gas config lead to incorrect gas resistance values.
2018-06-05 23:45:26 +02:00
marcelbuesing
9701e85c39
Derive PartialEq for FieldDataCondition 2018-06-01 14:48:19 +02:00
marcelbuesing
ceed9e844b
Add example to crate documentation 2018-05-31 12:28:07 +02:00
marcelbuesing
833f892e6b
Rename Bme680_dev struct to Bme680 2018-05-31 12:13:36 +02:00
marcelbuesing
650db10d69
Reduce struct visibility where not required 2018-05-31 12:10:34 +02:00
marcelbuesing
ba7a1dd09f
Rename Bme680Error to Error 2018-05-31 11:46:46 +02:00
marcelbuesing
301cd55df4
Cleanup constants 2018-05-31 11:35:19 +02:00
marcelbuesing
3b84d4f6f3
Add documentation to settings and lib 2018-05-30 21:27:29 +02:00
marcelbuesing
336305d30d
Replace u8 with IIRFilterSize enum 2018-05-30 21:06:11 +02:00
marcelbuesing
44fc891b3e
Introduce SettingsBuilder 2018-05-30 08:28:48 +02:00
marcelbuesing
cce7d4c65c
Replace run_gas u8 with boolean 2018-05-28 19:56:57 +02:00
marcelbuesing
214eec18dd
Introduce enum for I2CAddress, regards #1 2018-05-27 22:20:23 +02:00
marcelbuesing
887ff00a30
Add missing Cargo manifest fields 2018-05-25 23:09:16 +02:00
marcelbuesing
39c432134c
Add crate description 2018-05-25 23:05:18 +02:00
marcelbuesing
02ea1e18c3
Replace InfoMsg struct in boundary check 2018-05-25 22:22:03 +02:00
marcelbuesing
acfa564e42
Extract to settings module 2018-05-25 21:29:39 +02:00
marcelbuesing
53d2fe8b5b
Remove std dependencies, make it no_std crate 2018-05-25 20:48:17 +02:00
marcelbuesing
d1fe4a972a
Replace heat_dur u32 with Duration 2018-05-24 22:02:23 +02:00
marcelbuesing
a8a7426888
Replace u8 with OversamplingSetting enum 2018-05-23 22:10:06 +02:00
marcelbuesing
b703479be4
Replace set sensor settings constants 2018-05-21 18:07:13 +02:00
marcelbuesing
4788c6c14e
Replace Vec with arrays where sensible 2018-05-21 16:55:25 +02:00
marcelbuesing
fc57f277c4
Add unit conversions 2018-05-21 16:26:14 +02:00
marcelbuesing
9df8c0b2c3
Turn readfield loop into for loop 2018-05-21 15:49:13 +02:00
marcelbuesing
6b6e19b975
Fix rewriting owerwriting buffer twice 2018-05-20 22:16:12 +02:00
marcelbuesing
2dd1b8f9ba
Fix read field return when InfoMsg empty 2018-05-19 19:06:27 +02:00
marcelbuesing
266c8b70ea
Fix i2c read bytes 2018-05-18 22:12:42 +02:00
marcelbuesing
a5f8310bf6
Return I2C error 2018-05-18 17:37:11 +02:00
marcelbuesing
287e673761
Remove TryFrom in order to build with stable 2018-05-18 15:26:35 +02:00