実践KSP

MIDI CCの送受信

on init
declare ui_knob $exp (0,127,1) set_control_par (get_ui_id($exp),$CONTROL_PAR_DEFAULT_VALUE,127)
end on
on controller { recieve }
if ($CC_NUM = 11)
$exp := %CC[$CC_NUM]
end if
end on
on ui_control($exp) { send }
set_controller(11,$exp)
end on

状態の保存

on init
declare ui_knob $a (0,127,1)
set_control_par (get_ui_id($a),$CONTROL_PAR_DEFAULT_VALUE,80)
make_persistent ($a)
end on