-

Y_MA_CalculateAngles

Image

This function block calculates the start and traversed angles between line segments using

Parameters

* Parameter Data Type Description Default
VAR_INPUT
B Enable BOOL The function block will continue to execute every scan while Enable is TRUE and there are no errors. FALSE
E ArcDefinitionMode INT There are two ArcDefinitionModes to calculate the start and traversed angle. Mode 0 uses starting point, ending point, and a known center point (XC, YC). Mode 1 uses two coordinates and the radius of an arc that contains the starting and ending points INT#0
E X1 LREAL X coordinate of starting point LREAL#0.0
E Y1 LREAL Y coordinate of starting point LREAL#0.0
E X2 LREAL X coordinate of ending point LREAL#0.0
E Y2 LREAL Y coordinate of ending point
LREAL#0.0
E XC LREAL X coordinate of the center of the circle
LREAL#0.0
E YC LREAL Y coordinate of the center of the circle
LREAL#0.0
E Radius LREAL Radius of an arc that contains both coordinates LREAL#0.0
B Direction BOOL Direction of traversed angle from point 1 to point 2. True is Counter Clockwise and False is Clockwise FALSE
VAR_OUTPUT
B Valid BOOL The Valid output indicates that the function block is operating normally and the outputs of the function block are valid. FALSE
E Error BOOL The Error output is set to TRUE if an error has occurred during the operation of the function block. The output is cleared when the Execute or Enable input becomes FALSE. FALSE
E ErrorID UINT The ErrorID output provides the identifier of the error when there is an active error in the function block execution. The output is cleared when the Execute or Enable input becomes FALSE.
UINT#0
E StartAngle LREAL Angle between X axis and starting point LREAL#0.0
E TraversedAngle LREAL Angle traversed in the direction specified from starting point to ending point LREAL#0.0


Notes

Error Description

See the Function Block ErrorID List.

Example




 


This help information is valid for iCube Engineer Online Help 2025.6

Copyright © 2025 YASKAWA EUROPE GmbH and © 2025 YASKAWA America, Inc.