Show Posts
Pages: 1 2 [3] 4 5 ... 17
31  Community / Exhibition / Gallery / Re: BlueCopter - Arduino Quadcopter on: January 16, 2014, 03:27:15 pm
@MuhammadArslanKhan: I told you to not connect the motors while SAFE mode is turned off.. Turn on SAFE MODE.. What you are experiencing is the ESC's not getting enough time to check for the PWM freq. and the PWM zero level.. What happens is the each ESC will be timed differently and thus give you this erratic behavior.. After turning on SAFE mode connect the motors and start up your quadcopter.. Give it 3-5 seconds (until the motors stop beeping).. Then increase the throttle to approximatley 10%.. If it still doesn't start increase it to 20%.. It should start as soon as the throttle signal is approx. 1100us.. Try it out..

@Satiro: I can't say for sure what the problem is.. It definitely has something to do with the PID's in some way.. Not necessarily the integral-action.. It could be that your quadcopter not getting enough throttle after the arming procedure.. Try increasing the MOTOR_ARM_START in config.h to let us say 150..

//Basel
32  Community / Exhibition / Gallery / Re: BlueCopter - Arduino Quadcopter on: January 15, 2014, 02:41:59 pm
@ basel
yessss..!!!! u r the man basel....thanksssss
its working now...


This doesn't mean that it's working! There is something not working.. The SAFE procedure keeps your motors from spinning out of control as soon as you connect the battery! So don't connect your motors just yet!! Debug your transmitter (RX) and see that your controls give values between 1000 and 2000us. If they doesn't that means that you need to calibrate these values in config.h...

//Basel
33  Community / Exhibition / Gallery / Re: BlueCopter - Arduino Quadcopter on: January 15, 2014, 01:47:16 pm
Here comes the updated photo:

//Basel
34  Community / Exhibition / Gallery / Re: BlueCopter - Arduino Quadcopter on: January 15, 2014, 09:41:31 am
@Muhammad... Disconnect the motors, turn off safe mode by commenting the line

Config.h
Code:
#define SAFE    //Arming procedure

Turn on debug mode and check and see if you get any response..

@Satiro: I'll be back with a better drawing of my setup..

@TheAviator.. I'm not using a kalman filter.. Instead I'm using a complementary filter.. You can see it at lines 27 and 28 in Sensor.ino .. I'm using a low-pass filter for the accelerometer and a two-step moving average filter for the gyrometer...

"avr/pgmspace.h" this file does exist if you're using avrgcc.. No it's not a arduino library, it's a header and is part of the avrgcc compiler..

//Basel
35  Community / Exhibition / Gallery / Re: BlueCopter - Arduino Quadcopter on: January 13, 2014, 07:41:36 pm
@satiro: well your post indicates that you didn't read through this thread before starting your quadcopter project.. Now, my software package isn't as complete as multiwii.. Because what I'm offering is a way to learn how everything works or how to make your own firmware plus hardware from scratch.. Multiwii doesn't give you that option because it's a complete software package with a nice and simple interface between PC and quadcopter.. When I answered your questions I was assuming that your ESC's, propellers, hardware in general were complete and your only problem were lying in software.. But clearly that wasn't the case.. If you've done everything right your PID values should have been very close to the ones in the original file.. As I said earlier, I'm working on a mini quadcopter that uses my bluecopter firmware.. Today I test flew it.. And it flew without any problems with the original PID values, no modifications.. I'll post the results very soon together with a flight video.. Just to compare, my original quadcopter is 660mm from motor to motor and weighs 1500g.. The mini quadcopter is 150mm and weighs 45g.. Anyhow, I'm glad your getting somewhere with your project.. Best of luck smiley

//Basel
36  Community / Exhibition / Gallery / Re: BlueCopter - Arduino Quadcopter on: January 13, 2014, 03:38:38 pm
Wow, a lot of messages.. No, I'm not on vacation, it's just I usually visit this site when I get a notification email that says that I've got a new Post on the forum.. This didn't happen...

Anyhow to the problems:

