Pcode execution error while running it
7 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
종석 김
le 5 Jan 2022
Réponse apportée : Walter Roberson
le 5 Jan 2022
When I execute pcode (which is .p), I got the error below.
I used pcode (filename) statement to make .p file.
Anyone knows what the problem is?
Error in sweep_3level_PWM_harmonic (line 44)
run('Grid_side_3_level_anpc_Rectifier_PWM_harmonic_run') - Show complete stack trace
Caused by:
Error using Grid_side_3_level_anpc_Rectifier_PWM_harmonic_run (line 89)
Simulink cannot determine sizes and/or types of the outputs for block 'Grid_side_3_level_anpc_Rectifier_PWM_harmonic/Modulator/MATLAB Function1' due
to errors in the block body, or limitations of the underlying analysis. The errors might be inaccurate. Fix the indicated errors, or explicitly
specify sizes and/or types for all block outputs. - Show complete stack trace
Error using Grid_side_3_level_anpc_Rectifier_PWM_harmonic_run (line 89)
Error occurred in 'Grid_side_3_level_anpc_Rectifier_PWM_harmonic/Modulator/MATLAB Function1'. - Show complete stack trace
0 commentaires
Réponse acceptée
Walter Roberson
le 5 Jan 2022
Normally when your Simulink MATLAB Function Block invokes a function that is .m code, Simulink examines the source code to try to deduce what size and datatype are needed for each of the signals.
When you invoke pcode then Simulink cannot examine the MATLAB code to determine the sizes and data types.
You will need to use the port manager to mark the MATLAB Function Block ports for data type and data size.
0 commentaires
Plus de réponses (0)
Voir également
Catégories
En savoir plus sur Startup and Shutdown 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!