Controller_manager in a different namespace
I am using Ros Noetic in Ubuntu 20.02 and i am trying to move joints using rostopic to simulate a rover. I have created a simple robot with only one join and when i try to load the controller, it doesn't work. I've followed the tutorial of gazebo ros control but it doesnt work as well. My files are the following:
.xacro:
<?xml version="1.0" ?>
.gazebo:
<?xml version="1.0" ?>
gazebo.launch:
controller.launch:
and controller.yaml: srob: # Publish all joint states ----------------------------------- jointstatecontroller: type: jointstatecontroller/JointStateController publish_rate: 50
# Position Controllers -------------------------------------- Revpositioncontroller: type: effort_controllers/JointPositionController joint: Rev pid: {p: 100.0, i: 0.01, d: 10.0}
The rosservice list after executing the roslaunch gazebo and controller :/controllermanager/listcontrollertypes /controllermanager/listcontrollers /controllermanager/loadcontroller /controllermanager/reloadcontrollerlibraries /controllermanager/switchcontroller /controllermanager/unloadcontroller /gazebo/applybodywrench /gazebo/applyjointeffort /gazebo/clearbodywrenches /gazebo/clearjointforces /gazebo/deletelight /gazebo/deletemodel /gazebo/getjointproperties /gazebo/getlightproperties /gazebo/getlinkproperties /gazebo/getlinkstate /gazebo/getloggers /gazebo/getmodelproperties /gazebo/getmodelstate /gazebo/getphysicsproperties /gazebo/getworldproperties /gazebo/pausephysics /gazebo/resetsimulation /gazebo/resetworld /gazebo/setjointproperties /gazebo/setlightproperties /gazebo/setlinkproperties /gazebo/setlinkstate /gazebo/setloggerlevel /gazebo/setmodelconfiguration /gazebo/setmodelstate /gazebo/setparameters /gazebo/setphysicsproperties /gazebo/spawnsdfmodel /gazebo/spawnurdfmodel /gazebo/unpausephysics /gazebogui/getloggers /gazebogui/setloggerlevel /robotstatepublisher/getloggers /robotstatepublisher/setloggerlevel /rosout/getloggers /rosout/setloggerlevel /srob/controllerspawner/getloggers /srob/controllerspawner/setloggerlevel.
As it can be seen there is srob before controller spawner but not before controllermanager. So when i try to execute the following command : rosservice call srob/controllermanager/loadcontroller "name: 'Revposition_controller'" the error message is service is not available and if i remove the srob/ the gazebo returns:
[ERROR] [1670887147.867585844]: Could not load controller 'Revpositioncontroller' because the type was not specified. Did you load the controller configuration on the parameter server (namespace: '/Revpositioncontroller')?
Thank you in advance for your help.
Asked by lectric on 2022-12-12 18:21:21 UTC
Comments