Mechanics Explorer: Update Input values during simulation

6 visualizaciones (últimos 30 días)
Thomas Scheu
Thomas Scheu el 20 de Mzo. de 2023
Respondida: Meet el 6 de Abr. de 2023
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.

Respuestas (1)

Meet
Meet el 6 de Abr. de 2023
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.

Categorías

Más información sobre Simulation and Analysis en Help Center y File Exchange.

Productos


Versión

R2022b

Community Treasure Hunt

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

Start Hunting!

Translated by