aboutsummaryrefslogtreecommitdiffstats
path: root/libmaple/include
diff options
context:
space:
mode:
authorMarti Bolivar <mbolivar@leaflabs.com>2012-06-19 17:29:58 -0400
committerMarti Bolivar <mbolivar@leaflabs.com>2012-06-22 14:06:09 -0400
commitc0e99fcc4958f8ccc4f245a441b523e3e9c84ec3 (patch)
tree411de907d7b5cbdace939b3af6cdd466c0b2c0e4 /libmaple/include
parente9574e9c9bc91a8213d1292c8fcab8a7a93aeb2b (diff)
downloadlibrambutan-c0e99fcc4958f8ccc4f245a441b523e3e9c84ec3.tar.gz
librambutan-c0e99fcc4958f8ccc4f245a441b523e3e9c84ec3.zip
<libmaple/i2c.h>: Cosmetics.
Put CCR definitions after SR2, to keep them in register map order. Signed-off-by: Marti Bolivar <mbolivar@leaflabs.com>
Diffstat (limited to 'libmaple/include')
-rw-r--r--libmaple/include/libmaple/i2c.h12
1 files changed, 6 insertions, 6 deletions
diff --git a/libmaple/include/libmaple/i2c.h b/libmaple/include/libmaple/i2c.h
index f27f8eb..7ee0b9a 100644
--- a/libmaple/include/libmaple/i2c.h
+++ b/libmaple/include/libmaple/i2c.h
@@ -158,12 +158,6 @@ extern i2c_dev* const I2C2;
#define I2C_OAR2_ADD2 0xFE // Interface address
#define I2C_OAR2_ENDUAL 1U // Dual addressing mode enable
-/* Clock control register */
-
-#define I2C_CCR_FS (1U << 15) // Fast mode selection
-#define I2C_CCR_DUTY (1U << 14) // 16/9 duty ratio
-#define I2C_CCR_CCR 0xFFF // Clock control bits
-
/* Status register 1 */
#define I2C_SR1_SMBALERT (1U << 15) // SMBus alert
@@ -192,6 +186,12 @@ extern i2c_dev* const I2C2;
#define I2C_SR2_BUSY (1U << 1) // Bus busy
#define I2C_SR2_MSL (1U << 0) // Master/slave
+/* Clock control register */
+
+#define I2C_CCR_FS (1U << 15) // Fast mode selection
+#define I2C_CCR_DUTY (1U << 14) // 16/9 duty ratio
+#define I2C_CCR_CCR 0xFFF // Clock control bits
+
/*
* Convenience routines
*/