SNMP_SET (FB)¶
FUNCTION_BLOCK SNMP_SET
Function block to send SNMP SET request to an agent.
- InOut:
- Scope - Name - Type - Initial - Comment - Input - xExecute- BOOL- Starts the request - sHost- STRING(100)- Hostname or IP address of the SNMP agent - sOwnIP- STRING(100)- Hostname or IP address of the SNMP master (the IP of the control) - snmpVarBindings- REFERENCE TO ARRAY [0..(gc_uiMaxSNMPValues - 1)] OF SNMPVarBinding - Variable bindings (OID/Value) to send - iNumberOfVarBindings- INT- Number of variable bindings. - uiPeerPort- UINT- 161 - Port of the sender (the control) - uiSendPort- UINT- 161 - Port of the agent (printer, router etc.) - sCommunity- STRING- ‘public’ - The community, default: ‘public’ - xClosePeer- BOOL- Rising edge closes the UDP peer. - uiTimeout- UINT- 1000 - Timeout in milliseconds, default: 1000 ms - bySNMPVersion- SNMPVersion.V1 - SNMP Version, default: V1 - sUserName- STRING- ‘’ - SNMP V3 only: Name of the registered user. Use the function CreateUser to register an user. - sContextName- STRING- ‘’ - SNMP V3 only: Context name - xRequestReport- BOOL- TRUE - SNMP V3 only: TRUE: Requests a report to discover the engineId of the agent, Default: TRUE - Output - xBusy- BOOL- True while busy - xDone- BOOL- True if the call has finished - xError- BOOL- True if an error occured - aSNMPValues- ARRAY [0..gc_uiMaxSNMPValues] OF SNMPValue - The result of the set request - iSize- INT- Size of aSNMPValues - eError- Error state of the function block - diErrorStatus- DINT- SNMP error status of the last request - diErrorIndex- DINT- SNMP error index of the last request (index of the object that caused the error) - diRequestId- DINT- SNMP request id of the last request - abResponse- ARRAY [0..(gc_uiMaxTelegramLength - 1)] OF BYTE - msgAuthoritativeEngineID- SNMP V3 only: The authoritative engine Id. If xRequestReport = TRUE then this is the discovered engine id of the agent. If xRequestReport = FALSE then GVL.g_pEngineId is used. 
Methods:
Structure:
