Commit Graph

432 Commits

Author SHA1 Message Date
gc87 47f6e54efd Fixed crash caused by uninitialized OPCUA client 2021-09-26 18:53:03 +08:00
fengzero 7f744a1956 fix uninitialized TAILQ
causes a crash when accessing TAILQ
2021-09-26 17:46:11 +08:00
fengzero a9c18532ee del add/update group config dst_node_id 2021-09-26 17:24:47 +08:00
fengzero d25f93290e fix json parse unit test
clang-format neu_types.h
2021-09-26 17:24:47 +08:00
Parker Liu 3b369acf25 Add send subscribe node message when Add default group configs 2021-09-26 17:15:59 +08:00
Parker Liu ba89625545 Switch to neu_data_val_t in sample plugin for read and write 2021-09-26 15:06:05 +08:00
lixiumei bf122ec702 Refining basic data structure tests 2021-09-24 19:32:34 +08:00
gc87 e018d73a6f Fix the link error of OPCUA driver 2021-09-24 18:49:04 +08:00
gc87 5898c2ab8e Add cyclic reading support and subscription support 2021-09-24 16:10:03 +08:00
gc87 eb00cc6070 Refactoring the OPC-UA driver
1. Simplify the code of read and write
2021-09-24 16:10:03 +08:00
fengzero 662ae1ec2d refactor json parse
separate mqtt parameter decode/encode
2021-09-24 16:06:48 +08:00
Parker Liu f4ad674df0 Add support subscribe/unsubscribe node in adapter and other functions
* Add subscribe/unsubscribe node in command and request interface.
* Add neuron request structure for subscribe/unsubscribe node.
* Add subscribe node before enter message loop.
* Add unsubscribe node after exit message loop.
* Add compare function for primitive value.
2021-09-23 18:17:39 +08:00
Parker Liu f552b41253 Add forward subscribe/unsubscribe message to driver adapter
* Add vector_find_index/vector_find_item/vector_has_elem util function
  for vector.
* Forward subscribe/unsubsribe message in manager, and make sure to
  forward the subscribe/unsubsribe message only once.
2021-09-22 18:28:32 +08:00
fengzero 4f5e858146 modbus: add subscribe/unsubscribe reqeust and check for group config updates 2021-09-22 10:12:50 +08:00
fengzero 44f05110d2 refactor decode/encode json
decode buf to neu_data_val_t
encode neu_data_val_t to buf
compile yaml as a dynamic library
2021-09-22 10:12:50 +08:00
Parker Liu 05ee33fefe Add unittest for serialize/deserialize int-val and string-val pair 2021-09-18 16:47:03 +08:00
Parker Liu abdd56c897 Comment the test statement for check IP address of mqtt server 2021-09-18 10:10:42 +08:00
Parker Liu 19aaceadda Add int-val and string-val pair structue for data value
* Add neu_int_val_t and neu_string_val_t structures and functions
* Add functions for set/get int-val and string-val in data value
* Add functions for supoort serial/deserial int-val and string-val
2021-09-17 19:59:02 +08:00
gc87 dae9f9def4 Read configuration file 2021-09-16 19:16:49 +08:00
Parker Liu 74f1c33968 Add periodic read command and subscribe/unsubscribe driver command
* Add commands for start/stop periodic read and support in manager
* Add commands for subscribe/unsubscribe driver and support in manager
* Add commands for group config changed and support in manager
2021-09-16 19:12:05 +08:00
Parker Liu 7b89528f85 Add anchor/unanchor functions for tag group config 2021-09-16 14:19:17 +08:00
Parker Liu 1e7264f4a7 Add a standalone CMakeLists file for sample plugins 2021-09-16 11:50:31 +08:00
Parker Liu b49332ca2d Fix issue of failed build modbus plugin in macOS 2021-09-16 11:43:59 +08:00
Parker Liu 62abad7bb9 Fix issue of failed build datatag_table_test and some memory leak issue 2021-09-16 11:30:23 +08:00
lixiumei123 22c8ea8fdd add plugin manager test (#77)
* add plugin manager test

* Plugin manager test add a check if the plugin_info is equal to param_update
2021-09-16 11:04:41 +08:00
fengzero 312d432569 fix use nng in plugins by linking dynamic libraries
clang-format message_handle
2021-09-16 10:14:08 +08:00
Parker Liu 8d14c5ec8c Add get/set familly functions for cstr/string/bytes/array/vec 2021-09-15 19:02:28 +08:00
fengzero 370aed5e2d modbus tcp: add cycle read
del demo code
use aio timeout as timer
2021-09-15 19:00:14 +08:00
gc87 7c3a2ccfaa Complete adaptation of mqtt driver and modbus-tcp driver
1. Fix modbus write value error
2021-09-14 10:28:24 +08:00
gc87 6817eeae6d Improve the read command of opcua driver 2021-09-13 18:10:07 +08:00
fengzero 0fed83398e read/write 2 tags for demo 2021-09-13 17:41:42 +08:00
Parker Liu 08d0af6473 Remove some warnings of neuron data value 2021-09-13 12:20:51 +08:00
Parker Liu 767d4459e5 Fix memory leak in data_val_test.cc and reformat source files 2021-09-13 10:20:17 +08:00
Parker Liu 8df731b7ce Add a new data value type with serialize/deserialize function
* Add a structure for fixed array
* Add a structure for bytes
* Add unit test cases of neuron data type
2021-09-13 09:03:46 +08:00
gc87 112f9fe0f3 Add opcua plugin support
1. Update README.md
2. Update install-lib.sh
3. Add the key field to the variable
4. Use config to read
5. It works
2021-09-12 22:58:51 +08:00
fengzero a84853692a Add parser yaml config module
del unused file
dashboard plugin read config from neuron.yaml
2021-09-11 11:09:50 +08:00
lixiumei d91f506e2c fix the problems of test plugin api interface functionality 2021-09-11 10:53:33 +08:00
lixiumei 9005a0305f Add add/delete/update/get plugin api 2021-09-11 10:53:33 +08:00
lixiumei 071de30f90 Add add/delete/update/get plugin api 2021-09-11 10:53:33 +08:00
fengzero 07e9b226cf Add node/group config api
support add/del/update/get
rename group config json field
2021-09-09 22:07:00 +08:00
lixiumei 4ba98dacff Add plugin json parse and plugin test 2021-09-09 11:51:52 +08:00
gc87 dba5a634a2 Dynamically add and delete datatag_ids of group config
1. Fix spelling errors in function names and structure names
2. Delete the nodeId field of the return value of get group config
2021-09-09 11:01:48 +08:00
lixiumei 93a090ea95 Add plugin json parse 2021-09-09 10:22:29 +08:00
Parker Liu ce36e2e5dd Fix issue of stuck on waiting for bind adapter when add group config
The nng_dial function sometimes returned after call the callback
function manager_bind_adapter by nng_pipe_notify. This causes the
manager_bind_adapter function to be called with another missing adapter,
the bind_count of current bound adapter should not be changed, so it
will be stuck on waiting for the bind adapter.
2021-09-08 19:25:40 +08:00
Parker Liu 8cc26fd524 Add a judgment to prevent register a adapter with same name 2021-09-08 17:03:26 +08:00
gc87 0513895a8d Remove the group item from the API parameters
1. Remove internal function name prefix
2021-09-08 10:22:33 +08:00
lixiumei123 563ae2cd10 Merge pull request #66 from lixiumei123/main
fix format: neu_json_node.h
2021-09-07 18:21:40 +08:00
lixiumei 9851dd1220 fix format: neu_json_node.h 2021-09-07 10:20:29 +00:00
lixiumei 342841d624 add adapter json parse and test 2021-09-07 18:05:49 +08:00
fengzeroz bd6c0e15b5 Merge pull request #64 from fengzeroz/main
fix clang-format
2021-09-07 17:00:59 +08:00