Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Help needed with the project #1

Open
MaulshreeSingh opened this issue Apr 24, 2023 · 10 comments
Open

Help needed with the project #1

MaulshreeSingh opened this issue Apr 24, 2023 · 10 comments

Comments

@MaulshreeSingh
Copy link

Hi,

I'm trying to follow your project but implementing it on my own. When I added the ROSMoveItControllerGeneric.cs to my assets script in Unity, I'm getting these two errors:

  • The type or namespace name 'Time' does not exist in the namespace 'RosMessageTypes.Std' (are you missing an assembly reference?)
  • The type or namespace name 'JointTrajectory' does not exist in the namespace 'RosMessageTypes.Trajectory' (are you missing an assembly reference?)

I'm new to this. Can you please help me in figuring out what can I do to fix it?

@szandara
Copy link
Owner

szandara commented Apr 24, 2023

Have you added the right libraries to Unity?

https://github.com/Unity-Technologies/ROS-TCP-Connector.git#v0.1.2 
https://github.com/Unity-Technologies/URDF-Importer.git#v0.1.2

@MaulshreeSingh
Copy link
Author

yes. I have been following the Unity-Robotics-Hub tutorial too. I have been working on ABB robotic arm and trying to implement yours and that tutorial in my own project.

@szandara
Copy link
Owner

That's pretty odd, it seems it cannot find some URDF importer and ROS-TCP-Connector . Seems like it could be an different versions.

Can you check in your Editor files if you have RosMessageTypes and the subfolder Std?

@MaulshreeSingh
Copy link
Author

I couldn't find any folder named RosMessageTypes within the project, however, there is an Std folder under the library.

Library/PackageCache/com.unity.robotics.ros-tcp-connector@c27f00c6cf/Runtime/Messages/Std

@MaulshreeSingh
Copy link
Author

Hi again,

I fixed this error for "'JointTrajectory' does not exist in the namespace 'RosMessageTypes.Trajectory' (are you missing an assembly reference?)" by replacing 'JointTrajectory' with 'JointTrajectoryMsg' by referring to this file https://github.com/Unity-Technologies/ROS-TCP-Connector/blob/main/com.unity.robotics.ros-tcp-connector/Runtime/Messages/Trajectory/msg/JointTrajectoryMsg.cs

But as you can see there is no file for 'Time' here https://github.com/Unity-Technologies/ROS-TCP-Connector/tree/main/com.unity.robotics.ros-tcp-connector/Runtime/Messages/Std/msg

@szandara
Copy link
Owner

Are you sure you are using the correct version?

https://github.com/Unity-Technologies/ROS-TCP-Connector/blob/v0.1.2/Runtime/MessageGeneration/std_msgs/Time.cs The file is there. The ROS-TCP-Connector must be version 0.1.2

@MaulshreeSingh
Copy link
Author

Hi again,

I'm still working on this project and I'm stuck again. If you could help me it will that would be great. So I have modified the Unity script based on new versions of the packages. The issue I'm facing right now is the '/move_group' node is not publishing any Joint Trajectory msgs on the '/move_group/unity_trajectory/unity_arm_controller' topic. The topic is listed on but no new msg is being published there. I have made no changes in unity_moveit_manager.cpp script and using same files(modified to my robot) as [https://github.com/szandara/unity_reachy_tutorial/tree/master/src/unity_reachy_tutorial] on the ROS side. Will you know how I can fix it, please?

@szandara
Copy link
Owner

JointTrajectory should be published by your moveit console. When do you expect to see JointTrajectory messages exactly? Can you share some logs?

@MaulshreeSingh
Copy link
Author

MaulshreeSingh commented Aug 23, 2023

here is the screenshot of Unity scene showing the connection between ros and unity
Screenshot from 2023-08-23 11-54-09

joint_states of robotic arm is being published by unity for MoveIt to use

Screenshot from 2023-08-23 11-54-17 (1)

However, there is no msg being published by MoveIt in this topic

Screenshot from 2023-08-23 12-23-13

even though the info about the topic shows this

Screenshot from 2023-08-23 12-40-59

there is no problem in executing the goal
Screenshot from 2023-08-23 12-40-59

now I'm not sure what's the problem. Any help will be appreciated. Thanks.

@wongsinglam
Copy link

@MaulshreeSingh the problem is that the version of ros tcp connector has been upgraded. Check the package and modify it, and you will get everything work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants