Introduction
Xentara is a modular and secure real-time automation platform engineered for the smooth integration and management of industrial processes. The C++ Control Connector enables developers to formulate bespoke control logic that functions within Xentara's deterministic framework, guaranteeing accurate and dependable execution of automated activities. Utilizing the C++ Control Connector allows for the customization of control procedures to fulfil unique requirements, while leveraging Xentara's real-time capabilities.
The utilization of the Xentara C++ Control Connector presents numerous benefits:
- Customizable Control Logic — Create control actions specifically designed to meet your requirements.
- Seamless Integration — Function within Xentara's deterministic architecture for accurate execution.
- Improved Flexibility — Seamlessly adjust to changing industrial automation demands.
The Xentara C++ Control Connector is an exemplary option for those aiming to establish accurate and flexible control solutions in a deterministic setting.
Core Principles
Each Xentara C++ Control instance comprises properties, events, and tasks.
Attributes retain essential information regarding the execution and status of a control instance. For example::
- executionState – Denotes the present execution status
- executionTime – Captures the most recent execution timestamp
- error – Captures an error code upon failure
- errorMessage – Delivers comprehensive error descriptions for debugging purposes
plus more elements. These properties facilitate the monitoring and debugging of control execution within Xentara.
Events allow the control instance to indicate execution results, facilitating appropriate responses from external systems. For example:
- executed – Raised when the control instance completes execution.
- executionError – Raised when an error occurs.
- executionOk – Raised when execution is successful.
These events facilitate the monitoring of execution flow and enable dynamic responses to control status.
Tasks delineate the manner and timing of a control instance's execution of a certain operation. Steps perform a singular iteration of the control logic.
Setup
To incorporate the C++ Control Connector into your Xentara environment, adhere to the following steps:
Step 1: Install Dependencies
Verify the installation of the following components:
- Xentara Core and C++ Connector – installed and configured
- C++ build environment
Step 2: Create a Custom Control Class
Establish a control class that derives from Xentara::Control to oversee execution phases and engage with the Xentara model. The initialize method configures the control instance, whereas the step method encompasses the control logic executed during runtime.
Step 3: Implement the initialize Method
The initialize method is invoked once prior to execution, granting access to configuration settings, Xentara components, and timers. This method initializes the control instance by acquiring essential data points and timings from Xentara.
Step 4: Implement the step Method
The step method encompasses the fundamental execution logic of the control instance and is invoked frequently during Xentara's operational phase. This approach guarantees accurate execution of automation tasks within Xentara's deterministic framework.
Step 5: Register the Control Connector with Xentara
Utilize Xentara::ControlExporter to register your control class, ensuring its recognition and loading by Xentara.
Step 6: Configure the Control Connector in JSON
Specify your control connector in the configuration file of Xentara (.json). This can be accomplished by either manually updating your model.json file or utilizing the Xentara Workbench. This option instructs Xentara to instantiate your control during runtime.
Conclusion
This concludes our introduction to the Xentara C++ Control Connector. We examined attributes, events, tasks, configuration, and the operational dynamics within Xentara’s structured execution paradigm.
For a comprehensive guide on a project utilizing the C++ control connection, please refer to the Tutorial section of the Xentara Knowledge Base.