Breakpoint in Simulink MATLAB function block not working

24 visualizaciones (últimos 30 días)
Scott
Scott el 13 de Nov. de 2023
Respondida: Scott el 13 de Nov. de 2023
I add a breakpoint to the code in my MATLAB function block in Simulink. I am running Simulink from a script using sim and it does not stop at the breakpoint. It is running the function because Simulink errors are being generated from functions called by the function block.

Respuesta aceptada

Scott
Scott el 13 de Nov. de 2023
I tried a breakpoint in a similar model and it worked. I then realized that the function is not running; my Simulink error is a coder error.

Más respuestas (1)

Fangjun Jiang
Fangjun Jiang el 13 de Nov. de 2023
  2 comentarios
Fangjun Jiang
Fangjun Jiang el 13 de Nov. de 2023
Then it is better to run simulation interactively to debug it, although you could use sldebug().

Iniciar sesión para comentar.

Categorías

Más información sobre Schedule Model Components en Help Center y File Exchange.

Productos


Versión

R2017b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by