BB.Ufactory.Robots.XArm6 (bb_ufactory v0.1.0)

Copy Markdown View Source

BB robot definition for the UFactory xArm6.

6-DOF serial manipulator with revolute joints J1–J6. All joints rotate about their local Z axis. Joint limits and effort values are sourced from the xArm Developer Manual V1.10.0 and confirmed against the URDF in tmp/urdf/xarm6/.

Joint Limits

JointLower (rad)Upper (rad)Effort (N·m)Max Velocity (rad/s)
J1-2π+2π50π
J2-2.059+2.09450π
J3-3.927+0.19232π
J4-2π+2π32π
J5-1.69332π
J6-2π+2π20π

Usage

defmodule MyRobot do
  use BB.Ufactory.Robots.XArm6

  controllers do
    controller :xarm, {BB.Ufactory.Controller,
      host: "192.168.1.111",
      model: :xarm6,
      loop_hz: 100
    }
  end
end

Or copy the topology into an existing robot module that also includes accessories (gripper, F/T sensor, linear track).

Summary

Functions

Returns a child specification for starting this robot under a supervisor.

Returns the optimised robot representation.

Starts the robot's supervision tree.

Functions

child_spec(opts \\ [])

@spec child_spec(Keyword.t()) :: Supervisor.child_spec()

Returns a child specification for starting this robot under a supervisor.

robot()

@spec robot() :: BB.Robot.t()

Returns the optimised robot representation.

This struct is built at compile-time from the DSL definition and contains:

  • All physical values converted to SI base units (floats)
  • Flat maps for O(1) lookup of links, joints, sensors, and actuators
  • Pre-computed topology metadata for efficient traversal

Examples

robot = Elixir.BB.Ufactory.Robots.XArm6.robot()
link = BB.Robot.get_link(robot, :base_link)
joint = BB.Robot.get_joint(robot, :shoulder)

start_link(opts \\ [])

@spec start_link(Keyword.t()) :: Supervisor.on_start()

Starts the robot's supervision tree.

Options

All options are passed through to sensor and actuator child processes.