Main Content

checkPermission

Check UAV platform permission based on geofencing

Since R2020b

Description

permission = checkPermission(platform) checks whether the current UAV platform position is permitted according to the geofences.

permission = checkPermission(platform,position) checks whether a specific position in the scenario inertial frame is permitted.

permission = checkPermission(platform,position,Name,Value) specifies options using one or more name-value pair arguments. For example, 'UseLatLon',true uses latitude, longitude, and altitude coordinates for the positions input.

Input Arguments

collapse all

UAV platform in a scenario, specified as a uavPlatform object.

UAV platform position in the scenario inertial frame, specified as a vector of the form [x y z].

Data Types: double

Name-Value Arguments

Specify optional pairs of arguments as Name1=Value1,...,NameN=ValueN, where Name is the argument name and Value is the corresponding value. Name-value arguments must appear after other arguments, but the order of the pairs does not matter.

Before R2021a, use commas to separate each name and value, and enclose Name in quotes.

Example: 'UseLatLon',trueuses latitude, longitude, and altitude coordinates for the positions input.

Use latitude, longitude, and altitude coordinates for platform position, specified as the comma-separated pair 'UseLatLon' and a logical 0 (false) or 1(true).

Data Types: logical

Reference frame for computing UAV platform motion, specified as the comma-separated pair consisting of 'ReferenceFrame' and a string scalar, which matches any reference frame in the uavScenario.

Data Types: char | string

Output Arguments

collapse all

Geofence permission for platform, returned as a 0 (false) or 1 (true), which indicates whether the UAV platform is permitted inside the geofence (true) or not permitted (false).

Data Types: logical

Version History

Introduced in R2020b