how to convert cpp program to ROS
hi folks
i have a program which i make on eclipse in cpp language, and which contains opencv and librealsense libraries, i need to convert this to ROS,, please tell me how to do this .
thanks ya all .
Providing some code will help us help you!
its just cpp code, normal. and i have build this project using eclipse and so i have a make file in debug folder and in src folder my cpp code. i just need to convert this project to ROS
Try creating a CMakeLists.txt file for your cpp code, using the instructions on this page.
What do you mean by converting it to ROS platform? Using a catkin workspace? Or do you need any other stuff in ROS as well?
It's not really clear what you mean by "convert". Are you trying to turn this executable into a node that has publishers, subscribers, and other ROS capabilities? Or are you simply trying to compile the exact code using catkin, the ROS build system?
hi, yes i need to make it a ros topic with this cpp file...
I'd edit your original question and supply much more information. What does your CPP code do? How are you trying to convert it to ROS? What does/doesn't work? You could also study example ROS packages that mimic what you are trying to do for inspiration (I'd suggest some, but I don't know your info)
i got it working,, i made a node out of it,, now i can run my program with rosrun ,,, thanks all guys