Skip to content

Specify path to config.xml #10

@matteodv99tn

Description

@matteodv99tn

Hi,
I am using this library since I want to control my Z1 robot through ROS2.

I am doing some testing and it appears that there's no way to specify the config path for the arm.
In particular the following line fails if I execute the z1_ctrl executable in a path that is different from /repo_root/build; it seems that the reported line searches the specific path ../config/config.xml to configure the control components.

CtrlComponents *ctrlComp = new CtrlComponents(argc, argv);

When running the z1_ctrl executable in a path which doesn't allow to reach the ../config/config.xml file, then I receive the error

Failed to open file: No such file or directory
Failed to load file: No root element.
: No such file or directory
Segmentation fault (core dumped)

Is there a way to specify the path to the configuration file prior to the creation of the control component?

I need this possibility, as a ROS2 user could arbitrary execute his code from any folder (as long as the workspace has been sourced).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions