projects
/
fw
/
altos
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
72ea90d
)
altos/stm: Make i2c code handle PCLK1 of 24MHz
author
Keith Packard
<keithp@keithp.com>
Mon, 20 Feb 2017 20:14:10 +0000
(12:14 -0800)
committer
Keith Packard
<keithp@keithp.com>
Mon, 20 Feb 2017 20:34:02 +0000
(12:34 -0800)
Just adds the necessary defines to the code.
Signed-off-by: Keith Packard <keithp@keithp.com>
src/stm/ao_i2c_stm.c
patch
|
blob
|
history
diff --git
a/src/stm/ao_i2c_stm.c
b/src/stm/ao_i2c_stm.c
index 29a8f173f948682d81b1f367d07b20ec7c0687fe..59cad4951058fce99d360da9ce91cbc47f58720c 100644
(file)
--- 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