Skip to content

Vertical environments are unable to accurately sustain altitude #59

Description

@jangroter

The current implementation of altitude actions in VerticalCREnv and DescentEnv make it difficult to maintain altitude.
When decreasing the vertical rate initially it decreases as expected, but as the action approaches 0.0 it reaches a treshold where the vertical rate increases instead.

Requirement
at action == 0 the current altitude should be maintained and as action assymptotically goes to zero the vertical rate should decrease proportionally to the action.

This is currently not satisfied.

See code block for current implementation of vertical actions:

action = action * ACTION_2_MS

# Bluesky interpretes vertical velocity command through altitude commands 
# with a vertical speed (magnitude). So check sign of action and give arbitrary 
# altitude command

# The actions are then executed through stack commands;
if action >= 0:
    bs.traf.selalt[0] = 1000000 # High target altitude to start climb
    bs.traf.selvs[0] = action
elif action < 0:
    bs.traf.selalt[0] = 0 # High target altitude to start descent
    bs.traf.selvs[0] = action

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions