Borrar filtros
Borrar filtros

Global variables in simulink - embedded coder

4 visualizaciones (últimos 30 días)
richard
richard el 6 de Abr. de 2024
Respondida: Fangjun Jiang el 6 de Abr. de 2024
Using the C2000 blockset with an F28379D. I have a subsystem block that I call with an interrupt (an ADC block).
--> What I want to do is create a "counter" variable in the subsystem, where this counter increments itself by 1 every time the interrupt is called. This way, I can view this variable in Data Inspector to see how often the interrupt is called. Is there an example that shows how to do this?

Respuestas (1)

Fangjun Jiang
Fangjun Jiang el 6 de Abr. de 2024
I think you can try this block. Put it inside the Subsystem and specify the sample time as -1, which inherits the interrupt.

Categorías

Más información sobre Deployment, Integration, and Supported Hardware en Help Center y File Exchange.

Productos


Versión

R2023a

Community Treasure Hunt

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

Start Hunting!

Translated by