QUOTE(wagner @ Feb 8 2007, 03:06 PM)

Hello Jawhar,
I think you misunderstood my explanation of the event stuff. Of course Dymola acts correctly with edge and change. It's just that you can't see an event in the resulting chart. You simply can't see a signal change which is only active for one simulation step, because it's infinitively short in time.
Can you reduce your overall package/model to the most relevant parts which is still possible to simulate? Then it's much easier for us to get an idea of your problem.
Regards
Florian
okey, thank you Florian for your answers.
I have two models. One model send an event to the other model to activate it. A variable in model1 changes from false to true, when this changes happens the second model2 had to detect this event (read it from connector). This is the model1 wich represent the state1 of a real system.
CODE
model state1
Real x;
connector1 dout1; // two attributes (s: real and state: boolean)
connector1 din1;// two attributes (s: real and state: boolean)
Boolean resolve(start=true);
equation
if (initial()) then
if (din1.state) then
reinit(x,din1.s);
else
reinit(x,0.2);
end if;
end if;
when edge( din1.state) then // if din1.state changes i had to reinitialise the x variable because i will use it in the differential equation later.
reinit(x,din1.s); // The problem here is that edge(din1.state) have the same result (false) so i can't detect the event and reinitialise the variabe x.
end when;
if (resolve) then
der(x)=2*x;
else
der(x)=0;
end if;
when (x>0.6) then
resolve=false;
dout1.state = true;
end when;
dout1.s = x;
end state1;
I hope that is more clear.. i think i had to detect this event without using edge function.
Best regards,
Jawhar.