Commit 38b96adf authored by Julian Oes's avatar Julian Oes

Arming flag is now included when flight mode is changed in the ControlWidget

parent cf176d0c
...@@ -178,6 +178,12 @@ void UASControlWidget::transmitMode() ...@@ -178,6 +178,12 @@ void UASControlWidget::transmitMode()
UASInterface* mav = UASManager::instance()->getUASForId(this->uas); UASInterface* mav = UASManager::instance()->getUASForId(this->uas);
if (mav) if (mav)
{ {
// include armed state
if (engineOn)
uasMode |= MAV_MODE_FLAG_SAFETY_ARMED;
else
uasMode &= ~MAV_MODE_FLAG_SAFETY_ARMED;
mav->setMode(uasMode); mav->setMode(uasMode);
QString mode = ui.modeComboBox->currentText(); QString mode = ui.modeComboBox->currentText();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment