ΣSigmaStudio Ask AI Русский Log in

Need an Example on how to use the GET_OBJECT_PROPERTY in python to retrieve a parameter value.

SigmaDSP & SigmaStudio clffrd Feb 28, 2023 00:00 2 replies Original on forum ↗
Thread Summary

Thread Summary

The user encountered an error while trying to read the gain block volume value using the `GET_OBJECT_PROPERTY` method in Python. The solution involved declaring the output variable as a win32com variant array, which resolved the error and allowed the function to execute successfully. However, the output variable remained `None`, suggesting further configuration may be needed.
AI Generated Content
Subscribe
clffrd Question
Feb 28, 2023 00:00

Hello,

I am trying to read back the volume value of my gain block in my project using python scripts.

when i set the gain using :

result=ss_server.SET_OBJECT_PROPERTY("setControlValue", "vol", [0, 0, "Gain", value])

it works absolutely fine.

But when trying to read the property using :

x = None

ss_server.GET_OBJECT_PROPERTY("getControlValue", "vol", x, [0,0,"Gain"])

it returns me an error:

the syntax on the documentation is :

can some one show me an example of how to use the GET_OBJECT_PROPERTY method ??

Edit Notes
typos and added api documentation

[edited by: clffrd at 4:53 PM (GMT -5) on 28 Feb 2023]

software

sigmaStudio 4.7

sigma studio 4.7

python

scripting

pastedimage1677602791871v1.png
pastedimage1677602791871v1.png
pastedimage1677603269569v1.png
pastedimage1677603269569v1.png
clffrd Reply
Mar 1, 2023 00:00

I have got an update:

y = None
z = ss_server.GET_OBJECT_PROPERTY("getControlValue", "filt", [y], [0,0,'Gain'])

print(z)

I modified my code like this and i don't get the error anymore and i get a true in my z, which means that the function has successfully executed. However my y is still None after the function execution. I think i have to design my object slightly differently , but it would really help to have an example.

clffrd Reply
Mar 1, 2023 00:00

Updating my own thread now since i have a working solution.

the output var has to be declared as a win32com variant array. it would be useful if this was updated in the documentation.