Skip to main content
Glama
Edge-JB
by Edge-JB

tc_cpp

Create, build, and publish TwinCAT C++ projects and modules via TIXC. Perform code generation, property editing, and import existing projects.

Instructions

TwinCAT C++ projects/modules under TIXC (paths use ^ separators). C++ ONLY — TISC (safety) untouched; runtime needs a later activate/download. VS-hosted-safe: create/open go purely through ITcSmTreeItem.CreateChild on TIXC (no New/Open/SaveConfiguration). Actions: create_project (name, template, before?) — CreateChild a new C++ project node under TIXC from a wizard; template = "TwinCAT C++ Project Wizard" | "TcVersionedDriverWizard" | "TcModuleCyclicCallerWizard" (or a full template .vcxproj/.tczip path — if a wizard NAME is rejected, fall back to the file path). create_module (projectPath = TIXC^, name, template? default "TwinCAT Class Wizard", before?) — CreateChild a module/class on an existing C++ project. open (file = existing .vcxproj/.tczip, subType? 0 copy into solution dir (default) /1 move/2 use-in-place, before?) — import an existing C++ project; the project is NOT renamed (CreateChild name is empty). tmc_codegen (projectPath) — offline StartTmcCodeGenerator (regenerates C++ from the .tmc; no runtime impact). set_props (projectPath, bootProjectEncryption? None|Target, saveProjectSources?) — offline config edit via ConsumeXml (at least one prop required). build (projectName = the .vcxproj DTE project Name/UniqueName, config? default "Release|TwinCAT RT (x64)", waitForFinish? default true, timeoutMs? default 1800000) — compile a single C++ project via SolutionBuild2.BuildProject; compiles only, does NOT deploy. publish (projectPath, confirm) — GUARDED, requires confirm="ALLOW_CPP_PUBLISH" and defaults to no-op: builds the module for ALL platforms and exports the deployable/shippable driver artifacts (long-running); does NOT itself activate/restart the runtime. CAVEAT: the ConsumeXml wrapper element for C++ project params is from a doc summary (Set-TreeItemXml surfaces GetLastXmlError, so a wrong element fails loudly); ProduceXml the project node once to confirm element names before relying on tmc_codegen/set_props/publish.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
fileNo
nameNo
actionYes
beforeNoinsert before this sibling
configNo
confirmNo
subTypeNo
templateNo
timeoutMsNo
projectNameNo
projectPathNo
waitForFinishNo
saveProjectSourcesNo
bootProjectEncryptionNo

Schema Changelog

Changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. Changed1 schema field changedv2.4.0
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
  2. Addedv2.1.1

TDQS

A4.3/5.0
Behavior4/5

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

With no annotations provided, the description fully discloses behavior: build does not deploy, publish does not activate/restart runtime, ConsumeXml wrapper element details, and fallback logic. The caveat about ProduceXml to confirm element names adds important nuance. A slightly more organized summary would improve clarity, but transparency is strong.

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

Conciseness3/5

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

The description is dense at over 500 words, covering seven actions and many details. While every sentence adds value, the structure is a single paragraph block with inline action descriptions and a trailing caveat. Better formatting (e.g., bullet lists or subheadings) would improve scannability for an AI agent.

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?

Given the tool's complexity (14 parameters, 7 actions, no output schema, no annotations, many siblings), the description covers most aspects: each action's purpose, parameter usage, fallbacks, and limitations. It addresses potential pitfalls (e.g., ConsumeXml element names). Missing explicit return value or error handling information, but the overall completeness is high.

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 only 7% (only 'before' has a brief description). The description compensates thoroughly: it explains each action's parameters in context (e.g., template enum values and fallback, subType meanings, confirm guard for publish, default config and timeoutMs). This adds significant meaning beyond the sparse schema.

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?

The description clearly states the tool is for TwinCAT C++ projects/modules under TIXC, explicitly listing seven distinct actions. It distinguishes from siblings by stating 'C++ ONLY — TISC (safety) untouched' and noting runtime needs a later activate/download, which sets it apart from activation tools like twincat_activate_configuration.

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?

The description provides explicit context: 'C++ ONLY — TISC (safety) untouched' tells when not to use for safety projects. It details action-specific usage (e.g., template fallback, subType options, guarded publish). However, it does not explicitly list alternative tools for specific scenarios, relying on the sibling list for comparison.

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

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/Edge-JB/TwinCAT-XAE-MCP'

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