-
Notifications
You must be signed in to change notification settings - Fork 370
Dev_Protocols
Mehmet Emre Çakal edited this page Oct 10, 2024
·
3 revisions
RosBridgeClient is designed to keep the communication protocol generic. New protocols can be added by implementing a simple and minimalistic
IProtocol interface:
public interface IProtocol
{
void Connect();
void Close();
bool IsAlive();
void Send(byte[] data);
event EventHandler OnReceive;
}
A RosSocket
is instantiated by passing in the IProtocol interface implementation that you want to use.
Example:
string uri = "ws://xxx.xxx.xxx.xxx:9090";
RosSocket rosSocket = new RosSocket(new RosBridgeClient.Protocols.WebSocketNetProtocol(uri));
Though ROS# currently comes with two WebSocket-based IProtocol
implementations, note that an IProtocol
does not necessarily need to be a WebSocket client.
A WebSocket client that is based on the .NET ClientWebSocket class.
- Available since .NET Framework 4.6 / Net Standard 1.3 and will work with .NET Core 8.0
- Requires System.Threading.Channels
A wrapper for WebSocketSharp-NetStandard.
- The original WebSocket client used in ROS#
- Requires additional assembly
websocket-sharp.dll
- Not compatible with e.g. UWP
A WebSocket client for UWP using Windows.NetWorking.Sockets.
- Not included in the main repo, a running ROS# version with this protocol is hosted on @dwhit 's fork.
Platform | WebSocketNetProtocol | WebSocketSharpProtocol | WebSocketUWPProtocol |
---|---|---|---|
Windows 7 | no | yes | no |
Windows 8+ | yes | yes | no |
Ubuntu | ? | yes | no |
UWP | no | no | yes |
iOS | ? | yes | no |
If you tested a protocol on a new platform, and can contribute with new info in above table, please do!
© Siemens AG, 2017-2024
-
- 1.3.1 R2D2 Setup
- 1.3.2 Gazebo Setup on VM
- 1.3.3 TurtleBot Setup (Optional for ROS2)
-
- 2.1 Quick Start
- 2.2 Transfer a URDF from ROS to Unity
- 2.3 Transfer a URDF from Unity to ROS
- 2.4 Unity Simulation Scene Example
- 2.5 Gazebo Simulation Scene Example
- 2.6 Fibonacci Action Client
- 2.7 Fibonacci Action Server
- 3.1 Import a URDF on Windows
- 3.2 Create, Modify and Export a URDF Model
- 3.3 Animate a Robot Model in Unity
- Message Handling: Readers & Writers
- Thread Safety for Message Reception
- File Server Package
- ROS-Unity Coordinate System Conversions
- Post Build Events
- Preprocessor Directives in ROS#
- Adding New Message Types
- RosBridgeClient Protocols
- RosBridgeClient Serializers
- Action Server State Machine Model
© Siemens AG, 2017-2024