Page 3 of 7

Re: Helicopter integration

Posted: Wed Aug 01, 2012 7:19 pm
by Hamburger
Only cheap crius lite with oled piggypacked, no hh gyro. I have not given up yet to improve on yaw code.

Re: Helicopter integration

Posted: Sun Aug 05, 2012 4:14 am
by Aluken
great work!!!! :P :P

Re: Helicopter integration

Posted: Sun Aug 26, 2012 6:37 pm
by Hamburger
the video proof you asked for :)

cx450.4-mwc-1 http://www.vidup.de/v/9DOJ2/
cx450.4-mwc-2 http://www.vidup.de/v/yhgpi/

as you can see the tail does weird things. A hh gyro could do much better. MWii has ways to go.

Re: Helicopter integration

Posted: Sun Aug 26, 2012 6:41 pm
by copterrichie
Hamburger wrote:the video proof you asked for :)

cx450.4-mwc-1 http://www.vidup.de/v/9DOJ2/
cx450.4-mwc-2 http://www.vidup.de/v/yhgpi/

as you can see the tail does weird things. A hh gyro could do much better. MWii has ways to go.



Very interesting, in fact extremely interesting!!!

Question, how would the usage of Digital Servos work here?

Re: Helicopter integration

Posted: Sun Aug 26, 2012 7:27 pm
by Hamburger
Zero difference. It already runs on digital servos mg922.

Re: Helicopter integration

Posted: Sun Aug 26, 2012 7:28 pm
by copterrichie
Thank you, follow up question, what refresh rate?

Re: Helicopter integration

Posted: Sun Aug 26, 2012 8:12 pm
by Hamburger
Still default 50Hz.
When I tried 160Hz on the other copter with mg90 analog servos I wventually got random
Servo jitter and crash.
I will test 160hz and 300hz woth the digitals soon.

Re: Helicopter integration

Posted: Sun Aug 26, 2012 8:25 pm
by copterrichie
I will be watching with some popcorn. :)

Re: Helicopter integration

Posted: Sun Aug 26, 2012 9:07 pm
by Hamburger
What do you expect to see?

Re: Helicopter integration

Posted: Sun Aug 26, 2012 9:12 pm
by copterrichie
Well, I been meaning to test some digital servos with the 490hz Motor updates, just have not gotten around to doing that.

Re: Helicopter integration

Posted: Mon Sep 10, 2012 9:47 pm
by Hamburger
Intermittently the heli drops about 1m but otherwise remains stable.
So I think it is all 3 cyclic servos move simultaneously to center or low and then recover to hover position.
Not sure if tail servo makes same movement.
Has happened on both mwii helis.
Any idea what could be causing this?

Re: Helicopter integration

Posted: Wed Sep 12, 2012 11:48 pm
by Alexinparis
I suppose it's related to vibration.
When vibration are problematic, it's sometime possible to fly but with a reduced power.
I think it happens when all axis PIDs go in the same direction, leading to a cyclic overall pitch variation in case of heli

Re: Helicopter integration

Posted: Thu Sep 13, 2012 8:00 am
by Hamburger
I suppose it's related to vibration

ok, but
any idea how to tame it down even more? GYRO.SMOOTHING is up to (75, 75, 40) already. I am afraid to increase much more, because I assume it will with new values taking longer to effectively influence the mwc. This would introduce more 'lag'; like it will feel squishy.
Using the other gyro smoothing function MMGYRO might be better, but I am still unsure which value for that option to begin with.
Faulty settings easily result in a crash. With a heli that definitely means broken parts and lengthy repairs each time.

Re: Helicopter integration

Posted: Thu Sep 13, 2012 11:24 am
by hkubota
To make sure vibrations are not the issue, should it not be sufficient, to add some mass to the FC (metal plate should work), put this on soft stuff (foam) so that vibrations are mostly eliminated? For a test about vibrations I did this for my Naze32 to make sure the acc readings are not caused by the motor/prop vibrations.

Re: Helicopter integration

Posted: Thu Sep 13, 2012 12:43 pm
by Hamburger
short answer: yes.
But
How much is enough but not too much? I went with regular heli gyro double sided tape. What is good for a gyro is good for mwc?
From past experience with multicopters I learnt to not overdo the foam/dampening.

Helis have so much more vibration than your regular multicopter. That is why I use gyro.smoothing. From my an others' experience it seems one cannot go without for a decent sized heli. We are only at the beginning of MWii on helis (missing good HH tail gyro functionality).

Re: Helicopter integration

Posted: Thu Sep 13, 2012 1:52 pm
by copterrichie
I never really had a problem with vibration however I am very curious to find out if lowering the Accelerometer G-range from 8g to 4g or even 2g will help?

Edited: And making adjustments to "float wGyro = 300; // gyro weight/smooting factor"

Re: Helicopter integration

Posted: Wed Oct 10, 2012 4:02 pm
by jtrides65
i wish i had this on my new 500 helicopter. i bought a tarot flybarless controller from hobby king and it doesnt work, no tech support. if and when you get this working and decide to sell it please let me know, im all about trying new controllers.

Re: Helicopter integration

Posted: Wed Oct 10, 2012 7:12 pm
by PatrikE
Get a new controller and start.... :D
MWC MultiWii SE 39 USD

Re: Helicopter integration

Posted: Wed Oct 31, 2012 8:07 pm
by Hamburger
I made the alternate gyro smoothing method named MMGYRO (by magnetron) into a tunable parameter (stored in eeprom). It is available as r1241. Anyone willing to test fly it and compare against GYRO_SMOOTHING? Magnetron was convinced the equal weighted MMGYRO method with shorter vector should behave better than the weighted GYRO_SMOOTHING method with large value.

I fly successfully with GYRO_SMOOTHING = (45, 45, 45), but could not get a comparable result with MMGYRO; tested this with values from 10 to 25. Maybe that is because of my poor helicopter mechanics only?

It is possible to compile in both gyro smoothing methods in one sketch. To test fly, only one should be active; the other can be effectively disabled by setting its value(s) to 1. So it is easy to tune and compare without repeated compile&flash.

Testers report back here, please.

Helicopter integration

Posted: Sun Nov 25, 2012 11:56 am
by olaf45
Hi,

I'm new user of the Patrick.E code and I have fitted a FBL head on my HDX450 with and the management is made by arduino mini... Before 1st test I have some questions :
- Why do you have to connect the throttle to the arduino and not directly to the ESC. You needn't to manage engine for FBL?
- In the code , I don't find where is the calculation of the phasis according to the gyroscopic precesion.

Thanks for you help

Re: Helicopter integration

Posted: Sun Nov 25, 2012 12:58 pm
by Hamburger
MWii does use throttle input for configuration stick combos and controls throttle for failsafe, armed vs. unarmed etc.
Throttle management like governor may get implemented into MWii in future.

no phasis calculation is done. You need setup phasis mechanically - probably 90 degrees?

Re: Helicopter integration

Posted: Mon Nov 26, 2012 10:29 pm
by olaf45
Thanks for your answers. I'll give you feedback after my first tests.

Re: Helicopter integration

Posted: Tue Dec 04, 2012 5:13 pm
by Imen
Hi, is anyone had tried to big size heli, ex 700 size :?:

Re: Helicopter integration

Posted: Sat Dec 08, 2012 5:03 pm
by Hamburger
I thought Patrik uses a servo to control throttle on his gasser - so most likely flying big?

Re: Helicopter integration

Posted: Sat Dec 08, 2012 9:51 pm
by PatrikE
Hamburger wrote:I thought Patrik uses a servo to control throttle on his gasser - so most likely flying big?

Sorry i'we only tested it on a 450 size.
My Gasser have been seriously crashed once and have too much vibrations after the rebuild. :cry:

Re: Helicopter integration

Posted: Sun Dec 09, 2012 10:42 am
by olaf45
Hi,

I've finished the integration in my HDX450. It seems to be great but I have something I don't understand.
After calib_acc, when I switch from acc_mode to passthru , nothing spends and I find that's good. But when I switch to normal mode, the left and nick servos move slowly to an around 50 offset.

Can you help me ?

Thanks

Re: Helicopter integration

Posted: Sun Dec 09, 2012 5:41 pm
by olaf45
Hi,

I had my first flight this afternoon with FBL head and normal mode , after setting up PID for roll and nick (P=3 /I=0.01/ D=10 ) and smoothing (20,20,4) . For the yaw, I kept my GY401 working ( not everthing at the same time step by step ). There're some little jerks for rapid movement but it's flyable and quite good.
I tried the level mode and it was catastrophic. My helico danced the lambada and it was difficult to avoid the crash . I tried different tunings but it was not better. On my desk ( rotor and blades stopped ) when I move it back and forth, the level correction is good.
What is your feedback about it ?

Thanks

Re: Helicopter integration

Posted: Mon Dec 10, 2012 2:29 am
by Imen
Hi Patrik

How about if we use governor (mine GV-o1) for throttle control in gasser ?
its kinda parallel throttle input into governor and multiwii board, any idea ?

Re: Helicopter integration

Posted: Mon Dec 10, 2012 2:32 am
by Imen
olaf45 wrote:Hi,

I had my first flight this afternoon with FBL head and normal mode , after setting up PID for roll and nick (P=3 /I=0.01/ D=10 ) and smoothing (20,20,4) . For the yaw, I kept my GY401 working ( not everthing at the same time step by step ). There're some little jerks for rapid movement but it's flyable and quite good.
I tried the level mode and it was catastrophic. My helico danced the lambada and it was difficult to avoid the crash . I tried different tunings but it was not better. On my desk ( rotor and blades stopped ) when I move it back and forth, the level correction is good.
What is your feedback about it ?

Thanks


Hi olaf, maybe vibration issue on acc

Re: Helicopter integration

Posted: Mon Dec 10, 2012 9:36 pm
by Hamburger
Did you calibrate acc at least once?
Some boards seem to randomly forget calibration data between power cycling. Best do it once after connecting battery.
Also for level you should try lower I value like 0.08 to start with. My level P is around 4 only and my smoothing needs to be 40 40 50 or higher.

Re: Helicopter integration

Posted: Mon Dec 10, 2012 11:38 pm
by PatrikE
@Imen
You need throttle connected from RX to be able to do some settings and Arm/Disarm the MWii.
The stabilisation works even if its unarmed but Then you can change settings via stick input accidently!
Always ARM before flying!!!!!
But you can connect the governor via Y-cable and bypass MWii direct to the servo.

Re: Helicopter integration

Posted: Mon Dec 10, 2012 11:48 pm
by PatrikE
@Olaf.

You use gyrosmoothing to reduce noize from vibrations.
Same noize reaches the ACC.
(20,20,4) means avarage on 20 readings on Tilt & Roll.

Look at the IMU complimentary filter tuning in config.h
You can Set the Low Pass Filter factor for ACC
//#define ACC_LPF_FACTOR 100

And Gyro Weight for Gyro/Acc complementary filter
//#define GYR_CMPF_FACTOR 400.0f

There's some info about it in the config file.

Good luck
/Patrik

Re: Helicopter integration

Posted: Thu Dec 13, 2012 12:32 pm
by Hamburger
Should we add governor functionality to MWii?
( compared to heading hold this seems to be the easier task towards a modern fbl controller)

Re: Helicopter integration

Posted: Thu Dec 13, 2012 2:40 pm
by olaf45
Hi,

