Skip to content

How do I add a PrescribedController to a model? #856

Answered by adamkewley
adamkewley asked this question in Q&A
Discussion options

You must be logged in to vote

The error is because OpenSim's Controller API requires entries in the actuator_list to be the names, not paths, of actuators in the model.

The fix is either:

  • Leave actuator_list blank, which will cause the implementation to figure out what the actuator is from your STO file (i.e. it will automatically populate PointToPointActuator in the actuator_list field)
  • Or write "PointToPointActuator" in the actuator_list field (i.e. just the name of the actuator)

Relevant source code in OpenSim: https://github.com/opensim-org/opensim-core/blob/4.5/OpenSim/Simulation/Control/Controller.cpp#L177

Replies: 1 comment

Comment options

adamkewley
May 2, 2024
Maintainer Author

You must be logged in to vote
0 replies
Answer selected by adamkewley
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant