Skip to main content
Glama
apexsotjo-blip

RemoteConnect MCP Server

write_st_logic

Write or replace IEC 61131-3 Structured Text logic for a program section, optionally declaring variables, then build the project to fix any errors.

Instructions

Write a program section in plain IEC 61131-3 Structured Text — no XML required. Creates the section or replaces its logic if it exists.

task is the program task that owns the section — 'MAST' for the default master task (also 'FAST', 'AUX0'..'AUX3', 'SAFE'); call get_project_structure to see the project's tasks. section is the section name to create or overwrite. st_source is raw ST (IF/CASE/FOR, FB calls like 'T1(IN := x, PT := t#3s, Q => y);', set()/reset() on EBOOLs, re()/fe() edges). declare optionally declares variables as a comma-separated 'name:TYPE' list, e.g. 'StartPB:BOOL, Delay1:TON, Level:REAL' — FB instances called in the code (TON/TOF/CTU/DFB types) must exist or be declared here. Run build_project afterwards and fix any errors from its output.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
taskYes
declareNo
sectionYes
st_sourceYes
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full burden. It discloses the destructive overwrite behavior, that it accepts raw ST, that FB instances must exist or be declared, and that build_project is a separate follow-up. It does not clarify whether existing declarations are merged or replaced, nor what success/failure returns look like.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is front-loaded with the core purpose and then organized by parameter. Examples are embedded without padding, and the build_project follow-up is stated in a single actionable sentence. Every sentence earns its place.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a tool with no annotations and no output schema, the description covers purpose, all parameters, prerequisites, valid task names, required declarations, and a post-step. It would be stronger if it briefly stated what the tool returns on success or failure, but it is sufficient for an agent to select and invoke it correctly.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, but the description fully compensates by explaining every parameter: task with concrete examples, section as create/overwrite target, st_source with ST syntax examples, and declare with a comma-separated 'name:TYPE' example and FB declaration requirement. This is exactly the compensation needed.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Clearly states a specific verb ('Write') and resource ('program section in plain IEC 61131-3 Structured Text'), and immediately distinguishes itself from XML-based tools by saying 'no XML required.' It also clarifies create-or-replace semantics, helping an agent distinguish it from read_section, create_section, and import_xml.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Provides strong contextual guidance: identifies the owning task with valid values, tells the agent to call get_project_structure to discover tasks, requires FB instances to be declared, and gives the follow-up workflow of running build_project. It does not explicitly enumerate alternatives or when-not-to-use cases, so it falls just short of a 5.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

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/apexsotjo-blip/remoteconnect-mcp'

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