Commit Graph

8 Commits

Author SHA1 Message Date
estr Eckerstorfer Andreas
166d03c351 refactor(core): Substitute tabs by spaces in source code 2024-09-14 02:33:22 +02:00
Julius Pfrommer
705801a55c refactor(examples): Use the NS0ID shorthand in the examples 2024-07-26 08:30:16 +02:00
Julius Pfrommer
8439c500aa refactor(examples): Clean up arch-dependent API usage in examples 2023-07-28 21:42:56 +02:00
Julius Pfrommer
4b8ec01827 refactor(examples): Use UA_Server_runUntilInterrupt in examples 2023-01-15 17:34:17 +01:00
Joakim Roubert
d69ee99f4d
Fix(doc): Documentation spelling fixes (#4472)
Signed-off-by: Joakim Roubert <joakimr@axis.com>
2021-06-14 21:50:36 +02:00
Julius Pfrommer
41cb0ba117 refactor(doc): Clean up A&C Tutorial 2020-05-31 13:19:17 +02:00
Urs Fässler
c7c57e9aba fix: create condition source object with a parent
Without a parent, the error "Node for event must be in ObjectsFolder!"
occurs when an event is sent.
2020-01-15 17:19:31 +01:00
Sameer AL-Qadasi
ff87c2876d (feat): First Implementation of Alarms and Conditions (#2083)
* Update src/server/ua_subscription_events.c

* Alarms and Conditions First Implementation

implemented facets:
1- A&C Base Condition Server Facet (only mandatory)
2- A&C Enable Server Facet (only mandatory)
3- A&C Alarm Server Facet (only mandatory)
4- A&C Acknowledgeable Alarm Server Facet (complete, with ConfirmedState and Confirm Method)

Notes:
1) Change in ua_subscriptions_monitoreditem.c is related to issue #2114. Without that fix, the server crashes when generating OverflowEvents.

2) The Events: RefreshStart and RefreshEnd are abstract according to the specification. So to make it possible to create instances of them the fix in function "create_event()" is added (change abstract attribute of the EventType to false).

@basysKom-jvoe, I will be glad if you help reviewing the code:)

* some fixes

Update src/server/ua_subscription_alarms_conditions.c

* correcting example name

adding function prototype

* some fixes

1) keep events and A&C disabled and NS0 reduced in main CMakeLists
2) enable A&C in test scripts (Travis and Veyor)

* Update ua_subscription_alarms_conditions.c

fix som error handling

* Update ua_subscription_alarms_conditions.c

* fixing issues from first review

1) calculate size of array
2) correct misspelling
3) correct some comments

* Update ua_subscription_alarms_conditions.c

to retrigger travis test.
14 - subscription_events test fails randomly!

* fix memory leak issues

the function UA_NodeId_copy was used multiple times, however,  the memory allocated is not freed because only numeric NodeIds were used in testing. So using nun numeric NodeIds will cause memory leak.
Next commit/version should fix that issue.

* review fixes: comments 1 and 2

1) use new server logger function (PR rebase).
2) use values instead of pointers in A&C API functions for consistency

* Review: reduce indent

reducing indent by using "continue" inside if statements in loops

* Update tutorial_server_alarms_conditions.c

modify includes

* update to upstream master and fix some A&C Module issues

* fix CI test and some review issues

* fix some review issues

the previous commits fix issues mentioned in comments:
- https://github.com/open62541/open62541/pull/2083#discussion_r241070233
- https://github.com/open62541/open62541/pull/2083#discussion_r241072127
- https://github.com/open62541/open62541/pull/2083#discussion_r241076137
- https://github.com/open62541/open62541/pull/2083#discussion_r241076137
- https://github.com/open62541/open62541/pull/2083#discussion_r241079915
- https://github.com/open62541/open62541/pull/2083#discussion_r241082415
- https://github.com/open62541/open62541/pull/2083#discussion_r241083539
- https://github.com/open62541/open62541/pull/2083#discussion_r284586642
- https://github.com/open62541/open62541/pull/2083#discussion_r284587406
- https://github.com/open62541/open62541/pull/2083#discussion_r284589129

not resolved yet, need further discussion:
- https://github.com/open62541/open62541/pull/2083#discussion_r241072659
- https://github.com/open62541/open62541/pull/2083#discussion_r241075205

* some modification after rebase

* remove unused code + some fixes

* some fixes and modifications

changes:
- fix conflicting variable names
- pass FieldNames directly without help variable in
  "UA_Server_setConditionField"
- remove unused code
- add some comments
- correct indentation

* fix issues mentioned in review

* enable setting ConditionId when creating Condition Instances

* fix issues based on review

- pass variant instead of void* and type when setting Condition Fields and their Properties.

- Change RefreshEvents IsAbstract attribute to "False" when creating the Condition instead of doing that when generating the event.

- comment issue #2114 fix out (it seems to work fine after recent commits).

- modify A&C example according to changes.

* use A&C public API to set condition fields and properties

* check for Null pointer before comparing NodeIds

Co-Authored-By: andr <aandranikk@gmail.com>

* correct Typo

Co-Authored-By: andr <aandranikk@gmail.com>

* rebase + fix issues from review

some issues need further discussion before fixing them. Please see:
https://github.com/open62541/open62541/pull/2083#discussion_r326857289
https://github.com/open62541/open62541/pull/2083#discussion_r326857373

* fixup after rebase
2019-12-17 20:28:40 +01:00