Creating a Custom Library
You can create a custom library to save a collection of shared subsystems and custom modeling components that you want to reuse in multiple files. Custom libraries appear in custom palettes in the MapleSim window and are saved on your hard drive in either the standard .msimlib format or the .base_msimlib format, which is more suitable for revision control systems.
This help page describes how to create an empty custom library and then populate it with shared subsystems and custom components. You can also create a custom library from a MapleSim model, as described in Creating a Custom Library from a Model.
To create a custom library:
From the File menu, select New > Library. The Create Library dialog appears.
Under Package enter a name for the library. The name must be unique and cannot contain spaces. No other user library or Modelica-imported library can share the package name.
Select a directory to save the library in from the Location list. (You cannot edit the entries in this list. See the notes section for information on how to add entries to the Location list.)
If you want to create a version controlled library, select Version Controlled. This saves your library in the exploded .base_msimlib format which is designed for use with revision control systems.
Optionally, enter a description.
Click OK. A custom palette with the specified name appears in the Library Components tab (
). This palette will appear in the window the next time you start MapleSim. Custom palettes are indicated with an icon:
You are now in library edit mode. The is a Properties tab (
) on the right of the main MapleSim window summarizes the name, location, description, and creation date of your custom library. Additionally, a watermark with the library's name is displayed on the workspace.
To build the custom library:
To populate the palette with subsystems and custom components, create subsystems and components and then organize them into a hierarchy.
Create custom components and subsystems in the workspace or copy them from an existing MapleSim model.
To include a subsystem in the custom library, you must convert the subsystem to a shared subsystem. For more information, see Converting a Subsystem into a Shared Subsystem.
The components and shared subsystems will display in the Components palette of the Local Components tab (
Move the components and shared subsystems to the Hierarchy. For details, see Updating a Custom Library.
Note: Only components in the library hierarchy will appear in the custom library palette.
(Optional) If your components contain documentation, from the Tools menu select Create Library & Documentation.
When you create a custom library, an entry is also added to the library list in the Manage Libraries window (Tools > Manage Libraries...). You can use this window to hide or delete custom libraries. For more information, see Hiding or Deleting a Custom Library.
If you add a parent subsystem (a subsystem that contains another subsystem or custom component) to a custom library, its child subsystem or custom component is automatically added.
Custom libraries are saved to a default location. To save a custom library to a different location, you must add the following flag to the maplesimlauncher.l4j.ini file:
where pathnames is a string containing one or more locations. On Windows, for example, this flag could be -DMapleSim.LibraryPath="C:/myLib;Z:/shared/MapleSimLibs"
When MapleSim is started with this flag, the Create Library dialog will list these two library location paths in addition to the default location.
The maplesimlauncher.l4j.ini file is located in the <Maple>/toolbox/MapleSim/bin.<SYS> folder, where <Maple> is your maple installation directory and <SYS> is your system platform (for example, X86_64_WINDOWS).
To see the documentation for a component, right-click (Control-click for Mac) the component on the Model Workspace and select Help on componentName. Your preferred web browser opens displaying the documentation.
Adding an Attachment to a Custom Library
Creating a Custom Library from a Model
Creating Custom Modeling Components
Converting a Subsystem into a Shared Subsystem
Displaying a Previously Hidden Custom Library
Exporting a Custom Library to a Model
Generating Custom Library Documentation
Hiding or Deleting a Custom Library
Importing Modelica Models and Libraries
The MapleSim Window
Updating a Custom Library
Using Custom Libraries
Download Help Document
What kind of issue would you like to report? (Optional)