Why do I get a build error when generating a code for model containing stateflow in MATLAB 2011b "error calling s generated S function" ?
    6 vues (au cours des 30 derniers jours)
  
       Afficher commentaires plus anciens
    
Why do I get a build error when generating a code for model containing stateflow "error calling s generated S function" ?
Model simulates properly, when build system to generate code is selected the following error is got in MATLAB 2011b. The model has a stateflow and I'm taking a guess its because of this.
Error recieved is : Error calling generated Sfunction, model_sfun. Undefined function 'model_sfun' for input arguments of type 'double'
0 commentaires
Réponses (1)
  Gerhard Feichtinger
 le 8 Juil 2015
        I just had the same error in 2015a, and it seems to be because I was setting the Simulink CodeGenFolder and CacheFolder parameters to nonstandard values. I'm not sure if there's a similar StateFlow value to set, but commenting out these lines from my setup file fixed the issue. So maybe it's something that you set up for Simulink that Stateflow is expecting in a different location?
%  Simulink.fileGenControl('set', 'CacheFolder', [userpath  '/_code_dummy_'], 'createDir', true)
%  Simulink.fileGenControl('set', 'CodeGenFolder', [userpath '/_code_dummy_'], 'createDir', true)
0 commentaires
Voir également
Catégories
				En savoir plus sur Simulink Coder dans Help Center et File Exchange
			
	Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!

