MIStudio MCP Server

Updated

The MIStudio™ MCP server lets an AI assistant such as Claude Code, Cursor or VS Code Copilot build, inspect and maintain MIStudio applications. The assistant works in the MIStudio you have open, while you watch, and every change it makes is an ordinary edit you could have made yourself: one step in the undo history, nothing saved until the project is saved, and nothing live until you say so.

MIStudio logic editor wired to OPC UA tags, the finished dashboard with trends and gauges, and the AI assistant's build notes
An OPC UA dashboard and logger built through the MCP server in one take. The logic, the screen and the assistant's notes are all open for review.

What is an MCP server?

MCP, the Model Context Protocol, is the open standard AI assistants use to work with outside tools. An MCP server offers a set of tools; an assistant connected to it can call them. MIStudio's MCP server offers the studio itself: its palettes, editors, property sheets and project. The assistant doesn't write code to describe an application. It builds the application in MIStudio, with MIStudio's own components.

What the assistant can do

  • Add, rename, delete and open applications, and save the project
  • Search the logic and design palettes, then place logic nodes and screen components, move them and remove them
  • Read and set properties, through the property sheet and its checks
  • Browse what a connected system offers before choosing what to read: an OPC UA server's address space, a EUROMAP 63 machine's parameters, a database's tables and columns
  • Wire outputs to inputs, and bring a screen component into the logic so it can be wired
  • Have MIStudio's own code chat write a Python script, a screen's background page or an animation, see the script engine's diagnostics, and accept or reject the result
  • Take screenshots of the logic and the screen, and read back the values a component last received, to check its own work
  • Run a node you have allowed and read its result, such as a query's rows or a feature extraction, to investigate as well as build
  • Deploy the project to one of its configured targets, then check the result on the runtime
  • Undo and redo

The same server builds with TransSECS components: in the 25-minute video below, Claude wires a SECS/GEM interface into a running etch-tool simulator.

Done the same way an engineer would

An add is a palette drop. A property write goes through the property sheet with its checks. Each change is one step in the application's undo history, shared by its logic and screen windows. So there is nothing the assistant builds that you cannot see, select, change or undo in the ordinary way, and nothing it can do that you could not. It also builds the way ErgoTech recommends: calculations on their own named nodes rather than hidden in scripts, static screen artwork as one background page, colours from the application's palette, and components on the design grid.

The engineer stays in control

Watching Nodes and components appear in the open windows as they are added. A banner shows what the assistant is doing, and Take control stops it.
Simulating and live A project opens simulating: drivers do not talk to devices, and databases are not queried or written. Only an engineer can press Go Live. The assistant cannot go live, or go back.
What it may run Each node's Model Access setting (None, Read or Run) decides whether the assistant may read or run it, and running only works while live. The assistant cannot change Model Access, so allowing a node is always the engineer's decision.
Deploying Only to targets already set up in the project. The target's host, port and login, and the build settings, stay as the engineer set them. One deploy at a time.
Undo and save Every change can be undone until the project is saved, and nothing is written to disk until then. Each save is committed to the project's git repository.
Who can connect The server is off until an engineer turns it on, after a warning that explains what a connected assistant can do. It listens only on the local machine and refuses requests from web pages.

How this differs from an AI coding assistant writing code: Same model, different engineering »

Connecting an assistant

Turn on Tools > Enable MCP Server. MIStudio first explains what a connected assistant can do, and starts nothing unless you agree. The setting is remembered, so the server stays on across restarts until you turn it off. It serves at http://127.0.0.1:7250/mcp.

You can also start MIStudio with the server on from the command line, which is also how to choose a different port:

MIStudio -mcp 7300
Claude Code claude mcp add --transport http mistudio http://127.0.0.1:7250/mcp
Cursor, VS Code and others Add a server of type http (streamable HTTP) with the URL http://127.0.0.1:7250/mcp
Claude Desktop Clients that only start local programs need a bridge, such as npx mcp-remote http://127.0.0.1:7250/mcp

The assistant runs on the same machine as MIStudio. A “remote connector” added in a web-based assistant won't work, because it connects from the provider's servers. Scripts are written by MIStudio's own code chat, using the model selected in the script editor, which can be a local model.

How to ask

Say what the application should do, in the terms of your plant, and let the assistant find the palette entries. For example:

Add an application called Oven. In its logic, read four temperatures from a Modbus TCP device at 192.168.1.20 (holding registers 100-103, tenths of a degree). Convert them to degrees C. On the screen, show each zone on a gauge, 0-300 C, with a trend of all four over the last hour underneath. Save when done.

It can also explain and repair: “Look at the Mixer application and tell me what it does. Don't change anything,” or “The trend on the Oven screen shows a single point instead of a line. Find out why and fix it.” A modest screen with a handful of components and some wiring typically takes several minutes.

What it cannot do

  • Add anything that isn't in the palettes, including new Java components
  • Set properties that have their own editor dialogs, such as tag tables and file lists. It says so, and you set them.
  • Write scripts in anything but Python
  • Go live, change MIStudio's settings, change a deploy target, or change what it is allowed to run
  • Make a device reachable: whether a driver connects depends on the network and the device, as it does by hand

Watch it work