paparazzi-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[paparazzi-commits] [6011] fix some more actuators includes


From: Felix Ruess
Subject: [paparazzi-commits] [6011] fix some more actuators includes
Date: Tue, 28 Sep 2010 14:48:38 +0000

Revision: 6011
          http://svn.sv.gnu.org/viewvc/?view=rev&root=paparazzi&revision=6011
Author:   flixr
Date:     2010-09-28 14:48:38 +0000 (Tue, 28 Sep 2010)
Log Message:
-----------
fix some more actuators includes

Modified Paths:
--------------
    paparazzi3/trunk/sw/airborne/beth/main_stm32.c
    paparazzi3/trunk/sw/airborne/booz/booz2_telemetry.h
    paparazzi3/trunk/sw/airborne/booz/test/booz2_test_mc.c
    paparazzi3/trunk/sw/airborne/csc/arm7/props_csc.h
    paparazzi3/trunk/sw/airborne/csc/csc_servos.c
    paparazzi3/trunk/sw/airborne/csc/csc_telemetry.h
    paparazzi3/trunk/sw/airborne/csc/mercury_ap.c
    paparazzi3/trunk/sw/airborne/firmwares/rotorcraft/main.c
    paparazzi3/trunk/sw/airborne/test/test_actuators.c

Modified: paparazzi3/trunk/sw/airborne/beth/main_stm32.c
===================================================================
--- paparazzi3/trunk/sw/airborne/beth/main_stm32.c      2010-09-28 14:05:43 UTC 
(rev 6010)
+++ paparazzi3/trunk/sw/airborne/beth/main_stm32.c      2010-09-28 14:48:38 UTC 
(rev 6011)
@@ -1,6 +1,6 @@
 /*
  * $Id$
- *  
+ *
  * Copyright (C) 2010 Antoine Drouin <address@hidden>
  *
  * This file is part of paparazzi.
@@ -18,7 +18,7 @@
  * 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. 
+ * Boston, MA 02111-1307, USA.
  */
 
 
@@ -29,7 +29,7 @@
 #include "sys_time.h"
 #include "downlink.h"
 #include "booz/booz2_commands.h"
-#include "booz/actuators.h"
+#include <firmwares/rotorcraft/actuators.h>
 //#include "booz/booz_radio_control.h"
 #include <firmwares/rotorcraft/imu.h>
 #include "lisa/lisa_overo_link.h"
@@ -131,7 +131,7 @@
   overo_link.up.msg.gyro.p = imu.gyro_unscaled.p;
   overo_link.up.msg.gyro.q = imu.gyro_unscaled.q;
   overo_link.up.msg.gyro.r = imu.gyro_unscaled.r;
-  
+
   //can_err_flags (uint16) represents the board number that is not 
communicating regularly
   //spi_errors (uint16) reflects the number of crc errors on the spi link
   //TODO: if >10% of messages are coming in with crc errors, assume something 
is really wrong
@@ -161,25 +161,25 @@
 
   if (cnt == 0) {
     DOWNLINK_SEND_IMU_GYRO_RAW(DefaultChannel,
-                              &imu.gyro_unscaled.p,
-                              &imu.gyro_unscaled.q,
-                              &imu.gyro_unscaled.r);
-    
+                   &imu.gyro_unscaled.p,
+                   &imu.gyro_unscaled.q,
+                   &imu.gyro_unscaled.r);
+
     DOWNLINK_SEND_IMU_ACCEL_RAW(DefaultChannel,
-                               &imu.accel_unscaled.x,
-                               &imu.accel_unscaled.y,
-                               &imu.accel_unscaled.z);
+                &imu.accel_unscaled.x,
+                &imu.accel_unscaled.y,
+                &imu.accel_unscaled.z);
   }
   else if (cnt == 7) {
     DOWNLINK_SEND_BOOZ2_GYRO(DefaultChannel,
-                            &imu.gyro.p,
-                            &imu.gyro.q,
-                            &imu.gyro.r);
-    
+                 &imu.gyro.p,
+                 &imu.gyro.q,
+                 &imu.gyro.r);
+
     DOWNLINK_SEND_BOOZ2_ACCEL(DefaultChannel,
-                             &imu.accel.x,
-                             &imu.accel.y,
-                             &imu.accel.z);
+                  &imu.accel.x,
+                  &imu.accel.y,
+                  &imu.accel.z);
   }
 }
 
@@ -192,15 +192,15 @@
 
   if (cnt%2) {
     DOWNLINK_SEND_BOOZ2_MAG(DefaultChannel,
-                           &imu.mag.x,
-                           &imu.mag.y,
-                           &imu.mag.z);
+                &imu.mag.x,
+                &imu.mag.y,
+                &imu.mag.z);
   }
   else {
     DOWNLINK_SEND_IMU_MAG_RAW(DefaultChannel,
-                             &imu.mag_unscaled.x,
-                             &imu.mag_unscaled.y,
-                             &imu.mag_unscaled.z);
+                  &imu.mag_unscaled.x,
+                  &imu.mag_unscaled.y,
+                  &imu.mag_unscaled.z);
   }
 }
 

Modified: paparazzi3/trunk/sw/airborne/booz/booz2_telemetry.h
===================================================================
--- paparazzi3/trunk/sw/airborne/booz/booz2_telemetry.h 2010-09-28 14:05:43 UTC 
(rev 6010)
+++ paparazzi3/trunk/sw/airborne/booz/booz2_telemetry.h 2010-09-28 14:48:38 UTC 
(rev 6011)
@@ -37,7 +37,7 @@
 #include "autopilot.h"
 #include <firmwares/rotorcraft/guidance.h>
 
-#include "actuators.h"
+#include <firmwares/rotorcraft/actuators.h>
 
 #ifndef TELEMETRY_STARTUP_DELAY
 #define TELEMETRY_STARTUP_DELAY 0

Modified: paparazzi3/trunk/sw/airborne/booz/test/booz2_test_mc.c
===================================================================
--- paparazzi3/trunk/sw/airborne/booz/test/booz2_test_mc.c      2010-09-28 
14:05:43 UTC (rev 6010)
+++ paparazzi3/trunk/sw/airborne/booz/test/booz2_test_mc.c      2010-09-28 
14:48:38 UTC (rev 6011)
@@ -1,6 +1,6 @@
 /*
  * $Id$
- *  
+ *
  * Copyright (C) 2008-2009 Antoine Drouin <address@hidden>
  *
  * This file is part of paparazzi.
@@ -18,7 +18,7 @@
  * 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. 
+ * Boston, MA 02111-1307, USA.
  */
 
 #include <inttypes.h>
@@ -34,7 +34,7 @@
 
 #include "commands.h"
 #include "i2c.h"
-#include "actuators.h"
+#include <firmwares/rotorcraft/actuators.h>
 
 static inline void main_init( void );
 static inline void main_periodic_task( void );
@@ -67,15 +67,14 @@
 static inline void main_periodic_task( void ) {
   RunOnceEvery(50, {LED_TOGGLE(2); DOWNLINK_SEND_TIME(&cpu_time_sec);});
 
-  Actuator(SERVO_FRONT) = 20;                                
-  Actuator(SERVO_BACK)  = 20;                                
-  Actuator(SERVO_RIGHT) = 20;                                
-  Actuator(SERVO_LEFT)  = 20;                                
-  ActuatorsCommit();                                         
+  Actuator(SERVO_FRONT) = 20;
+  Actuator(SERVO_BACK)  = 20;
+  Actuator(SERVO_RIGHT) = 20;
+  Actuator(SERVO_LEFT)  = 20;
+  ActuatorsCommit();
 
 }
 
 static inline void main_event_task( void ) {
 
 }
-

Modified: paparazzi3/trunk/sw/airborne/csc/arm7/props_csc.h
===================================================================
--- paparazzi3/trunk/sw/airborne/csc/arm7/props_csc.h   2010-09-28 14:05:43 UTC 
(rev 6010)
+++ paparazzi3/trunk/sw/airborne/csc/arm7/props_csc.h   2010-09-28 14:48:38 UTC 
(rev 6011)
@@ -2,7 +2,7 @@
 #define PROPS_CSC_H
 
 #include "airframe.h"
-#include "actuators.h"
+#include <firmwares/rotorcraft/actuators.h>
 #include "sys_time.h"
 #include "csc_ap_link.h"
 #include "csc_msg_def.h"

Modified: paparazzi3/trunk/sw/airborne/csc/csc_servos.c
===================================================================
--- paparazzi3/trunk/sw/airborne/csc/csc_servos.c       2010-09-28 14:05:43 UTC 
(rev 6010)
+++ paparazzi3/trunk/sw/airborne/csc/csc_servos.c       2010-09-28 14:48:38 UTC 
(rev 6011)
@@ -3,20 +3,20 @@
 #include "LPC21xx.h"
 #include "std.h"
 #include "sys_time.h"
-#include "actuators.h"
+#include <firmwares/rotorcraft/actuators.h>
 #include "airframe.h"
 #include ACTUATORS
 
 #define CSC_SERVOS_NB 4
 
 static uint32_t csc_servos_rng[] = 
{SYS_TICS_OF_USEC(SERVO_S1_MAX-SERVO_S1_MIN),
-                                   SYS_TICS_OF_USEC(SERVO_S2_MAX-SERVO_S2_MIN),
-                                   SYS_TICS_OF_USEC(SERVO_S3_MAX-SERVO_S3_MIN),
-                                   
SYS_TICS_OF_USEC(SERVO_S4_MAX-SERVO_S4_MIN)};
+                    SYS_TICS_OF_USEC(SERVO_S2_MAX-SERVO_S2_MIN),
+                    SYS_TICS_OF_USEC(SERVO_S3_MAX-SERVO_S3_MIN),
+                    SYS_TICS_OF_USEC(SERVO_S4_MAX-SERVO_S4_MIN)};
 static uint32_t csc_servos_min[] = {SYS_TICS_OF_USEC(SERVO_S1_MIN),
-                                   SYS_TICS_OF_USEC(SERVO_S2_MIN),
-                                   SYS_TICS_OF_USEC(SERVO_S3_MIN),
-                                   SYS_TICS_OF_USEC(SERVO_S4_MIN)};
+                    SYS_TICS_OF_USEC(SERVO_S2_MIN),
+                    SYS_TICS_OF_USEC(SERVO_S3_MIN),
+                    SYS_TICS_OF_USEC(SERVO_S4_MIN)};
 
 
 void csc_servos_init(void)
@@ -31,7 +31,7 @@
   if(val == 0) csc_servo_set(id,0);
   else{
     uint32_t ticks = csc_servos_rng[id]*(val-1);
-  
+
     csc_servo_set(id,ticks/((1<<16)-2) + csc_servos_min[id]);
   }
 }
@@ -74,5 +74,3 @@
 
   csc_servos_commit();
 }
-
-

Modified: paparazzi3/trunk/sw/airborne/csc/csc_telemetry.h
===================================================================
--- paparazzi3/trunk/sw/airborne/csc/csc_telemetry.h    2010-09-28 14:05:43 UTC 
(rev 6010)
+++ paparazzi3/trunk/sw/airborne/csc/csc_telemetry.h    2010-09-28 14:48:38 UTC 
(rev 6011)
@@ -1,6 +1,6 @@
 /*
  * $Id: booz2_telemetry.c 3002 2009-02-10 11:36:07Z poine $
- *  
+ *
  * Copyright (C) 2008  Antoine Drouin
  *
  * This file is part of paparazzi.
@@ -18,14 +18,14 @@
  * 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. 
+ * Boston, MA 02111-1307, USA.
  *
  */
 
 #ifndef CSC_TELEMETRY_H
 #define CSC_TELEMETRY_H
 
-#include "actuators.h"
+#include <firmwares/rotorcraft/actuators.h>
 #include <inttypes.h>
 
 extern uint8_t telemetry_mode_Ap_DefaultChannel;
@@ -72,7 +72,7 @@
 #include "booz_radio_control.h"
 #define PERIODIC_SEND_RC(_chan) DOWNLINK_SEND_RC(_chan, 
RADIO_CONTROL_NB_CHANNEL, radio_control.values)
 #define PERIODIC_SEND_FBW_STATUS(_chan) { uint16_t current; 
DOWNLINK_SEND_FBW_STATUS(_chan, &radio_control.status, &pprz_mode, &vsupply, 
&current); }
-#else 
+#else
 #ifdef RADIO_CONTROL
 #define PERIODIC_SEND_RC(_chan) DOWNLINK_SEND_RC(_chan, PPM_NB_PULSES, 
rc_values)
 #define PERIODIC_SEND_FBW_STATUS(_chan) { uint16_t current; 
DOWNLINK_SEND_FBW_STATUS(_chan, &rc_status, &pprz_mode, &vsupply, &current); }
@@ -81,36 +81,36 @@
 
 #ifdef USE_GPS
 #define PERIODIC_SEND_BOOZ2_GPS(_chan) {                       \
-DOWNLINK_SEND_BOOZ2_GPS( _chan,                                \
+DOWNLINK_SEND_BOOZ2_GPS( _chan,                 \
                          &booz_ins_gps_pos_cm_ned.x,           \
                          &booz_ins_gps_pos_cm_ned.y,           \
-                            &booz_ins_gps_pos_cm_ned.z,        \
-                            &booz_gps_state.ecef_speed.x,      \
-                            &booz_gps_state.ecef_speed.y,      \
-                            &booz_gps_state.ecef_speed.z,      \
-                            &booz_gps_state.pacc,              \
-                            &booz_gps_state.sacc,              \
-                            &booz_gps_state.pdop,              \
-                            &booz_gps_state.num_sv,            \
-                            &booz_gps_state.fix)               \
+                 &booz_ins_gps_pos_cm_ned.z,   \
+                 &booz_gps_state.ecef_speed.x, \
+                 &booz_gps_state.ecef_speed.y, \
+                 &booz_gps_state.ecef_speed.z, \
+                 &booz_gps_state.pacc,         \
+                 &booz_gps_state.sacc,         \
+                 &booz_gps_state.pdop,         \
+                 &booz_gps_state.num_sv,               \
+                 &booz_gps_state.fix)          \
   }
 #endif
 
 #define PERIODIC_SEND_GPS_ERROR(_chan) {                               \
-DOWNLINK_SEND_GPS_ERROR( _chan,                                \
-                            &csc_gps_errors.pos.x,             \
-                          &csc_gps_errors.pos.y,               \
-                          &csc_gps_errors.pos.z,               \
-                          &csc_gps_errors.rate.x,              \
-                          &csc_gps_errors.rate.y,              \
-                          &csc_gps_errors.rate.z)              \
-    }                     
-       
+DOWNLINK_SEND_GPS_ERROR( _chan,                 \
+                 &csc_gps_errors.pos.x,                \
+               &csc_gps_errors.pos.y,          \
+               &csc_gps_errors.pos.z,          \
+               &csc_gps_errors.rate.x,         \
+               &csc_gps_errors.rate.y,         \
+               &csc_gps_errors.rate.z)      \
+    }
+
 #define PERIODIC_SEND_INS3(_chan) { \
-DOWNLINK_SEND_INS3(_chan,        \
+DOWNLINK_SEND_INS3(_chan,     \
 &booz_ins_gps_pos_cm_ned.x,    \
-&booz_ins_gps_pos_cm_ned.y,        \
-&booz_ins_gps_pos_cm_ned.z,        \
+&booz_ins_gps_pos_cm_ned.y,     \
+&booz_ins_gps_pos_cm_ned.z,     \
 &booz_ins_gps_speed_cm_s_ned.x,   \
 &booz_ins_gps_speed_cm_s_ned.y,   \
 &booz_ins_gps_speed_cm_s_ned.z    \

Modified: paparazzi3/trunk/sw/airborne/csc/mercury_ap.c
===================================================================
--- paparazzi3/trunk/sw/airborne/csc/mercury_ap.c       2010-09-28 14:05:43 UTC 
(rev 6010)
+++ paparazzi3/trunk/sw/airborne/csc/mercury_ap.c       2010-09-28 14:48:38 UTC 
(rev 6011)
@@ -34,7 +34,7 @@
 #include "string.h"
 #include "booz_radio_control.h"
 #include "mercury_supervision.h"
-#include "actuators.h"
+#include <firmwares/rotorcraft/actuators.h>
 #include "props_csc.h"
 #include "csc_booz2_guidance_v.h"
 

Modified: paparazzi3/trunk/sw/airborne/firmwares/rotorcraft/main.c
===================================================================
--- paparazzi3/trunk/sw/airborne/firmwares/rotorcraft/main.c    2010-09-28 
14:05:43 UTC (rev 6010)
+++ paparazzi3/trunk/sw/airborne/firmwares/rotorcraft/main.c    2010-09-28 
14:48:38 UTC (rev 6011)
@@ -35,7 +35,7 @@
 #include "datalink.h"
 
 #include "booz2_commands.h"
-#include "actuators.h"
+#include <firmwares/rotorcraft/actuators.h>
 #include "booz_radio_control.h"
 
 #include <firmwares/rotorcraft/imu.h>

Modified: paparazzi3/trunk/sw/airborne/test/test_actuators.c
===================================================================
--- paparazzi3/trunk/sw/airborne/test/test_actuators.c  2010-09-28 14:05:43 UTC 
(rev 6010)
+++ paparazzi3/trunk/sw/airborne/test/test_actuators.c  2010-09-28 14:48:38 UTC 
(rev 6011)
@@ -28,7 +28,7 @@
 
 #include "i2c.h"
 #include "booz/booz2_commands.h"
-#include "firmwares/rotorcraft/actuators.h"
+#include <firmwares/rotorcraft/actuators.h>
 
 static inline void main_init( void );
 static inline void main_periodic_task( void );




reply via email to

[Prev in Thread] Current Thread [Next in Thread]