AixOCAT icon indicating copy to clipboard operation
AixOCAT copied to clipboard

Extension MQTT Interface - read symbols by identifier

Open StGoebel opened this issue 4 years ago • 1 comments

What is the issue?

When you want to get the variables of a TwinCAT project, always the whole variable list of the project is extracted. Sometimes you just want to control a subset of all the variables. The issue is to provide a functionality, such that you can mark with comments the variables you want to get and only those variables will be extracted.

What is the current application?

The module parsing_and_assignment contains the functions, that extract the variable list of the TwinCAT project. You provide either a text file (*.GVL) containing the variables list or a an ADS connection to the corresponding function in parsing_and_assignment (for example parsing_and_assignment.getADSVariables(gvl_file)) and the functions return the variables categorized in a publish- and a subscribe-set.

How do we want to solve it?

To parsing_and_assignment the functions "getMarkedADSVariables" and "getMarkedADSvarsFromSymbols" will be added. One function gets the marked variables from a text file, the other on directly from the ADS connection. The desired variables have to be commented with "//#" in the TwinCAT project, the functions will then only extract the variables marked with the respective comment.

StGoebel avatar Jun 10 '21 08:06 StGoebel

Hi @ErnestoVivas, the functions are working! Two points we should work on:

  • the marker for identifying the symbol which should be published should not have to stand alone in the comment
  • variables inside a structure should be considered

StGoebel avatar Jun 30 '21 08:06 StGoebel