open-simulation-interface icon indicating copy to clipboard operation
open-simulation-interface copied to clipboard

TrafficCommandUpdate can not feedback success information.

Open yanqd0 opened this issue 1 year ago • 0 comments

Describe the feature

Current TrafficCommandUpdate message is here (while docs are removed for short):

message TrafficCommandUpdate
{
    optional InterfaceVersion version = 1;
    optional Timestamp timestamp = 2;
    optional Identifier traffic_participant_id = 3;
    repeated DismissedAction dismissed_action = 4;

    message DismissedAction 
    {
        optional Identifier dismissed_action_id = 1;
        optional string failure_reason = 2;
    }
}

It is clear that this message is not for accepted or completed actions.

Describe the solution you would like

message TrafficCommandUpdate
{
    optional InterfaceVersion version = 1;
    optional Timestamp timestamp = 2;
    optional Identifier traffic_participant_id = 3;
    repeated DismissedAction dismissed_action = 4;

    message DismissedAction 
    {
        optional Identifier dismissed_action_id = 1;
        optional string failure_reason = 2;
    }

    repeated AcceptedAction accepted_action = 5;

    message AcceptedAction 
    {
        optional Identifier id = 1;
        optional ActionState state = 2;
        optional string description = 3;
    }

    enum ActionState {
        ACTION_STATE_UNKNOWN = 0;
        ACTION_STATE_ACCEPTED = 1;
        ACTION_STATE_RUNNING = 2;
        ACTION_STATE_SUCCESS = 3;
        ACTION_STATE_ABORTED = 4;
        ACTION_STATE_FAILED = 5;
        ACTION_STATE_CUSTOM0 = 6;
        ACTION_STATE_CUSTOM1 = 7;
        ACTION_STATE_CUSTOM2 = 8;
        ACTION_STATE_CUSTOM3 = 9;
    }
}

Or sth like that.

Describe alternatives you have considered

None.

Describe the backwards compatibility

It is backwards compatible that only extra fields are added.

Additional context

None.

yanqd0 avatar Mar 20 '24 03:03 yanqd0