Here is the Lua scripts I got for the Ensonig Mirage.
The oscPairSelect1 and oscPairSelect2 send a osc select sysex message and then stay quite a bit. Without the if contruct the select message would be send directly with the value update and the Mirage would only update the osc select parameters.
I tried to incorporate some kind of sleep/wait and this is the way I got it to work.
Now the getPatchNumberByte function does not work. I can really use some hints here.
What is the numerical id for a sysex message? I checked in the docs and in the schema but cannot find it. tried both 4 and 5.
parameterNumber = 40 is a control for which Patch you want to edit. Named “PATCH SELECT”. And the patch request needs to request this patch.
But when I press the patch select button I get always “00 00 23 01 43 04 00”
mirageSoundProcessDeviceId = 9
incCount = 1
function getPatchNumberByte()
-- parameterNumber 40 is patch select in the json file
local parameterNumber = 40
-- messagetype I am guessing as I cannot find the numerical id of sysex in the docs
patchNumber = parameterMap.get (mirageSoundProcessDeviceId, 4, parameterNumber )
return (patchNumber)
end
function oscPairSelect1()
device = devices.get (mirageSoundProcessDeviceId)
if incCount == 1 then
midi.sendSysex (PORT_1, { 0, 0, 35, 1, 67, 60, 1, 0 })
incCount = incCount + 1
end
if (incCount == 15) then
incCount = 1
end
if incCount > 1 then
incCount = incCount + 1
end
end
function oscPairSelect2()
device = devices.get (mirageSoundProcessDeviceId)
if incCount == 1 then
midi.sendSysex (PORT_1, { 0, 0, 35, 1, 67, 60, 2, 0 })
incCount = incCount + 1
end
if (incCount == 15) then
incCount = 1
end
end
Ensoniq Mirage Soundprocess OS.epr (75.1 KB)