Client
In the Analytics Storage Provider Client it is possible to connect to an Analytics Storage Provider. This does not necessarily have to run locally on the device, but can also be addressed via an external MQTT broker. Thus, it is not mandatory to configure an Analytics Storage Provider locally to use the client. Recordings can then be started and stopped on a connected Analytics Storage Provider, as well as historical data streams to a configurable MQTT topic.
The following inputs are available for this:
1 | Establishes a connection with the MQTT broker from the local configuration and selects the configured Analytics Storage Provider |
2 | Starts a dialog to connect to an MQTT broker |
3 | Closes the connection to the current MQTT broker |
10 | Provides the analytics storage providers available under the MQTT broker for selection |
20 | Reads in a configuration file from an Analytics Storage Provider Recorder, with the recordings configured in it |
31 | Starts a recording |
32 | Stops a recording based on the alias and the MQTT topic |
33 | Starts a historical data stream |
34 | Stops a historical data stream based on the result MQTT topic |
35 | Updates streaming parameters of a running historical data stream |
36 | Checks whether a recording is active |
40 | Stops all active recordings |
41 | Stops all historical data streams |
To use the Analytics Storage Provider Client, a connection to an MQTT broker must first be established. Entering "2" starts a dialog in which the already configured MQTT brokers are presented for selection. There a new MQTT broker can be configured and connected by entering "0". Then, by entering "10" in the client main menu, an Analytics Storage Provider can be selected, which is available under the MQTT broker. Alternatively, by entering "1" in the client main menu, a connection to the MQTT broker and Analytics Storage Provider can be established directly from the local configuration file.
After the connection is successfully established, information about the connected MQTT broker and the selected Analytics Storage Provider is displayed in the prompter display before the prompt:

(MQTT broker: Analytics Storage Provider)
To start recordings, a dialog is started by entering "31". It is possible to start a recording that has already been created, provided that recordings have already been configured or read in via a recorder configuration file. In addition to the listed recordings, a new recording can also be configured and started by entering "0":

The configuration parameters correspond to the known parameters from the graphical Analytics Storage Provider Recorder. The default values can be deleted if necessary and replaced by individual entries. With the recording mode after the input "Subset" a subset of the symbolism can be defined by the recording data. Immediately after configuration, a command to start recording is sent to the connected Analytics Storage Provider. Running recordings can be stopped by entering "32". They are referenced by the MQTT topic from which the data comes and by the recording alias. If a recording is to be stopped by another client, the corresponding Recorder Guid must also be specified. The Recorder Guid is displayed together with the Recorder Alias above the input options in the client main menu (red 1).
Recording configurations created in the console client are not persisted. So after closing the client, the list of recording configurations is no longer available. Therefore, reading recorder configuration files (enter "20" in the client main menu) can be very helpful. The configuration file of a recorder is stored on Windows systems under the path C:\Users\*** \AppData\Roaming\Beckhoff\TwinCAT Analytics Storage Provider (replace *** with the corresponding user).
The historized data of the Analytics Storage Provider can be transmitted as a data stream to a definable result MQTT topic via the input "33". This also starts a dialog in which a previously configured data stream can be started. By entering "0", a new historical data stream can also be configured:

The parameters define a historized recording, whereby the parameter result topic defines the MQTT topic to which the data is to be streamed. After configuration, a command to start the historical stream is automatically sent to the Analytics Storage Provider.
By entering "35" in the client main menu, the parameters of an active historical stream can be adjusted. The historical stream is referenced by its result MQTT topic. The parameters can be used, for example, to adjust the speed or packet size of the data stream while it is running. Canceling a historical data stream is possible by entering "34" and specifying the result MQTT topic.