@Satiro: I'm having a hard time knowing what you're after.. Do you want to fly it in + mode? In that case you'll have to modify the output of the PIDs to the motors.. You can find these in the following variables: in FlightCtrl.ino

Code:
  int m0_val=throttle+PIDroll_val+PIDpitch_val+PIDyaw_val;
  int m1_val=throttle-PIDroll_val+PIDpitch_val-PIDyaw_val;
  int m2_val=throttle+PIDroll_val-PIDpitch_val-PIDyaw_val;
  int m3_val=throttle-PIDroll_val-PIDpitch_val+PIDyaw_val;

You have to rearrange PIDroll, PIDpitch, PIDyaw accordinaly.. But I don't recommend you to do anything like that until you get your quadcopter working with my setup.. Because if you venture into something like that I can't be 100% sure each time I answer your questions..

What settings do you want me to pass you? Can you try out something for me? Try the following values and report back:

Code:
#define ROLL_PID_KP  0.200
#define ROLL_PID_KI  0.800
#define ROLL_PID_KD  0.00
#define ROLL_PID_MIN  -50.0
#define ROLL_PID_MAX  50.0

#define PITCH_PID_KP  0.200
#define PITCH_PID_KI  0.800
#define PITCH_PID_KD  0.00
#define PITCH_PID_MIN  -50.0
#define PITCH_PID_MAX  50.0

#define YAW_PID_KP  0.500
#define YAW_PID_KI  0.300
#define YAW_PID_KD  0.00
#define YAW_PID_MIN  -50.0
#define YAW_PID_MAX  50.0

#define ANGLEX_KP 3.0
#define ANGLEX_KI 0.02
#define ANGLEX_KD -0.015
#define ANGLEX_MIN -100.0
#define ANGLEX_MAX 100.0

#define ANGLEY_KP 3.0
#define ANGLEY_KI 0.02
#define ANGLEY_KD -0.015
#define ANGLEY_MIN -100.0
#define ANGLEY_MAX 100.0

If these settings don't work at all, then you maybe you have your IMU set in the wrong direction on the quadcopter.. Anyhow, try these settings and report back..


@MuhammadArslanKh: What's not working when you upload/run the code on the leonardo..? If you've connected everything right then it should run right out of the box.. Check your connections again and report back..

//Basel
37  Community / Exhibition / Gallery / Re: BlueCopter - Arduino Quadcopter on: December 30, 2013, 07:51:11 am
@satiro: I did use matlab.. I used the serial interface to get data for my model (taking all the delays into consideration in the plant model), then optimized the PID values for the plant model and used those values in my final design..

//Basel
38  Community / Exhibition / Gallery / Re: BlueCopter - Arduino Quadcopter on: December 30, 2013, 05:39:12 am
Can you help me ?

Hey,

It sounds like you have a small delay.. That delay could be the Serial interface.. So just put the D-term to 0.014 (I calculated this number) and try adjusting the I-term instead..

//Basel
39  Community / Exhibition / Gallery / Re: BlueCopter - Arduino Quadcopter on: December 22, 2013, 09:53:46 am
hello Basel..!
if i use your code for Arduino Mega2560, whatt kind of problems would occur..??

You'd have to re-write the entire receiver (RX.ino) section to support the mega.. otherwise everything else should be compatible..

//Basel
40  Community / Exhibition / Gallery / Re: BlueCopter - Arduino Quadcopter on: December 21, 2013, 04:19:05 pm
I own:
Spectrum dx7 transmitter/receiver
Arduino uno
hobby king 20A speed controllers

Will I also need a 9DOF? do i just need a gyro? or an accelerometer?  Is there something similar that would work better or anything cheaper?  I just want something that will keep it stable in the air so it will be much easier to handle. Also do i have to plug it into arduino or is there something that i could plug inline with my receiver to the arduino that will adjust the signal accordingly?

anything else i might need?

Hey Dustin,

The transmitter/reciever will work with my code.. Unfortunately the Arduino UNO isn't supported by my code.. To make it work with the UNO you'll need to re-write the entire receiver section (RX.ino) to support the UNO.. Otherwise you'll need to get a Arduino Leonardo/Micro to make my code work, out of the box...

