I was trying to use Robotics System Toolbox(MATLAB 2015a on windows 7) to communicate with the ROS running on Ubuntu 14.04. The "rosinit" was successful and MATLAB can see the rosnode list, rostopic list, etc. I can also create the rossubscriber from MATLAB to any topic successfully.
But when I run "receive" command, it just wait forever until timeout. It seems no new message is coming which should not be the case (as I am sure the ROS on Ubuntu is constantly publishing the new kinect images).
I have tried several different settings for rosinit, such as using ROS_MASTER_URI, ROS_IP, etc. Also the two PCs can ping each other's IP successfully. So I think the network connection between the two machines should be good. But MATLAB still couldn't receive the message although it can see and subscribe the topic.
Could anyone suggest any possible cause for this issue? Your help would be really appreciated!
NOTE:-
Matlabsolutions.com provide latest MatLab Homework Help,MatLab Assignment Help , Finance Assignment Help for students, engineers and researchers in Multiple Branches like ECE, EEE, CSE, Mechanical, Civil with 100% output.Matlab Code for B.E, B.Tech,M.E,M.Tech, Ph.D. Scholars with 100% privacy guaranteed. Get MATLAB projects with source code for your learning and research.
I figureed out the solution for this problem. The following steps seem to be helpful:
1. In Ubuntu PC hosts file (/etc/hosts), add the hostnames and the IP addresses of both Ubuntu PC and Windows PC
2. In Windows PC host file (/windows/system32/driver/etc/host), do the same thing as in previous step
3. Turn off all the firewalls on Window PC and Ubuntu PC (if there is any)
4. Reboot both machines to make the new host files effective
5. Set the following environment variables on Ubuntu PC
sudo gedit ~/.bashrc
Add the following lines in .bashrc file, save and then restart terminal
SEE COMPLETE ANSWER CLICK THE LINK
Comments
Post a Comment