182
Manual – IPOSplus®
14
SEW standard structures
Compiler – Programming
14.8 SEW standard structures
SEW standard structures provide ready-made structures for commands that are depen-
dent on structures.
The following table shows a list of the standard structures available for each specific
statement. For the corresponding elements, refer to the description of the respective
command, see section Standard functions (page 208).
These standard structures are used as follows. First, a variable is declared as the struc-
ture variable in the declaration part. Then the elements of the structure are addressed
as explained in the following example. The structure is addressed within the command
by using the name of the structure variable without additions.
Instruction type Standard structure
_GetSys GSAINPUT
GSAOUTPUT
GSCAM
GSCAM_EXT
CAM_EXT_OUT
GSPODATA3
GSACTSPEEDEXT
GSPODATA10
_MovCommDef (only for MQx) MOVCOM
MCPDATA
MCPARDATA
_MoviLink MOVLNK
MLDATA
_SBusCommDef SCREC
SCTRACYCL
SCTRCYCL
_SetSys SSPOSRAMP
SSPOSSPEED
SSPIDATA3
SSPIDATA10
// Declare
SSPOSSPEED rapid speed, slow speed;
// Initiate
rapid_speed.cw = 14000; // rapid speed cw 1400 rpm
rapid_speed.ccw = 12500; // rapid speed ccw 1250 rpm
slow_speed.cw = 3000; // slow speed cw 300 rpm
slow_speed.ccw = 4500; // slow speed ccw 450 rpm
// set rapid speed
_SetSys( SS_POSSPEED,rapid speed );
// set slow speed
_SetSys( SS_POSSPEED,slow speed );