How can I use the scope in my model while running a the host model?

1 vue (au cours des 30 derniers jours)
Irfan Guven Comezoglu
Irfan Guven Comezoglu le 10 Avr 2022
I'm trying to use the Field Oriented Contol of PMSM using hall sensor, https://www.mathworks.com/help/mcb/gs/foc-pmsm-using-hall-sensor-example.html, and want to add scopes to variables in the model so that I can see how they change in real time. The model and the host model works fine but I can't seem to get the scopes to work. After I add scopes to the main model, when I try to run the host model and see what the scopes are showing, all I get is the simulation results. They do not change according to me running the kit in real time.

Réponses (1)

Keyur Mistry
Keyur Mistry le 18 Mai 2022
To observe variable in real time, we are supposed to send variable data from controller to MATLAB host model via serial communication.
Pleaes ensure the variable you want observe in real time is being sent through "SCI Transmit" block in target model (main model) and being received thorugh "Host Serial Receive" block in host model.

Produits


Version

R2021b

Community Treasure Hunt

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

Start Hunting!

Translated by