ns=2;s=DEPRAG Smart/Devices/DEPRAG/AST/ActiveDevices/0/Settings/ScrewdrivingRelated/SaveScrewdrivingRelatedSetting
The command sets the settings that affect the screwdriving process.
In addition to the parameters already explained, the following variables must be created / transferred for the implementation in TwinCAT 3:
VAR
bAstSaveScrewdrivingRelatedSetting : BOOL;
outputAstSaveScrewdrivingRelatedSetting : ST_VoidOutputData;
hrAstSaveScrewdrivingRelatedSetting : HRESULT;
screwdrivingRelatedSetting : ST_ScrewdrivingRelatedSettingSmart := (
MainDirection := MainDirection.Right,
SpeedReduction := ActiveInactiveEnum.Inactive,
StartMode := StartMode.StartScrewdriver,
PrgChoice := ProgramChoice.PgChoiceSetup,
StartEnable := StartEnable.Inactive,
StartEnableMode := StartEnableMode.SEInternalLogic,
PrgHandtool1 := 1,
PrgHandtool2 := 2,
ProcessDisplay := ProcessDisplay.ProcessDisplay1,
StartSignalTimeout := 0,
ReloadDurationInMilliseconds := 50,
CanReloadByDisplay := ActiveInactiveEnum.Inactive);
fbAst : FB_AST;
END_VAR
hrAstSaveScrewdrivingRelatedSetting := fbAst.SaveScrewdrivingRelatedSetting(
bExecute := bAstSaveScrewdrivingRelatedSetting,
ConnectionHandle := depragSmartConnection.ConnectionHandle,
sDeviceId := '0',
ScrewdrivingRelatedSettingSmart := screwdrivingRelatedSetting,
OutputData => outputAstSaveScrewdrivingRelatedSetting);
IF hrAstSaveScrewdrivingRelatedSetting <> S_FALSE THEN
bAstSaveScrewdrivingRelatedSetting := FALSE;
END_IF
For examples and explanations regarding the calls of nodes via Siemens TIA Portal please refer to the sub-menu "Siemens TIA Portal" in section "Getting Started".