Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pkg/openwsn: add sock_udp [upstream implementation] #15310

Closed
wants to merge 14 commits into from
Closed
Show file tree
Hide file tree
Changes from 6 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion pkg/openwsn/Makefile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
PKG_NAME=openwsn
PKG_URL=https://github.com/openwsn-berkeley/openwsn-fw.git
PKG_VERSION=028db872c0c60f756e16880a0c86d6282e421c71
PKG_VERSION=a49f5a34304daa8c013772ca1705f3d7da1e1514
PKG_LICENSE=BSD-3-Clause

include $(RIOTBASE)/pkg/pkg.mk
Expand All @@ -13,6 +13,9 @@ IGNORE_MODULES := openwsn_leds \
openwsn_iee802154e_security \
openwsn_radio \
openwsn_riotos \
openwsn_sock_udp \
openwsn_sock \
openwsn_sock_async \
fjmolinas marked this conversation as resolved.
Show resolved Hide resolved
openwsn_serial \
openwsn_sctimer \
openwsn_sctimer_rtt \
Expand Down
19 changes: 18 additions & 1 deletion pkg/openwsn/Makefile.dep
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@ ifneq (,$(filter openwsn_openstack,$(USEMODULE)))
USEMODULE += openwsn_scheduler

DEFAULT_MODULE += auto_init_openwsn

endif

ifneq (,$(filter openwsn_scheduler,$(USEMODULE)))
Expand Down Expand Up @@ -43,6 +42,10 @@ ifneq (,$(filter openwsn_cjoin,$(USEMODULE)))
USEMODULE += openwsn_crypto
endif

ifneq (,$(filter openwsn_opencoap,$(USEMODULE)))
USEMODULE += openwsn_sock_async
endif

ifneq (,$(filter openwsn_crypto,$(USEMODULE)))
USEMODULE += crypto_3des
USEMODULE += cipher_modes
Expand Down Expand Up @@ -99,5 +102,19 @@ ifneq (,$(filter openwsn_debugpins,$(USEMODULE)))
FEATURES_REQUIRED += periph_gpio_irq
endif

ifneq (,$(filter sock_udp,$(USEMODULE)))
USEMODULE += openwsn_sock_udp
endif

ifneq (,$(filter openwsn_sock%,$(USEMODULE)))
USEMODULE += openwsn_sock
USEMODULE += core_mbox
USEMODULE += ztimer_usec
endif

ifneq (,$(filter openwsn_sock_async,$(USEMODULE)))
USEMODULE += sock_async
endif

# This port currently requires setting ISR_STACKSIZE
FEATURES_BLACKLIST += arch_esp32 arch_esp8266 arch_riscv arch_avr8
14 changes: 14 additions & 0 deletions pkg/openwsn/Makefile.include
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@ PSEUDOMODULES += openwsn_serial \
openwsn_icmpv6_echo \
openwsn_iee802154e_security \
openwsn_leds \
openwsn_sock \
openwsn_sock_async \
openwsn_sock_udp \
openwsn_scheduler \
openwsn_sctimer \
openwsn_sctimer_rtt \
Expand Down Expand Up @@ -72,6 +75,17 @@ ifneq (,$(filter openwsn_adaptive_msf,$(USEMODULE)))
CFLAGS += -DOPENWSN_ADAPTIVE_MSF
endif

ifneq (,$(filter openwsn_sock%,$(USEMODULE)))
CFLAGS += -DSOCK_HAS_IPV6
ifneq (,$(filter openwsn_sock_async,$(USEMODULE)))
CFLAGS += -DSOCK_HAS_ASYNC
endif
ifneq (,$(filter sock_async_event,$(USEMODULE)))
# Needed only if using event and not simple callbacks
CFLAGS += -DSOCK_HAS_ASYNC_CTX
endif
endif

# In OpenWSN the ISR stack is shared with the network stack. OpenWSN stack is
# 2Kb, this means that the ISR stack in OpenWSN might have up to 2Kb available.
# To keep the same marging increase the ISR stack to 2Kb as well. In practice
Expand Down
Loading