Keywords: OSDK waypoint v2, cruising speed
How to set the cruise speed in OSDK waypoint v2? Is it possible to set different speeds for different waypoints?
The cruising speed is the global cruising speed. It does not support the pre-setting of a single waypoint.But It can be evaluated and implemented indirectly by calling API to change the cruising speed after reched the waypoint.
void WaypointV2MissionSample::setGlobalCruiseSpeed(const GlobalCruiseSpeed &cruiseSpeed, int timeout)
{
ErrorCode::ErrorCodeType ret = vehiclePtr->waypointV2Mission->setGlobalCruiseSpeed(cruiseSpeed, timeout);
if(ret != ErrorCode::SysCommonErr::Success)
{
DERROR("Set glogal cruise speed %f m/s failed ErrorCode:0x%lX", cruiseSpeed, ret);
ErrorCode::printErrorCodeMsg(ret);
return;
}
DSTATUS("Current cruise speed is: %f m/s", cruiseSpeed);
}
Note: This article is from Chinese and is translated by machine. If there is any suggestions, please point it out and we will correct it in time
Comments
0 comments
Please sign in to leave a comment.