dts: bindings: Add optional timings capability
By default the I2C timing (I2C_TIMINGR register) of I2C V2 peripheral is computed depending on clocks at runtime with relatively low precision. This optional property allows to provide a list of pre-computed values (typically computed from STM32CubeMX SW tool) instead of using runtime algorithm. The precomputed value is only valid for a given clock configuration and I2C speed setting, so this valid configuration is provided with each value entry. Signed-off-by: Laurent Meunier <laurent.meunier@st.com>
This commit is contained in:
parent
58a75eb50e
commit
ea491b3a9f
@ -13,3 +13,28 @@ properties:
|
||||
|
||||
interrupts:
|
||||
required: true
|
||||
|
||||
timings:
|
||||
type: array
|
||||
required: false
|
||||
description: |
|
||||
An optional table of pre-computed i2c timing values with the
|
||||
matching clock configuration.
|
||||
|
||||
Precise timings values for a given Hardware can be pre-computed
|
||||
with a tool like STM32CubeMX or directly from I2C_TIMINGR register
|
||||
description.
|
||||
|
||||
Because timing value is valid for a given I2C peripheral clock
|
||||
frequency and target I2C bus clock, each timing value must be
|
||||
provided with the matching configuration.
|
||||
|
||||
The resulting table entries should look like <periph_clock
|
||||
clock-frequency timing>
|
||||
|
||||
For example timings could be defined as
|
||||
|
||||
timings = <64000000 I2C_BITRATE_STANDARD 0x10707DBC>,
|
||||
<64000000 I2C_BITRATE_FAST 0x00603D56>,
|
||||
<56000000 I2C_BITRATE_STANDARD 0x10606DA4>,
|
||||
<56000000 I2C_BITRATE_FAST 0x00501D63>;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user