GithubHelp home page GithubHelp logo

mtbrobotanist / rosbridgelib Goto Github PK

View Code? Open in Web Editor NEW

This project forked from csun-serl/rosbridgelib

0.0 1.0 0.0 45.87 MB

A Unity ROS tool

License: GNU Lesser General Public License v2.1

C# 100.00%

rosbridgelib's Introduction

ROSBridgeLib

A Unity library for communicattion with ROS through RosBridge

The first version of this I believe origins from Michael Jenkin, in the repo unityros. He has made a sample unity project showing turtlesim, with good instructions on how to use this project. All honor goes to him. I created this project because there was no repository containing the barebone library.

This repository is intended to be imported as a git submodule.

Included messages

This repository does not contain every ROS message. If you need to add one, please fork this repository, add the file and make a pull request.

Documentation

Documentation is in the code. I have added some more in addition to what Michael Jenkin (original author). The main file is ROSBridgeWebSocketConnection.cs, which sets up everything.

Example usage

A Unity project which uses this repository UnityROSSensorVisualizer:

public class RealsenseViewer : MonoBehaviour  {
  private ROSBridgeWebSocketConnection ros = null;
    
  void Start() {
    ros = new ROSBridgeWebSocketConnection ("ws://localhost", 9090);
    ros.AddSubscriber (typeof(RealsenseCompressedImageSubscriber));
    ros.AddServiceResponse (typeof(RealsenseServiceResponse));
    ros.Connect ();
  }
  
  // Extremely important to disconnect from ROS. OTherwise packets continue to flow
  void OnApplicationQuit() {
    if(ros!=null) {
      ros.Disconnect ();
    }
  }
  
  // Update is called once per frame in Unity
  void Update () {
    ros.Render ();
  }
}

License

Note: SimpleJSON is included here as a convenience. It has its own licensing requirements. See source code and unity store for details.

rosbridgelib's People

Contributors

kevinkeyser avatar mathiasciarlo avatar michherren avatar miquelmassot avatar mtbrobotanist avatar rcodddow avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.