Code Monkey home page Code Monkey logo

serialportexample's Introduction

serialportexample's People

Contributors

felhr85 avatar stephanebg 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  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  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

serialportexample's Issues

Unable to receive response from CDC device.

When compiling and installing the apk I can connect to the cdc device and I'm assuming the command gets sent, however, I am receiving no feedback.

This does work with DroidTerm though.

I'm running this on KitKat (4.4) if that helps.

Thank you.

Not able to send AT commands through USB

I am trying to send AT commands from android app to adafruit fona, through usb OTG cable. When I type some AT command, nothing is really happening, but the USB serial terminal app from the play store is able to send AT command through USB.

Can't send zeros

I'm trying to send zeros to my arduino Uno with serialPort.write(new byte[0x00]), but nothing happens. With another program (Serial USB Terminal), it works properly.

We need to take an array of

    @Override
    public void handleMessage(Message msg) {
        switch (msg.what) {
            case UsbService.MESSAGE_FROM_SERIAL_PORT:
                String data = (String) msg.obj;
                mActivity.get().display.append(data);
                break;
        }
    }

I'm sending a request which consists of 3 or 8 bytes. In response, I have to get an array of the same 3 or 8 bytes. How do I do that? Send I got.
byte[] cats = {0x00, 0x05, 0x3F};
usbService.write(cats);
Here's how to accept and display, I do not know ...
Can you help me?
Sorry for my English.

Defective logic in findSerialPortDevice() ?

I want to thank you for sharing UsbSerial and the SeirialPortExample.

I have a question about some logic in the findSerialPortDevice() routine of the SerialPortExample in the UsbService.java file.

in line 158 inside findSerialPortDevice():

if (deviceVID != 0x1d6b && (devicePID != 0x0001 || devicePID != 0x0002 || devicePID != 0x0003))

This will exclude all devices with a deviceVID of 0x1d6b without regard to the value of the devicePID because (devicePID != 0x0001 || devicePID != 0x0002 || devicePID != 0x0003) will be true for all values of devicePID.

is it possible you intended:

if ( !(deviceVID == 0x1d6b && (devicePID == 0x0001 || devicePID == 0x0002 || devicePID == 0x0003)))

I think this would only exclude a device if it both had a VID of 1d6b and a PID of 1,2 or 3 allowing all other PID's for that VID.

or did you intend something else?

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.