Real time data sharing between Matlab/Simulink and Python

39 次查看(过去 30 天)
I have a real-time simulator in Matlab/Simulink running at ≈100-300Hz and want to share data to a grapical environment for real time visualization in Python. My question is how to pass data (signals or variables) quickly enough to Python? (Working on OSX)
Glad for any pointers :-)

回答(1 个)

Aman
Aman 2023-2-15
Hi,
I understand that you have made some MATLAB/Simulink model whose data you want to share with your Python application.
For sharing the MATLAB/Simulink data with your Python application you need to change MATLAB session to shared session, for doing that you can use “matlab.engine.shareEngine” method. You can refer the below File Exchange article for reference.

类别

Help CenterFile Exchange 中查找有关 Call Python from MATLAB 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by