Multiple real time plots on multiple figures
12 次查看(过去 30 天)
显示 更早的评论
Hello all, greetings. I´m a beginner in Matlab. I want to plot real time graphs on matlab for 4 motors, the data being read from the serial port. The data from the serial port will contain certain parameters that I should extract and compute and plot graphs in real time. My front screen will have buttons for 4 motors. When i click on m1, it should display live graphs (read from the the serial port) and when i click on m2, the corresponding data for m2 needs to be plotted, simultaneous to m1 graphs on another figure. Is this possible? If yes, please give me an basic algorithm to follow. I can catch up from there. I appreciate any kind of help. Thanks a lot!
0 个评论
回答(1 个)
Steven Samuel
2020-12-11
I know this is some 4 odd years too late but you can just do
figure(1),plot (x, y)
figure(2),plot (x, y)
if you have them inside a while loop they will work or you can alternatively add this line after each figure declaration:
drawnow
0 个评论
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Annotations 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!