aboutsummaryrefslogtreecommitdiffstats
path: root/os
diff options
context:
space:
mode:
authorgdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4>2014-10-02 16:34:45 +0000
committergdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4>2014-10-02 16:34:45 +0000
commit62556f44e90cb83039dc0c8eae49c60a25e05a21 (patch)
treeb78d247b3122cae0933ef7d9e8c9bf48c0b55294 /os
parent455943c0984deb7f389a28f72ffab58c8b3a5d85 (diff)
downloadChibiOS-62556f44e90cb83039dc0c8eae49c60a25e05a21.tar.gz
ChibiOS-62556f44e90cb83039dc0c8eae49c60a25e05a21.tar.bz2
ChibiOS-62556f44e90cb83039dc0c8eae49c60a25e05a21.zip
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@7351 35acf78f-673a-0410-8e92-d51de3d6d3f4
Diffstat (limited to 'os')
-rw-r--r--os/common/ports/ARMCMx/compilers/GCC/ld/STM32F334x8.ld31
-rw-r--r--os/hal/ports/STM32/STM32F3xx/hal_lld.c2
-rw-r--r--os/hal/ports/STM32/STM32F3xx/stm32_registry.h5
3 files changed, 35 insertions, 3 deletions
diff --git a/os/common/ports/ARMCMx/compilers/GCC/ld/STM32F334x8.ld b/os/common/ports/ARMCMx/compilers/GCC/ld/STM32F334x8.ld
new file mode 100644
index 000000000..8bdc8b676
--- /dev/null
+++ b/os/common/ports/ARMCMx/compilers/GCC/ld/STM32F334x8.ld
@@ -0,0 +1,31 @@
+/*
+ ChibiOS - Copyright (C) 2006,2007,2008,2009,2010,
+ 2011,2012,2013,2014 Giovanni Di Sirio.
+
+ This file is part of ChibiOS.
+
+ ChibiOS is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 3 of the License, or
+ (at your option) any later version.
+
+ ChibiOS is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program. If not, see <http://www.gnu.org/licenses/>.
+*/
+
+/*
+ * STM32F3334x8 memory setup.
+ */
+MEMORY
+{
+ flash : org = 0x08000000, len = 64k
+ ram : org = 0x20000000, len = 12k
+ ccmram : org = 0x10000000, len = 4k
+}
+
+INCLUDE rules.ld
diff --git a/os/hal/ports/STM32/STM32F3xx/hal_lld.c b/os/hal/ports/STM32/STM32F3xx/hal_lld.c
index cfa538e2e..9c02300dc 100644
--- a/os/hal/ports/STM32/STM32F3xx/hal_lld.c
+++ b/os/hal/ports/STM32/STM32F3xx/hal_lld.c
@@ -122,8 +122,10 @@ void hal_lld_init(void) {
among multiple drivers.*/
rccEnableAPB2(RCC_APB2ENR_SYSCFGEN, TRUE);
+#if STM32_HAS_USB
/* USB IRQ relocated to not conflict with CAN.*/
SYSCFG->CFGR1 |= SYSCFG_CFGR1_USB_IT_RMP;
+#endif
}
/**
diff --git a/os/hal/ports/STM32/STM32F3xx/stm32_registry.h b/os/hal/ports/STM32/STM32F3xx/stm32_registry.h
index 1a576e5dd..1336a6ed8 100644
--- a/os/hal/ports/STM32/STM32F3xx/stm32_registry.h
+++ b/os/hal/ports/STM32/STM32F3xx/stm32_registry.h
@@ -1287,11 +1287,10 @@
#define STM32_HAS_OTG2 FALSE
#endif /* defined(STM32F358xC) */
-
/*===========================================================================*/
/* STM32F334xC. */
/*===========================================================================*/
-#if defined(STM32F334xC) || defined(__DOXYGEN__)
+#if defined(STM32F334x8) || defined(__DOXYGEN__)
/* ADC attributes.*/
#define STM32_HAS_ADC1 TRUE
#define STM32_HAS_ADC2 TRUE
@@ -1435,7 +1434,7 @@
#define STM32_HAS_USB FALSE
#define STM32_HAS_OTG1 FALSE
#define STM32_HAS_OTG2 FALSE
-#endif /* defined(STM32F334xC) */
+#endif /* defined(STM32F334x8) */
/** @} */