From 885f44ebc80d16f690480f5ee7f539d5d33e811e Mon Sep 17 00:00:00 2001 From: qyz <917768104@qq.com> Date: Fri, 29 Nov 2024 14:31:50 +0800 Subject: [PATCH 1/3] add drmp --- misc/Kconfig | 1 + misc/drmp/Kconfig | 40 ++++++++++++++++++++++++++++++++++++++++ misc/drmp/package.json | 34 ++++++++++++++++++++++++++++++++++ 3 files changed, 75 insertions(+) create mode 100644 misc/drmp/Kconfig create mode 100644 misc/drmp/package.json diff --git a/misc/Kconfig b/misc/Kconfig index 232672b308..91e8aa7f46 100644 --- a/misc/Kconfig +++ b/misc/Kconfig @@ -37,4 +37,5 @@ source "$PKGS_DIR/packages/misc/soem/Kconfig" source "$PKGS_DIR/packages/misc/qparam/Kconfig" source "$PKGS_DIR/packages/misc/CorevMCU_CLI/Kconfig" source "$PKGS_DIR/packages/misc/get_irq_priority/Kconfig" +source "$PKGS_DIR/packages/misc/drmp/Kconfig" endmenu diff --git a/misc/drmp/Kconfig b/misc/drmp/Kconfig new file mode 100644 index 0000000000..4256338009 --- /dev/null +++ b/misc/drmp/Kconfig @@ -0,0 +1,40 @@ + +# Kconfig file for package drmp + +menuconfig PKG_USING_DRMP + bool "A protocol stack used for remote device maintenance" + default n + +if PKG_USING_DRMP + + config PKG_DRMP_PATH + string + default "/packages/misc/drmp" + + config DRMP_VCOM_TOTAL + bool "vcom total (must >= 2)" + default 2 + + config DRMP_USING_SAMPLE + bool "using sample" + default n + + choice + prompt "Version" + default PKG_USING_DRMP_LATEST_VERSION + help + Select the package version + + config PKG_USING_DRMP_LATEST_VERSION + bool "latest" + + config PKG_USING_DRMP_V100 + bool "v1.00" + endchoice + + config PKG_DRMP_VER + string + default "latest" if PKG_USING_DRMP_LATEST_VERSION + default "v1.00" if PKG_USING_DRMP_V100 + +endif diff --git a/misc/drmp/package.json b/misc/drmp/package.json new file mode 100644 index 0000000000..5131783a4e --- /dev/null +++ b/misc/drmp/package.json @@ -0,0 +1,34 @@ +{ + "name": "drmp", + "description": "A protocol stack used for remote device maintenance", + "description_zh": "用于设备远程维护的协议栈", + "enable": "PKG_USING_DRMP", + "keywords": [ + "protocol", + "remote", + "maintenance" + ], + "category": "misc", + "author": { + "name": "qiyongzhong0", + "email": "917768104@qq.com", + "github": "qiyongzhong0" + }, + "license": " LGPL-2.1", + "repository": "https://github.com/qiyongzhong0/rt-thread-drmp", + "homepage": "https://github.com/qiyongzhong0/rt-thread-drmp#readme", + "site": [ + { + "version": "latest", + "URL": "https://github.com/qiyongzhong0/rt-thread-drmp.git", + "filename": "", + "VER_SHA": "master" + }, + { + "version": "v1.00", + "URL": "https://github.com/qiyongzhong0/rt-thread-drmp/archive/v1.00.zip", + "filename": "rt-thread-drmp-1.00.zip", + "VER_SHA": "" + } + ] +} From 7af0760bfae808b70cffb31173148e0e571244ef Mon Sep 17 00:00:00 2001 From: qyz <917768104@qq.com> Date: Fri, 29 Nov 2024 14:50:37 +0800 Subject: [PATCH 2/3] fix misc/drmp/Kconfig --- misc/drmp/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/misc/drmp/Kconfig b/misc/drmp/Kconfig index 4256338009..322db23485 100644 --- a/misc/drmp/Kconfig +++ b/misc/drmp/Kconfig @@ -12,7 +12,7 @@ if PKG_USING_DRMP default "/packages/misc/drmp" config DRMP_VCOM_TOTAL - bool "vcom total (must >= 2)" + int "vcom total (2 - 16)" default 2 config DRMP_USING_SAMPLE From 89b4e2f3258442815a839c0274fed1bae10ccafc Mon Sep 17 00:00:00 2001 From: qyz <917768104@qq.com> Date: Fri, 27 Jun 2025 16:11:03 +0800 Subject: [PATCH 3/3] fix qmodbus --- iot/qmodbus/Kconfig | 16 ++++++++++++++++ iot/qmodbus/package.json | 6 ++++++ 2 files changed, 22 insertions(+) diff --git a/iot/qmodbus/Kconfig b/iot/qmodbus/Kconfig index a83b94fe87..48179a8241 100644 --- a/iot/qmodbus/Kconfig +++ b/iot/qmodbus/Kconfig @@ -38,6 +38,11 @@ if PKG_USING_QMODBUS select RT_USING_SAL default n + config MB_USING_SOCK_BACKEND + bool "using TCP-server backend" + select RT_USING_SAL + default n + config MB_USING_RTU_PROTOCOL bool "using MODBUS-RTU protocol" default y @@ -86,6 +91,13 @@ if PKG_USING_QMODBUS select MB_USING_TCP_PROTOCOL select MB_USING_SLAVE default n + + config MB_USING_SAMPLE_TCP_SRV_SLAVE + bool "sample TCP-server slave" + select MB_USING_SOCK_BACKEND + select MB_USING_TCP_PROTOCOL + select MB_USING_SLAVE + default n endif choice @@ -97,6 +109,9 @@ if PKG_USING_QMODBUS config PKG_USING_QMODBUS_LATEST_VERSION bool "latest" + config PKG_USING_QMODBUS_V110 + bool "v1.10" + config PKG_USING_QMODBUS_V100 bool "v1.00" endchoice @@ -104,6 +119,7 @@ if PKG_USING_QMODBUS config PKG_QMODBUS_VER string default "latest" if PKG_USING_QMODBUS_LATEST_VERSION + default "v1.10" if PKG_USING_QMODBUS_V110 default "v1.00" if PKG_USING_QMODBUS_V100 endif diff --git a/iot/qmodbus/package.json b/iot/qmodbus/package.json index 8a9d57ad7b..bd3f7ae77a 100644 --- a/iot/qmodbus/package.json +++ b/iot/qmodbus/package.json @@ -26,6 +26,12 @@ "filename": "qmodbus-1.00.zip", "VER_SHA": "" }, + { + "version": "v1.10", + "URL": "https://github.com/qiyongzhong0/qmodbus/archive/v1.10.zip", + "filename": "qmodbus-1.10.zip", + "VER_SHA": "" + }, { "version": "latest", "URL": "https://github.com/qiyongzhong0/qmodbus.git",