JackoMidiOutConnect

JackoMidiOutConnect — Creates a MIDI connection from Csound to a Jack port.

Description

Plugin opcode in jacko. This opcode is part of the plugin repository and has to be installed separately. The plugin repository can be found here: https://github.com/csound/plugins

In the orchestra header, creates a connection from a Jack MIDI output port inside this instance of Csound to an external Jack MIDI input port.

Syntax

JackoMidiOutConnect ScsoundPortName, SexternalPortName

Initialization

ScsoundPortName -- The short name ("portname") of the internal Jack MIDI output port.

SexternalPortName -- The full name ("clientname:portname") of an external Jack MIDI input port.

Performance

The actual MIDI data must be written with the JackoMidiOut or JackoNoteOut opcodes.

[Note] Note
works with an already running Jack daemon. Do not use -+rtaudio=jack in CsOptions

Examples

Here is an example of the JackoMidiOutConnect opcode. It uses the file JackoNoteOut.csd.

Example 498. Example of the JackoMidiOutConnect opcode.

See the sections Real-time Audio and Command Line Flags for more information on using command line flags.

<CsoundSynthesizer>
<CsOptions>
-n ; no sound
</CsOptions>
<CsInstruments>

sr      = 48000 ; one possible Jack setting
ksmps   = 128
nchnls  = 2

; by Menno Knevel - 2023

JackoInit   "default", "csound6"						; Csound as a Jack client
JackoMidiOutConnect "midioutMAUDIO", "M-Audio-Delta-1010:midi/capture_1"	; create 1 Midi port
JackoMidiOutConnect "midioutEDIROL", "UM-3:midi/capture_1"			; create 2nd Midi port

	instr 1	; send notes to the M-Audio Midi port	

irandom     random      30, 80
JackoNoteOut "midioutMAUDIO", 1-1, irandom, 100		    ; channel range 0-15
	endin

      instr 2 ; send notes to Edirol Midi port	

irandom     random      30, 80
JackoNoteOut "midioutEDIROL", 1-1, irandom, 100
	endin

</CsInstruments>
<CsScore>
s
i1 1 .1
i1 2 1
i1 4 2
s
i2 1 .1
i2 2 1
i2 4 2
e 
</CsScore>
</CsoundSynthesizer>


See also

Jacko Opcodes

Credits

By: Michael Gogins 2010