How do I start using ROS Web Tool

973 views
Skip to first unread message

Ashish Tupate

unread,
Jun 5, 2017, 6:02:08 AM6/5/17
to Robot Web Tools
Hello Everyone,
            I am doing a small robot project where I am not using the ROS system.I am instead using the raspberry pi processor.   I am using QT creator for developing programming in C++ on Robot Side. On QT, I am using Websocket for Communication with the server. Through web socket,  I am sending data from Robot side. 
            I want to use ROS Web tool for visualizing Robot data on Cloud Server. For that, I have to use ROS Web tool on Cloud server, but I am not sure that is only required on the server side, or else I have to use ROS on Robot side also. This is what my doubt.  Because of WebSocket common for communication. 

Jihoon Lee

unread,
Jun 6, 2017, 12:29:51 PM6/6/17
to Robot Web Tools
Hi Ashish,

RWT is designed as a client library for rosbridge_server. So, I would recommend to use ROS and rosbridge_sever to use RWT for your web application for your robot.
If you really want to use RWT without ROS, please check out rosbridge protocol documentation. RWT should work as long as a server sends a right JSON data format.

Cheers,
Jihoon

Ashish Tupate

unread,
Jun 7, 2017, 2:51:28 AM6/7/17
to Robot Web Tools
Thank you! Jihoon Lee.

       I definitely try this and hope that will help me. I have one more question. I will get data on the client side using WebSocket from server How do I change the default port of WebSocket so that I can transfer data to and from the server to the client? Can you give me any simple example so that I start?  This will be very useful for me and will really appreciate that.

Thank you!

Jihoon Lee

unread,
Jun 7, 2017, 6:00:40 AM6/7/17
to robot-w...@googlegroups.com

Roslibjs Examples are here. In case you want to configure rosbridge, check this rosbridge_suite ros wiki tutorial. :)

Jihoon

--
You received this message because you are subscribed to the Google Groups "Robot Web Tools" group.
To unsubscribe from this group and stop receiving emails from it, send an email to robot-web-too...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Ashish Tupate

unread,
Jun 8, 2017, 2:13:02 AM6/8/17
to Robot Web Tools
          I have referred some examples from the link given by you. After importing one the example [ sample.html ] I am getting a WebSocket error [ WebSocket connection to 'ws://localhost:8080/ROSExample//serverendpointdemo1' failed: Error during WebSocket handshake: Unexpected response code: 404 ].

          I have created server endpoint using Java. Also I have  changed my WebSocket address in javascript like this [  ros.connect('ws://localhost:8080/ROSExample//serverendpointdemo1');  ] in sample.html page. I have also imported libraries like roslibjs and  eventemitter2.min.js which is required in the html page. The address seems to be correct but still giving an error. Is this because of roslibjs? Or some other problem? If the  WebSocket address is correct then only I can be able to communicate with the front end from the server. 

Ashish Tupate

unread,
Jun 8, 2017, 10:05:43 AM6/8/17
to Robot Web Tools
Also, I have one last question. Is is necessary to use rosbridge server for using roslibjs? Can I use Java server instead?


On Wednesday, June 7, 2017 at 3:30:40 PM UTC+5:30, Jihoon Lee wrote:

Chad Jenkins

unread,
Jun 8, 2017, 10:55:30 AM6/8/17
to robot-w...@googlegroups.com


This would be difficult to debug from this description alone. However, I would suggest looking at similar projects implementing rosbridge interface through Java:

https://github.com/rctoris/jrosbridge

-Chad

To unsubscribe from this group and stop receiving emails from it, send an email to robot-web-tools+unsubscribe@googlegroups.com.

Ashish Tupate

unread,
Jun 9, 2017, 12:56:48 AM6/9/17
to Robot Web Tools
       I will definitely try this.Just a curiosity that if I am using my Simple Java server is it possible to send and receive data without using rosbridge? 

      Or If I am not using robbridge then I can't use roslibjs also?Are rosbridge and roslibjs independent? 

Jihoon Lee

unread,
Jun 9, 2017, 5:46:00 AM6/9/17
to robot-w...@googlegroups.com, Ashish Tupate

Yes it is possible as long as the data format is correct as I explained in previous e-mail. But, it will probably be difficult to match all the apis.



On 09.06.2017 06:56, Ashish Tupate wrote:
       I will definitely try this.Just a curiosity that if I am using my Simple Java server is it possible to send and receive data without using rosbridge? 

      Or If I am not using robbridge then I can't use roslibjs also?Are rosbridge and roslibjs independent? 

Chad Jenkins

unread,
Jun 9, 2017, 8:35:00 AM6/9/17
to robot-w...@googlegroups.com, Ashish Tupate


Adding to Jihoon's response, it is important to distinguish between the rosbridge protocol and a server that adheres to this protocol. The rosbridge_server node and roslibjs client library adhere to the rosbridge protocol. As long as your client and server properly "speaks" rosbridge, interoperability will be maintain.

-Chad

Yes it is possible as long as the data format is correct as I explained in previous e-mail. But, it will probably be difficult to match all the apis.



On 09.06.2017 06:56, Ashish Tupate wrote:
       I will definitely try this.Just a curiosity that if I am using my Simple Java server is it possible to send and receive data without using rosbridge? 

      Or If I am not using robbridge then I can't use roslibjs also?Are rosbridge and roslibjs independent? 
--
You received this message because you are subscribed to the Google Groups "Robot Web Tools" group.
To unsubscribe from this group and stop receiving emails from it, send an email to robot-web-tools+unsubscribe@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Robot Web Tools" group.
To unsubscribe from this group and stop receiving emails from it, send an email to robot-web-tools+unsubscribe@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages