summaryrefslogtreecommitdiff
path: root/nuttx/arch/arm/src/stm32/stm32_i2c.c
diff options
context:
space:
mode:
authorpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2013-02-10 20:35:34 +0000
committerpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2013-02-10 20:35:34 +0000
commit7f70b0ff398db4b0f6640b7758893bd97d62488c (patch)
tree26595f05efaac1fb628309a768cde2c0bc25b9aa /nuttx/arch/arm/src/stm32/stm32_i2c.c
parent610648a0b4a6115a3d73a40ae108fb18a75c1965 (diff)
downloadpx4-nuttx-7f70b0ff398db4b0f6640b7758893bd97d62488c.tar.gz
px4-nuttx-7f70b0ff398db4b0f6640b7758893bd97d62488c.tar.bz2
px4-nuttx-7f70b0ff398db4b0f6640b7758893bd97d62488c.zip
Add STM32 F3 I2C register definitions
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@5636 42af7a65-404d-4744-a932-0658087f49c3
Diffstat (limited to 'nuttx/arch/arm/src/stm32/stm32_i2c.c')
-rw-r--r--nuttx/arch/arm/src/stm32/stm32_i2c.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/nuttx/arch/arm/src/stm32/stm32_i2c.c b/nuttx/arch/arm/src/stm32/stm32_i2c.c
index c2d638dd4..ee1033635 100644
--- a/nuttx/arch/arm/src/stm32/stm32_i2c.c
+++ b/nuttx/arch/arm/src/stm32/stm32_i2c.c
@@ -7,7 +7,7 @@
*
* With extensions, modifications by:
*
- * Copyright (C) 2011-2012 Gregory Nutt. All rights reserved.
+ * Copyright (C) 2011-2013 Gregory Nutt. All rights reserved.
* Author: Gregroy Nutt <gnutt@nuttx.org>
*
* Redistribution and use in source and binary forms, with or without
@@ -93,8 +93,15 @@
#include "stm32_i2c.h"
#include "stm32_waste.h"
+/* At least one I2C peripheral must be enabled */
+
#if defined(CONFIG_STM32_I2C1) || defined(CONFIG_STM32_I2C2) || defined(CONFIG_STM32_I2C3)
+/* This implementation is for the STM32 F1, F2, and F4 only */
+
+#if defined(CONFIG_STM32_STM32F10XX) || defined(CONFIG_STM32_STM32F20XX) || \
+ defined(CONFIG_STM32_STM32F40XX)
+
/************************************************************************************
* Pre-processor Definitions
************************************************************************************/
@@ -2086,4 +2093,5 @@ out:
}
#endif /* CONFIG_I2C_RESET */
+#endif /* CONFIG_STM32_STM32F10XX || CONFIG_STM32_STM32F20XX || CONFIG_STM32_STM32F40XX */
#endif /* CONFIG_STM32_I2C1 || CONFIG_STM32_I2C2 || CONFIG_STM32_I2C3 */