Update chop constant with DAT

Hi,

I am trying to increment a chop constant value using a DAT.

Using a DAT I can print the value of the chop using:

print (op('constant2')['chan1'])

But I can’t work out how to increment the value of the constant using the DAT.

Ive tried:

op('constant2')['chan1'].par.const0value + 1

and

op('constant2')['chan1'] + 1

and a few other things but i’m not sure what im doing wrong?

Caould anyoen point me in the right direction?
Thanks

in Python, the shorthand syntax to increment a value is +=
So you can use:
op("constant1").par.const0value += 1

1 Like

Thankyou for this nettoyeur much appreciated :slight_smile: