1# Copyright (c) 2020 PHYTEC Messtechnik GmbH 2# SPDX-License-Identifier: Apache-2.0 3 4menuconfig MODBUS 5 bool "Modbus support" 6 select CRC 7 8if MODBUS 9 10config MODBUS_BUFFER_SIZE 11 int "Modbus buffer size" 12 default 256 13 range 64 256 14 help 15 Modbus buffer size. 16 17choice 18 prompt "Supported node roles" 19 default MODBUS_ROLE_CLIENT_SERVER 20 help 21 Specify the type of supported node roles. 22 23config MODBUS_ROLE_CLIENT 24 bool "Client support" 25 26config MODBUS_ROLE_SERVER 27 bool "Server support" 28 29config MODBUS_ROLE_CLIENT_SERVER 30 bool "Client and server support" 31 32endchoice 33 34config MODBUS_SERVER 35 bool 36 default y if MODBUS_ROLE_SERVER || MODBUS_ROLE_CLIENT_SERVER 37 38config MODBUS_CLIENT 39 bool 40 default y if MODBUS_ROLE_CLIENT || MODBUS_ROLE_CLIENT_SERVER 41 42config MODBUS_SERIAL 43 bool "Modbus over serial line support" 44 default y 45 depends on SERIAL && SERIAL_HAS_DRIVER 46 depends on DT_HAS_ZEPHYR_MODBUS_SERIAL_ENABLED 47 select UART_USE_RUNTIME_CONFIGURE 48 help 49 Enable Modbus over serial line support. 50 51config MODBUS_ASCII_MODE 52 depends on MODBUS_SERIAL 53 bool "Modbus transmission mode ASCII" 54 help 55 Enable ASCII transmission mode. 56 57config MODBUS_RAW_ADU 58 bool "Modbus raw ADU support" 59 help 60 Enable Modbus raw ADU support. 61 62config MODBUS_NUMOF_RAW_ADU 63 int "Number of raw ADU instances" 64 depends on MODBUS_RAW_ADU 65 range 1 4 66 help 67 Number of raw ADU instances. 68 69config MODBUS_FP_EXTENSIONS 70 bool "Floating-Point extensions" 71 default y 72 help 73 Enable Floating-Point extensions 74 75config MODBUS_FC08_DIAGNOSTIC 76 bool "FC08 Diagnostic support" 77 depends on MODBUS_SERVER 78 default y 79 help 80 Enable function code 08 Diagnostic support 81 82module = MODBUS 83module-str = Modbus Support 84module-help = Sets log level for Modbus support 85source "subsys/logging/Kconfig.template.log_config" 86 87endif 88