From 355701525e048e1f77e64bc5dc4546c0e5d86fba Mon Sep 17 00:00:00 2001 From: Uwe Hermann Date: Sat, 18 Jul 2009 05:34:38 +0200 Subject: [PATCH] Add initial minimal rcc.h implementation (not complete). --- include/libopenstm32.h | 1 + include/libopenstm32/rcc.h | 30 ++++++++++++++++++++++++++++++ 2 files changed, 31 insertions(+) create mode 100644 include/libopenstm32/rcc.h diff --git a/include/libopenstm32.h b/include/libopenstm32.h index 3196ca81..82ebe9bd 100644 --- a/include/libopenstm32.h +++ b/include/libopenstm32.h @@ -23,6 +23,7 @@ #include "libopenstm32/common.h" #include "libopenstm32/memorymap.h" +#include "libopenstm32/rcc.h" #include "libopenstm32/gpio.h" #endif diff --git a/include/libopenstm32/rcc.h b/include/libopenstm32/rcc.h new file mode 100644 index 00000000..2f8724a7 --- /dev/null +++ b/include/libopenstm32/rcc.h @@ -0,0 +1,30 @@ +/* + * This file is part of the libopenstm32 project. + * + * Copyright (C) 2009 Uwe Hermann + * + * This program 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 2 of the License, or + * (at your option) any later version. + * + * This program 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, write to the Free Software + * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA + */ + +#ifndef LIBOPENSTM32_RCC_H +#define LIBOPENSTM32_RCC_H + +#include "libopenstm32.h" + +#define RCC_APB2ENR MMIO32(RCC_BASE + 0x18) + +#define RCC_IOPCEN (1 << 4) + +#endif