Inputing the values of the external torque per time step to the TorqueActuator while CMC Simulation in Simulink

Provide easy-to-use, extensible software for modeling, simulating, controlling, and analyzing the neuromusculoskeletal system.
POST REPLY
User avatar
Wahyu Kasendra Sugiarto
Posts: 8
Joined: Thu Apr 09, 2020 11:13 am

Inputing the values of the external torque per time step to the TorqueActuator while CMC Simulation in Simulink

Post by Wahyu Kasendra Sugiarto » Wed Aug 12, 2020 6:00 am

Hello,

Right now i want to do a CMC (Computed Muscle Control) simulation to get the needed muscle forces under consideration of external torque in simulink. So this external torque (as a function of the input kinematics) will help the osim model to tracking the given reference/input kinematics.
But i'm struggling to input the calculated external torque from my other simulink block to the CMC-block in simulink.
can anyone help me with it or give me a suggestion/an example to how to write the code to input the values of the calculated external torque per time step from my other simulink block to the CMC-block in simulink?

Here is the force set from my osim-model: ('Torque_from_CableActuator')
model with torque.png
model with torque.png (86.99 KiB) Viewed 425 times
Best regards
Wahyu

Tags:

User avatar
Carmichael Ong
Posts: 401
Joined: Fri Feb 24, 2012 11:50 am

Re: Inputing the values of the external torque per time step to the TorqueActuator while CMC Simulation in Simulink

Post by Carmichael Ong » Thu Aug 20, 2020 10:48 am

If you know the input kinematics ahead of time, and thus can calculate the values for your TorqueActuator for the whole simulation ahead of time, you could add a PrescribedController for your TorqueActuator and run CMC. If you are trying to do this between steps of CMC, I'm not aware of a way to do this since CMC is fairly rigid.

POST REPLY