Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Documentation: Add unit for actuator slew rate and reword description #23846

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 6 additions & 7 deletions src/modules/control_allocator/module.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -71,15 +71,14 @@ parameters:
description:
short: Motor ${i} slew rate limit
long: |
Minimum time allowed for the motor input signal to pass through
the full output range. A value x means that the motor signal
can only go from 0 to 1 in minimum x seconds (in case of
reversible motors, the range is -1 to 1).
Forces the motor output signal to take at least the configured time (in seconds)
to traverse its full rangr normally [0%, 100%] if reversible [-100%, 100%].
MaEtUgR marked this conversation as resolved.
Show resolved Hide resolved

Zero means that slew rate limiting is disabled.
type: float
decimal: 2
increment: 0.01
unit: s
num_instances: *max_num_mc_motors
min: 0
max: 10
Expand All @@ -90,14 +89,14 @@ parameters:
description:
short: Servo ${i} slew rate limit
long: |
Minimum time allowed for the servo input signal to pass through
the full output range. A value x means that the servo signal
can only go from -1 to 1 in minimum x seconds.
Forces the servo output signal to take at least the configured time (in seconds)
to traverse its full range [-100%, 100%].
Copy link
Contributor

@hamishwillee hamishwillee Oct 23, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is the range of a servo defined from -1 to 1? I.e. can a servo be defined to have a range of 0 - 100%? If it can, I'd be tempted to remove the [-100%, 100%].

I ask because a while a rudder (say) moves about a neutral centre position, a flap moves from a neutral position to full extension. Now I think that for flaps the movement is always 0 - 1 but you can set zero to be half way across the servo PWM output range or at the lowest value.
That's all a bit confusing - I guess I'm saying, is it the time for moving neutral to full for a rudder?

Also, as above range [-1,1] is consistent with other docs.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

From the actuator doc example "They also have a slew rate of 0.5/s, meaning that it will take 2s to fully deflect them (a slew rate on the flaps is generally recommended to reduce the disturbances their movement creates)."

So I think this is from 0 to 1.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I actually don't know and would need to check in code. Likely @sfuhrer knows by heart and in case it's not super clear certainly how it should be.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The servo movement is always defined from -1 to 1. A flap is at -1 if at neutral and at 1 if fully deflected.
Does that answer your question?


Zero means that slew rate limiting is disabled.
type: float
decimal: 2
increment: 0.05
unit: s
num_instances: *max_num_servos
min: 0
max: 10
Expand Down
Loading