GithubHelp home page GithubHelp logo

jodle001 / eip_bridge Goto Github PK

View Code? Open in Web Editor NEW

This project forked from swri-robotics/eip_bridge

0.0 0.0 0.0 30 KB

ROS to PLC bridge using Ethernet/IP

License: Apache License 2.0

Python 94.90% CMake 5.10%

eip_bridge's Introduction

EIP Bridge

license - Apache 2.0

This repository contains a bridge between a ROS system and PLC using the Ethernet/IP (EIP) communication protocol.

Dependencies:

  1. PyComm 1.0.8
    • pip install pycomm==1.0.8

Notes:

  • Supported message types:
    • Core PLC data types (e.g. integers, floats, booleans, strings, etc.)
    • Fixed-length arrays of core PLC data types
  • Not currently supported:
    • User-defined type (UDT)
    • User-defined type array
  • Currently only tested on Allen Bradley PLCs

Configuration

The EIP bridge accepts a YAML config file specifying communication between the ROS system and PLC. This includes:

  • Subscribers: PLC tags which should receive data from ROS topics (i.e. ROS -> PLC)
  • Publishers: PLC tags which should publish their values as ROS messages (i.e. PLC -> ROS)
  • Services: on-demand access via ROS service for getting/setting data of a specified type on arbitrary tags

The format of the YAML configuration file is shown below:

Services:
  - name: <Service topic name>
  - type: <Service message type>
Publishers:
  - name: <ROS topic on which to publish data>
    tag: <PLC tag from which to publish data>
    type: <PLC data type>
    length: <Array length, 0 for single values>
    sim_value: <Arbitrary value to publish for simulation>
Subscribers:
  - name: <ROS topic on which to subscribe>
    tag:  <Tag into which to write data from the ROS system>
    type: <PLC data type>
    length: <Array length (0 for single values)>
    sim_value: <Arbitrary initial value - used only by simulated PLC>

See the example configuration file for reference

Usage:

  1. Create YAML file listing ROS topics to map to EIP tags

  2. (Optional) Add the path to pycomm to the PYTHONPATH environment variable

    export PYTHONPATH=<path_to_pycomm_install>

    Note: this should not be necessary if pycomm was installed using pip

  3. Run the launch file, specifying the path to your config file

    roslaunch eip_bridge eip_bridge.launch config_file:='/path/to/config.yaml' sim:=<true/false>

eip_bridge's People

Contributors

marip8 avatar k-okada 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.