Which ESC are you getting?? hobbyking 20A speed controllers can be anything.. ESC that will work and that I'm currently using is the BlueSeries ESC from hobbyking.. Here is the 20A version of the blueseries ESC i'm using: https://www.hobbyking.com/hobbyking/store/__13430__HobbyKing_20A_BlueSeries_Brushless_Speed_Controller.html
The reason you may ask? The reason is you need the ESC to support PWM signals.. And because I've used the blueseries ESC, I can personally guarantee that they will work..

For my current code you need at least a 6 DOF, more specifically the ADXL345 and L3G4200D (accelerometer and gyrometer)... you can find some cheap IMU's on ebay..  And yes, you need to plug the IMU directly to the arduino...


@xSpamerx: Because it's not a direct modified copy of my code, I can't just look at it and point something out.. With other words, I really would like to, if I had the time..

//Basel
41  Community / Exhibition / Gallery / Re: BlueCopter - Arduino Quadcopter on: December 18, 2013, 02:43:32 pm
Basel, it is kind of complicated, because how am I going to send data through the serial interface to handle with one hand and still girálo it on low speed until start to swing! is half difícel of view! I think it is as follows:

Connecting the quad;
increase the throttle to 40%;
Go varying Kp values ​​until the system oscillates turning the quad left or right;
If ouver problems reduce to zero the throttle!

Do the same for the Kd and Ki!
  That basel ....?

Basel, the next video would clear enough!

I know that you have little time ... but it would help very much!

It won't oscillate left or right.. When it oscillates it will start to rock back and forth.. Yes, your method is a-okay! Yes, you do the same for Kd and Ki also! I couldn't find a suitable video for you, sorry for that.. But you need to start experimenting a little.. Don't be afraid to do something wrong (just don't cut of a finger =P ).. Try experimenting yourself and find a method that works for you, otherwise you won't learn anything..
42  Community / Exhibition / Gallery / Re: BlueCopter - Arduino Quadcopter on: December 18, 2013, 11:55:04 am
Basel,
can you tell me how to adjust the Yaw, type the walkthrough, because this weekend I want to take on the project in earnest! Look, stretch a wire in my room and I think you can hang it! You can adjust the yaw PID as well?

I didn't hang my quadcopter.. I held it in my hand.. Just use the same guide as you did before, it will work fine.. Just be careful as always.. You'll have to hold it in your hand, change the desired P, I or D and try spinning it with your other hand and observe the respons.. At some point it will start oscillating (it will shake/vibrate a lot, usually you'll see that two motors, CW or the CCW motors will somehow take over and make the quad go back and forth).. It is really hard to explain but you'll see it when it comes =)! Again be careful and push down the throttle to zero if it gets out of hand..!!

//Basel
43  Community / Exhibition / Gallery / Re: BlueCopter - Arduino Quadcopter on: December 18, 2013, 06:48:17 am
More Basel,
yourself said you must first balance and then adjust the Yaw! can not then test to see if will be balanced in the air and then start of the PID Yaw?
Yes, you can try it.. But it's not ready to fly per say.. But sure, go ahead and try it out =)!
44  Community / Exhibition / Gallery / Re: BlueCopter - Arduino Quadcopter on: December 17, 2013, 07:38:54 pm

Basel,
with PID Pitch and Roll adjusted it already is balanced? You can fly it?
You need to balance the yaw too... otherwise there is a risk that it will start to spin... When the yaw is calibrated you can go ahead and fly it smiley...
45  Community / Exhibition / Gallery / Re: BlueCopter - Arduino Quadcopter on: December 17, 2013, 10:14:51 am
Well, I don't really remember, but it's something near the default values that comes with the firmware... No, I meant changing the value in config.h to 0.36 .. My recommendation is to calibrate the yaw axis before the angle PID's.. that way uou won't have any dependencies from the yaw axis while calibrating the angles...
//Basel
Pages: 1 2 [3] 4 5 ... 17