naoki-mizuno / ds4_driver

DualShock 4 driver for both ROS1 and ROS2
http://wiki.ros.org/ds4_driver
85 stars 53 forks source link

ds4_twist_node error #7

Closed AhmedSo3da closed 4 years ago

AhmedSo3da commented 4 years ago

I just need to clarify that I am still a beginner in ROS in general, so the issue is whenever i hit "rosrun ds4_driver ds4_twist_node.py " i get an error : Traceback (most recent call last): File "/home/ahmedso3da/catkin_ws/src/ds4_driver/nodes/ds4_twist_node.py", line 64, in main() File "/home/ahmedso3da/catkin_ws/src/ds4_driver/nodes/ds4_twist_node.py", line 58, in main StatusToTwist() File "/home/ahmedso3da/catkin_ws/src/ds4_driver/nodes/ds4_twist_node.py", line 16, in init self._inputs = rospy.get_param('~inputs') File "/opt/ros/kinetic/lib/python2.7/dist-packages/rospy/client.py", line 465, in get_param return _param_server[param_name] #MasterProxy does all the magic for us File "/opt/ros/kinetic/lib/python2.7/dist-packages/rospy/msproxy.py", line 123, in getitem raise KeyError(key) KeyError: '~inputs'

naoki-mizuno commented 4 years ago

You can run roslaunch ds4_driver ds4_twist.launch dof:=2 for X, Y, theta velocity commands, or dof:=6 for X, Y, Z, roll, pitch, and yaw. This way you can use the default mappings defined in the driver.

If you want to define a custom mapping, take a look at the config.

AhmedSo3da commented 4 years ago

Thanks a lot! it worked