Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/thirdpin/libopencm3.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBuFran <BuFran@seznam.cz>2013-07-10 20:18:40 +0400
committerPiotr Esden-Tempski <piotr@esden.net>2013-08-23 04:18:39 +0400
commitcd9ba870732ba156213de48403ffbd711b1cbe90 (patch)
treedf75ddf33008545ee53c779441890c8df8be2e35 /include/libopencm3/stm32/common/syscfg_common_l1f234.h
parent9f8dd28a5c10b7805285c835f6a295ed110e54bc (diff)
[STM32F0:SYSCFG] Add support for SYSCFG. Old file moved to common directory for L1 and F234
Diffstat (limited to 'include/libopencm3/stm32/common/syscfg_common_l1f234.h')
-rw-r--r--include/libopencm3/stm32/common/syscfg_common_l1f234.h60
1 files changed, 60 insertions, 0 deletions
diff --git a/include/libopencm3/stm32/common/syscfg_common_l1f234.h b/include/libopencm3/stm32/common/syscfg_common_l1f234.h
new file mode 100644
index 00000000..41e501ee
--- /dev/null
+++ b/include/libopencm3/stm32/common/syscfg_common_l1f234.h
@@ -0,0 +1,60 @@
+/*
+ * This file is part of the libopencm3 project.
+ *
+ * Copyright (C) 2011 Fergus Noble <fergusnoble@gmail.com>
+ *
+ * This library is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This library 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 Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with this library. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+/* THIS FILE SHOULD NOT BE INCLUDED DIRECTLY, BUT ONLY VIA SPI.H
+The order of header inclusion is important. spi.h includes the device
+specific memorymap.h header before including this header file.*/
+
+/** @cond */
+#if defined(LIBOPENCM3_SYSCFG_H)
+/** @endcond */
+#ifndef LIBOPENCM3_SYSCFG_COMMON_L1F234_H
+#define LIBOPENCM3_SYSCFG_COMMON_L1F234_H
+
+
+#include <libopencm3/stm32/memorymap.h>
+
+
+/* --- SYSCFG registers ---------------------------------------------------- */
+
+#define SYSCFG_MEMRM MMIO32(SYSCFG_BASE + 0x00)
+
+#define SYSCFG_PMC MMIO32(SYSCFG_BASE + 0x04)
+
+/* External interrupt configuration register 1 (SYSCFG_EXTICR1) */
+#define SYSCFG_EXTICR1 MMIO32(SYSCFG_BASE + 0x08)
+
+/* External interrupt configuration register 2 (SYSCFG_EXTICR2) */
+#define SYSCFG_EXTICR2 MMIO32(SYSCFG_BASE + 0x0c)
+
+/* External interrupt configuration register 3 (SYSCFG_EXTICR3) */
+#define SYSCFG_EXTICR3 MMIO32(SYSCFG_BASE + 0x10)
+
+/* External interrupt configuration register 4 (SYSCFG_EXTICR4) */
+#define SYSCFG_EXTICR4 MMIO32(SYSCFG_BASE + 0x14)
+
+#define SYSCFG_CMPCR MMIO32(SYSCFG_BASE + 0x20)
+
+#endif
+
+/** @cond */
+#else
+#warning "syscfg_common_l1f234.h should not be included explicitly, only via syscfg.h"
+#endif
+/** @endcond */