aboutsummaryrefslogtreecommitdiff
path: root/apps/drivers/boards/px4fmu/px4fmu_init.c
diff options
context:
space:
mode:
authorpx4dev <px4@purgatory.org>2012-10-23 22:23:55 -0700
committerpx4dev <px4@purgatory.org>2012-10-23 23:51:13 -0700
commit7b4118a5e7a2da0e352ba30128e42c244f1542c9 (patch)
tree6a51efe957d76e6e5598d39d45b378c8e289fc54 /apps/drivers/boards/px4fmu/px4fmu_init.c
parent4c82f7a1af8cc1d20d0a01474d52e90354959ba4 (diff)
downloadpx4-firmware-7b4118a5e7a2da0e352ba30128e42c244f1542c9.tar.gz
px4-firmware-7b4118a5e7a2da0e352ba30128e42c244f1542c9.tar.bz2
px4-firmware-7b4118a5e7a2da0e352ba30128e42c244f1542c9.zip
Hoist SPI functions.
Diffstat (limited to 'apps/drivers/boards/px4fmu/px4fmu_init.c')
-rw-r--r--apps/drivers/boards/px4fmu/px4fmu_init.c25
1 files changed, 21 insertions, 4 deletions
diff --git a/apps/drivers/boards/px4fmu/px4fmu_init.c b/apps/drivers/boards/px4fmu/px4fmu_init.c
index bb30087e0..249de6034 100644
--- a/apps/drivers/boards/px4fmu/px4fmu_init.c
+++ b/apps/drivers/boards/px4fmu/px4fmu_init.c
@@ -102,7 +102,24 @@
* Public Functions
****************************************************************************/
-__EXPORT int nsh_archinitialize(void);
+/************************************************************************************
+ * Name: stm32_boardinitialize
+ *
+ * Description:
+ * All STM32 architectures must provide the following entry point. This entry point
+ * is called early in the intitialization -- after all memory has been configured
+ * and mapped but before any devices have been initialized.
+ *
+ ************************************************************************************/
+
+__EXPORT void stm32_boardinitialize(void)
+{
+ /* configure SPI interfaces */
+ stm32_spiinitialize();
+
+ /* configure LEDs */
+ up_ledinit();
+}
/****************************************************************************
* Name: nsh_archinitialize
@@ -121,16 +138,16 @@ static struct i2c_dev_s *i2c3;
#include <math.h>
#ifdef __cplusplus
-int matherr(struct __exception *e) {
+__EXPORT int matherr(struct __exception *e) {
return 1;
}
#else
-int matherr(struct exception *e) {
+__EXPORT int matherr(struct exception *e) {
return 1;
}
#endif
-int nsh_archinitialize(void)
+__EXPORT int nsh_archinitialize(void)
{
int result;