Skip to content

control_io_interfaceControlIoInterfaceControlIoInterfacecontrol_io_interfaceT_control_io_interfaceπŸ”—

Short descriptionπŸ”—

control_io_interfaceControlIoInterfaceControlIoInterfacecontrol_io_interfaceT_control_io_interface β€” Perform an action on the I/O interface.

SignatureπŸ”—

control_io_interface( string IOInterfaceName, string Action, string Argument, out string Result )void ControlIoInterface( const HTuple& IOInterfaceName, const HTuple& Action, const HTuple& Argument, HTuple* Result )static void HOperatorSet.ControlIoInterface( HTuple IOInterfaceName, HTuple action, HTuple argument, out HTuple result )def control_io_interface( iointerface_name: str, action: str, argument: MaybeSequence[Union[int, float, str]] ) -> Sequence[Union[int, float, str]]

Herror T_control_io_interface( const Htuple IOInterfaceName, const Htuple Action, const Htuple Argument, Htuple* Result )

static HTuple HIODevice::ControlIoInterface( const HString& IOInterfaceName, const HString& Action, const HTuple& Argument )

static HTuple HIODevice::ControlIoInterface( const HString& IOInterfaceName, const HString& Action, const HString& Argument )

static HTuple HIODevice::ControlIoInterface( const char* IOInterfaceName, const char* Action, const char* Argument )

static HTuple HIODevice::ControlIoInterface( const wchar_t* IOInterfaceName, const wchar_t* Action, const wchar_t* Argument ) (Windows only)

static HTuple HIODevice.ControlIoInterface( string IOInterfaceName, string action, HTuple argument )

static HTuple HIODevice.ControlIoInterface( string IOInterfaceName, string action, string argument )

DescriptionπŸ”—

control_io_interfaceControlIoInterface performs an action on the I/O interface. The supported parameters are interface-specific and listed in the corresponding documentation of the used I/O interface that can be found in the directory doc/html/reference/io.

The special value 'keep_open'"keep_open" for Actionactionaction is used to control when the interface should be unloaded. If Argumentargumentargument is set to 'true'"true", the interface will remain loaded until the HALCON process is terminated. If it is set to 'false'"false", the interface will be unloaded as soon as all its device instances are closed. This is the default behavior.

AttentionπŸ”—

On Windows Systems, error dialog boxes from the operating system can occur when dependency modules of the interface are not found, e.g., the according SDK was not installed. The occurrence of the error boxes can be controlled by setting Windows’ Error Mode. Please refer to the description of SetErrorMode within the Windows MSDN documentation.

Execution informationπŸ”—

Execution information
  • Multithreading type: reentrant (runs in parallel with non-exclusive operators).

  • Multithreading scope: global (may be called from any thread).

  • Processed without parallelization.

ParametersπŸ”—

IOInterfaceNameIOInterfaceNameiointerface_name (input_control) string β†’ (string)HTuple (HString)HTuple (string)strHtuple (char*)

HALCON I/O interface name.

Default: [][]
Suggested values: 'ADLINK-DAQPilot', 'ADLINK-EOS', 'Advantech', 'Contec', 'Hilscher-cifX', 'Interface', 'Linux-GPIO', 'NIDAQmx', 'OPC_Classic', 'OPC_UA'"ADLINK-DAQPilot", "ADLINK-EOS", "Advantech", "Contec", "Hilscher-cifX", "Interface", "Linux-GPIO", "NIDAQmx", "OPC_Classic", "OPC_UA"

Actionactionaction (input_control) string β†’ (string)HTuple (HString)HTuple (string)strHtuple (char*)

Name of the action to perform.

Argumentargumentargument (input_control) string(-array) β†’ (string / integer / real)HTuple (HString / Hlong / double)HTuple (string / int / long / double)MaybeSequence[Union[int, float, str]]Htuple (char* / Hlong / double)

List of arguments for the action.

Default: [][]

Resultresultresult (output_control) string-array β†’ (string / integer / real)HTuple (HString / Hlong / double)HTuple (string / int / long / double)Sequence[Union[int, float, str]]Htuple (char* / Hlong / double)

List of results returned by the action.

ResultπŸ”—

If the parameters are valid, the operator control_io_interfaceControlIoInterface returns the value 2 (H_MSG_TRUE). If necessary an exception is raised. In this case an extended error information may be set and can be queried with the operator get_extended_error_infoGetExtendedErrorInfo.

Combinations with other operatorsπŸ”—

Combinations

See also

query_io_interfaceQueryIoInterface

ModuleπŸ”—

Foundation