mbusFilterEnable (Function)

Top  Previous  Next

Architecture:

NX32L

Device support:

LX4,NX-400

Firmware version:

1.94.00


This function controls which message to receive from a Wireless M-Bus interface.

When enabled, only messages from slaves registered with mbusSlaveRegister are received.

 

Input:

handle : SYSHANDLE

A handle to the connection

 

enable : BOOL Default TRUE

Set to true to only receive from registered slaves, set to false to receive all messages.

 

 

Returns: INT

1

- Success.

0

- Not supported.

-1

- Invalid handle

-5

- Invalid interface type.

-9

- Communication error

 

Declaration:

FUNCTION mbusFilterEnable : INT;
VAR_INPUT
  handle   : SYSHANDLE;
  enable   : BOOL := TRUE;
END_VAR;

 

 

Example:

  ...
  // Only receive data from registered devices
  rc := mbusFilterEnable(handle:=mb, enable:=TRUE);
  DebugFmt(message:="mbusFilterEnable(): \1", v1:=rc);
  ...