PID settings for EXT_MOTOR_RANGE

This forum is dedicated to software development related to MultiWii.
It is not the right place to submit a setup problem.

PID settings for EXT_MOTOR_RANGE

Postby crashlander » Fri Mar 02, 2012 8:24 am

Hello.
Question for those that are using EXT_MOTOR_RANGE! What are some workable PID settings for different kind of setups?
If I understand correctly we have now 2 different kinds of EXT_MOTOR_RANGE types: on ProMini we have 8bit PWM from 2 to 254 (252 steps(, and on mega we have 16bit PWM (??steps)?!

Regards
Andrej
crashlander
 
Posts: 500
Joined: Thu May 05, 2011 8:13 am
Location: Slovenia

Re: PID settings for EXT_MOTOR_RANGE

Postby ronco » Fri Mar 02, 2012 8:44 am

Hi,

in dev 225 there is just EXT_MOTOR_RANGE witch changes the signal range to near ~0 - 2ms. it can only be used with reflashed ESC's viewtopic.php?f=13&t=516

mega and promicro have some 11 & 16 bit timer active now but MWC uses just 11 bit intern (witch is enough) so



without EXT_MOTOR_RANGE

promini:
- motor 1-4 HW PWM 8bit (7used) = 125-250 (1-2ms) == 125 steps resolution
- motor 5-8 SW PWM 8bit (8used) = 5-245 (1-2ms) == 240 steps resolution <- isnt better then HW PWM eaven with higher resolution

promicro
- motor 1-4 HW PWM 11bit (10used) = 1000-2000 (1-2ms) == 1000 steps resolution
- motor 5-8 SW PWM 11bit (10used) = ~1040-~1960 (1-2ms) == ~920 steps resolution

mega
- motor 1-6 HW PWM 11bit (10used) = 1000-2000 (1-2ms) == 1000 steps resolution
- motor 7-8 HW PWM 8bit (7used) = 125-250 (1-2ms) == 125 steps resolution

with EXT_MOTOR_RANGE

promini:
- motor 1-4 HW PWM 8bit (8used) = 2-252 (~0-2ms) == 250 steps resolution
- motor 5-8 SW PWM 8bit (8used) = 5-245 (1-2ms) == 240 steps resolution

promicro
- no support for EXT_MOTOR_RANGE atm.

mega
- motor 1-6 HW PWM 11bit (11used) =16-2016 (~0-2ms) == 2000 steps resolution (MWC dont uses more then 1000 atm.)
- motor 7-8 HW PWM 8bit (8used) = 2-252 (~0-2ms) == 250 steps resolution


regards

Felix
ronco
 
Posts: 315
Joined: Thu Aug 18, 2011 2:58 pm

Re: PID settings for EXT_MOTOR_RANGE

Postby Stalk » Fri Mar 02, 2012 9:17 am

And where we can define EXT_MOTOR_RANGE?
Thanks you for reply.
regards
Stanley
Stalk
 
Posts: 49
Joined: Tue Apr 05, 2011 12:39 pm

Re: PID settings for EXT_MOTOR_RANGE

Postby Hamburger » Fri Mar 02, 2012 9:47 am

If and only if you have these reflasehd ESCs
Code: Select all
#define EXT_MOTOR_RANGE
in config.h
You can about double P for roll and pitch to start with.
User avatar
Hamburger
 
Posts: 2323
Joined: Tue Mar 01, 2011 2:14 pm

Re: PID settings for EXT_MOTOR_RANGE

Postby ronco » Fri Mar 02, 2012 9:49 am

hi Stanley, you are right there is no entry in config.h for it ...

but you can do it with wirite
Code: Select all
#define EXT_MOTOR_RANGE


to it


regards

felix
ronco
 
Posts: 315
Joined: Thu Aug 18, 2011 2:58 pm

Re: PID settings for EXT_MOTOR_RANGE

Postby p25o1 » Tue Jul 10, 2012 9:51 am

hi everyone,

i just have a question about the EXT_MOTOR_RANGE option,

i posted the same question here

viewtopic.php?f=8&t=2024

i missed this post.

i'm using a quadrino zoom rev 1e which is based on the Nano ATmega328

can it support the EXT_MOTOR_RANGE option, and if no why?

if i enable this option , do i need to re calibrate my escs?

thx everyone
p25o1
 
Posts: 33
Joined: Thu Mar 29, 2012 3:19 pm

Re: PID settings for EXT_MOTOR_RANGE

Postby Hamburger » Tue Jul 10, 2012 11:13 am

ronco wrote:hi Stanley, you are right there is no entry in config.h for it ...

ah, but it is.
It is right at the beginning of section 7 in config.h
User avatar
Hamburger
 
Posts: 2323
Joined: Tue Mar 01, 2011 2:14 pm

Re: PID settings for EXT_MOTOR_RANGE

Postby Hamburger » Tue Jul 10, 2012 12:15 pm

crashlander wrote:Hello.
Question for those that are using EXT_MOTOR_RANGE! What are some workable PID settings for different kind of setups?

Andrej,
as rule of thumb I found I can double the P for nick&roll when converting to mwii-esc. On my TRIs with mwii-esc flashed ESCs I have P at 7 to 8.
User avatar
Hamburger
 
Posts: 2323
Joined: Tue Mar 01, 2011 2:14 pm

Re: PID settings for EXT_MOTOR_RANGE

Postby crashlander » Tue Jul 10, 2012 12:48 pm

p25o1 wrote:hi everyone,

i just have a question about the EXT_MOTOR_RANGE option,

i posted the same question here

viewtopic.php?f=8&t=2024

i missed this post.

i'm using a quadrino zoom rev 1e which is based on the Nano ATmega328

can it support the EXT_MOTOR_RANGE option, and if no why?

if i enable this option , do i need to re calibrate my escs?

thx everyone


Hello, it seems somebody resurrected that old post :)
@p25o1 like it was said before you can use extended motor range ONLY WITH SPECIALY PROGRAMMED (REFLASHED) ESC, and of course than you don't need to calibrate ESC's because they are already calibrated.

Regards Andrej
crashlander
 
Posts: 500
Joined: Thu May 05, 2011 8:13 am
Location: Slovenia

Re: PID settings for EXT_MOTOR_RANGE

Postby p25o1 » Tue Jul 10, 2012 1:04 pm

i have simon Flashed esc,,, will they do the job/work?

i enabled the option it but the motors didn’t work initially.

after applying full throttle they started to spin,

i'm asking since i see in the code

with EXT_MOTOR_RANGE
"promicro
- no support for EXT_MOTOR_RANGE atm."

i just wanted to know if this is a hardware limitation , or it will come in time/development .
p25o1
 
Posts: 33
Joined: Thu Mar 29, 2012 3:19 pm

Re: PID settings for EXT_MOTOR_RANGE

Postby Hamburger » Tue Jul 10, 2012 1:15 pm

simonk flashed ESC are fine, but do not work with EXT_MOTOR_RANGE. Set minthrottle as described in config.h.
User avatar
Hamburger
 
Posts: 2323
Joined: Tue Mar 01, 2011 2:14 pm

Re: PID settings for EXT_MOTOR_RANGE

Postby p25o1 » Tue Jul 10, 2012 2:04 pm

simonk flashed ESC work fine with my setup

but as you pointed out it will not work with EXT_MOTOR_RANGE ,
when I enable it with the same simonk flashed ESC , it only spins the motor when i give it full throttle.

no issues, i'll leave this option for now,
p25o1
 
Posts: 33
Joined: Thu Mar 29, 2012 3:19 pm

Re: PID settings for EXT_MOTOR_RANGE

Postby ronco » Tue Jul 10, 2012 2:18 pm

p25o1 wrote:i have simon Flashed esc,,, will they do the job/work?

i enabled the option it but the motors didn’t work initially.

after applying full throttle they started to spin,

i'm asking since i see in the code

with EXT_MOTOR_RANGE
"promicro
- no support for EXT_MOTOR_RANGE atm."

i just wanted to know if this is a hardware limitation , or it will come in time/development .


its no HW limitation .. it is just not implementet yet .. i thought it wa snot needed because it has a quite high resolution in normal configuration .. but as alex said .. its also good for brushed motors .. so ill implement it soon :)

