Purpose: Deep understanding of FrameworX for AI tools and
...
API programmers
...
FrameworX has a clear separation between configuration (design-time) and execution (runtime).
Design-Time Components:
Runtime Components:
Architecture Flow Table:
| Layer | Component | Purpose | Communication |
|---|---|---|---|
| Design-Time | Designer.exe | Human configuration UI | Writes to .DBSLN |
| Design-Time | MCP Designer Tools | AI configuration | Writes to .DBSLN |
| Transition | TStartup.exe | Process launcher | Reads .DBSLN, starts TServer |
| Runtime | TServer.exe | UNS + module host | Listens on port 3101 |
| Runtime | Runtime MCP Tools | AI monitoring | Connects to TServer |
| Runtime | WPF/Web/Mobile Client | User displays | Connects to TServer port |
Key Points:
| Aspect | Description |
|---|---|
| Format | Encrypted SQLite database |
| Contains | All configuration tables, compiled code, display definitions |
| Editing | Single file, but multiple Designer instances supported with built-in protection |
| Export/Import | JSON files for individual objects, but solution is single file |
| Action | Purpose | Required? |
|---|---|---|
| Save | Commits changes, incremental compile | Automatic |
| Build | Full recompile, creates restore point, increments build number | Optional (for versioning) |
| Publish | Creates .DBRUNTIME (read-only) for regulated environments (FDA) | Only for regulated deployment |
...
FrameworX has a unified structure where TableType, UI Navigation, and Runtime Namespace are linked.
Mapping Table:
| TableType | UI Section | UI Tab | Runtime Namespace |
|---|---|---|---|
| AlarmsGroups | Alarms | Groups | Alarm.Group.{name} |
| AlarmsItems | Alarms | Items | Alarm.Item.{name} |
| DevicesChannels | Devices | Channels | Device.Channel.{name} |
| DevicesNodes | Devices | Nodes | Device.Node.{name} |
| UnsTags | Uns | Tags | Tag.{path}/{name} |
| ScriptsTasks | Scripts | Tasks | Script.Task.{name} |
| ScriptsClasses | Scripts | Classes | Script.Class.{name} |
| HistorianTables | Historian | HistorianTables | Historian.Table.{name} |
| DatasetsQueries | Datasets | Queries | Dataset.Query.{name} |
| DisplaysList | Displays | List | Display.{name} |
Implication: Objects in a table (e.g., AlarmsGroups has "Critical", "Warning") become runtime namespace objects (Alarm.Group.Critical, Alarm.Group.Warning).
ALL objects in FrameworX are "runtime objects" - they have properties that can be read (and sometimes written) at runtime.
Runtime Object Categories:
Example: Device.Node.MyNode has properties like .Error, .Status that can be read at runtime for diagnostics.
...
Tag Path Syntax: Tag.Folder1/Folder2/TagName
Structure:
When creating a tag with a UDT type, member tags are automatically created.
Example UDT Definition (UnsUserTypes):
| Property | Value |
|---|---|
| Name | PID |
| Members | SP (Double), PV (Double), Output (Double), Auto (Digital) |
Tag Instance Creation:
| Property | Value |
|---|---|
| Name | Controller1 |
| Type | PID |
Resulting Runtime Objects:
UDT Advantages:
Domain Scope Table:
| Domain | Scope | Example Objects | Use Cases |
|---|---|---|---|
| Server | Synchronized to ALL connected clients | Tag., Alarm., Device., Script., Historian., Dataset. | Process data, shared state |
| Client | Local to each client only | @Client.Username, tags with Domain='Client' | User-specific UI state, report parameters |
Server Domain Behavior:
Client Domain Behavior:
Creating Client Domain Tags:
{ "Name": "ReportStartDate", "Domain": "Client", "Type": "DateTime" }
...
| Aspect | Script Tasks | Script Expressions |
|---|---|---|
| Complexity | Full methods, multi-line code | One-liners |
| Languages | C#, VB, Python | Expression syntax |
| Compilation | Compiled to .NET method | Interpreted |
| Trigger | Events, schedules, tag changes | OnChange, intervals |
| Use Case | Complex logic, API calls | Simple calculations |
| Performance | Equivalent | Equivalent |
| Configuration | More setup required | Quick and simple |
When to use Expressions:
When to use Tasks:
| Context | Syntax | Example |
|---|---|---|
| Script Tasks/Classes | @ prefix required | @Tag.Temperature.Value |
| Script Expressions | No prefix | Tag.Temperature + Tag.Offset |
| Display Bindings | @ prefix + .Value | @Tag.Temperature.Value |
| StringWithObjects | Curly braces | "Value: {Tag.Temperature}" |
StringWithObjects Usage: Used in text fields, SQL queries, alarm messages:
...
| Type | Positioning | Use Case |
|---|---|---|
| Canvas | Absolute X,Y (Left, Top) | Process graphics, P&IDs |
| Dashboard | Grid cells | KPI screens, responsive layouts |
Displays run inside Layout regions. The layout (DisplaysLayouts) defines which display appears in each region.
| Region | Position | Typical Size | Purpose |
|---|---|---|---|
| Header | Top | 1366 x 40 | Application header, logo, user info |
| Menu | Left | Variable | Navigation menu |
| SubMenu | Right | Variable | Secondary navigation or details |
| Footer | Bottom | Variable | Status bar, messages |
| Content | Center | 1366 x 728 | Main working area (fills remaining space) |
Key Points:
Direct binding (most properties):
{ "ElementType": "TextBox", "LinkedValue": "@Tag.Temperature.Value" }
Expression binding:
{ "ElementType": "TextBox", "LinkedValue": "@Tag.Value1 + @Tag.Value2" }
String with embedded tags (where supported):
{ "ElementType": "TextBlock", "Text": "Temperature: {Tag.Temperature} C" }
Creating a Symbol (hashtag syntax in original element):
Using Symbol Instance:
{
"ElementType": "Symbol",
"SymbolName": "HMI/Pumps/CentrifugalPump",
"SymbolLabels": [
{ "Key": "FlowRate", "Value": "Tag.Pump1/Flow" },
{ "Key": "Status", "Value": "Tag.Pump1/Running" }
]
}
Pre-built industrial symbols with configurable appearance.
| Wizard Type | Description |
|---|---|
| BLOWER | Industrial blower/fan |
| MOTOR | Electric motor |
| PUMP | Various pump styles |
| TANK | Storage tank |
| VALVE | Various valve styles |
Usage:
{
"Type": "Symbol",
"WizardType": "VALVE",
"Left": 100,
"Top": 200,
"Width": 65,
"Height": 65,
"SymbolLabels": [
{ "Key": "State", "LabelValue": "@Tag.ValveState.Value" }
]
}
Note: Created with default appearance. User can customize in Designer dialogs.
...
| Layer | Table | Purpose | Example |
|---|---|---|---|
| 1. Tags | UnsTags | Process variables | Tag.Pump1/Flow |
| 2. Points | DevicesPoints | Address mapping | Address: HR100 |
| 3. Nodes | DevicesNodes | Device address | IP: 192.168.1.100 |
| 4. Channels | DevicesChannels | Protocol config | Protocol: Modbus |
| 5. Physical | - | Actual device | PLC, sensor |
Creation Order: Channels, then Nodes, then Points
These fields vary by protocol - use get_protocol_schema(protocol) to get valid values.
| Table | Field | Modbus Example | OPC UA Example |
|---|---|---|---|
| DevicesChannels | ProtocolOptions | Port=502 | SecurityMode=None |
| DevicesNodes | PrimaryStation | 192.168.1.100 | opc.tcp://server:4840 |
| UnsTagProviders | PrimaryStation | 192.168.1.100 | opc.tcp://server:4840 |
| DevicesPoints | Address | HR100 | ns=2;s=Temperature |
AI workflow for helping users connect equipment:
...
Allow same solution to run in different environments with different connection settings.
| Profile | Use Case |
|---|---|
| Development | Local testing, simulator connections |
| Production | Real equipment, production databases |
| Validation | Test environment with real-like settings |
| Custom | User-defined scenarios |
| Action | Allowed |
|---|---|
| Query current profile | Yes - designer_action('get_state') |
| Change selected profile | Yes - designer_action('set_execution_profile', 'Production') |
| Modify profile configurations | No - ExecutionProfiles table not exposed |
...
Startup Sequence:
Note: Code is already compiled during design-time saves. START just launches the runtime processes.
...
| Purpose | Actions |
|---|---|
| Configuration | Create, read, update objects in .DBSLN |
| Navigation | Navigate Designer UI |
| Analysis | Query TrackChanges, documentation |
| Runtime Control | START only (not stop) |
| Online Config | Apply changes to running system |
| Purpose | Actions |
|---|---|
| Monitoring | Read tag values, alarm states |
| Control | Write to tags, acknowledge alarms |
| Diagnostics | Query error properties, logs |
| Status | Get module states, connection status |
...
| Term | Definition |
|---|---|
| UNS | Unified Namespace - central tag database |
| UDT | User Defined Type - custom data structure template |
| Runtime Object | Any object with readable/writable properties at runtime |
| Domain | Server (global) or Client (local) scope for data |
| AssetTree | Hierarchical folder structure for tags |
| TableType | Internal name for configuration table (e.g., UnsTags) |
| DBSLN | Solution file (encrypted SQLite) |
| DBRUNTIME | Read-only published solution for regulated environments |
| Execution Profile | Environment-specific connection settings |
| Label | Parameterized property in a Symbol |
| StringWithObjects | Text field that allows embedded tag references |
| Layout | Display container defining Header, Menu, Content, Footer regions |
...
| Pattern | Example | Description |
|---|---|---|
| Hierarchy | Tag.Folder1/Folder2/TagName | Use / for folders |
| Array element | Tag.ArrayTag[5] | Zero-indexed |
| UDT member | Tag.UDTInstance.Member | Dot notation |
| Context | Syntax | Example |
|---|---|---|
| In Scripts | @ prefix + .Value | @Tag.Name.Value |
| In Expressions | No prefix | Tag.Name + Tag.Offset |
| In Displays | @ prefix + .Value | @Tag.Name.Value |
| In Strings | Curly braces | "Text {Tag.Name}" |
...
Document Version: 1.1 (Confluence-compatible formatting) Based on: FrameworX MCP Tools Code Review Session For: AI training, documentation enhancement, search_docs content