Deploying sources in a password-protected library

A generated library might not contain the sources for all library elements – this depends on how the library element has been specified within the library configuration. But if you select the password-protected generation, the sources for all library elements are additionally provided in a password-protected library. Subsequently, you are able to access the sources of all library elements directly within the project – you only require the password that has been defined when generating the library.

This is how the library differs from the library for which the sources have been deployed in a password-protected library:


Generation

Variant: Password-protected generation

Creating the library configuration

There are no differences/restrictions for the library configuration.

Please observe: The specification of DEPLOY:=INTERFACE or DEPLOY:=OBJECT for a library element in der library configuration controls which statements will be included in the library and – hence – which statements are visible directly at the used library element within the project.

Generating the library

  • context menu of the library configuration, command Generate Library

or

  • expand the library configuration, open the context menu for the library (displayed as sub-level), select command Generate

expand the library configuration, open the context menu for the library (displayed as sub-level), select command Generate (Password Protected)..., in the opened dialog: enter/confirm a password and click OK

Result of the generation

The library contains the library elements according to the specifications of the library configuration. This library is not protected by a password.


Moreover, a password-protected library is generated.

This password-protected library

  • is part of the library that is not protected by a password. In the following, this library not protected by a password is identified as the outer library.

  • contains all sources for the library elements. Hence, this library contains the statements/assignments that are not included within the outer library due to DEPLOY:=INTERFACE or DEPLOY:=OBJECT.

Deploying and installing the library

There are no differences/restrictions for deploying and installing the library.

Result of the installation

The project contains the library that is not protected by a password.
The installed library is displayed with the icon images/download/thumbnails/443057630/IconLibrary-version-1-modificationdate-1586434414821-api-v22.png .

Here, the project also contains the library that is not protected by a password.
The installed library is displayed with the icon images/download/thumbnails/483360908/IconLibraryLocked-version-2-modificationdate-1639397927279-api-v2.png .

Show/hide the sources for an installed library

Directly at the used library element within the project, the sources are visible as it has been specified in the library configuration.

Consequence: If you double-click a library element (e.g. within the project explorer), the assigned default editor is opened and the corresponding statements are displayed. Only when the library element has been specified with DEPLOY:=SOURCE within der library configuration (or the keyword DEPLOY has not been specified for the library element at all), all statements are visible within the ST-editor or the logic is visible within the FBD-/LD-editor.


If requested, you are able to view all sources of the library elements within the project: context menu of the installed library, command View Protected Sources..., in the opened dialog enter the password and click OK
Result: The installed library is displayed with the iconimages/download/thumbnails/483360903/IconLibraryUnlocked-version-2-modificationdate-1639397945170-api-v2.png .

Consequence: If you double-click a library element (e.g. within the project explorer), the complete ST-code or the logic within the FBD-/LD-editor is visible. This is also valid for those library elements for which DEPLOY:=INTERFACE or DEPLOY:=OBJECT has been specified within the library configuration.

After you have analyzed the sources, you are able to switch back to the outer library: context menu of the installed library, command Hide Protected Sources
Result: as after the library has been installed

Good to know

images/s/b2ic8e/9012/1ca6q62/_/images/icons/emoticons/lightbulb.svg You must enter a password when creating the password-protected library (the field must not be empty). Otherwise, there are no guidelines for the password. However, define a secure password.

images/s/b2ic8e/9012/1ca6q62/_/images/icons/emoticons/lightbulb.svg Write this password down – in a secure place.
logi.CAD 3 provides no possibility to reset the password of an already generated library. As a workaround, you might want to generate the library anew and define a new password. Subsequently, you must deploy and install the newly generated library.

images/s/b2ic8e/9012/1ca6q62/_/images/icons/emoticons/lightbulb.svg If you want to see the password while entering it in the dialog, click images/download/thumbnails/483360896/ViewPassword-version-1-modificationdate-1638362633648-api-v2.png within the dialog.

images/s/b2ic8e/9012/1ca6q62/_/images/icons/emoticons/lightbulb.svg According messages indicate when the passwords (entered at the generation) do not match or when a wrong password has been entered to view the sources.

images/s/b2ic8e/9012/1ca6q62/_/images/icons/emoticons/lightbulb.svg If you exit logi.CAD 3 while there are still some protected sources of library elements to be viewed in projects, a prompt is displayed whether to hide the protected sources. logi.cals recommends you to answer Yes in order to not allow the access to protected sources by mistake. In this case, when logi.CAD 3 is restarted, the libraries are provided in the projects as after they have been installed.

images/s/b2ic8e/9012/1ca6q62/_/images/icons/emoticons/lightbulb.svg If you deploy the sources within a password-protected snapshot library and view the protected sources of the library elements within a project, logi.CAD 3 automatically switches back to the outer library when the snapshot library is updated (e.g. when opening a project). Hence, after the snapshot library has been updated, you will have to view the sources of the library elements again.