Controller — Query Methods
Back to Controller.
GetName
def GetName() -> strGet the controller name.
Returns: str — Controller name.
GetControllerType
def GetControllerType() -> intGet the controller type.
Returns: int — Controller type.
GetManufacturer
def GetManufacturer() -> strGet the controller manufacturer.
Returns: str — Controller manufacturer.
GetSeries
def GetSeries() -> strGet the controller series.
Returns: str — Controller series.
GetModel
def GetModel() -> strGet the controller model.
Returns: str — Controller model.
GetActors
def GetActors(itemType: int, itemSubType: int, actorType: int) -> list[CENPyOlpActor]Returns the attached actors of specified type.
Parameters:
| Name | Type | Description |
|---|---|---|
itemType | int | — |
itemSubType | int | — |
actorType | int | — |
Returns: list[CENPyOlpActor] — List of CENPyOlpActor objects, actors that respect the given filters..
GetSensors
def GetSensors(itemType: int, itemSubType: int, sensorType: int) -> list[CENPyOlpSensor]Gets all sensors which are on a controlled item.
Parameters:
| Name | Type | Description |
|---|---|---|
itemType | int | Filter for the controlled items. |
itemSubType | int | Filter for the controlled items, applied together with itemType. |
sensorType | int | Filter for the sensors. |
Returns: list[CENPyOlpSensor] — List of CENPyOlpSensor objects, sensors that respect the given filters.
GetSignalNumber
def GetSignalNumber(signalName: str) -> intSearches for the first signal with the given name, found on a controller signal connection for this controller, and returns its signal number.
Parameters:
| Name | Type | Description |
|---|---|---|
signalName | str | Signal name to search for. |
Returns: int — The signal number of the found signal.
GetUuId
def GetUuId() -> strGets the controller’s unique ID.
Returns: str — Controller’s unique ID.
GetActiveToolFrameIndex
def GetActiveToolFrameIndex() -> intGets the index of the active tool frame.
Returns: int — Active tool frame index.
GetActiveBaseFrameIndex
def GetActiveBaseFrameIndex() -> intGets the index of the active base frame.
Returns: int — Active base frame index.
GetActiveToolFrameMatrix
def GetActiveToolFrameMatrix() -> CENPyOlpMatrixGets the matrix of the active tool frame.
Returns: CENPyOlpMatrix — Active tool frame matrix.
GetActiveBaseFrameMatrix
def GetActiveBaseFrameMatrix() -> CENPyOlpMatrixGets the matrix of the active base frame.
Returns: CENPyOlpMatrix — Active base frame matrix.
GetActiveToolFrameName
def GetActiveToolFrameName() -> strGet the tool frame name of the active tool.
Returns: str — Tool frame name of the active tool.
GetActiveToolResourceName
def GetActiveToolResourceName() -> strGet the resource name of the active tool.
Returns: str — Resource name of the active tool.
GetResources
def GetResources(itemType: int, itemSubType: int) -> list[CENPyOlpResource]Gets resources that are controlled by this controller.
Parameters:
| Name | Type | Description |
|---|---|---|
itemType | int | Item type to filter the resources by. |
itemSubType | int | Item sub type to filter the resources by |
Returns: list[CENPyOlpResource] — List of CENPyOlpResource objects, resources that respect the given filters.
GetMainResourcesMaxTCPFeedrate
def GetMainResourcesMaxTCPFeedrate() -> floatReturns the max TCP feedrate of main resource of the controller.
Returns: float — Value of the maximum resource feedrate.
IsTeamController
def IsTeamController() -> boolReturns whether the controller is a team controller.
Returns: bool — True if team controller is selected.
GetTeamController
def GetTeamController() -> CENPyOlpControllerReturns the team controller current controller is connected to. If there is no team controller, returns a nullptr.
Returns: CENPyOlpController — Connected team controller.
GetControllers
def GetControllers() -> list[CENPyOlpController]Returns all controllers connected to this controller.
Returns: list[CENPyOlpController] — List of CENPyOlpController objects, controllers connected to this one.
GetProgramNames
def GetProgramNames() -> listReturns a list of program names on this controller.
Returns: list — List of program names.
GetLogicPortByName
def GetLogicPortByName(portName: str) -> CENPyOlpPortReturns the first logic port found on the current controller with the given name.
Parameters:
| Name | Type | Description |
|---|---|---|
portName | str | Logic port name to search for. |
Returns: CENPyOlpPort — Olp port.
GetOutputDirectory
def GetOutputDirectory() -> strReturns the download output directory of the program. First gets the root download directory of an active program, and if it is empty, gets the output directory from the translator.
Returns: str — File path to the output directory.
GetEtwoLanguage
def GetEtwoLanguage() -> strReturns the language setting of E2 as a String (de-DE, en-US, fr-FR, ja-JP, zh-CN).
Returns: str — the Language String.
GetAttributeByName
def GetAttributeByName(attributeName: str) -> CENPyOlpAttributeGets a user-defined attribute by the given name.
Parameters:
| Name | Type | Description |
|---|---|---|
attributeName | str | Name of the attribute to find. |
Returns: CENPyOlpAttribute — Olp attribute.
GetAttributeIntegerByName
def GetAttributeIntegerByName(attributeName: str) -> CENPyOlpAttributeIntGets the Integer attribute by the given name.
Parameters:
| Name | Type | Description |
|---|---|---|
attributeName | str | Name of the attribute to find. |
Returns: CENPyOlpAttributeInt — Integer attribute.
GetAttributeDoubleByName
def GetAttributeDoubleByName(attributeName: str) -> CENPyOlpAttributeDoubleGets the Double attribute by the given name.
Parameters:
| Name | Type | Description |
|---|---|---|
attributeName | str | Name of the attribute to find. |
Returns: CENPyOlpAttributeDouble — Double attribute.
GetAttributeStringByName
def GetAttributeStringByName(attributeName: str) -> CENPyOlpAttributeStringGets the String attribute by the given name.
Parameters:
| Name | Type | Description |
|---|---|---|
attributeName | str | Name of the attribute to find. |
Returns: CENPyOlpAttributeString — String attribute.
GetAttributeBoolByName
def GetAttributeBoolByName(attributeName: str) -> CENPyOlpAttributeBoolGets the Bool attribute by the given name.
Parameters:
| Name | Type | Description |
|---|---|---|
attributeName | str | Name of the attribute to find. |
Returns: CENPyOlpAttributeBool — Bool attribute.
GetLastGeneratedFilePathsFromDownload
def GetLastGeneratedFilePathsFromDownload() -> listGets the absolute file paths generated during the last download.
Returns: list — Absolute paths to the last generated files. It is empty if the download is not done yet.
GetLastSelectedFilePathsFromUpload
def GetLastSelectedFilePathsFromUpload() -> listGets the absolute file paths selected during the last upload.
Returns: list — Absolute paths to the last selected files. It is empty if the upload is not done yet.
GetWeldingDataSetsFromDataBase
def GetWeldingDataSetsFromDataBase() -> listGet defined welding data sets from weld database of the active controller
Returns: list — Defined welding data sets from weld database of the active controller.
GetActiveProgram
Since R2025.2.4
def GetActiveProgram() -> CENPyOlpProgramGet active controller program.
Returns: CENPyOlpProgram — Active created program. May return None if there is no active program.
GetPrograms
Since R2025.2.4
def GetPrograms() -> list[CENPyOlpProgram]Returns a list of programs on this controller.
Returns: list[CENPyOlpProgram] — List of programs.