Re: LAU midiMassageReceived cause crash

Home Forums General Programming LAU midiMassageReceived cause crash Re: LAU midiMassageReceived cause crash

#3967
atom
Keymaster
    • Topics: 159
    • Replies: 2945
    • Total: 3104
    • ★★★★★

    It’s weird, i think there is something weird happening with the naming scheme here. Try to create a new panel, add a method call it myMethod and paste the code from the old method, so that it look like this:
    [code:6dx2hvce]


    — Called when a panel receives a midi message (does not need to match any modulator mask)

    myMethod = function(midiMessage)

    data = midiMessage:getLuaData()

    console (string.format ("midiIncomming size: %d", data:getSize()))
    console ("HEX: "..data:toHexString(1))

    for i=0,data:getSize()-1 do
    console (string.format("BYTE[%d]: %d/%x", i, data:getByte(i), data:getByte(i)))
    end

    end
    [/code:6dx2hvce]

    but try it on a new panel and see if that keeps crashing.

    Ctrlr