-
Notifications
You must be signed in to change notification settings - Fork 65
Expose activity info #136
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
Expose activity info #136
Conversation
a0b3e4a to
dea4246
Compare
|
|
||
|
|
||
| void onFlightModeInfoChange(const std::function<void(const std::optional<std::string>&)> & callback) { _on_flight_mode_info_change = callback; } | ||
| void setFlightModeInfo(const std::optional<std::string>& flightModeInfo); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you avoid the term flight mode? It can also be used on non-flying vehicles. Maybe 'activity info' would be better.
Can you add API docs for what the purpose of this is? Are there formatting constraints (i.e. can it be multiple lines)?
Should the info be cleared when moving on to the next mission item? Or when deactivating and on abort?
dea4246 to
7e7a1e9
Compare
7e7a1e9 to
feb34e8
Compare
a5510df to
0b0de17
Compare
feb34e8 to
998eca0
Compare
8cd3cb9 to
11d86e0
Compare
| /** | ||
| * @brief Clears the activity information. | ||
| * This method sets the activity info of the mission executor to `std::nullopt`. | ||
| * It should be called after an action is completed to ensure the state is properly reset. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's call this automatically when switching to the next waypoint, or when the mission is deactivated or aborted.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I saw that. It's an extra step that can easily be forgotten.
11d86e0 to
37e0cf4
Compare
f4afb3a to
644fb7e
Compare
37e0cf4 to
030c980
Compare
644fb7e to
748b7c7
Compare
986409f to
45eba72
Compare
08a1785 to
b9d0f45
Compare
ac68a06 to
e0f68dc
Compare
b9d0f45 to
b44a064
Compare
We need a way from an action to set some extra information about the current activity, so those can gets exposed externally if wanted. This commit adds an interface from the ActionHandler to set/clear the activity info into the mission_executor. It will call the clear activty info when: - switch next waypoint - mission aborted - mission deactivated
b44a064 to
98a3c14
Compare
We need a way from an action to set some extra information about the current action, so those can gets exposed externally if wanted.
This commit adds an interface from the ActionHandler to set/clear the flight mode info into the mission_execturo