diff options
author | Keith Packard <keithp@keithp.com> | 2017-02-20 12:14:10 -0800 |
---|---|---|
committer | Keith Packard <keithp@keithp.com> | 2017-02-20 12:34:02 -0800 |
commit | 80fd7f7bef5320ce86048d74dc4a72e1ec361120 (patch) | |
tree | 205d7acbee316e22a8f22806b62160d0b40b815f /src | |
parent | 72ea90d28817549c4343d2fea03a4c951f849cbe (diff) |
altos/stm: Make i2c code handle PCLK1 of 24MHz
Just adds the necessary defines to the code.
Signed-off-by: Keith Packard <keithp@keithp.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/stm/ao_i2c_stm.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/stm/ao_i2c_stm.c b/src/stm/ao_i2c_stm.c index 29a8f173..59cad495 100644 --- a/src/stm/ao_i2c_stm.c +++ b/src/stm/ao_i2c_stm.c @@ -75,6 +75,9 @@ uint8_t ao_i2c_mutex[STM_NUM_I2C]; #if AO_PCLK1 == 16000000 # define AO_STM_I2C_CR2_FREQ STM_I2C_CR2_FREQ_16_MHZ #endif +#if AO_PCLK1 == 24000000 +# define AO_STM_I2C_CR2_FREQ STM_I2C_CR2_FREQ_24_MHZ +#endif #if AO_PCLK1 == 32000000 # define AO_STM_I2C_CR2_FREQ STM_I2C_CR2_FREQ_32_MHZ #endif |