From a3cb11875de44a070c727bff2c1f69d8d35a4e8f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B6rn=20Quentin?= Date: Tue, 24 Dec 2024 12:16:20 +0100 Subject: [PATCH] Migration guide --- esp-hal/MIGRATING-0.22.md | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/esp-hal/MIGRATING-0.22.md b/esp-hal/MIGRATING-0.22.md index 888366622..c810a0831 100644 --- a/esp-hal/MIGRATING-0.22.md +++ b/esp-hal/MIGRATING-0.22.md @@ -326,6 +326,29 @@ To avoid abbreviations and contractions (as per the esp-hal guidelines), some er + Error::ZeroLengthInvalid ``` +## I2C Configuration changes + +The timeout field in `Config` changed from `Option` to a dedicated `Timeout` enum. + +```diff +- timeout: Some(10) ++ timeout: Timeout::BusCycles(10) +``` + +or (ESP32, ESP32-S2) + +```diff +- timeout: None ++ timeout: Timeout::Max +``` + +or (other chips) + +```diff +- timeout: None ++ timeout: Timeout::Disabled +``` + ## The crate prelude has been removed The reexports that were previously part of the prelude are available through other paths: