Opened 7 years ago

Closed 7 years ago

#4730 closed defect (fixed)

Issue with function generation after NF processing

Reported by: Francesco Casella Owned by: Per Östlund
Priority: high Milestone: 2.0.0
Component: New Instantiation Version:
Keywords: Cc:

Description

Please check the Modelica.Electrical.Analog.Examples.AmplifierWithOpAmpDetailed model in the MSL. When compiled with the NF, the SimCode module later fails with this error:

Modelica_3.2.2_Modelica.Electrical.Analog.Examples.AmplifierWithOpAmpDetailed.c:210:109:
error: too many arguments to function call, expected single argument 'threadData', have 7 arguments
data->localData[0]->realVars[30] /* opAmp.q_sum_help variable */ = omc_opAmp_FCNq__sum__limit(threadData, data->localData[0]->realVars[29] /* opAmp.q_sum variable */, data->localData[0]->realVars[0] /* opAmp.q_fp1 STATE(1) */, 
data->simulationInfo->realParameter[0], data->simulationInfo->realParameter[1], data->simulationInfo->realParameter[32], data->simulationInfo->realParameter[30]);

Apparently there is something wrong in how the function opAmp.FCNq_sum_limit is handled to the code generation phase.

The only difference revealed by flattening the model with OMEdit is that the old FE defines function Modelica.Electrical.Analog.Basic.OpAmpDetailed.FCNiout_limit, while the new FE defines function opAmp.FCNiout_limit. I'm not sure whether this is relevant or not.

Change History (1)

comment:1 by Francesco Casella, 7 years ago

Resolution: fixed
Status: newclosed

Fixed on 02-06-2018

Note: See TracTickets for help on using tickets.