Csound Csound-dev Csound-tekno Search About

[Csnd] Passing args via cmdline

Date2013-08-03 21:33
FromDavid Akbari
Subject[Csnd] Passing args via cmdline
Hello List,

Is there a simple way to pass string variables or macro definitions to an orchestra via commandline? If it matters I am using Csound 5.17 on RPi. My ideal use case is to have a line somewhere in the orc like:

"al, ar  diskin2  $FILE, 1, 0, 1"

Where the $FILE definition is passed via commandline.

I could not find a clear answer after looking here:

Cheers,
David

Date2013-08-03 21:37
FromLuis Antunes Pena
SubjectRe: [Csnd] Passing args via cmdline
Hello David,

are you looking for this:

--omacro:XXX=YYY
Set orchestra macro XXX to value YYY

Best,
Luís


Am 03.08.13 22:33, schrieb David Akbari:
Is there a simple way to pass string variables or macro definitions to an orchestra via commandline? If it matters I am using Csound 5.17 on RPi. My ideal use case is to have a line somewhere in the orc like:

Date2013-08-03 21:43
FromDavid Akbari
SubjectRe: [Csnd] Passing args via cmdline
Thanks Luís!

That seems to help as I see the macro being registered on compilation but curiously doesn't overwrite the defined macro in instr 0 space? Is the solution to use --omacro:XXX=YYY in the <CsOptions> and just pass it via commandline?


On Sat, Aug 3, 2013 at 3:37 PM, Luis Antunes Pena <k_o_m_p@yahoo.de> wrote:
Hello David,

are you looking for this:

--omacro:XXX=YYY
Set orchestra macro XXX to value YYY

Best,
Luís


Am 03.08.13 22:33, schrieb David Akbari:
Is there a simple way to pass string variables or macro definitions to an orchestra via commandline? If it matters I am using Csound 5.17 on RPi. My ideal use case is to have a line somewhere in the orc like: