added gy80 dcm

Dependencies:   mbed DCM_AHRS_GY80 PID MMA8451Q

Fork of quadCommand by Greg Abdo

Revision:
50:197a18e49eb4
Parent:
49:f202fb0d4128
Child:
51:60258b84ebab
--- a/quadCommand/quadCommand.cpp	Mon Jun 10 04:43:30 2013 +0000
+++ b/quadCommand/quadCommand.cpp	Mon Jun 10 05:04:53 2013 +0000
@@ -12,17 +12,15 @@
     pidYaw(1.5,0.1,1.20,DEFAULT_WINDUP_GUARD)
 {
         motorProcess.attach(this, &quadCommand::updateMotors, MOTOR_UPDATE/1000);
-        sensorProcess.attach( this, &quadCommand::updateCurrent, SENSSORDELAY/1000 );
-        sendProcess.attach( this, &quadCommand::sendTelemetry, SENDDELAY/1000 );
-
+        sensorProcess.attach( this, &quadCommand::updateCurrent, SENSSOR_DELAY /1000 );
+     
+        myCom = new com( TXPIN, RXPIN );            // Setup com object.       
+        world = new sensors();                      // Setup the sensors.
         
-        myCom = new com( TXPIN, RXPIN );        // Setup com object.       
-        world = new sensors();                  // Setup the sensors.
-        
-        myMotors[0] = new motor( MOTOR1 );      // Connect motor 0 to PTD4 pin.
-        myMotors[1] = new motor( MOTOR2 );      // Connect motor 1 to PTA12 pin.
-        myMotors[2] = new motor( MOTOR3 );      // Connect motor 2 to PTA4 pin.
-        myMotors[3] = new motor( MOTOR4 );      // Connect motor 3 to PTA5 pin.
+        myMotors[0] = new motor( MOTOR1 );          // Connect motor 0 to PTD4 pin.
+        myMotors[1] = new motor( MOTOR2 );          // Connect motor 1 to PTA12 pin.
+        myMotors[2] = new motor( MOTOR3 );          // Connect motor 2 to PTA4 pin.
+        myMotors[3] = new motor( MOTOR4 );          // Connect motor 3 to PTA5 pin.
         
         targetThrottle  = currentThrottle   = 0;
         targetPitch     = currentPitch      = 0;
@@ -38,8 +36,12 @@
 {   
     while(1)
     {     
+        DEBUG(pc.printf("\r\n------------------- IN RUN ---------------------\r\n");)
+        
         if( myCom->isData() ) 
             rxInput();
+        
+        sendTelemetry();
     }
 }