Skip to content

Commit

Permalink
Allow armed state and flight mode to be set directly
Browse files Browse the repository at this point in the history
  • Loading branch information
Jon Reeves committed Feb 18, 2025
1 parent 87e6c07 commit c6aa3a6
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions protos/action_server/action_server.proto
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,10 @@ service ActionServerService {
rpc SetAllowableFlightModes(SetAllowableFlightModesRequest) returns(SetAllowableFlightModesResponse) { option (mavsdk.options.async_type) = SYNC; }
// Get which modes the vehicle can transition to (Manual always allowed)
rpc GetAllowableFlightModes(GetAllowableFlightModesRequest) returns(GetAllowableFlightModesResponse) { option (mavsdk.options.async_type) = SYNC; }
// Set/override the armed/disarmed state of the vehicle directly, and notify subscribers
rpc SetArmedState(SetArmedStateRequest) returns(SetArmedStateResponse) { option (mavsdk.options.async_type) = SYNC; }
// Set/override the flight mode of the vehicle directly, and notify subscribers
rpc SetFlightMode(SetFlightModeRequest) returns(SetFlightModeResponse) { option (mavsdk.options.async_type) = SYNC; }
}

message SetAllowTakeoffRequest {
Expand All @@ -55,6 +59,14 @@ message SetAllowableFlightModesRequest
AllowableFlightModes flight_modes = 1;
}

message SetArmedStateRequest {
bool is_armed = 1; // Is armed now?
}

message SetFlightModeRequest {
FlightMode flight_mode = 1;
}

message GetAllowableFlightModesRequest {}

message SubscribeArmDisarmRequest {}
Expand Down Expand Up @@ -126,6 +138,14 @@ message GetAllowableFlightModesResponse {
AllowableFlightModes flight_modes = 1;
}

message SetArmedStateResponse {
ActionServerResult action_server_result = 1;
}

message SetFlightModeResponse {
ActionServerResult action_server_result = 1;
}

// State to check if the vehicle can transition to
// respective flightmodes
message AllowableFlightModes {
Expand Down

0 comments on commit c6aa3a6

Please sign in to comment.