diff options
| author | Dario Nieuwenhuis <[email protected]> | 2025-08-13 19:49:00 +0200 |
|---|---|---|
| committer | GitHub <[email protected]> | 2025-08-13 19:49:00 +0200 |
| commit | 86973d2186a960f45290d959c905e611f2b56580 (patch) | |
| tree | 939e2ecf1c46040efbe349b94bcab0fa142c0aa3 | |
| parent | f689cd10000d3c5d608907d52c686abcc6c0971f (diff) | |
| parent | b0024ecb45fe5f66549494571e3b11bf2c6ec9b2 (diff) | |
Merge pull request #4543 from mbrieske/fix_blocking_i2c
fix STM32: wait for STOP flag in blocking_write_vectored
| -rw-r--r-- | embassy-stm32/src/i2c/v2.rs | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/embassy-stm32/src/i2c/v2.rs b/embassy-stm32/src/i2c/v2.rs index aeb4c1c00..3b09f1b34 100644 --- a/embassy-stm32/src/i2c/v2.rs +++ b/embassy-stm32/src/i2c/v2.rs | |||
| @@ -582,9 +582,11 @@ impl<'d, M: Mode, IM: MasterMode> I2c<'d, M, IM> { | |||
| 582 | } | 582 | } |
| 583 | } | 583 | } |
| 584 | // Wait until the write finishes | 584 | // Wait until the write finishes |
| 585 | let result = self.wait_tc(timeout); | 585 | self.wait_tc(timeout)?; |
| 586 | self.master_stop(); | 586 | self.master_stop(); |
| 587 | result | 587 | self.wait_stop(timeout)?; |
| 588 | |||
| 589 | Ok(()) | ||
| 588 | } | 590 | } |
| 589 | } | 591 | } |
| 590 | 592 | ||
