get_actual_joint_pose
Retrieve current joint angles from a Universal Robots collaborative robot by specifying its IP address to monitor real-time positioning data.
Instructions
获取指定IP机器人的当前关节角度 IP:机器人地址
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ip | Yes |
Implementation Reference
- MCP tool handler decorated with @mcp.tool(). Retrieves current joint positions using robot_list[ip].get_actual_joint_positions() after connection check. Returns formatted message or error.@mcp.tool() def get_actual_joint_pose(ip: str): """获取指定IP机器人的当前关节角度 IP:机器人地址""" try: if '连接失败' in link_check(ip): return return_msg(f"与机器人的连接已断开。") logger.info(f"当前关节姿态 {robot_list[ip].get_actual_joint_positions()}") return return_msg(f"当前关节姿态 {robot_list[ip].get_actual_joint_positions()}") except Exception as e: logger.error(f"TCP位置获取失败: {str(e)}") return return_msg(f"TCP位置获取失败: {str(e)}")