Matlab stop execution without any error while doing a real-time acquisition
Mostrar comentarios más antiguos
Hello everybody,
I have a issue that maybe someone can clear me up. Basically, I built a GUI (graphical user interface) and I am using it to make some analyses while acquiring real-time data from a National Instrument hardware.
The problem is that at some time the Background acquisition stops without returning any error. Does anybody know why this happens or to what it might be related? Is there any way to solve this issue?
Thank you all.
4 comentarios
Xavier
el 11 de Sept. de 2020
Are you able to provide more information such as code and the hardware in question?
Mario Malic
el 11 de Sept. de 2020
Editada: Mario Malic
el 11 de Sept. de 2020
The problem is that at some time the Background acquisition stops without returning any error. We see no code and can't help, but guess. Since it's a GUI, maybe you enter some function and/or does calculation so your screen does not refresh after some time (do you have drawnow?). If you save data in a variable during the analysis, assign it to workspace and see values for the time after your data acquisition stops.
Xavier
el 11 de Sept. de 2020
Yes use drawnow to force the GUI to update
Mario Malic
el 11 de Sept. de 2020
Editada: Mario Malic
el 11 de Sept. de 2020
I checked the other thread, maybe this solution might help, it will stop updating GUI once process is closed
while ~daqSession.HasExited
drawnow
pause (0.1) % Updates GUI every 0.1s
end
Respuestas (0)
Categorías
Más información sobre Simultaneous and Synchronized Operations 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!