order_zone_points()
  • 1 Minute to read

order_zone_points()


Article summary

order_zone_points()

Retrieve all the points that are composing a specified zone area.

Reference

Arguments

ArgumentsTypeDefault value
zone_namestrThe requested zone on the map.
from_current_poseboolFalseIf True, sort from the current pose, if False sort from the center of the zone.

Return

Dict with a bool if the points was sorted and the number of points.

KeyTypeInfo
ordered_pointsboolTrue if the points were sorted successfully.
num_pointsintnumber of points.
Important note!

This function does not return the points, it only orders and stores them to be obtained with the function get_sorted_zone_point.

Exceptions

ExceptionCondition
RayaNavNotLocatedThe robot is not located on the map.
RayaNavZonesNotFoundNo zones found on the map.
RayaNavUnkownErrorAn unknown error occurs.
RayaWrongArgumentpos_unit is neither POS_UNIT.METERS nor POS_UNIT.PIXEL.

See the complete list of Raya Exceptions.


Was this article helpful?

What's Next