SmcWGetCtrlTypeOut


Function

Retrieves the settings of type of control output signal.

Format

Ret = SmcWGetCtrlTypeOut( Id, AxisNo, CtrlOut1, CtrlOut2, CtrlOut3)

Parameters

Id [ VB.NET: Short ] [ C, C++: short ] [ C#: short ] [ Python: ctypes.c_short ]
SSpecify the Deice ID retrieved by SmcWInit function.

AxisNo [ VB.NET: Short ] [ C, C++: short ] [ C#: short ] [ Python: ctypes.c_short ]
Specify the axis number.

CtrlOut1 [ VB.NET: Short ] [ C, C++: short * ] [ C#: out short ] [ Python: ctypes.POINTER(ctypes.c_short) ]
Specify the address of a variable to store the type of control output signal OUT1.

CtrlOut2 [ VB.NET: Short ] [ C, C++: short * ] [ C#: out short ] [ Python: ctypes.POINTER(ctypes.c_short) ]
Specify the address of a variable to store the type of control output signal OUT2.

CtrlOut3 [ VB.NET: Short ] [ C, C++: short * ] [ C#: out short ] [ Python: ctypes.POINTER(ctypes.c_short) ]
Specify the address of a variable to store the type of control output signal OUT3.

Type of control output signal    Setting for OUT1 to OUT3

0

General-purpose output

1

Alarm clear signal

2

Deviation counter clear signal (ERC)

5

Hold off signal

Return Value

Ret [ VB.NET: Integer ] [ C, C++: long ] [ C#: int ] [ Python: ctypes.c_long ]

0

Terminated normally

Non-zero

Terminated abnormally

See also: Error code details

Initial Value

0 : Control outputs OUT1 to OUT3 are all used as general-purpose outputs

Remarks

This function can be executed even if the axis is in operation.

Example

The set up information of the control output signal form of axis number 1 is acquired.

VB.NET
Dim Ret As Integer
Dim CtrlOut1 As Short
Dim CtrlOut2 As Short
Dim CtrlOut2 As Short
Ret = SmcWGetCtrlTypeOut( Id , 1, CtrlOut1 , CtrlOut2 , CtrlOut3)

C, C++
long Ret;
short CtrlOut1;
short CtrlOut2;
short CtrlOut3;
Ret = SmcWGetCtrlTypeOut( Id , 1, &CtrlOut1 , &CtrlOut2 , &CtrlOut3);

C#
int Ret;
short CtrlOut1;
short CtrlOut2;
short CtrlOut3;
Ret = Smc.WGetCtrlTypeOut( Id , 1, out CtrlOut1 , out CtrlOut2 , out CtrlOut3);

Python
Ret = ctypes.c_long()
CtrlOut1 = ctypes.c_short()
CtrlOut2 = ctypes.c_short()
CtrlOut3 = ctypes.c_short()
Ret.value = csmc.SmcWGetCtrlTypeOut( Id , 1, ctypes.byref(CtrlOut1) , ctypes.byref(CtrlOut2) , ctypes.byref(CtrlOut3))

See Also

SmcWSetCtrlTypeOut