Alberto Lpz's Posts (1)

Sort by

Testing platform for multicopters

DSCN3083.JPG

I've been developing a hexacopter with a new code, using the Arducopter libreries.
As a testing work bench, I've been using a platform like the pictures above.

DSCN3085.JPGDSCN2978.JPGDSCN3086.JPGDSCN3087.JPGDSCN3168.JPG

In this way you can test it safety without any accident or crashes with material loss.
The hexacopter can move with in the 3 axis and have 3 potenciometers to know the exactly position.

Here you can see it working in the video:

min,

0.00 description.
0.33 Yaw control.
1.01 Pitch & roll control.
2.05 Vibrations.


I dont know what will be the differents between the simulator and the real flight. have anyone any suggestion or idea??

During my tests i've found many vibrations while it is working at high speed... I hope it will disappear in the air. does anyone know why??


I'm using the ArduPilotMega 1.4 board.

While testing i have found a lot of noise with the roll Axis. Here are the graphics of a test.

(legend: red=accel, black=gyro, cyan and gren=motors speed)
Ptich axis:
3689474108?profile=original

Roll axis:3689474224?profile=original

Due to roll gyro has a strange behaviour I recorded the data without any moving in the starting position without motors, here are the plots:
(legend: red=accel, black=gyro, cyan and gren=motors speed)

Pitch axis:
3689474244?profile=original

Roll axis:

3689474185?profile=original
Maeby my gyroscope is not correct... ( bought it in September). I dont understand why the accel.y correspond with gyro.x and viceversa... and gyro.y has opposite sign than accel.x


my code, mainly is:

[declarations]

[read radio]

         imu.update();
                accel = imu.get_accel();
                gyro =  imu.get_gyro();

     pitch    =  accel.y;
         roll     =  accel.x;

         giroPitch=  gyro.x;
         giroRoll =  gyro.y;


[discrete filters for accel]

          pitchSum +=errorPitch;             //integral
          rollSum += errorRoll;             //integral

errorPitch=yref-pitchFilter;
errorRoll=xref-rollFilter;

//FRONT      RED           
valor[1] = throttle + 1.0* (KpR*errorRoll   - KdR*giroRollFilter   + KiR*rollSum);
valor[5] = throttle + 0.5* (KpR*errorRoll   - KdR*giroRollFilter   + KiR*rollSum) -0.866* (KpP*errorPitch +KdP*giroPitchFilter + KiP*pitchSum);
valor[4] = throttle + 0.5* (KpR*errorRoll   - KdR*giroRollFilter   + KiR*rollSum) +0.866* (KpP*errorPitch +KdP*giroPitchFilter + KiP*pitchSum);
//BACK  BLACK
valor[2] = throttle - 1.0* (KpR*errorRoll   - KdR*giroRollFilter   + KiR*rollSum);
valor[3] = throttle - 0.5* (KpR*errorRoll   - KdR*giroRollFilter   + KiR*rollSum)  -0.866* (KpP*errorPitch +KdP*giroPitchFilter + KiP*pitchSum);
valor[6] = throttle - 0.5* (KpR*errorRoll   - KdR*giroRollFilter   + KiR*rollSum)  +0.866* (KpP*errorPitch +KdP*giroPitchFilter + KiP*pitchSum);
                 
//     CONTROL DEL YAW
valor[1] +=kyaw*yaw;
valor[3] +=kyaw*yaw;
valor[6] +=kyaw*yaw;
                                           
valor[2] -=kyaw*yaw;
valor[4] -=kyaw*yaw;
valor[5] -=kyaw*yaw;

[constrain]


for(int8_t i=1;i<=6;i++){    
                      APM_RC.OutputCh(i,0 );  //valor[i]
                                                  
                       }

[sent data]

Any commentary is welcome!!! :)
Regards. Alberto.

Original post: www.dieBotReise.blogspot.com

Read more…