フィルターのクリア

Mechanics Explorer: Update Input values during simulation

8 ビュー (過去 30 日間)
Thomas Scheu
Thomas Scheu 2023 年 3 月 20 日
回答済み: Meet 2023 年 4 月 6 日
Hi everybody,
in my simscape multibody model of a gearbox, one parameter is varied by a "horizontal slider". Everything is working fine, except the dynamic simulation of the gearbox: the animation is not updating when i change the value with the horizontal slider. If i stop the simulation and run it again (with changed value of the slider), the animation is correct - but again, only for the starting value of the slider. When I check the varied value with a scope during simulation, everything is working as it should - except the dynamic animation in the mechanics explorer.
What do I have to do to get a real time animation of my gearbox?
Thank you very much for your help.

回答 (1 件)

Meet
Meet 2023 年 4 月 6 日
Hi,
This happens because of the difference in clock speed of simulation and the Mechanical Explorer. The simulation clock is running at about 100 times faster than the wall clock, whereas, the Mechanics Explorer is playing the animation at 1x wall clock speed by default.
You can refer to the answer posted in Simscape Multibody - model does not react to slider gain changes without stopping and starting the simulation again - MATLAB Answers - MATLAB Central (mathworks.com). The user was facing a similar issue and was able to solve it using the solution mentioned in the answer.

カテゴリ

Help Center および File ExchangeAssembly についてさらに検索

製品


リリース

R2022b

Community Treasure Hunt

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

Start Hunting!

Translated by