hms-networks / flexy-cumulocity-connector

A connector-based solution to Cumulocity for linking Ewon devices using a direct data path with a Flexy Java application.
Apache License 2.0
3 stars 2 forks source link

[BUG] An alarm gets raised after a tag value returns to a normal value #72

Open attkat opened 4 months ago

attkat commented 4 months ago

Do I have the latest version of the Ewon firmware?

Do I have the latest version of the application?

Do I have a custom or modified version of the application?

Ewon Firmware Version

14.8s0

Application Version

1.4.1

Network Connection Type

Ethernet

Current Behavior

An alarm gets raised after a tag value returns to a normal value.

In the file: CConnectorAlarmMgr.java the following condition in line 103 may be incorrect:

if (alarmStatus.equals("END") || alarmStatus.equals("NONE")) {

The variable alarmStatus can not have the value "NONE". Possible values for alarmStatus are "ALM", "ACK", "END", "RTN". The variable alarmType can have the value "NONE".

Expected Behavior

An alarm shall not be raised after a tag value returns to a normal value.

In the file: CConnectorAlarmMgr.java the condition in line 103 may be altered to:

if (alarmStatus.equals("END") || alarmStatus.equals("RTN")) {

Steps to Reproduce

Raise a LEVEL alarm for a tag. The first alarm be raised in Cumulocity. Return back to normal level for a tag. The second alarm will be raised in Cumulocity. It is not the expected behavior.

Additional Information

No response

Code of Conduct