Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for replaceable models in Modelica templates #359

Open
AntoineGautier opened this issue Sep 13, 2023 · 1 comment
Open

Add support for replaceable models in Modelica templates #359

AntoineGautier opened this issue Sep 13, 2023 · 1 comment
Assignees

Comments

@AntoineGautier
Copy link
Collaborator

Currently ctrl-flow parser can only handle replaceable components inside Modelica templates.
This ticket is to add support for replaceable models.
Additional details are provided in the joint MBL issue lbl-srg/modelica-buildings#3507.

@AntoineGautier
Copy link
Collaborator Author

AntoineGautier commented Dec 6, 2024

There is another issue that the branch issue3507_replaceableClass reveals.
In this branch, the component secRel of Buildings.Templates.AirHandlersFans.Components.OutdoorReliefReturnSection.MixedAirWithDamper is a simple replaceable component that should be visible in the configuration panel, but it isn't.
The corresponding option object in templates.json is:

    {
      "modelicaPath": "Buildings.Templates.AirHandlersFans.Components.OutdoorReliefReturnSection.MixedAirWithDamper.secRel",
      "type": "Buildings.Templates.AirHandlersFans.Components.ReliefReturnSection.ReturnFan",
      "value": "Buildings.Templates.AirHandlersFans.Components.ReliefReturnSection.ReturnFan",
      "name": "Relief/return air section",
      "group": "Configuration",
      "tab": "",
      "visible": true,
      "modifiers": {...},
      "enable": true,
      "choiceModifiers": {},
      "options": [
        "Buildings.Templates.AirHandlersFans.Components.ReliefReturnSection.ReturnFan",
        "Buildings.Templates.AirHandlersFans.Components.ReliefReturnSection.ReliefFan",
        "Buildings.Templates.AirHandlersFans.Components.ReliefReturnSection.ReliefDamper"
      ],
      "definition": false,
      "replaceable": true
    },

The following mods is not created by new ConfigContext:

    "secOutRel.secRel": {
      "value": "Buildings.Templates.AirHandlersFans.Components.ReliefReturnSection.ReliefDamper",
      "optionPath": "Buildings.Templates.AirHandlersFans.Components.OutdoorReliefReturnSection.MixedAirWithDamper.secRel"
    },

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants