aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarti Bolivar <mbolivar@leaflabs.com>2011-06-11 19:55:40 -0400
committerMarti Bolivar <mbolivar@leaflabs.com>2011-06-11 20:05:42 -0400
commit8abe719099efe1ebbefc5bfb104951b001cc7515 (patch)
tree46e5347484e87cdef0dcd479b9dcb546d675f0ae
parentd6e359e227b6cefbd8d4f80ee3d25773c8b75a28 (diff)
downloadlibrambutan-8abe719099efe1ebbefc5bfb104951b001cc7515.tar.gz
librambutan-8abe719099efe1ebbefc5bfb104951b001cc7515.zip
stm32.h: Don't blindly assume PCLK1 and PCLK2 values.
Put the PCLK1 and PCLK2 within #ifndef guards. This assumption is biased towards LeafLabs boards.
-rw-r--r--libmaple/stm32.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/libmaple/stm32.h b/libmaple/stm32.h
index 21c18df..985b941 100644
--- a/libmaple/stm32.h
+++ b/libmaple/stm32.h
@@ -5,8 +5,12 @@
#ifndef _STM32_H_
#define _STM32_H_
+#ifndef PCLK1
#define PCLK1 36000000U
+#endif
+#ifndef PCLK2
#define PCLK2 72000000U
+#endif
#ifdef STM32_MEDIUM_DENSITY
#define NR_INTERRUPTS 43