Giter Site home page Giter Site logo

Comments (5)

kshoji avatar kshoji commented on June 3, 2024

Thanks for using this library!

The sysex data must be start with 'F0', and end with 'F7'.
for example,
byte[] data = new byte[] {(byte) 0xF0, 0x00, 0x01, 0x0C, 0x01, 0x00, 0x01, (byte) 0xF7};

Please try adding '0xF0' to the head of 'data', and call the sendMidiSystemExclusive() method.

from usb-midi-driver.

brudywr avatar brudywr commented on June 3, 2024

Frankly sending with sendMidiSystemExclusive makes the app to freeze regardless to passed data. I've managed to get some response from my midi device splitting the original sysex message into 3 pieces and sending 3-byte parts via sendMidiSystemCommonMessage. In that case the app continues working and catches sysex message = '2 0 2 0 -9'. May the usb host driver be the trouble maker? Or some exact version of Android SDK (my android device runs 4.2)

from usb-midi-driver.

kshoji avatar kshoji commented on June 3, 2024

I tried to debug with the MIDI monitor, and found the data-loss bug in sendMidiSystemExclusive method.
It was fixed(maybe), so please pull and test the code.

With the long message data, sending sysex still fails... (my environment only...?)

from usb-midi-driver.

brudywr avatar brudywr commented on June 3, 2024

thanks a lot - now it can send sysex messages without freezes. But I found that there's a bug in MidiMessageCallback class - line 78 - while assembling long sysex response it's supposed to concatenate it but now you clears it every for-cycle. I mean:
systemExclusive = new ByteArrayOutputStream();

should be replaced with something like:
if (systemExclusive == null) systemExclusive = new ByteArrayOutputStream();

I checked this fix with my device - it can now get the whole sysex message longer than 3 bytes.

At the moment I finally can receive the preset names from my line 6 pocket pod.

from usb-midi-driver.

kshoji avatar kshoji commented on June 3, 2024

Thanks. I have confirmed the bug, and fixed.
Now, I'll close this issue.

from usb-midi-driver.

Related Issues (20)

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.