regards felix
ronco
 
Posts: 315
Joined: Thu Aug 18, 2011 2:58 pm

Re: PID settings for EXT_MOTOR_RANGE

Postby ronco » Tue Jul 10, 2012 2:59 pm

.. i added it now .. its in r975

regards felix
ronco
 
Posts: 315
Joined: Thu Aug 18, 2011 2:58 pm

Re: PID settings for EXT_MOTOR_RANGE

Postby p25o1 » Tue Jul 10, 2012 5:43 pm

oh , cool ,

i'll give it a try anyways to see how the esc respond with it :-)
p25o1
 
Posts: 33
Joined: Thu Mar 29, 2012 3:19 pm

Re: PID settings for EXT_MOTOR_RANGE

Postby polo_fly2 » Wed Jul 11, 2012 10:52 am

Hi,

I´m just a bit confused about using Ext_Motor_Range or not. ??

Its a combo of Flyduino 25A - Simonk firmware ESCs connected to Nanowii (Promicro)

Actually Ext_Motor_Range is activated in my config.h , and the copter is running absolutely normal and fine ??

Hamburger wrote that the SimonK ESC do not work when Ext_Motor_Range is activated. ?

Is it better to remove this def ?

thank you
Georg
User avatar
polo_fly2
 
Posts: 34
Joined: Fri Aug 05, 2011 1:12 pm
Location: Munich - Bavaria

Re: PID settings for EXT_MOTOR_RANGE

Postby Hamburger » Wed Jul 11, 2012 11:31 am

polo_fly2 wrote:I´m just a bit confused about using Ext_Motor_Range or not. ??
Its a combo of Flyduino 25A - Simonk firmware ESCs ...

I wrote
simonk flashed ESC are fine, but do not work with EXT_MOTOR_RANGE

what question is left?
for brushless ESCs: If and only if you have wii-esc flashed ESCs use EXT_MOTOR_RANGE. In all other cases, do not use it.
User avatar
Hamburger
 
Posts: 2323
Joined: Tue Mar 01, 2011 2:14 pm

Re: PID settings for EXT_MOTOR_RANGE

Postby ronco » Wed Jul 11, 2012 12:35 pm

polo_fly2 wrote:Hi,

I´m just a bit confused about using Ext_Motor_Range or not. ??

Its a combo of Flyduino 25A - Simonk firmware ESCs connected to Nanowii (Promicro)

Actually Ext_Motor_Range is activated in my config.h , and the copter is running absolutely normal and fine ??

Hamburger wrote that the SimonK ESC do not work when Ext_Motor_Range is activated. ?

Is it better to remove this def ?

thank you
Georg


that is because in all MWC versions before r975 EXT_MOTOR_RANGE has no effekt on a promicro..

regards felix
ronco
 
Posts: 315
Joined: Thu Aug 18, 2011 2:58 pm

Re: PID settings for EXT_MOTOR_RANGE

Postby polo_fly2 » Wed Jul 11, 2012 12:40 pm

hi and thanks, its clear now.. :-)

Georg
User avatar
polo_fly2
 
Posts: 34
Joined: Fri Aug 05, 2011 1:12 pm
Location: Munich - Bavaria

Re: PID settings for EXT_MOTOR_RANGE

Postby Hamburger » Wed Jul 11, 2012 1:56 pm

Ok. Have fun clying.
And simonk esc is good.
User avatar
Hamburger
 
Posts: 2323
Joined: Tue Mar 01, 2011 2:14 pm


Return to Software development

Who is online

Users browsing this forum: No registered users and 10 guests