TB_SyncCam_Init

Representation in FBD

General Information

With this module, the synchronous movement of the TB_SyncLin und TB_SyncRot technology modules can be replaced. By default, a straight line is used so that the axis moves in sync with the master with regard to both angle and velocity.

The following conditions are to be complied with for user synchronization cams.
-The slope at the beginning and end must be the same.
-The curve at the beginning and end must be zero.
-The cam must consist of 512 data points

The cam must be normalized to 0 to 16,777,216 in the x- and y-directions.

x-direction:
512 data points for the x-positions [0]0, [1]32,768, [2]65,536, …, [511]16,744,448 are specified, and the accompanying y-value is saved in the _SyncCam table. The x-value is not saved.

y-direction:
The y-value for the first x-position is _SyncCam[0] = 0. The value is always 0. The last value of the cam would be the 513th value, i.e. _SyncCam[512] = 16,777,216. Since the cam is only defined up to _SyncCam[511], however, the points are to be normalized in such a way that the 513th value is 16,777,216. For a simple straight line, _SyncCam[511] is thus 16,744,448.

When using the user synchronization cam, note that the SEP may occur at the earliest at the end of the user synchronization cam, as otherwise a jerk or impact could result upon reversing. The movement after the user synchronization cam up to the SEP occurs with a straight line.

Recommended task: Cyclic, one-time execution during program start or change of cam
Libraries used: TECH_TYPES_xxbd05 or greater

InOut Parameter

Marking: Data type: Description:
_SyncCam CAM_POINTS Data points of the normalized user synchronization cam.
_SyncDat TB_SYNC_TYPE Initialization parameter for the TB_SyncRot and TB_SyncLin modules.

Input Parameter

Marking: Data type: Description:
x_Enable BOOL TRUE: The user synchronization cam is initialized and prepared for use with TB_SyncRot and TB_SyncLin.
di_SX_Cam DINT Scale of the normalized cam in x-direction in user master units.
di_SY_Cam DINT Scale of the normalized cam in y-direction in user units.

Output Parameter

Marking: Data type: Description:
x_Ok BOOL TRUE: User synchronization cam available.
i_Result INT Message number of the module. See error table.
s_ResTxt STRING Message text of the module.
i_Result s_ResTxt Description
0 TB_SyncCam_Init: Not Active Module is not active (if x_Enable = FALSE)
0 TB_SyncCam_Init ok Execution complete successfully (if x_Enable = TRUE).
-10 Error: SX_Cam <= 0! The scale of the master axis may not be zero or negative.
-11 Error: SY_Cam <= 0! The scale of the following axis may not be zero or negative.