SmcWSetHoldOff


Function

Outputs hold off signal.

Format

Ret = SmcWSetHoldOff( Id, AxisNo, HoldOff )

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 axis number.

HoldOff [ VB.NET: Short ] [ C, C++: short ] [ C#: short ] [ Python: ctypes.c_short ]
Set hold off signal.

0

Hold the axis

1

Release the holding of axis

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

Remarks

The signal can be changed only for the bit which are set to "hold off signal" in settings of CtrlTypeOut1 to CtrlTypeOut3 in SmcWSetCtrlTypeOut function.

It can not be executed while motor is already in motion.

Example

The holding of axis number 1 is released.

VB.NET
Dim Ret As Integer
Dim HoldOff As Short
HoldOff = 1
Ret = SmcWSetHoldOff( Id , 1, HoldOff )

C, C++
long Ret;
short HoldOff;
HoldOff = 1;
Ret = SmcWSetHoldOff( Id , 1, HoldOff );

C#
int Ret;
short HoldOff;
HoldOff = 1;
Ret = Smc.WSetHoldOff( Id , 1, HoldOff );

Python
Ret = ctypes.c_long()
HoldOff = ctypes.c_short()
HoldOff.value = 1
Ret.value = csmc.SmcWSetHoldOff( Id , 1, HoldOff )

See Also

SmcWGetHoldOff