joshnewans / articubot_one

303 stars 263 forks source link

Can't see the wheels in the RVIZ #3

Open deebot opened 2 years ago

deebot commented 2 years ago

I followed your tutorial creating rough 3D model of your robot : creating a rough 3d model of our robot https://www.youtube.com/watch?v=BcjHyhV0kIs

But I dont see the wheels in RVIZ . I have checked everything multiple times. The state publisher is running, launch file is also running perfectly but no wheels. But when i slide the slider on the publisher gui the TF axis for wheels does rotate. Below is a video for better explanation.

https://www.veed.io/view/4918fe1a-e40f-417a-a0b0-5264dbe23cd0?sharingWidget=true

Another point to note is that I have commented out the caster wheel code in the URDF. Still under the Golbal options where we select fixed frame I get option to chose a caster as a fixed link. Dont know where this caster is listed from as it is not described in my URDF.

AustrianOakvn commented 1 year ago

I had same problem as you encountered. From this issue: link I think it is because joint_state_publisher is not launched. I created a new python launch file just like the rsp.launch.py and change the robot_state_publiser to joint_state_publisher, then launch both file before running rviz, now you could see the wheels. Hope it could help.

SchlackBoles commented 7 months ago

You do not need to make a new file. It is enough to create a node called joint state publisher and then add this in the launch part: node_joint_state_publisher.

That is, after the robot_state publisher you go with this:

    # Create a joint_state_publisher node
    node_joint_state_publisher = Node(
        package='joint_state_publisher',
        executable='joint_state_publisher',
        name='joint_state_publisher',
        parameters=[params]
    )

    # Launch!
    return LaunchDescription([
        DeclareLaunchArgument(
            'use_sim_time',
            default_value='false',
            description='Use sim time if true'),

        node_robot_state_publisher,
        node_joint_state_publisher
    ])

Hope this helps

0RBalaji commented 2 months ago

run the joint_state_publisher_gui to display the continuous joint using the command: $ ros2 run joint_state_publisher_gui joint_state_publisher_gui

If not installed install it first and then run it.