AxisSetReferencingCamSignal

AxisSetReferencingCamSignal 1:

AxisSetReferencingCamSignal sets the reference cam signal in nDeCtrlDWord according to the bReferencingCamSignal input, and returns nDeCtrlDWord as the result of the function.

FUNCTION AxisSetReferencingCamSignal: DWORD

VAR_INPUT
    nDeCtrlDWord          : DWORD;
    bReferencingCamSignal : BOOL;
END_VAR

nDeCtrlDWord : Control-Word from the cyclic axis interface from the PLC to the NC

bReferencingCamSignal : Reference cam signal requiring to be set [FALSE,TRUE]

 

Function result: nDeCtrlDWord

Example

PROGRAM MAIN
VAR
    PlcToNc1            AT %QB1000 : PLCTONC_AXLESTRUCT;
    NcToPlc1            AT %IB1000 : NCTOPLC_AXLESTRUCT;
    ReferencingCamInput AT %IX0.0  : BOOL;
END_VAR
PlcToNc1.nDeCtrlDWord := AxisSetReferencingCamSignal(PlcToNc1.nDeCtrlDWord, ReferencingCamInput );

Requirements

Development environment

Target system type

PLC libraries to include

TwinCAT v2.7.0

PC (i386)

TcNcUtilities.Lib

TwinCAT v2.8.0

PC (i386)

TcNC.Lib