0
0
Drone Programmingprogramming~10 mins

Camera gimbal control in Drone Programming - Interactive Code Practice

Choose your learning style9 modes available
Practice - 5 Tasks
Answer the questions below
1fill in blank
easy

Complete the code to set the gimbal pitch angle to 30 degrees.

Drone Programming
gimbal.set_pitch([1])
Drag options to blanks, or click blank then click option'
A30
B45
C60
D90
Attempts:
3 left
💡 Hint
Common Mistakes
Using an angle value that is too large or too small.
Confusing pitch with yaw or roll.
2fill in blank
medium

Complete the code to smoothly move the gimbal yaw to 90 degrees.

Drone Programming
gimbal.move_yaw([1], speed=10)
Drag options to blanks, or click blank then click option'
A45
B0
C180
D90
Attempts:
3 left
💡 Hint
Common Mistakes
Using pitch or roll values instead of yaw.
Setting the angle to 0 which points forward.
3fill in blank
hard

Fix the error in the code to correctly set the gimbal roll angle to 15 degrees.

Drone Programming
gimbal.set_roll([1])
Drag options to blanks, or click blank then click option'
A15
B'15'
C15.0
Droll_angle
Attempts:
3 left
💡 Hint
Common Mistakes
Passing the angle as a string like '15'.
Using a variable name that is not defined.
4fill in blank
hard

Fill both blanks to create a dictionary of gimbal angles for pitch and yaw.

Drone Programming
angles = {'pitch': [1], 'yaw': [2]
Drag options to blanks, or click blank then click option'
A30
B45
C90
D15
Attempts:
3 left
💡 Hint
Common Mistakes
Swapping pitch and yaw values.
Using angles outside the typical range.
5fill in blank
hard

Fill all three blanks to set pitch, yaw, and roll angles in the gimbal control dictionary.

Drone Programming
gimbal_angles = {'pitch': [1], 'yaw': [2], 'roll': [3]
Drag options to blanks, or click blank then click option'
A15
B45
C90
D30
Attempts:
3 left
💡 Hint
Common Mistakes
Mixing up the order of angles.
Using string values instead of numbers.