siemens/tia-portal-ai-extensions/plc-data-types
Claude Code and agent skill by siemens/tia-portal-ai-extensions
- community
Checking that the SKILL.md file is still in the repository.
TIA Portal PLC Data Types (UDTs / PlcType) — TypeGroup navigation, recursive search, UDT XML export structure (Section Name="None"), and Member attribute formats. Use when writing or reviewing C# code that accesses, searches, creates, or parses UDTs in PlcSoftware.TypeGroup.
Install
npx vskill@latest install siemens/tia-portal-ai-extensions/plc-data-typesSKILL.md
PLC Data Types (UDTs)
Overview
PLC Data Types (UDTs) live in PlcSoftware.TypeGroup as PlcType objects. They are completely separate from blocks (PlcSoftware.BlockGroup) and from library types (GlobalLibrary.TypeFolder). This skill covers TypeGroup navigation, recursive search, and the XML export structure for UDTs.
Required Namespaces
Required Assemblies
Siemens.Engineering.Base.dllSiemens.Engineering.Step7.dll
1. TypeGroup Structure
PlcTypeUserGroup sub-folders are purely organizational — they are NOT SW-Units.
2. Finding a UDT
Types.Find(name) searches only the current group level. For deep search, recurse into Groups:
To search across the entire PLC (root and all SW-Units), see `sw-units`.
3. Creating and Navigating Sub-Groups
Group nesting is unlimited. Always use Find before Create to avoid duplicates.
4. UDT XML Export — Section Name Rule
When a PLC Data Type (SW.Types.PlcStruct) is exported via Openness, its members are always inside <Section Name="None">.
Critical rule: Never look for <Section Name="Static"> when parsing UDT exports — that section name belongs exclusively to Global DBs (SW.Blocks.GlobalDB). UDTs always use "None".
5. Member Attribute Formats
Each <Member> element carries:
| Attribute | Format | Example | |
|---|---|---|---|
| Primitive type | Plain type name | Datatype="Real", Datatype="Bool", Datatype="Int" | |
| UDT reference | XML-escaped quoted name | Datatype=""MyNamespace.MyUDT"" | |
| Array | Array declaration | Datatype="Array[0..9] of Real" | |
| Array of UDT | Combined | Datatype="Array[0..3] of "MyUDT"" |
When parsing member data types programmatically, unescape " → " before processing.
Quick Reference
| Goal | API | |
|---|---|---|
| Find UDT by name (one level) | PlcTypeGroup.Types.Find(name) | |
| Find UDT recursively | Recurse into group.Groups manually | |
| Create type sub-group | group.Groups.Find(name) ?? group.Groups.Create(name) | |
| Place UDT from LibraryType | typeGroup.Types.CreateFrom(udtVersion, UpdatePathsMode.UpdatePathsInTarget) | |
| Place UDT from MasterCopy | typeGroup.Types.CreateFrom(mc, MasterCopyMode.ThrowIfExists) | |
| UDT XML section name | <Section Name="None"> — always, never "Static" |
Common Failure Modes
| Symptom | Root Cause | Fix | |
|---|---|---|---|
| UDT not found | Searching only one group level | Recurse into Groups | |
| No members extracted from XML | Parsing Section Name="Static" instead of "None" | Look for Section Name="None" for UDTs | |
| Duplicate type sub-group | Create called without Find first | Always Find before Create |
Related Files
- `sw-units` — PLC-wide UDT search across root and all SW-Unit TypeGroups
- `global-library` — placing UDTs from library (MasterCopy or LibraryType path)
- `blocks` — blocks live in
BlockGroup, notTypeGroup
Security
- Security scanPassed, 90 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingopenness_development/skills/plc-data-types/SKILL.md
Popularity
- 7-day trend score
- 0
Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/siemens/tia-portal-ai-extensions/plc-data-types)