Hi everyone,
I've been playing a bit with a Csound handpan synth from here and I've used the r_cycle external to make a handpan with my Launchpad (the patch is not very complicated so I didn't try to make it neat, sorry!).
The csound patch maps specific MIDI notes to the synth according to a scale, and the Pd patch lights up the pads so each colored group of pads sends the corresponding MIDI note to CSound:
I'm super happy with it, but the next step is to make it configurable: the csound patch contains many different scales defined with giNotes = ftgen(0, 0, -<number of notes>, -2, <list of note numbers> )
:
; B Kurd
;giNotes = ftgen(0, 0, -10, -2, 47, 54, 55, 57, 59, 61, 62, 64, 66, 69)
; B Golden Arcadia
giNotes = ftgen(0, 0, -9, -2, 47, 51, 54, 58, 59, 61, 65, 66, 68)
So instead of editing the CSD file and changing the color mapping of the launchpad when I want to change scale, I would like to send a list/array/table of note numbers from Pd to [csound6~] via a message (and adjust the MIDI notes sent by the launchpad at the same time).
I know basically nothing about Csound, so I've read up and found examples using chnget
/chnset
or invalue
which seem relatively straightforward to change the value of a single int variable. However I don't really have any idea on how to pass the list/array of scale notes using chnset or invalue, or if there is a better way to do it.
Maybe someone around here has an idea? Thanks for reading so far in any case