# Extraneous MIDI from Logic Pro X \[128 123 64\] messages

**URL:** <https://forum.juce.com/t/extraneous-midi-from-logic-pro-x-128-123-64-messages/45609>\
**Category:** General JUCE discussion\
**Created:** [April 20, 2021, 7:40am UTC](https://forum.juce.com/t/extraneous-midi-from-logic-pro-x-128-123-64-messages/45609 "2021-04-20T07:40:58Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![martinrobinson-2](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/martinrobinson-2/32/630_2.png) [@martinrobinson-2](https://forum.juce.com/u/martinrobinson-2)\
**Post date:** [April 20, 2021, 7:40am UTC](https://forum.juce.com/t/extraneous-midi-from-logic-pro-x-128-123-64-messages/45609/1 "2021-04-20T07:40:58Z")

</div>

I’m wondering if anyone else can reproduce this since it seems unusual, and possibly a bug in Logic Pro X or the Core Audio MIDI classes?

I added the sample logging code from the `MidiBuffer` documentation to the MultiOutSynth example i.e.

```auto
    void processBlock (AudioBuffer<float>& buffer, MidiBuffer& midiBuffer) override
    {
        for (const MidiMessageMetadata metadata : midiBuffer)
            if (metadata.numBytes == 3)
                Logger::writeToLog (metadata.getMessage().getDescription());
...

```

1. On intialisation, Logic Pro X sends a bunch of initial messages, they all make sense (RPN resets etc).
2. Then I play a note and the note on and off make sense
3. Switch Logic Pro X in to the background (back to Xcode) and it sends a bunch of note-offs

This is what I get

```auto
Controller Registered Parameter (fine): 4 Channel 1
Controller Registered Parameter (coarse): 0 Channel 1
Controller Data Entry (coarse): 0 Channel 1
Controller Registered Parameter (fine): 3 Channel 1
Controller Registered Parameter (coarse): 0 Channel 1
Controller Data Entry (coarse): 0 Channel 1
[... etc repeated for each channel ...]

[play a note]
Note on C3 Velocity 98 Channel 1
Note off C3 Velocity 64 Channel 1

[switch to background back to Xcode]
Note off D#8 Velocity 64 Channel 1
Note off D#8 Velocity 64 Channel 1
Note off D#8 Velocity 64 Channel 1
Note off D#8 Velocity 64 Channel 1
Note off D#8 Velocity 64 Channel 1
Note off D#8 Velocity 64 Channel 1
Note off D#8 Velocity 64 Channel 1
Note off D#8 Velocity 64 Channel 1
Note off D#8 Velocity 64 Channel 1
Note off D#8 Velocity 64 Channel 1
Note off D#8 Velocity 64 Channel 1
Note off D#8 Velocity 64 Channel 1
Note off D#8 Velocity 64 Channel 1
Note off D#8 Velocity 64 Channel 1
Note off D#8 Velocity 64 Channel 1
Note off D#8 Velocity 64 Channel 1
Note off D#8 Velocity 64 Channel 1
Note off D#8 Velocity 64 Channel 1

```

Those note-offs are data [128 123 64]. That “123” has a certain whiff since it’s the CC# for “all notes off”.

Any ideas?

---

<div class="post-metadata">

**Author:** ![reuk](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/reuk/32/21494_2.png) [@reuk](https://forum.juce.com/u/reuk)\
**Post date:** [April 20, 2021, 11:24am UTC](https://forum.juce.com/t/extraneous-midi-from-logic-pro-x-128-123-64-messages/45609/2 "2021-04-20T11:24:30Z")

</div>

I just gave this a go with both the AudioPluginDemo, and with the MultiOutSynthPlugin. In both cases, I see some controller and sysex messages sent after initialisting the plugin instance, but I don’t see any `[128 123 64]` messages when switching between applications.

I tested with the AU versions of these plugins. Are you using AU, or AUv3? Also, which Logic version are you using?

Is there anything else notable about your setup, such as specific midi controllers or drivers? Does the issue happen every time you switch between apps?

You could try sticking a breakpoint or some logging in `HandleMidiEvent` in `juce_AU_Wrapper.mm` to check whether the strange events are coming from Logic, or being added accidentally somewhere in the AU wrapper. If you see the D#8 note-off events in `HandleMidiEvent`, then the issue is likely somewhere in Logic.

---

<div class="post-metadata">

**Author:** ![martinrobinson-2](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/martinrobinson-2/32/630_2.png) [@martinrobinson-2](https://forum.juce.com/u/martinrobinson-2)\
**Post date:** [April 20, 2021, 11:32am UTC](https://forum.juce.com/t/extraneous-midi-from-logic-pro-x-128-123-64-messages/45609/3 "2021-04-20T11:32:08Z")

</div>

Thanks for the quick response. I already saw the messages coming from the `HandleMidiEvent` callback from the Core Audio classes, rather than the JUCE AU wrapper. I’m on Logic 10.4.6, just AU (not v3), with this check. I’m not aware of anything unusual installed and have no external controllers connected during this check. I’ll check whether it’s switching between any apps, or just the Logic \> Xcode transition. And delve in to see if I have any unusual drivers

---

<div class="post-metadata">

**Author:** ![reuk](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/reuk/32/21494_2.png) [@reuk](https://forum.juce.com/u/reuk)\
**Post date:** [April 20, 2021, 11:33am UTC](https://forum.juce.com/t/extraneous-midi-from-logic-pro-x-128-123-64-messages/45609/4 "2021-04-20T11:33:08Z")

</div>

It could be a bug in that Logic version. I was testing with 10.6.1 and didn’t see any similar issues.

---

<div class="post-metadata">

**Author:** ![martinrobinson-2](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/martinrobinson-2/32/630_2.png) [@martinrobinson-2](https://forum.juce.com/u/martinrobinson-2)\
**Post date:** [April 20, 2021, 11:36am UTC](https://forum.juce.com/t/extraneous-midi-from-logic-pro-x-128-123-64-messages/45609/5 "2021-04-20T11:36:08Z")

</div>

I’ll grab 10.6.1 now! Thanks
