[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[paparazzi-commits] [4604] booz_drop is now a module
From: |
Gautier Hattenberger |
Subject: |
[paparazzi-commits] [4604] booz_drop is now a module |
Date: |
Tue, 02 Mar 2010 09:13:17 +0000 |
Revision: 4604
http://svn.sv.gnu.org/viewvc/?view=rev&root=paparazzi&revision=4604
Author: gautier
Date: 2010-03-02 09:13:17 +0000 (Tue, 02 Mar 2010)
Log Message:
-----------
booz_drop is now a module
Modified Paths:
--------------
paparazzi3/trunk/sw/airborne/booz/booz2_main.c
Added Paths:
-----------
paparazzi3/trunk/conf/modules/booz_drop.xml
paparazzi3/trunk/sw/airborne/modules/drop/
paparazzi3/trunk/sw/airborne/modules/drop/booz_drop.c
paparazzi3/trunk/sw/airborne/modules/drop/booz_drop.h
Removed Paths:
-------------
paparazzi3/trunk/sw/airborne/booz/booz_drop.c
paparazzi3/trunk/sw/airborne/booz/booz_drop.h
Added: paparazzi3/trunk/conf/modules/booz_drop.xml
===================================================================
--- paparazzi3/trunk/conf/modules/booz_drop.xml (rev 0)
+++ paparazzi3/trunk/conf/modules/booz_drop.xml 2010-03-02 09:13:17 UTC (rev
4604)
@@ -0,0 +1,15 @@
+<!DOCTYPE module SYSTEM "module.dtd">
+
+<module name="drop">
+ <!-- depend require="booz_pwm" -->
+ <header>
+ <file name="booz_drop.h"/>
+ </header>
+ <init fun="booz_drop_init()"/>
+ <periodic fun="booz_drop_periodic()" freq="10."/>
+ <makefile>
+ <flag name="USE_DROP"/>
+ <file name="booz_drop.c"/>
+ </makefile>
+</module>
+
Modified: paparazzi3/trunk/sw/airborne/booz/booz2_main.c
===================================================================
--- paparazzi3/trunk/sw/airborne/booz/booz2_main.c 2010-03-01 18:41:40 UTC
(rev 4603)
+++ paparazzi3/trunk/sw/airborne/booz/booz2_main.c 2010-03-02 09:13:17 UTC
(rev 4604)
@@ -57,10 +57,6 @@
#include "booz2_cam.h"
#endif
-#ifdef USE_DROP
-#include "booz_drop.h"
-#endif
-
#if defined USE_CAM || USE_DROP
#include "booz2_pwm_hw.h"
#endif
@@ -139,10 +135,6 @@
booz2_cam_init();
#endif
-#ifdef USE_DROP
- booz_drop_init();
-#endif
-
#ifdef BOOZ2_SONAR
booz2_sonar_init();
#endif
@@ -212,10 +204,6 @@
RunOnceEvery(50,booz2_cam_periodic());
#endif
-#ifdef USE_DROP
- RunOnceEvery(50,booz_drop_periodic());
-#endif
-
#ifdef BOOZ2_SONAR
booz2_analog_periodic();
#endif
Deleted: paparazzi3/trunk/sw/airborne/booz/booz_drop.c
===================================================================
--- paparazzi3/trunk/sw/airborne/booz/booz_drop.c 2010-03-01 18:41:40 UTC
(rev 4603)
+++ paparazzi3/trunk/sw/airborne/booz/booz_drop.c 2010-03-02 09:13:17 UTC
(rev 4604)
@@ -1,22 +0,0 @@
-#include "booz_drop.h"
-#include "booz2_pwm_hw.h"
-
-
-bool_t booz_drop_ball;
-int16_t booz_drop_servo;
-
-#define DROP_SERVO_OPEN 1700
-#define DROP_SERVO_CLOSED 900
-
-void booz_drop_init(void) {
- booz_drop_ball = FALSE;
- booz_drop_periodic();
-}
-
-void booz_drop_periodic(void) {
- if (booz_drop_ball == TRUE)
- booz_drop_servo = DROP_SERVO_OPEN;
- else
- booz_drop_servo = DROP_SERVO_CLOSED;
- Booz2SetPwmValue(booz_drop_servo);
-}
Deleted: paparazzi3/trunk/sw/airborne/booz/booz_drop.h
===================================================================
--- paparazzi3/trunk/sw/airborne/booz/booz_drop.h 2010-03-01 18:41:40 UTC
(rev 4603)
+++ paparazzi3/trunk/sw/airborne/booz/booz_drop.h 2010-03-02 09:13:17 UTC
(rev 4604)
@@ -1,11 +0,0 @@
-#ifndef BOOZ_DROP_H
-#define BOOZ_DROP_H
-
-#include "std.h"
-
-extern bool_t booz_drop_ball;
-
-extern void booz_drop_init(void);
-extern void booz_drop_periodic(void);
-
-#endif /* BOOZ_DROP_H */
Added: paparazzi3/trunk/sw/airborne/modules/drop/booz_drop.c
===================================================================
--- paparazzi3/trunk/sw/airborne/modules/drop/booz_drop.c
(rev 0)
+++ paparazzi3/trunk/sw/airborne/modules/drop/booz_drop.c 2010-03-02
09:13:17 UTC (rev 4604)
@@ -0,0 +1,45 @@
+/*
+ * $Id: $
+ *
+ * Copyright (C) 2009 Flixr
+ *
+ * This file is part of paparazzi.
+ *
+ * paparazzi 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, or (at your option)
+ * any later version.
+ *
+ * paparazzi 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 paparazzi; see the file COPYING. If not, write to
+ * the Free Software Foundation, 59 Temple Place - Suite 330,
+ * Boston, MA 02111-1307, USA.
+ */
+
+#include "booz_drop.h"
+#include "booz2_pwm_hw.h"
+
+
+bool_t booz_drop_ball;
+int16_t booz_drop_servo;
+
+#define DROP_SERVO_OPEN 1700
+#define DROP_SERVO_CLOSED 900
+
+void booz_drop_init(void) {
+ booz_drop_ball = FALSE;
+ booz_drop_periodic();
+}
+
+void booz_drop_periodic(void) {
+ if (booz_drop_ball == TRUE)
+ booz_drop_servo = DROP_SERVO_OPEN;
+ else
+ booz_drop_servo = DROP_SERVO_CLOSED;
+ Booz2SetPwmValue(booz_drop_servo);
+}
Added: paparazzi3/trunk/sw/airborne/modules/drop/booz_drop.h
===================================================================
--- paparazzi3/trunk/sw/airborne/modules/drop/booz_drop.h
(rev 0)
+++ paparazzi3/trunk/sw/airborne/modules/drop/booz_drop.h 2010-03-02
09:13:17 UTC (rev 4604)
@@ -0,0 +1,35 @@
+/*
+ * $Id: $
+ *
+ * Copyright (C) 2009 Flixr
+ *
+ * This file is part of paparazzi.
+ *
+ * paparazzi 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, or (at your option)
+ * any later version.
+ *
+ * paparazzi 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 paparazzi; see the file COPYING. If not, write to
+ * the Free Software Foundation, 59 Temple Place - Suite 330,
+ * Boston, MA 02111-1307, USA.
+ */
+
+
+#ifndef BOOZ_DROP_H
+#define BOOZ_DROP_H
+
+#include "std.h"
+
+extern bool_t booz_drop_ball;
+
+extern void booz_drop_init(void);
+extern void booz_drop_periodic(void);
+
+#endif /* BOOZ_DROP_H */
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [paparazzi-commits] [4604] booz_drop is now a module,
Gautier Hattenberger <=