Git Product home page Git Product logo

usbip-next's Introduction

An advanced USB/IP including features:

1. Exporting device

    It allows to connect from device side. Many devices can be connected to
    remote with plug-and-play manner. 

    EXISTING) - invites devices from application(vhci)-side
             +------+                               +------------------+
     device--+ STUB |                               | application/VHCI |
             +------+                               +------------------+
     1) # usbipd ... start daemon
     = = =
     2) # usbip list --local
     3) # usbip bind
                      <--- list bound devices ---  4) # usbip list --remote
                      <--- import a device ------  5) # usbip attach
     = = =
                         X disconnected            6) # usbip detach
     7) usbip unbind

    NEW) - dedicates devices from device(stub)-side
             +------+                               +------------------+
     device--+ STUB |                               | application/VHCI |
             +------+                               +------------------+
                                                   1) # usbipa ... start daemon
     = = =
     2) # usbip list --local
     3) # usbip connect    --- export a device ------>
     = = =
     4) # usbip disconnect --- un-export a device --->

     You can add allow/deny rules with TCP wrappers (./configure
     --with-tcp-wrappers) and/or udev rules.

2. VHCI number of ports extension

    It extends number of ports limitaion in application (vhci) side by
    multiplying number of VHCI.

    Driver portion of static extension has been merged at 4.9-rc1. Userspace
    tools and dynamic extenstion are added.

    USBIP_VHCI_HC_PORTS:
        Number of ports per USB/IP virtual host controller. The default is 8.
    USBIP_VHCI_MAX_HCS:
        Maximum number of USB/IP virtual host controllers. The default is 1.
    USBIP_VHCI_INIT_HCS:
        Initial number of USB/IP virtual host controllers. The default is 1.

3. Cross platform device side node

    It adds porting of USB/IP device side command and daemon with libusb instead
    of stub driver. It allows to port device side node to other operation
    systems which are supported by libusb.

    tools/usb/usbip
    +-- src: command and daemon
    +-- libsrc: common, host driver interface and vhci driver interface
    +-- doc: manuals
    +-- libusb : implementation with libusb (newly added)
        +-- src: makes ../../src objects without stub driver dependent
        |        code giving -DUSBIP_WITH_LIBUSB.
        +-- libsrc: makes ../../libsrc objects giving -DUSBIP_WITH_LIBUSB.
        |   +-- dummy_device_driver.c : dummy host device driver
        +-- stub: stub driver emulation library with libusb.
        +-- os: OS dependent code.
        |   +-- unix: unix dependent code used in libusb.
        |   +-- win32: Win32 dependent cocde.
        +-- doc: manuals

    Make
        in tools/usb/usbip : original with stub driver
        in tools/usb/usbip/libusb : new with stub emulator with libusb
            ./configure --with-dummy-driver applies dummy host device driver
            instead of vUDC.

    Binary names
        usbip: command with stub/vhci driver (original)
        usbipd: daemon with vhci driver (original)
	usbipa: daemon with stub driver (new as 1)
        libusbip: command with stub emulator (new)
        libusbipd: daemon with stub emulator (new)

4. API to add arbitrary network protocol

    It introduces userspace API to add network protocols to USB/IP. The API
    allows to program to wrap USB/IP with arbitrary network protocol using
    network protocol library, for example, libwebsockets or Poco C++ for
    WebSocket.

    The detail of the API is written as manual pages.

    The shared libraries below are created.
        libusbip.so : common, as same as original
        libusbipc.so : for commands
        libusbipd.so : for device side daemon
        libusbipa.so : for application side daemon
    Device side libraries with libub are created by build at
    tools/usb/usbip/libusb.
        libusbip_libusb.so : common
        libusbip_stub.so : stub emulator with libusb
        libusdipc_libusb.so : for device side commands
        libusbipd_libusb.so : for device side daemon

    To enable the API, a driver to forward packets to userspace should be
    loaded.
        # modprobe usbip-host (original, device side)
        # modprobe vhci-hcd (original, application side)
        # modprobe usbip-ux (new, both device and application side)
 
    A simple example for USB/IP API using IPv4 socket is included. USB over
    WebSocket using OSSs are stored in github below.
        with Poco C++ : https://github.com/novimusica/usbws-poco
        with libwebsockets : https://github.com/novimusica/usbws-lws

//

usbip-next's People

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.