﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	resolution	keywords	cc
5366	FMU Import in OMEdit for BouncingBall failes	Andreas Heuermann	Adeel Asghar	"When importing a FMU generatet for BouncingBall model
{{{
model BouncingBallFMI20
  parameter Real e=0.7 ""coefficient of restitution"";
  parameter Real g=9.81 ""gravity acceleration"";
  Real h(start=1) ""height of ball"";
  Real v ""velocity of ball"";
  Real v_new;
equation
  der(v) = -g;
  der(h) = v;

  when h <= 0.0 then
    v_new = -e*pre(v);
    reinit(v, v_new);
  end when;

end BouncingBallFMI20;
}}}
with `omc` the imported Model in OMEdit is not simulatable.

I imported and simulate the FMU with OMEdit and got the error message
`[BouncingBallFMI20_me_FMU: 64:7-64:37]: Operator reinit may only be used in the body of a when equation.`
See the attached file BouncingBallFMI20_me_FMU. I also included the previously generated FMU.

When importing and simulating with omc from shell no error is returned (since there is a test for that in testsuite\openmodelica\fmi\ModelExchange\2.0\BouncingBall.mos).

I was testing this on Windows, but hte problem should be the same on other OS.

OMEdit v1.14.0-dev-47-g29420dd9 (64-bit)
Connected to v1.14.0-dev-135-gba5885721 (64-bit)
omc Version used for generating FMU: v1.14.0-dev-136-g482cb0e7e (64-bit)"	defect	closed	blocker	1.14.0	OMEdit	v1.14.0-dev-nightly	invalid	fmu import code generation	v1.14.0-dev-136-g482cb0e7e (64-bit)
