Robotics StackExchange | Archived questions

Multiple robot control using joystick

Hello everyone, I am new to ROS and was having a model for robot simulation in gazebo, the simulation has four robots and I want to control them individually using four joysticks to four USB ports. Though I was able to control one using the joystick with code given following link

https://github.com/UbiquityRobotics/joystick_input

by publishing on cmdvel, I want to publish on other cmdvel on other namespaces so that other robots can be controlled. What changes do I have to make in the codes or scale the code to solve my problem.

Thanks in advance

Asked by FAIZ on 2016-10-18 01:24:26 UTC

Comments

Answers

I think you will have to start this node 4 times then, one for each joystick, with the correct USB port set for each. You can start each in the namespace of the robot that you want to control.

Asked by Sebastian Kasperski on 2016-10-18 05:01:26 UTC

Comments

Thanks Sebastian for the reply. I tried doing that and replacing cmd_vel with namespace/cmd_vel for other bots. I was not able to control other bots. Can you please explain the code to me... Thanks in advance.

Asked by FAIZ on 2016-10-18 09:56:46 UTC

I haven't used this specific node, so I cannot give any details. Have you checked "rqt_graph" for all connections? Next you should check the joy-topics and cmd-topics with "rostopic echo".

Asked by Sebastian Kasperski on 2016-10-19 02:35:14 UTC