ns=2;s=DEPRAG Smart/Devices/DEPRAG/AST/ActiveDevices/0/ScrewdrivingSequence/CreateOrUpdate
Creates or modifies an existing screwdriving sequence.
In addition to the parameters already explained, the following variables must be created / transferred for the implementation in TwinCAT 3:
VAR
bAstCreateOrUpdate : BOOL;
outputAstCreateOrUpdate : ST_VoidOutputData
hrAstCreateOrUpdate : HRESULT;
fbAst : FB_AST;
END_VAR
hrAstCreateOrUpdate := fbAst.CreateOrUpdate(
bExecute := bAstCreateOrUpdate,
ConnectionHandle := depragSmartConnection.ConnectionHandle,
sDeviceId := '0',
sSequenceJson := ADR('my screwdriving sequence string'),
SizeOfSequenceJson := SIZEOF('my screwdriving sequence string'),
OutputData => outputAstCreateOrUpdate);
IF hrAstCreateOrUpdate <> S_FALSE THEN
bAstCreateOrUpdate := 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".