FB_RemoteListenerBase

FB_RemoteListenerBase 1:

The function block serves as the basic implementation of an event listener of a remote system. New messages and state changes of alarms can be recognized through the overwriting of the event-driven methods.

This function block provides access to the EventLogger of a remote system and can be used to send events there or receive events from there.

Syntax

FUNCTION_BLOCK FB_RemoteListenerBase IMPLEMENTS I_RemoteListener

FB_RemoteListenerBase 2: Methods

Name

Description

Execute

Must be called cyclically so that the event queue can be processed.

Subscribe

Subscribes notifications.

Unsubscribe

Unsubscribes notifications.

FB_RemoteListenerBase 3:Event-driven methods

Name

Description

OnAlarmCleared

Called when the state of an alarm changes from "Raised" to "Clear".

OnAlarmConfirmed

Called when an alarm has been confirmed.

OnAlarmDisposed

Called when an alarm instance has been released again.

OnAlarmRaised

Called when the state of an alarm changes from "Clear" to "Raised".

OnConnectionStateChanged

Called when the connection to the remote system changes state.

OnDatabaseChanged

Called if the database has changed, e.g. if a ClearLoggedEvents() has been called

OnEventLoggerError

Called if an ADS error occurs during communication.

OnMessageSent

Called when a message has been sent.

FB_RemoteListenerBase 4: Properties

Name

Type

Access

Description

bSubscribed

BOOL

Get

Returns TRUE if the function block has registered notifications and event monitoring is active.

Requirements

Development environment

Target platform

PLC libraries to include

TwinCAT v3.1.4026.0

PC or CX (x64, x86, ARM)

Tc3_EventLogger (>=3.3.7.0)