2020-05-29 22:45:25 +08:00
|
|
|
# Copyright (c) 2020 PHYTEC Messtechnik GmbH
|
|
|
|
# SPDX-License-Identifier: Apache-2.0
|
|
|
|
|
2021-03-03 02:26:04 +08:00
|
|
|
if(CONFIG_MODBUS)
|
2020-05-29 22:45:25 +08:00
|
|
|
zephyr_library()
|
|
|
|
|
|
|
|
zephyr_include_directories(${ZEPHYR_BASE}/subsys/modbus)
|
|
|
|
|
|
|
|
zephyr_library_sources(
|
2021-03-03 02:35:09 +08:00
|
|
|
modbus_core.c
|
2021-03-04 00:55:14 +08:00
|
|
|
)
|
|
|
|
|
|
|
|
zephyr_library_sources_ifdef(
|
|
|
|
CONFIG_MODBUS_SERIAL
|
2021-03-03 20:43:48 +08:00
|
|
|
modbus_serial.c
|
2020-05-29 22:45:25 +08:00
|
|
|
)
|
|
|
|
|
2021-03-11 07:42:21 +08:00
|
|
|
zephyr_library_sources_ifdef(
|
|
|
|
CONFIG_MODBUS_RAW_ADU
|
|
|
|
modbus_raw.c
|
|
|
|
)
|
|
|
|
|
2020-05-29 22:45:25 +08:00
|
|
|
zephyr_library_sources_ifdef(
|
2021-03-03 02:26:04 +08:00
|
|
|
CONFIG_MODBUS_SERVER
|
2021-03-03 02:35:09 +08:00
|
|
|
modbus_server.c
|
2020-05-29 22:45:25 +08:00
|
|
|
)
|
|
|
|
|
|
|
|
zephyr_library_sources_ifdef(
|
2021-03-03 02:26:04 +08:00
|
|
|
CONFIG_MODBUS_CLIENT
|
2021-03-03 02:35:09 +08:00
|
|
|
modbus_client.c
|
2020-05-29 22:45:25 +08:00
|
|
|
)
|
|
|
|
endif()
|