How do I pass variables between timer callback functions?
Mostrar comentarios más antiguos
I have a timer and I initialise data in the StartFcn callback and manipulate that data in my TimerFcn callback. However, these callbacks have different scopes, and each time the TimerFcn is evaluated the workspace is cleared.
Is there a way of passing data between my StartFcn callback and the TimerFcn callback? And how can I have my TimerFcn manipulate the same variables each time without having to use persistent variables?
Respuesta aceptada
Más respuestas (0)
Categorías
Más información sobre Workspace Variables and MAT Files en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!