Giter VIP home page Giter VIP logo

libusb's Introduction

libusb
======

libusb is a library for USB device access from Linux, Mac OS X,
OpenBSD, NetBSD, and Windows userspace.
It is written in C and licensed under the LGPL-2.1 (see COPYING).

libusb is abstracted internally in such a way that it can hopefully
be ported to other operating systems. See the PORTING file for some
information, if you fancy a challenge. :)

libusb homepage:
http://libusb.org/

Developers will wish to consult the API documentation:
http://libusb.sourceforge.net/api-1.0/

Use the mailing list for questions, comments, etc:
http://libusb.org/wiki/MailingList

- Peter Stuge <[email protected]>
(use the mailing list rather than mailing developers directly)

-2014 Shachar Gritzman <[email protected]> 
this libusb version support android(no root needed). 
in android 5.0(lollipop) google has changed security policy and now SELinux is enforced on all devices.
the original libusb has been modified without breking the interface in order to work with this new policy.

In order to use this solution you have to do those steps:

1. you need to open device by UsbManager
2. open by libusb
3. close by libusb
4. close by UsbManager

libusb's People

Contributors

gritzman avatar tinysniper avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

libusb's Issues

how to modify the newest libusb?

I have to use newest libusb. Although Gritzman's libusb can work, I want know which file been modified, so that I can do it in newest libusb.
I have checked the source code, but because I don't know which version of libusb been modified by Grizman, so I can't modify the source code.

Add text

Please add brief usage on android to the readme, not clear without digging sources:

  1. you MUST open device by UsbManager
  2. open by libusb
  3. close by libusb
  4. close by UsbManager

Exactly that order will work.

libusb_init fails

I see your instructions in the README:

  1. you need to open device by UsbManager
  2. open by libusb
  3. close by libusb
  4. close by UsbManager

The substeps for step number 2 are, as I understand them:

  1. libusb_init
  2. libusb_open_device_with_vid_pid

...but I encounter a problem when attempting to open the device with libusb: libusb_init returns -99. I suppose that this is because my app lacks permissions to access /dev/bus/usb, but is there anything I can do about that?

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.