moveOnMap method

Future<String> moveOnMap(
  1. Pose destination,
  2. String componentName,
  3. String slamServiceName, {
  4. MotionConfiguration? motionConfiguration,
  5. List<Geometry>? obstacles,
  6. Map<String, dynamic>? extra,
})

Move the base named componentName to the destination in the SLAM map produced by the SLAM service named slamServiceName. Returns the execution ID of the resulting plan, which can be passed to getPlan.

// Example:
final executionId = await myMotionService.moveOnMap(Pose(x: 1000, y: 0, z: 0), 'myBase', 'mySlamService');

For more information, see the motion service docs.

Implementation

Future<String> moveOnMap(
  common_pb.Pose destination,
  String componentName,
  String slamServiceName, {
  MotionConfiguration? motionConfiguration,
  List<common_pb.Geometry>? obstacles,
  Map<String, dynamic>? extra,
}) async {
  final request = MoveOnMapRequest(
    name: name,
    destination: destination,
    componentName: componentName,
    slamServiceName: slamServiceName,
    motionConfiguration: motionConfiguration,
    obstacles: obstacles,
    extra: extra?.toStruct(),
  );
  final response = await client.moveOnMap(request, options: callOptions);
  return response.executionId;
}