Garageband's nunits cc 123 all notes off does not work

I have this software in a MacOS app that provides an All Notes Off button. When I start notes playing with the sendNoteOn function, I cannot get GarageBand to quiet/stop playing the notes.

func notesOffFor(channel: UInt8 ) {

guard connected, let dest = destination else { return }

var packetList = MIDIPacketList()

var packet = MIDIPacketListInit(&packetList)

let midiStatus : UInt8 = 0xB0 | (channel & 0xF)

let allNotesOff = [midiStatus, 123, 0]


packet = MIDIPacketListAdd(&packetList, 1024, packet, 0, allNotesOff.count, allNotesOff)

print("created packet: \(packet.pointee.length)=>\(packet.pointee.data)")


let res = MIDISend(outputPort, dest, &packetList)

print("sending all notes off for channel=\(channel) returns=\(res)")

}


func notesOffFor(channel: UInt8 ) {

guard connected, let dest = destination else { return }

var packetList = MIDIPacketList()


var packet = MIDIPacketListInit(&packetList)

let midiStatus : UInt8 = 0xB0 | (channel & 0xF)

let allNotesOff = [midiStatus, 123, 0]


packet = MIDIPacketListAdd(&packetList, 1024, packet, 0, allNotesOff.count, allNotesOff)

print("created packet: \(packet.pointee.length)=>\(packet.pointee.data)")


let res = MIDISend(outputPort, dest, &packetList)

print("sending all notes off for channel=\(channel) returns=\(res)")

}


These functions show a zero return code, and the notes I am testing with all play on separate tracks, and I have a loop that calls notesOffFor(), for all channels 0-15. Is it not possible to use this CC for the built in Midi controller in GarageBand?

Posted on Jul 22, 2025 06:17 AM

Reply

There are no replies.

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

Garageband's nunits cc 123 all notes off does not work

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.