diff options
| author | Andres Oliva <[email protected]> | 2023-10-11 22:20:17 +0200 |
|---|---|---|
| committer | Andres Oliva <[email protected]> | 2023-10-11 22:20:17 +0200 |
| commit | 1cd3ae9bd51a34a29b0d34374f8ecc08b9b830f9 (patch) | |
| tree | 65682ca8f2be45fd67a11e9b702063e8e917c18b | |
| parent | bfcca79c1e51a5cae6c5c40018b4a923e798c5ca (diff) | |
Add comment about feature gate on I2C mod
| -rw-r--r-- | embassy-stm32/src/i2c/mod.rs | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/embassy-stm32/src/i2c/mod.rs b/embassy-stm32/src/i2c/mod.rs index c35f59977..d5bb2ed21 100644 --- a/embassy-stm32/src/i2c/mod.rs +++ b/embassy-stm32/src/i2c/mod.rs | |||
| @@ -2,6 +2,8 @@ | |||
| 2 | 2 | ||
| 3 | use crate::interrupt; | 3 | use crate::interrupt; |
| 4 | 4 | ||
| 5 | // I2C V2 is gated on the `time` feature because timing facilities are necessary | ||
| 6 | // to provide timeout functionality in order to prevent some APIs from stalling indefinitely | ||
| 5 | #[cfg_attr(i2c_v1, path = "v1.rs")] | 7 | #[cfg_attr(i2c_v1, path = "v1.rs")] |
| 6 | #[cfg_attr(all(i2c_v2, feature = "time"), path = "v2.rs")] | 8 | #[cfg_attr(all(i2c_v2, feature = "time"), path = "v2.rs")] |
| 7 | mod _version; | 9 | mod _version; |