I always have jerk problem even with high value in low pass filter ( it's better but a lot of lag ... and unstable ). It seems, the trim ( acctrim ) and (offset ) are not applyed. Is there any tip to verify ? When I put a value offset, nothing happends on the servo . Is it normal ?
How can we read the value saved in eeprom ? Is it possible to add to multiwii_conf?

For the HH , We have to active headfreeze statut !

Re: Helicopter integration

Posted: Thu Dec 13, 2012 3:58 pm
by PatrikE
Last in Main loop You can use.

Code: Select all

debug[0]=conf.angleTrim[ROLL];  
debug[1]=conf.angleTrim[NICK];

Then you can see Acc trim in the Gui as debug.

Trim acc with the sticks.
Check values.
If the values is saved in Eeprom it will be the same after a reboot.

Re: Helicopter integration

Posted: Thu Dec 13, 2012 9:39 pm
by olaf45
Patrick,

It means, I need to recompile multiwii_conf.ino with this modification ?

Re: Helicopter integration

Posted: Thu Dec 13, 2012 9:54 pm
by PatrikE
Yepp!...
Insert the code in mainLoop and upload to the Arduino.

Re: Helicopter integration

Posted: Fri Dec 14, 2012 4:57 pm
by Hamburger
olaf45 wrote:
For the HH , We have to active headfreeze statut !

Sorry. I do not understand what you want to say?

Helicopter integration

Posted: Mon Dec 17, 2012 11:11 am
by olaf45
Hi,

I tryied to said , if I want to have the head lock like my GY401, should I active headfreeze function ( with mag ) or should I have to increase the I of the PID yaw.

Re: Helicopter integration

Posted: Mon Dec 17, 2012 12:18 pm
by Hamburger
MWii does _not_ provide HH like your gy401.
You can try and increase I for yaw, but it is not like HH.
For HH you would lower P and increase I and D. But it will not work well.

Re: Helicopter integration

Posted: Mon Dec 17, 2012 5:44 pm
by PatrikE
Using MAG should work same as for a TRI.

Re: Helicopter integration

Posted: Mon Dec 17, 2012 6:26 pm
by Hamburger
I have given up using MAG because it was only supported for tilt < 25 degrees and produces jump on tail when transitioning that tilt angle. With TRI and even more so with heli I have tilt > 25 degrees very often.

Does it work for you?

Re: Helicopter integration

Posted: Mon Dec 17, 2012 6:33 pm
by copterrichie
@Hamburger, Just curious, have you tried the latest modifications made by EOSBandi to the Mag?

Re: Helicopter integration

Posted: Mon Dec 17, 2012 6:54 pm
by Hamburger
no. I am still at the revision of my last commit to the repo _and_ my current MWC heli boards do not have a working mag.

Re: Helicopter integration

Posted: Thu Dec 20, 2012 7:04 pm
by olaf45
Hi,

Some feedback of my integration on my HDX450 with a FBL Tarot DFC.
I use an IMU ( GY 85 ) I decided to separate from arduino shield. I put on at the same place of the gyro. It's not the best place for mag because of magnetic interaction with tail servo but it was worst near the controller or brushless motor !

DSCF2119.JPG


DSCF2120.JPG


DSCF2121.JPG


It's flyable , the tuning is still not very fine but in acro mode I don't have any jerk in the three axes. Perhaps too smoothy because not very stable.

I thinks with a little more tuning the result should be as good ( better ) than commercial FBL module.

I have a "rookie" question. How to use a more recent multiwiiconf .I try 2.1 but it doesn't match with this soft ?

Re: Helicopter integration

Posted: Thu Dec 20, 2012 10:59 pm
by PatrikE
God to hear That you have hope for the HeliMode..:)

I dont know what version you use.
Every Version have a matched multiwiiconf packed in the Zip/Rar file.
If you load V2.1 in the copter you need to use multiwiiconf v2.1!

/Patrik

Re: Helicopter integration

Posted: Fri Dec 21, 2012 11:06 am
by Hamburger
not the best place for mag because of magnetic interaction with tail servo

do you fly the tail with MAG activated, if so, how does it feel? I found the tail jerking when transitioning the 25 degree limit (mag only getss factored in for tilt < 25 degrees). In the end I have swapped to gyro+acc controllers.

Re: Helicopter integration

Posted: Sat Dec 22, 2012 1:18 pm
by olaf45
Hi,

I have gived up the mag not for tilt reason but because of interaction with tail servo. When I move the tail servo ( not in flight ) the heading change. Nevertheless , according to this article (https://www.loveelectronics.co.uk/Tutor ... o-tutorial) it's possible to have a tilt compensation till 40° (not enough for heli ).

regards

Re: Helicopter integration

Posted: Thu Dec 27, 2012 11:15 am
by AlouetteIII
@PatrikE - I want to try a 120° swash helicopter with your code - using only Gyro/Acc on a 328CPU - leaving the tail servo to pass direct to the Quark spartan which does a really great job of HH by itself.

Is there any way to move Pin12 over to D3 or A0? What code lines do I need to change to do this - which ever is the easier.

Re: Helicopter integration

Posted: Thu Dec 27, 2012 10:08 pm
by PatrikE
You can copy the data from servo 3 to servo 5 ( D12 to D3 )
Insert servo[5] = servo[3]; last In the mixer code.

Code: Select all

    for(i=3;i<8;i++){
      servo[i]  = constrain( servo[i], servoEndpiont[i][0], servoEndpiont[i][1] );
    }
    servo[5] = servo[3];
  #endif
 
// End of PatrikE Experimentals

It will output same pwm on both outputs.

You can disable pwm on D12 by uncommenting
//#define D12_POWER