mirror of
https://github.com/apache/nuttx.git
synced 2026-10-18 11:39:00 +00:00
mpfs_i2c: Increase TTOA margin to 1ms
Due to interrupt latencies the i2c transfer done interrupt can get deferred by a few hunder microseconds. This makes the i2c transfer timeout way too early, even though the i2c IP block is already done. Fix this by adding a significant amount of margin (1ms) to the timeout value.
This commit is contained in:
parent
255d8c57c0
commit
597b3e6ca7
1 changed files with 1 additions and 1 deletions
|
|
@ -75,7 +75,7 @@
|
|||
/* Gives TTOA in microseconds, ~4.8% bias, +1 rounds up */
|
||||
|
||||
#define I2C_TTOA_US(n, f) ((((n) << 20) / (f)) + 1)
|
||||
#define I2C_TTOA_MARGIN 20
|
||||
#define I2C_TTOA_MARGIN 1000u
|
||||
|
||||
/****************************************************************************
|
||||
* Private Types
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue