From 9a210bdbe35bb3f36e01518284033b34d0db6301 Mon Sep 17 00:00:00 2001 From: Denis Nutiu Date: Sat, 24 Feb 2024 22:20:22 +0200 Subject: [PATCH] fix example for reading_temperature.rs --- examples/reading_temperature.rs | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/examples/reading_temperature.rs b/examples/reading_temperature.rs index 83b7aa1..63f240d 100644 --- a/examples/reading_temperature.rs +++ b/examples/reading_temperature.rs @@ -3,14 +3,14 @@ use bme680::*; use core::result; use core::time::Duration; -use embedded_hal::blocking::delay::DelayMs; -use embedded_hal::blocking::i2c; +use embedded_hal::i2c::blocking::Read; +use embedded_hal::i2c::blocking::Write; +use embedded_hal::delay::blocking::DelayMs; use linux_embedded_hal as hal; use linux_embedded_hal::Delay; use log::info; -fn main( -) -> result::Result<(), Error<::Error, ::Error>> +fn main() -> result::Result<(), Error<::Error, ::Error>> { env_logger::init(); @@ -41,7 +41,7 @@ fn main( info!("Sensor settings: {:?}", sensor_settings); loop { - delay.delay_ms(5000u32); + let _ = delay.delay_ms(5000u32); let power_mode = dev.get_sensor_mode(); info!("Sensor power mode: {:?}", power_mode); info!("Setting forced power modes");