Pipconfig.xml - calculation of partition sizes

Initial situation
If a project installation package (PIP package) is created, the selections made in the configuration masks are saved in pipconfig.xml.
This file tells the PLC how the installation should proceed and whether an initial installation should be permitted.

However, the configuration settings of the package are very error-prone, so that a misconfiguration in the field can, in the worst case, lead to a repartitioning and the complete loss of data of a machine in the field.
For this reason, the idea is now to create the package using automated scripts to prevent such misconfiguration.

Problem
A PIP package cannot be created directly via the command line (See related topic)
However, as a PIP package consists of artransfer.br, pipconfig.xml and arnbcfg.xml, one approach would be to carry out an offline installation using Script and generate the folder structure and the two XML files.

The pipconfig.xml basically contains all the information needed to create it, except for the partition sizes.

As this is a part generated by the AS, which according to the comments should not be changed, it is not described anywhere how these values are calculated.

Questions
The only connection that could be determined is that the partition size is specified in bytes.
100 MebiByte = 104857600 Byte

Does anyone know how the other sizes are calculated? Are there easily determinable correlations that can be used to calculate these values?

Support
We are aware that this part should not be changed and that changes to the part will result in it no longer being supported. However, we currently lack the alternatives so that this risk must be borne,

Thanks in advance and best regards
:fish:

Well AS basically “knows” the size of the BR modules and creates partitions for this.
RPSHD partition is also the destination for the ARTransfer file which results in a bigger size than RPSHDS.
Nevertheless we do not hand out details about the calculation and the “do not modify” is meant seriously :wink:

2 Likes

We have now found a solution for creating the Project installations package via scripts despite the lack of a command line function. Even if the variant leads to the goal via some detours, the package can be created automatically and, above all, the settings of pipconfig.xml can be predefined. This variant also makes it possible to create all configurations of a project at the same time.

To create the pip package automatically via a script, the following steps must be programmed in the script:

  1. Creation of RUC package
    Creation of a RUC package using BR.AS.Build.exe. During creation, the flag
    -buildRUCPackage flag must be set.

  2. Call up pil list
    Create a pil list which creates a project from the Ruc package for an installation using ArProject.


    This pil list can be called up in silent mode using call PviTransfer.exe.
    In this step, the partition sizes are also calculated based on the project settings and generated in pipconfig.xml.

  3. Adapt XML
    As a final step, the relevant flags in pipconfig.xml can now be changed using a script.

With this package, it is now possible to automatically create one or all configurations as a pip package using a script, which can then be used with ArProject or (by creating the arnbcfg.xml also for MpBackup).