Interface ManualCopterPilotingItf
-
- All Superinterfaces:
Activable
,PilotingItf
public interface ManualCopterPilotingItf extends PilotingItf, Activable
Manual piloting interface for copters.This piloting interface can be obtained from a
drone
using:drone.getPilotingItf(ManualCopterPilotingItf.class)
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static class
ManualCopterPilotingItf.SmartTakeOffLandAction
Action performed whensmartTakeOffLand()
is called.-
Nested classes/interfaces inherited from interface com.parrot.drone.groundsdk.device.pilotingitf.Activable
Activable.State
-
Nested classes/interfaces inherited from interface com.parrot.drone.groundsdk.device.pilotingitf.PilotingItf
PilotingItf.Provider
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description boolean
activate()
Activates this piloting interface.boolean
canLand()
Tells whether the copter can land.boolean
canTakeOff()
Tells whether the copter can take off.void
emergencyCutOut()
Requests emergency motor cut out.OptionalBooleanSetting
getBankedTurnMode()
Gets the current banked-turn mode.DoubleSetting
getMaxPitchRoll()
Gets the maximum roll and pitch angle setting, in degrees.OptionalDoubleSetting
getMaxPitchRollVelocity()
Gets the maximum roll and pitch velocity setting, in degrees/second.DoubleSetting
getMaxVerticalSpeed()
Gets the maximum vertical speed setting, in meters/second.DoubleSetting
getMaxYawRotationSpeed()
Gets the maximum yaw rotation speed setting in degrees/second.ManualCopterPilotingItf.SmartTakeOffLandAction
getSmartTakeOffLandAction()
Tells which action will be performed whensmartTakeOffLand()
is called.OptionalBooleanSetting
getThrownTakeOffMode()
Gets the current thrown take-off mode.void
hover()
Requests the copter to hover.void
land()
Requests the copter to land.void
setPitch(int value)
Sets the current pitch value.void
setRoll(int value)
Sets the current roll value.void
setVerticalSpeed(int value)
Set the current vertical speed value.void
setYawRotationSpeed(int value)
Set the current yaw rotation speed value.void
smartTakeOffLand()
Requests the copter to either take off, or get prepared for a thrown take-off, or cancel a thrown take-off, or land, depending on its state and on the thrown take-off setting.void
takeOff()
Requests the copter to take off.void
thrownTakeOff()
Requests the copter to get prepared for a thrown take-off.-
Methods inherited from interface com.parrot.drone.groundsdk.device.pilotingitf.Activable
deactivate, getState
-
-
-
-
Method Detail
-
activate
boolean activate()
Activates this piloting interface.If successful, the currently active piloting interface (if any) is deactivated and this one is activated.
- Returns:
true
on success,false
in case the piloting interface cannot be activated at this point
-
setPitch
void setPitch(int value)
Sets the current pitch value.value
is expressed as a signed percentage of themax pitch/roll setting
, in range [-100, 100].
-100 corresponds to a pitch angle of max pitch/roll towards ground (copter will fly forward), 100 corresponds to a pitch angle of max pitch/roll towards sky (copter will fly backward).Note:
value
may be clamped if necessary, in order to respect the maximum supported physical tilt of the copter.- Parameters:
value
- the new pitch value to set- See Also:
getMaxPitchRoll()
-
setRoll
void setRoll(int value)
Sets the current roll value.value
is expressed as a signed percentage of themax pitch/roll setting
, in range [-100, 100].
-100 corresponds to a roll angle of max pitch/roll to the left (copter will fly left), 100 corresponds to a roll angle of max pitch/roll to the right (copter will fly right).Note:
value
may be clamped if necessary, in order to respect the maximum supported physical tilt of the copter.- Parameters:
value
- the new pitch roll to set- See Also:
getMaxPitchRoll()
-
setYawRotationSpeed
void setYawRotationSpeed(int value)
Set the current yaw rotation speed value.value
is expressed as as a signed percentage of themax yaw rotation speed setting
, in range [-100, 100].
-100 corresponds to a counter-clockwise rotation of max yaw rotation speed, 100 corresponds to a clockwise rotation of max yaw rotation speed.- Parameters:
value
- the new yaw rotation speed value to set- See Also:
getMaxYawRotationSpeed()
-
setVerticalSpeed
void setVerticalSpeed(int value)
Set the current vertical speed value.value
is expressed as as a signed percentage of themax vertical speed setting
, in range [-100, 100].
-100 corresponds to max vertical speed towards ground,100 corresponds to max vertical speed towards sky.- Parameters:
value
- the new vertical speed value to set- See Also:
getMaxVerticalSpeed()
-
hover
void hover()
Requests the copter to hover.Puts pitch and roll to 0.
-
canTakeOff
boolean canTakeOff()
Tells whether the copter can take off.- Returns:
true
if the copter can take off, otherwisefalse
-
canLand
boolean canLand()
Tells whether the copter can land.- Returns:
true
if the copter can land, otherwisefalse
-
takeOff
void takeOff()
Requests the copter to take off.
-
thrownTakeOff
void thrownTakeOff()
Requests the copter to get prepared for a thrown take-off.
-
smartTakeOffLand
void smartTakeOffLand()
Requests the copter to either take off, or get prepared for a thrown take-off, or cancel a thrown take-off, or land, depending on its state and on the thrown take-off setting.
-
getSmartTakeOffLandAction
@NonNull ManualCopterPilotingItf.SmartTakeOffLandAction getSmartTakeOffLandAction()
Tells which action will be performed whensmartTakeOffLand()
is called.- Returns:
- action performed when
smartTakeOffLand()
is called
-
land
void land()
Requests the copter to land.
-
emergencyCutOut
void emergencyCutOut()
Requests emergency motor cut out.
-
getMaxPitchRoll
@NonNull DoubleSetting getMaxPitchRoll()
Gets the maximum roll and pitch angle setting, in degrees.Defines the range used by
setPitch(int)
andsetRoll(int)
methods. For instance, setting pitch to 100 corresponds to an angle ofgetMaxPitchRoll().getValue()
degrees.- Returns:
- the maximum roll/pitch setting
-
getMaxPitchRollVelocity
@NonNull OptionalDoubleSetting getMaxPitchRollVelocity()
Gets the maximum roll and pitch velocity setting, in degrees/second.Defines the copter dynamic by changing the speed by which the copter will move to the requested roll/pitch angle.
- Returns:
- the maximum roll/pitch velocity setting
-
getMaxVerticalSpeed
@NonNull DoubleSetting getMaxVerticalSpeed()
Gets the maximum vertical speed setting, in meters/second.Defines the range used by
setVerticalSpeed(int)
method. For instance, setting vertical speed to 100 corresponds to a vertical speed ofgetMaxVerticalSpeed().getValue()
meters/second.- Returns:
- the maximum vertical speed setting
-
getMaxYawRotationSpeed
@NonNull DoubleSetting getMaxYawRotationSpeed()
Gets the maximum yaw rotation speed setting in degrees/second.Defines the range used by
setYawRotationSpeed(int)
. For instance, setting yaw rotation speed to 100 corresponds to a yaw rotation speed ofgetMaxYawRotationSpeed().getValue()
degrees/second.- Returns:
- the maximum yaw rotation speed setting
-
getBankedTurnMode
@NonNull OptionalBooleanSetting getBankedTurnMode()
Gets the current banked-turn mode.If available, banked-turn mode can either be enabled or disabled.
When enabled, the drone will use yaw values from the piloting command to infer with roll and pitch when the horizontal speed is not null.- Returns:
- the banked-turn mode setting
-
getThrownTakeOffMode
@NonNull OptionalBooleanSetting getThrownTakeOffMode()
Gets the current thrown take-off mode.If available, thrown take-off mode can either be enabled or disabled.
When enabled, a call tosmartTakeOffLand()
may send a request to copter to get prepared for a thrown take-off, depending on copter's state.- Returns:
- the thrown take-off mode setting
-
-