Archived OpenModelica forums. Posting is disabled.

Alternative forums include GitHub discussions or StackOverflow (make sure to read the Stack Overflow rules; you need to have well-formed questions)


Forgot password? | Forgot username? | Register

ModelicaML template issue

ModelicaML template issue

Hello,

I'm quite new in this community and I would like to try the functionalities offered by ModelicaML. I constated some dependancies issues so I downloaded a working Windows package, http://www.ida.liu.se/labs/pelab/modeli … clipse.zip and tried to launched the code generation of the Two Tanks example project 'modelicaml.example.twotankssystem.tutorial_v05'. Yet, I didn't manage to obtain the Modelica source code from the example.

I got two errors:
- first, when I open the 'Two Tanks' model, this message appears: "Some local profiles have changed. Select the ones you want to re-apply:".
- secondly, when I launch the generation ('Generate Modelica code (from sub-tree)", the return is a errors.log file containing:

"Compilation error in the file : C:\Users\Pierre\Documents\Logiciels\Eclipse-ModelicaML-2\eclipse\configuration\org.eclipse.osgi\bundles\2699\1\.cp\ModelicaML2Modelica_v04.mt
The template contains errors. : --%> is required to close <%--"

I tried to figure out where the error comes from, I followed multiples tutorials and read some previous discussions from this forum but nothing came out.

Please, let me know how to handle this problem, which seems to be a rookie mistake,

Thanks,
Pierre

Re: ModelicaML template issue

Hi,

it sounds like you are using an obsolete example model.
Try to create a new model and generate gode from it.

regards,
Wladimir

Re: ModelicaML template issue

Hi!

Thank you for such a quick answer!

I've already tried to generate code from other models (empty model, model with one package, model with one package and a class: different little combinaitions). However, I still obtain the same error log that refers to the template error. Despite the fact I used the working package, could this be related to any Acceleo compatibility issue? or the template .mt file?

Thanks in advance

Re: ModelicaML template issue

Hi,

I've just gave it a try: I downloaded the eclipse from the link above, created a new model, generated code and simulated it. It works fine.
Regarding Acceleo, normally if you don't install Acceleo 3.x there shouldn't be an issues. Also (even if I don't think this is relevant in this case) there are issues when installing Eclipse in deep folder structures or in folders with whitespaces. This should be avoided because there are to path length etc. restrictions on Windows.

Regards,
Wladimir

Re: ModelicaML template issue

Hi,

I worked on a Acceleo 2.x version. However, I tried on two other computers and it worked well. It must be an access error or another issue. I'll look after it.

Thank you for your help.

There are 0 guests and 0 other users also viewing this topic