jiminy
jiminy copied to clipboard
[core] Introduce system options.
Currently, the sensor and controller update periods are set at engine level, while it should be specific to every robots. It would be natural to move the controller as an attribute Robot
, and request the user to the setController
method (currently part of EngineMultiRobot
) to set it on-the-fly.
This way, the notion of "system" can be removed altogether and replaced by "robot". The engine would still be responsible for calling the controller and its internal dynamics itself, but it is already the case for any physical quantity anyway.
To avoid any conflict or confusion, getName
method of Model
should be removed, in favor of manually accessing name
attribute of pinocchio_model
. The robots themselves as no name anymore apart from the ones the engine is giving to them to distinguish between them. This mechanism is different from the sensors and motors and maybe should be refactor. It seems more rationale to identity them from the name their owner is giving them since they are basically all identical.
In the same vein, registered forces should be named. Everything should return lists ordered by motors, sensors or rotor instead of a mix of unordered dicts and list as it is currently the case.