diff options
author | patacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3> | 2011-03-14 14:14:54 +0000 |
---|---|---|
committer | patacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3> | 2011-03-14 14:14:54 +0000 |
commit | ee2220174467b0e456446f5faaef1bd1660f786e (patch) | |
tree | 61937f54d7558e15f984b0450c2958e9ed45b5bd /nuttx/configs/vsn/include | |
parent | 38121cceb67b2408c5aab1d3e9998accef0d83c8 (diff) | |
download | px4-nuttx-ee2220174467b0e456446f5faaef1bd1660f786e.tar.gz px4-nuttx-ee2220174467b0e456446f5faaef1bd1660f786e.tar.bz2 px4-nuttx-ee2220174467b0e456446f5faaef1bd1660f786e.zip |
VSN/apps update
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@3378 42af7a65-404d-4744-a932-0658087f49c3
Diffstat (limited to 'nuttx/configs/vsn/include')
-rw-r--r-- | nuttx/configs/vsn/include/board.h | 33 | ||||
-rw-r--r-- | nuttx/configs/vsn/include/power.h | 71 |
2 files changed, 92 insertions, 12 deletions
diff --git a/nuttx/configs/vsn/include/board.h b/nuttx/configs/vsn/include/board.h index f4ad540c7..5c07f075e 100644 --- a/nuttx/configs/vsn/include/board.h +++ b/nuttx/configs/vsn/include/board.h @@ -1,5 +1,5 @@ /************************************************************************************ - * configs/vsn-1.2/include/board.h + * configs/vsn/include/board.h * include/arch/board/board.h * * Copyright (C) 2009 Gregory Nutt. All rights reserved. @@ -183,10 +183,11 @@ extern "C" { #endif /************************************************************************************ - * Public Function Prototypes + * Board Clock Configuration, called immediatelly after boot ************************************************************************************/ - EXTERN void stm32_board_clockconfig(void); +EXTERN void stm32_board_clockconfig(void); + /************************************************************************************ * Name: stm32_boardinitialize @@ -200,15 +201,9 @@ extern "C" { EXTERN void stm32_boardinitialize(void); + /************************************************************************************ - * Button support. - * - * Description: - * up_buttoninit() must be called to initialize button resources. After that, - * up_buttons() may be called to collect the state of all buttons. up_buttons() - * returns an 8-bit bit set with each bit associated with a button. See the - * BUTTON_* and JOYSTICK_* definitions above for the meaning of each bit. - * + * Button support. (TODO: button is not yet supported) ************************************************************************************/ #ifdef CONFIG_ARCH_BUTTONS @@ -216,11 +211,25 @@ EXTERN void up_buttoninit(void); EXTERN uint8_t up_buttons(void); #endif -/* Other peripherals startup routines, all returning OK on success */ + +/************************************************************************************ + * Memories + * - SDcard is tested to work up to 2 GB + * - RAMTRON has size of 128 kB + ************************************************************************************/ + EXTERN int up_sdcard(void); EXTERN int up_ramtron(void); +/************************************************************************************ + * Public Power Supply Contol + ************************************************************************************/ + +void board_power_reboot(void); +void board_power_off(void); + + #undef EXTERN #if defined(__cplusplus) } diff --git a/nuttx/configs/vsn/include/power.h b/nuttx/configs/vsn/include/power.h new file mode 100644 index 000000000..960c40fb1 --- /dev/null +++ b/nuttx/configs/vsn/include/power.h @@ -0,0 +1,71 @@ +/************************************************************************************
+ * configs/vsn/include/power.h
+ * include/arch/board/power.h
+ *
+ * Copyright (C) 2011 Uros Platise. All rights reserved
+ *
+ * Authors: Uros Platise <uros.platise@isotel.eu>
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ *
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in
+ * the documentation and/or other materials provided with the
+ * distribution.
+ * 3. Neither the name NuttX nor the names of its contributors may be
+ * used to endorse or promote products derived from this software
+ * without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
+ * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+ * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
+ * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
+ * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
+ * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+ * POSSIBILITY OF SUCH DAMAGE.
+ *
+ ************************************************************************************/
+
+#ifndef __ARCH_BOARD_POWER_H
+#define __ARCH_BOARD_POWER_H
+
+
+/************************************************************************************
+ * Included Files
+ ************************************************************************************/
+
+#ifndef __ASSEMBLY__
+#undef EXTERN
+#if defined(__cplusplus)
+#define EXTERN extern "C"
+extern "C" {
+#else
+#define EXTERN extern
+#endif
+
+/************************************************************************************
+ * Public Power Supply Contol
+ ************************************************************************************/
+
+void board_power_reboot(void);
+
+/* If this function returns, it means, that it was not possible to power-off the board */
+void board_power_off(void);
+
+
+#undef EXTERN
+#if defined(__cplusplus)
+}
+#endif
+
+#endif /* __ASSEMBLY__ */
+#endif /* __ARCH_BOARD_POWER_H */
|