VersBinarii / bme280-rs

A platform agnostic Rust driver for the Bosch BM[PE]-280
Other
59 stars 73 forks source link

Fix cargo build and cargo build --examples #30

Open tweksteen opened 1 year ago

tweksteen commented 1 year ago

Update stm32f4xx-hal to 0.14

stm32f4xx-hal 0.13.2 is pinned on embedded-hal =1.0.0-alpha.7, while bme280 is pinned on =1.0.0-alpha.8. Update the dependency so that cargo build succeeds.

Fix build for examples/

Update Cargo.toml so that examples/rtic.rs can be build. The default build target is not updated, which means it is still possible to run cargo build successfully on x86_64 by default (without installing the thumbv7em toolchain target). I was not able to test this change as I do not have access to this device. Added some documentation to the example on how to run it.

Disable autoexamples in Cargo.toml as examples/basic.rs contains invalid syntax.

It is now possible to build the examples using: $ cargo build --target thumbv7em-none-eabihf --examples