This logic element allows calling external programs
Please notice:
• | The program call runs on the system level. The called Programm need supporting this |
• | Parameters can be given. The rules of the parameter usage is handled by the called program. Multiple parameters are realized with a string array. |
• | The return value of the program is returned on the output parameter Exitcode |
• | The call works synchronously |
Mostly programs using a graphical frontend can not be called.
Some ways exist for returning complex data from the called program:
• | Files.The called program writes data into a file. After the program end the file is read in the logic table.The logic tables can not access the whole file system for security reasons. So a file "MyFile.txt" as parameter for a logic table will be c:\Users\Public\Documents\Tani\Userfiles\MyFile.txt for a Windows program called in the logic table. In Linux the same file will be /etc/Tani/Userfiles/MyFile.txt. |
• | Network connections. Mostly this are send/receive connections in PLC Engine Collect. The called program writes the return data into the connection. The logic table reads the data from the connection. |
OPC UA. The called program needs to be an OPC UA client. It writes the return data into memory variables of PLC Engine Collect.
In all of this cases it is recommended to give the parameters for the returned data system as a parameter to the called program.
|