In manufacturing, the data formats of mechanical design (CAD), control design (PLC) and plant operation don’t match, so every design change means moving the data over by hand. This project is part of the No-Code Manufacturing Innovation Ecosystem program (equipment control / robotics – PLC-based equipment control track). Its goal is a round-trip engineering (RTE) workflow built on a workcell digital twin, where design → simulation → operation → back to design runs as a loop.
- Period: 2025.10 – present
- Company: Codeflex Co., Ltd. (government-funded R&D)
- Role: Software Developer
- Tech stack:
Python,PySide6 (Qt/QML),QtQuick3D,OPC UA,WebSocket,MySQL,Next.js,NestJS,Gemini,Three.js,PLCopen XML,URDF

Goals
- Convert PLC logic (ST/FB) to a standard format (PLCopen XML) and connect it automatically to the joints of a robot model (URDF)
- Turn results verified in the digital twin back into runnable PLC code (reverse generation)
- Let people without PLC programming knowledge configure and monitor a workcell through a No-Code UI
Overview
I worked on two different tracks within the same project.
| Track | Project | What it does |
|---|---|---|
| Web | PLCStudio (plc-app) | Screens for PLC conversion, mapping, simulation sequence generation and PLC reverse generation (Next.js) |
| Web | plc-app-backend | Parser, Gemini integration, deterministic code generation and validation API (NestJS) |
| Desktop | AgentBuilder | Design-time tool for configuring the virtual workcell and data services (PySide6/QML) |
| Desktop | WorkcellAgent | Runtime app that monitors the configured workcell in real time (PySide6/QML) |
| Desktop | FIStudio | Tool for the OPC UA server/client and the tag linker (PySide6/QML) [Check: how to describe its role] |
Web-based services
The web side implements a four-step pipeline that links PLC code with robot models. Each step picks up the result of the previous one.
- Convert — turn PLC source (ST etc.) into IEC 61131-3 PLCopen XML
- AI Mapping — analyze PLC + URDF (+ an operating scenario) with Gemini to produce a mapping between joints/actuators and PLC variables
- AI Sim Program — build a digital-twin motion sequence from the mapping and replay it in a 3D viewer
- PLC Gen — reverse-generate PLC ST code from the mapping and sequence (Siemens SCL / Mitsubishi ST) and compare it with the original as a round trip
Design notes
- AI infers, code is deterministic: Gemini produces the mapping and sequence, but the actual PLC code is generated deterministically from per-equipment rules and checked in two stages. This keeps the final code stable even when the AI output is slightly off.
- Mapping repair: missing PLC variables are filled in by a separate repair step, and a truncated JSON response is retried up to three times.
- Two-way verification: the original ST → mapping → sequence → reverse-generated ST is compared against the original again to see exactly what changed.
- Joint space / Cartesian (TCP) profiles are detected automatically, so the mapping fits the type of robot.
Standalone QML apps
These are used directly on the shop floor, so I built them as desktop apps rather than web apps. All three share the same QML structure (MVVM, multiple languages, themes).
Separating UI and logic
All three apps use QML for the screens and Python for the logic. Mixing widgets and logic in PySide6 alone gets tangled as screens grow, so I wanted to separate the layers the way a layered web architecture does.
| Layer | Role | Web equivalent |
|---|---|---|
| QML View | Draws the screen, forwards user input | Frontend components |
| ViewModel (Python) | Exposes screen state, handles user actions | Controller / store |
| Service (Python) | The real logic: OPC UA, DB, URDF parsing, etc. | Service / domain layer |
The Python side knows nothing about the screen; it only exposes state through Property and Signal. (The example below is a new, simplified sketch that shows the structure — it is not code from the actual project.)
# viewmodels/status_viewmodel.py
from PySide6.QtCore import QObject, Property, Signal, Slot
from PySide6.QtQml import QmlElement
QML_IMPORT_NAME = "pyobjects"
QML_IMPORT_MAJOR_VERSION = 1
@QmlElement
class StatusViewModel(QObject):
runningChanged = Signal()
def __init__(self):
super().__init__()
self._running = False
@Property(bool, notify=runningChanged)
def running(self):
return self._running
@Slot()
def toggle(self):
self._running = not self._running # a Service call in real code
self.runningChanged.emit()
QML only binds to that state and holds no logic of its own.
import pyobjects 1.0
StatusViewModel { id: vm }
Button {
text: vm.running ? "Stop" : "Start"
onClicked: vm.toggle()
}
This way the screens can change freely in QML, and the logic can be tested in Python without any UI.
AgentBuilder — design time
- Virtual workcell configuration: loads a URDF in QtQuick3D, moves the joints, and positions the end effector with inverse kinematics (IK).
- Data service generation: builds WDF/WPF/Link definitions into DSF XML and hands them to the workcell monitoring side.
WorkcellAgent — runtime monitoring
- Receives equipment data over OPC UA and WebSocket and reflects it in a live 3D digital twin.
- Shows KPI dashboards such as OEE and throughput from data stored in MySQL.
- I supported the TKC GS (Good Software) certification for this app, and wrote the user manual and installation guide and linked them so they open inside the app.
FIStudio
- Supports the OPC UA server/client, tag linker editing and NodeSet generation. [Check: actual purpose and users]