Skip to main content
Glama

disconnect_ur

Terminate a UR robot's connection by specifying its IP address using the nUR MCP Server. Ensures controlled disconnection for industrial robotics management.

Instructions

根据用户提供的IP,断开与UR机器人的连接 IP:机器人地址

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
ipYes

Implementation Reference

  • The main handler function for the 'disconnect_ur' tool. It is decorated with @mcp.tool(), which registers it as an MCP tool. The function takes an IP string, checks if the connection exists in robot_list, closes the connection if it does, and returns appropriate messages.
    @mcp.tool() def disconnect_ur(ip: str): """根据用户提供的IP,断开与UR机器人的连接 IP:机器人地址""" try: if robot_list.get(ip, "unknown") == "unknown": return return_msg("连接不存在") robot_list[ip].close() return return_msg("连接已断开。") except Exception as e: logger.error(f"连接断开失败: {str(e)}") return return_msg(f"连接断开失败: {str(e)}")
  • The @mcp.tool() decorator registers the disconnect_ur function as an MCP tool.
    @mcp.tool()
  • The docstring describes the input parameter 'ip' as the robot's IP address, serving as input schema documentation.
    """根据用户提供的IP,断开与UR机器人的连接 IP:机器人地址"""
  • Internal call to disconnect_ur within the connection logic.
    disconnect_ur(ip)

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/nonead/nUR-MCP-SERVER'

If you have feedback or need assistance with the MCP directory API, please join our Discord server