aboutsummaryrefslogtreecommitdiff
path: root/src/platforms/stm32/gpio.h
diff options
context:
space:
mode:
authorGareth McMullin2015-03-01 22:16:04 -0800
committerGareth McMullin2015-03-01 22:16:04 -0800
commit4d4813de87721528fc9a06174dd1da5c245ae2f3 (patch)
tree298266ed212f574b51d21d5b3fa18d37a4388907 /src/platforms/stm32/gpio.h
parent9d80641261cee52fdf1976caa41d4fd24c392c9a (diff)
Clean up includes everywhere.
All source files include general.h first and before anything else. This inlcludes platform.h and platform_support.h No header file needs to include to include any of these, but should include any others needed for it's own declarations.
Diffstat (limited to 'src/platforms/stm32/gpio.h')
-rw-r--r--src/platforms/stm32/gpio.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/platforms/stm32/gpio.h b/src/platforms/stm32/gpio.h
index 035f3c9..ee8275e 100644
--- a/src/platforms/stm32/gpio.h
+++ b/src/platforms/stm32/gpio.h
@@ -20,6 +20,16 @@
#ifndef __GPIO_H
#define __GPIO_H
+#include <libopencm3/cm3/common.h>
+
+#ifndef STM32F4
+# include <libopencm3/stm32/f1/memorymap.h>
+# include <libopencm3/stm32/f1/gpio.h>
+#else
+# include <libopencm3/stm32/f4/memorymap.h>
+# include <libopencm3/stm32/f4/gpio.h>
+#endif
+
#define INLINE_GPIO
#define gpio_set_val(port, pin, val) do { \