The EITT automation API enables the user to write an application to access and manipulate data in a CTL file, to start telegram sequences automatically and to trace and evaluate the results.
The EITT setup makes all modifications in the WINDOWS registry, that allow the use of the automation API of EITT.
It is important for the use of the Automation API, that EITT is installed on the PC via the EITT setup!
All entries needed to use the automation API are shown in the file 'EITT.REG', that is copied in the EITT directory. 'EITT.REG' can also be used to manually register EITT (command: 'regsvr32 eitt.reg'). This is necessary i.e. after moving EITT from the installation directory to another directory (the path names in the file 'eitt.reg' must be changed before registering).
The program ID (ProgID) of the EITT automation interface is “Eitt.Application”.
The initial object, from which all other EITT objects can be accessed, is the Application Object. All available objects and its member functions are described in detail in the EITT manual, section 13.
To demonstrate the usage of the Automation API a small sample DLL was implemented in C# together with a small application, which uses that DLL to start EITT, open a .ctl-file and execute a telegram sequence.
The only purpose of this implementation is to show an example of how to use the API!
It does not claim to be complete or error-free! In particular, the library does not check whether the individual functions were successful or not. Only the principle of use is shown, it is the user's task to add checks and functions necessary for his application.
Description of the C# sample
The file “EITT Automation.zip” contains two sub directories with C# projects, “EittAutomationAPI” and “EittAutomatedCmd”.
EittAutomationAPI: DLL with EITT Automation objects and functions
EittAutomatedCmd: A sample application, which uses the DLL
The project can be compiled with Visual Studio 2019 using the solution file “EittAutomatedCmd.sln” in the directory “EittAutomatedCmd”.
Both sub projects must be compiled, first the sub project “EittAutomationAPI”, then the sub project “EittAutomationCmd”.
Before starting the sample application, an EITT .ctl file must be prepared with all required project specific KNX interface settings. The .ctl file must contain a telegram sequence ‘Telegram Sequence 1’, which will be called from the sample application.
The sample application reads the name of the .ctl-file from the configuration file “App.config”, which can be found in the directory “EittAutomatedCmd”. The default value is “c:\Test\EittTelSequence.ctl”.
Attention: The sample does not check for the existence of that .ctl-file. If the file doesn’t exist, a System.NullReferenceException occurs! It is to the user to implement the required checks.
The DLL “EittAutomationAPI.dll” contains a class “Eitt”, which encapsulates the EITT object. This object represents the Application Object, from which all other EITT objects can be retrieved. The Application Object is implemented in the file “Eitt.cs”.
The member functions “OpenProject” or “CreateProject” of the Eitt object show, how to retrieve other objects from the Application object.
The project object “EittProject” represents the .ctl-file content and is the starting point to get access to the telegram sequence manager object, the project specific bus connection list and the tracebuffer object.
Each object and its member functions are implemented in a corresponding class.
A complete list of available EITT automation objects can be found in the EITT manual.
The sample application creates the EITT object and reads the name of the .ctl-file from the configuration file “App.config”. Please note, that the ‘App.config’ will be renamed during the build process and is available in the build directory as “EittAutomatedCmd.exe.config”.
Then the application performs the following steps:
- Prepare EITT (disable dialog boxes, …).
- Open the project file and get the project object.
- Start the bus communication.
- Get the telegram sequence manager from the project object.
- Get the telegram sequence from the telegram sequence manager.
- Start the telegram sequence.
- Wait until telegram sequence execution has been finished.
- Wait for user input.
- Close the project file.
- Close the bus communication.
The EITT Automation.zip can be downloaded here.