ROI: accept ROIs of type None in missions to enable 'deactivating' another ROI

This commit is contained in:
Nicolas de Palezieux 2018-01-04 10:18:22 +01:00 committed by Lorenz Meier
parent bedaafcc20
commit add3692357
1 changed files with 4 additions and 0 deletions

View File

@ -1352,6 +1352,10 @@ MavlinkMissionManager::parse_mavlink_mission_item(const mavlink_mission_item_t *
mission_item->params[5] = mavlink_mission_item->y;
mission_item->params[6] = mavlink_mission_item->z;
} else if ((int)mavlink_mission_item->param1 == MAV_ROI_NONE) {
mission_item->nav_cmd = NAV_CMD_DO_SET_ROI;
mission_item->params[0] = MAV_ROI_NONE;
} else {
return MAV_MISSION_INVALID_PARAM1;
}