beckhoff TS6420 — 7.1.4 FB_DBOdbcConnectionAdd

PLC API VAR_INPUT VAR_INPUT sNetID :T_AmsNetId; eDBType :E_DBTypes; eDBValueType :E_DBValueType; sDBDriver :T_MaxString; sDBServer :T_MaxString; sDBDatabase :T_MaxString; nDBPort :UDINT; sDBProtocol :T_MaxString; sDBUserId :T_MaxString; sDBPassword :T_MaxString; sDBScheme :T_MaxString; sDBSequence :T_MaxString; sDBClientDll :T_MaxString; sDBTable :T_MaxString; bExecute :BOOL; tTimeout :TIME; END_VAR sNetID : Is a string containing the AMS network identifier of the target device to which the ADS command is directed. eDBType : Indicates the type of the database, e.g. 'Mobile server'. eDBValueType : Indicates the form in which the values are or will be stored. sDBDriver :

Gives the name of the ODBC - driver. sDBServer : Provides the name of the server. sDBDatabase : Gives the name of the database. nDBPort : Gives the port of the ODBC-connection. sDBProtocol : Contains the name of the used protocol (TCPIP). sDBUserId : Indicates the username for the registration. sDBPassword : Contains the password. sDBScheme : Contains the name of the scheme. sDBSequence : Contains the name of the sequence for the "autoID".(Only for Oracle DBs) sDBClientDll : Contains the path to the fbclient.dll.(Only for Firebird/Interbase DBs) sDBTable : Gives the name of the table into which the values are to be written. bExecute : The command is executed with the rising edge. tTimeout :

States the time before the function is cancelled. VAR_OUTPUT VAR_OUTPUT bBusy : BOOL; bError : BOOL; bErrID : UDINT; hDBID : UDINT; END_VAR bBusy : The command is in the process of being transmitted by ADS. No new command will be accepted as long as "bBusy" remains TRUE. bError : Becomes TRUE, as soon as an error occurs. nErrID : Supplies the ADS Error Code [ } 132] when the bError output is set. hDBID : Returns the ID of the database. TS6420 63 Version: 1.2