Excuse my ignorance on this subject as I just started in the quadcopter hobby.

I enabled AlwaysStablizeWhenArmed so I can perform flips and have authority over the motors at 0% throttle. However, I notice that when I enable this mode via the accessory I assigned, the motors spin at 0% throttle (I guess this is called "idle").

What I expected was for the motors to NOT spin (even with AlwaysStablizeWhenArmed enabled) until I input stick movement (roll/pitch/yaw) without throttle.

Can someone please help me understand why the motors must spin/idle when the throttle is at 0% in order to provide control over the motors?

Is this also how Air Mode works on CleanFlight (motors spinning even at 0% throttle)?
« Last Edit: August 02, 2017, 03:46:00 pm by emperorsgroove »

mr_w

  • *
  • 116
Re: AlwaysStabilizeWhenArmed Why must motors idle at 0% throttle?
« Reply #1 on: August 01, 2017, 09:58:20 pm »
Imagine you are up in the air, make throttle 0 and use just roll/pitch/yaw to make the quad upside down, or some other funny angle while free-falling. That is what you do with aswa (always-stabilize-when-armed, or air mode, same thing different name).

If the motors are not spinning, your quad would need to use some other magic force (??) to follow your roll/pitch/yaw commands. right? Throttle is 0.

Another thing is that changing motor speed from idle speed to some other is way much easier for motor to do, than to change from 0 to anything else. So it is spinning to make speed changes (follow your stick input) possible.
« Last Edit: August 01, 2017, 10:01:26 pm by mr_w »

Re: AlwaysStabilizeWhenArmed Why must motors idle at 0% throttle?
« Reply #2 on: August 01, 2017, 10:07:54 pm »
I understand that the quad needs to use the motors to follow my roll/pitch/yaw commands. I think your last point is what I'm referring to- that it's easier for the motors to respond to input while spinning rather than respond while sitting still.

I also read (in reference to Air Mode on CleanFlight) that the motors are idling because they keep the PID loop active. That makes sense, too, if it is what's happening in AlwaysStabilizeWhenArmed.

So, is it common practice for freestyle pilots to have a switch on their transmitter configured to enable/disable AlwaysStabilizeWhenArmed/Air Mode? I guess it's just not what I expected.

f5soh

  • *****
  • 3767
    • LibrePilot
Re: AlwaysStabilizeWhenArmed Why must motors idle at 0% throttle?
« Reply #3 on: August 01, 2017, 10:19:44 pm »
You can reuse the the flightmode switch for ASWA, this mean you can configure FM1 as normal for takeoff and landing, FM2 and FM3 with ASWA.

https://librepilot.atlassian.net/wiki/spaces/LPDOC/pages/39551030/Always+Stabilized+When+Armed+mode+setup#AlwaysStabilizedWhenArmedmodesetup-UsingFlightModeswitch

Indeed "PID loop active" mean the vehicle is stabilized, same as AlwaysStabilizedWhileArmed
Another reason the motors are spinning is safety : just think one second taking your quad by hand while ASWA is active and motors not spinning...


Re: AlwaysStabilizeWhenArmed Why must motors idle at 0% throttle?
« Reply #4 on: August 01, 2017, 10:23:30 pm »
You can reuse the the flightmode switch for ASWA, this mean you can configure FM1 as normal for takeoff and landing, FM2 and FM3 with ASWA.

https://librepilot.atlassian.net/wiki/spaces/LPDOC/pages/39551030/Always+Stabilized+When+Armed+mode+setup#AlwaysStabilizedWhenArmedmodesetup-UsingFlightModeswitch

Indeed "PID loop active" mean the vehicle is stabilized, same as AlwaysStabilizedWhileArmed
Another reason the motors are spinning is safety : just think one second taking your quad by hand while ASWA is active and motors not spinning...

I tried setting up my Flight Mode switch to also control ASWA before I used a dedicated ASWA switch using those instructions, but I couldn't get it to work properly. All flight modes ended up having ASWA enabled. I'll retry again. Maybe I missed something.

mr_w

  • *
  • 116
Re: AlwaysStabilizeWhenArmed Why must motors idle at 0% throttle?
« Reply #5 on: August 01, 2017, 10:49:00 pm »
I have all my quads configured to use 3 way arming switch - disarmed-armed-armedwithaswa, but in reality I tend to just arm directly to aswa mode and fly like that, complete with landing. In theory, you could be in trouble if you do a messy landing, touching the ground at odd angle and having the quad try to maintain attitude (or counter the unexpected rotation if in rate mode), but in practice I haven't had as many trouble as I expected.

So to say, while it is nice to have it on 3 way switch, I haven't really used non-aswa mode ever since I discovered it :)


Re: AlwaysStabilizeWhenArmed Why must motors idle at 0% throttle?
« Reply #6 on: August 01, 2017, 10:53:22 pm »
I have all my quads configured to use 3 way arming switch - disarmed-armed-armedwithaswa, but in reality I tend to just arm directly to aswa mode and fly like that, complete with landing. In theory, you could be in trouble if you do a messy landing, touching the ground at odd angle and having the quad try to maintain attitude (or counter the unexpected rotation if in rate mode), but in practice I haven't had as many trouble as I expected.

So to say, while it is nice to have it on 3 way switch, I haven't really used non-aswa mode ever since I discovered it :)

That sounds pretty clean! Can you share how you configured a switch to work that way?

mr_w

  • *
  • 116
Re: AlwaysStabilizeWhenArmed Why must motors idle at 0% throttle?
« Reply #7 on: August 01, 2017, 11:27:38 pm »
First thing is you need to have 3way switch configured correctly in your TX so it sends 3 different values on a channel.
Then you need to set that channel to control your normal arming accessory (for example accessory 0) but adjust the neutral to 30% so that middle position gives just enough value to arm (value that is greater than neutral accessory 0).
After that, you configure another accessory (for example accessory 3) using *same* tx channel, but make neutral at 70% so that 3rd position make it over neutral, and select that accessory for ASWA.

See attached picture, note that acc0 and acc3 are using same sbus channel 5, which I have configured on my tx to send 3 different values from 3way switch. Also note their neutral values (acc0 and acc3).



Re: AlwaysStabilizeWhenArmed Why must motors idle at 0% throttle?
« Reply #8 on: August 02, 2017, 02:16:34 am »
First thing is you need to have 3way switch configured correctly in your TX so it sends 3 different values on a channel.
Then you need to set that channel to control your normal arming accessory (for example accessory 0) but adjust the neutral to 30% so that middle position gives just enough value to arm (value that is greater than neutral accessory 0).
After that, you configure another accessory (for example accessory 3) using *same* tx channel, but make neutral at 70% so that 3rd position make it over neutral, and select that accessory for ASWA.

See attached picture, note that acc0 and acc3 are using same sbus channel 5, which I have configured on my tx to send 3 different values from 3way switch. Also note their neutral values (acc0 and acc3).

Thanks! I'll give it a try and see how it goes.

Re: AlwaysStabilizeWhenArmed Why must motors idle at 0% throttle?
« Reply #9 on: August 02, 2017, 03:01:25 am »
If your main concern is to control motors when inverted then CruiseControl is an option.

The default settings for CruiseControl is to reduce the motors to 5% (but still allow full power for control and stabilization) when inverted.  You simply don't bother to reduce the throttle stick when inverted because it does it for you.  Another good thing is that if you DO reduce the throttle stick to zero, the motors stop, so you have that safety feature.

The other thing CC does by default is bank angle compensation.  It increases thrust by the amount required to maintain altitude for the current bank angle.  Normally when you bank, you have to increase thrust to avoid loosing altitude.  CC handles that for you.

CC is completely configurable so that if you don't like one of these features you can turn it off or adjust it.

Re: AlwaysStabilizeWhenArmed Why must motors idle at 0% throttle?
« Reply #10 on: August 02, 2017, 10:19:42 am »
If your main concern is to control motors when inverted then CruiseControl is an option.

The default settings for CruiseControl is to reduce the motors to 5% (but still allow full power for control and stabilization) when inverted.  You simply don't bother to reduce the throttle stick when inverted because it does it for you.  Another good thing is that if you DO reduce the throttle stick to zero, the motors stop, so you have that safety feature.

The other thing CC does by default is bank angle compensation.  It increases thrust by the amount required to maintain altitude for the current bank angle.  Normally when you bank, you have to increase thrust to avoid loosing altitude.  CC handles that for you.

CC is completely configurable so that if you don't like one of these features you can turn it off or adjust it.

Good to know, thanks! I'd still like to get ASWA working though. I think it will provide the level of control for quick flips I'm looking for.

I tried enabling it using both the ASWA enable/ disable switch and the flight mode switch methods, but whenever I switch to disable, the motors keep spinning at idle. Here's what I did:

1) Configured a 2-way switch for CH 6 on my TX.
2) Assigned the switch to Acc 0 during TX setup wizard.
3) Checked the "Motor spin at neutral..." option.
4) Chose Acc 0 to enable ASWA mode.
5) Tested switch while on output page and watched ASWA enable/disable correctly (down=enable, up=disable)

Now here's where things get weird:

6) With Acc 0 switch set to up=disable, arm quad using yaw-right method.
7) Quad arms and motors immediately start spinning at idle speed, even though ASWA switch is set to disable and output page confirms ASWA is not enabled according to Acc 0 position.
8- Move Acc 0 to down=enabled position.
9) Motors start spinning even faster.
10 ) Move Acc 0 to up=disabled.
11) Motors go back to idle speed.

It seems that when I check the "Motor spin at neutral..." option, the motors idle even when Acc 0 is set to disable. Motors idle even faster when Acc 0 is set to enable.

Any idea why this would happen?
Did I configure the 2-way switch for Acc 0 correctly? Maybe I forgot a critical step. Though, I followed everything here (https://librepilot.atlassian.net/wiki/plugins/servlet/mobile?contentId=39551030#content/view/39551030) correctly (I think).

f5soh

  • *****
  • 3767
    • LibrePilot
Re: AlwaysStabilizeWhenArmed Why must motors idle at 0% throttle?
« Reply #11 on: August 02, 2017, 12:56:43 pm »
Quote
I tried enabling it using both the ASWA enable/ disable switch and the flight mode switch methods, but whenever I switch to disable, the motors keep spinning at idle.

The Motor spin at neutral still active, that the normal behavior.
Motor spin at neutral option is not switchable from RC.

Re: AlwaysStabilizeWhenArmed Why must motors idle at 0% throttle?
« Reply #12 on: August 02, 2017, 01:03:33 pm »
One thing about CruiseControl I forgot to mention is that it should not (cannot) be used with Acro+.  I recall that it won't let you do this without special tweaks.  It at least should be avoided if your Acro+ allows flipping faster than 2000 degrees per second or about 5 flips per second.  That is fast enough to break things in some cases (props, arms, motor mounts) just from the gyroscopic forces and sling batteries off if they are not well secured.

Acro+ can go faster than 2000 degrees per second (gyro max hardware rate), and if it does, the flipping faster than 2000 deg/sec confuses the concept of which way is up.  Acro+ does not need to know this, but CruiseControl does need to know this.

Re: AlwaysStabilizeWhenArmed Why must motors idle at 0% throttle?
« Reply #13 on: August 02, 2017, 03:44:10 pm »
Quote
I tried enabling it using both the ASWA enable/ disable switch and the flight mode switch methods, but whenever I switch to disable, the motors keep spinning at idle.

The Motor spin at neutral still active, that the normal behavior.
Motor spin at neutral option is not switchable from RC.

Oh wow. I didn't know that! I just assumed that the motors would only spin at neutral when ASWA is active. I read the words "Motor spin at neutral output when armed and throttle below zero" but didn't stop to think that this would be independent of ASWA being enable or disable. Now I get it. Thanks!

Here's how I configured:

3-way flight mode switch: Up=Rattitude, Mid=Rate, Down=Rate
Acc 0 - same channel as flight mode switch: Up/Mid=ASWA Disabled, Down=ASWA Enabled
Acc 1 - 2-way switch: Up=Disarm, Down=Arm

I tested on the bench this morning without props. I'm able to arm from Rattitude or Rate successfully. I'm able to switch to Rate+ASWA successfully. I'm able to switch back to Rattitude or Rate successfully, which disables ASWA. I'm able to disarm successfully.

Last thing to test is in-flight tonight, and hopefully not crash!

Thanks for helping me through my ignorance!

Re: AlwaysStabilizeWhenArmed Why must motors idle at 0% throttle?
« Reply #14 on: August 02, 2017, 03:47:21 pm »
One thing about CruiseControl I forgot to mention is that it should not (cannot) be used with Acro+. 

Good to know!