Skip to content

Commit

Permalink
Copter: tell the gcs that the number of available modes has changed w…
Browse files Browse the repository at this point in the history
…hen registering a custom mode
  • Loading branch information
IamPete1 committed Nov 15, 2024
1 parent f7659eb commit 1fd2a1e
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions ArduCopter/Copter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -448,6 +448,10 @@ AP_Vehicle::custom_mode_state* Copter::register_custom_mode(const uint8_t num, c
// Allocation failure
return nullptr;
}

// Registration sucsessful, notify the GCS that it should re-request the avalable modes
gcs().available_modes_changed();

return &mode_guided_custom[i]->state;
}
}
Expand Down

0 comments on commit 1fd2a1e

Please sign in to comment.