Information
We are currently investigating an issue with the editor of some pages. Please save your work and avoid to create new pages until this banner is gone.
...
Code Block | ||||||
---|---|---|---|---|---|---|
| ||||||
from Acspy.Clients.SimpleClient import PySimpleClient import maci client = PySimpleClient() compNamecompSpec = 'CLOCKTEST' compInfo = c.availableComponents(compName) if len(compInfo) != 1: print("Problem with the component: there should be one definition.") compInfo = compInfo[0] if not compInfo.reference is None: print("Problem with the component: it is already active.") if len(compInfo.clients) > 0: print("Problem with the component: someone already has a reference to it.") clock = client.getComponent() compInfo = c.availableComponents(compName)[0] if compInfo.reference is None: print("Problem with the component: it should have been activated.") if len(compInfo.clients) != 1: print("Problem with the component: it has not been activated or more than one component/client have a reference to it.") client.releaseComponent(clock.name) compInfo = c.availableComponents(compName)[0] if compInfo.reference is None: print("Problem with the component: it should have been deactivated.") if len(compInfo.clients) > 0: print("Problem with the component: someone still has a reference to it.maci.ComponentSpec("CLOCK1", "*", "*", "*") comp = client.getCollocatedComp(compSpec, False, "CLOCK1") |
...