Function
Sets the logic of origin input.
Format
Ret = SmcWSetOrgLog( Id, AxisNo, OrgLog )
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.
OrgLog
[ VB.NET: Short ] [ C, C++: short ] [ C#: short ] [ Python: ctypes.c_short
]
Set the logic of origin input.
[ 0 | 0 | 0 | 0 | 0 | 0 | Z | ORG ] Available range:0 to 3
Z |
0:Falling edge 1:Rising edge |
ORG |
0:Negative logic 1:Positive logic |
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
Z |
0:Falling edge |
ORG |
0:Negative logic |
Remarks
This function cannot be executed when the device is in operation.
After "Initial Setting function"
is executed, it is necessary to execute SmcWSetInitParam.
Refer to "About Initial
Setting function".
Example
The starting point input logic of axis number 1 is set to "Positive logic and Rising edge".
VB.NET
Dim Ret As Integer
Dim OrgLog As Short
OrgLog = 1
Ret = SmcWSetOrgLog( Id , 1, OrgLog )
C, C++
long Ret;
short OrgLog ;
OrgLog = 1;
Ret = SmcWSetOrgLog( Id , 1, OrgLog );
C#
int Ret;
short OrgLog ;
OrgLog = 1;
Ret = Smc.WSetOrgLog( Id , 1, OrgLog );
Python
Ret = ctypes.c_long()
OrgLog = ctypes.c_short()
OrgLog.value = 1
Ret.value = csmc.SmcWSetOrgLog( Id , 1, OrgLog )
See Also