0
0
Drone Programmingprogramming~10 mins

Setting geofence boundaries 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 maximum altitude for the geofence.

Drone Programming
geofence.set_max_altitude([1])
Drag options to blanks, or click blank then click option'
Amax_altitude
B100
Caltitude_limit
DsetAltitude
Attempts:
3 left
💡 Hint
Common Mistakes
Using a variable name instead of a number.
Passing a method name instead of a value.
2fill in blank
medium

Complete the code to define the geofence boundary as a circle with a radius.

Drone Programming
geofence.set_boundary_circle(center, [1])
Drag options to blanks, or click blank then click option'
Aperimeter
Bcircumference
Cdiameter
Dradius
Attempts:
3 left
💡 Hint
Common Mistakes
Using diameter instead of radius.
Using circumference or perimeter which are not parameters here.
3fill in blank
hard

Fix the error in the code to activate the geofence.

Drone Programming
geofence.[1]()
Drag options to blanks, or click blank then click option'
Adeactivate
Benable
Cactivate
Dstart
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'enable' or 'start' which are not valid methods here.
Using 'deactivate' which turns the geofence off.
4fill in blank
hard

Fill both blanks to create a rectangular geofence boundary with given corners.

Drone Programming
geofence.set_boundary_rectangle([1], [2])
Drag options to blanks, or click blank then click option'
Atop_left_corner
Bbottom_right_corner
Ccenter_point
Dradius
Attempts:
3 left
💡 Hint
Common Mistakes
Using center point or radius which are for circular boundaries.
Using the same point twice.
5fill in blank
hard

Fill both blanks to create a geofence dictionary with keys and a condition.

Drone Programming
geofence_data = {: {BLANK_2}} for [2] in boundaries if [1] > 0
Drag options to blanks, or click blank then click option'
A{
Bboundary
Ckey
D}
Attempts:
3 left
💡 Hint
Common Mistakes
Missing curly braces.
Using the same variable for key and value.
Not filtering boundaries with positive values.