Skip to content

Commit

Permalink
Merge pull request #4713 from authmillenon/pkg/port/emb6
Browse files Browse the repository at this point in the history
pkg: initial import of emb6 stack
  • Loading branch information
miri64 committed Mar 31, 2016
2 parents 757d461 + 43f7f55 commit 8ab89c4
Show file tree
Hide file tree
Showing 26 changed files with 4,077 additions and 0 deletions.
42 changes: 42 additions & 0 deletions Makefile.dep
Expand Up @@ -357,6 +357,29 @@ ifneq (,$(filter posix_semaphore,$(USEMODULE)))
USEMODULE += xtimer
endif

ifneq (,$(filter emb6_conn_udp,$(USEMODULE)))
USEMODULE += emb6_sock
endif

ifneq (,$(filter emb6_%,$(USEMODULE)))
USEMODULE += emb6
endif

ifneq (,$(filter emb6,$(USEMODULE)))
USEPKG += emb6
USEMODULE += emb6_bsp
USEMODULE += emb6_common
USEMODULE += emb6_contrib
USEMODULE += emb6_ipv6
USEMODULE += emb6_ipv6_multicast
USEMODULE += emb6_llsec
USEMODULE += emb6_mac
USEMODULE += emb6_netdev2
USEMODULE += emb6_rpl
USEMODULE += emb6_sicslowpan
USEMODULE += emb6_utils
endif

ifneq (,$(filter lwip_sixlowpan,$(USEMODULE)))
USEMODULE += lwip_ipv6_autoconfig
endif
Expand Down Expand Up @@ -411,6 +434,25 @@ ifneq (,$(filter lwip_contrib,$(USEMODULE)))
USEMODULE += sema
endif

ifneq (,$(filter emb6_%,$(USEMODULE)))
USEMODULE += emb6
endif

ifneq (,$(filter emb6,$(USEMODULE)))
USEPKG += emb6
USEMODULE += emb6_bsp
USEMODULE += emb6_common
USEMODULE += emb6_contrib
USEMODULE += emb6_ipv6
USEMODULE += emb6_ipv6_multicast
USEMODULE += emb6_llsec
USEMODULE += emb6_mac
USEMODULE += emb6_netdev2
USEMODULE += emb6_rpl
USEMODULE += emb6_sicslowpan
USEMODULE += emb6_utils
endif

ifneq (,$(filter sema,$(USEMODULE)))
USEMODULE += xtimer
endif
Expand Down
1 change: 1 addition & 0 deletions Makefile.pseudomodules
Expand Up @@ -4,6 +4,7 @@ PSEUDOMODULES += conn_tcp
PSEUDOMODULES += conn_udp
PSEUDOMODULES += core_msg
PSEUDOMODULES += core_thread_flags
PSEUDOMODULES += emb6_router
PSEUDOMODULES += gnrc_netdev_default
PSEUDOMODULES += gnrc_ipv6_default
PSEUDOMODULES += gnrc_ipv6_router
Expand Down
11 changes: 11 additions & 0 deletions pkg/emb6/Makefile
@@ -0,0 +1,11 @@
PKG_NAME=emb6
PKG_URL=https://github.com/hso-esk/emb6.git
PKG_VERSION=14e4a3cfff01644e078870e14e16a1fe60dcc895
PKG_BUILDDIR ?= $(BINDIRBASE)/pkg/$(BOARD)/$(PKG_NAME)

.PHONY: all

all: git-download
"$(MAKE)" -C $(PKG_BUILDDIR)

include $(RIOTBASE)/pkg/pkg.mk
71 changes: 71 additions & 0 deletions pkg/emb6/Makefile.include
@@ -0,0 +1,71 @@
PKG_BUILDDIR ?= $(BINDIRBASE)/pkg/$(BOARD)/emb6
EMB6_DIR := $(PKG_BUILDDIR)
EMB6_CONTRIB := $(RIOTBASE)/pkg/emb6/contrib

INCLUDES += -I$(PKG_BUILDDIR)/target
INCLUDES += -I$(RIOTBASE)/pkg/emb6/include

ifeq (,$(filter emb6_router,$(USEMODULE)))
CFLAGS += -DEMB6_CONF_ROUTER=FALSE
endif

ifneq (,$(filter emb6_bsp,$(USEMODULE)))
DIRS += $(EMB6_DIR)/target/bsp
endif

ifneq (,$(filter emb6_common,$(USEMODULE)))
DIRS += $(EMB6_DIR)/emb6
INCLUDES += -I$(EMB6_DIR)/emb6
endif

ifneq (,$(filter emb6_contrib,$(USEMODULE)))
DIRS += $(EMB6_CONTRIB)
endif

ifneq (,$(filter emb6_conn_udp,$(USEMODULE)))
DIRS += $(EMB6_CONTRIB)/conn/udp
endif

ifneq (,$(filter emb6_ipv6,$(USEMODULE)))
DIRS += $(EMB6_DIR)/emb6/src/net/ipv6
INCLUDES += -I$(EMB6_DIR)/emb6/inc/net/ipv6
endif

ifneq (,$(filter emb6_ipv6_multicast,$(USEMODULE)))
DIRS += $(EMB6_DIR)/emb6/src/net/ipv6/multicast
INCLUDES += -I$(EMB6_DIR)/emb6/inc/net/ipv6/multicast
endif

ifneq (,$(filter emb6_llsec,$(USEMODULE)))
DIRS += $(EMB6_DIR)/emb6/src/mac/llsec
INCLUDES += -I$(EMB6_DIR)/emb6/inc/mac/llsec
endif

ifneq (,$(filter emb6_mac,$(USEMODULE)))
DIRS += $(EMB6_DIR)/emb6/src/mac
INCLUDES += -I$(EMB6_DIR)/emb6/inc/mac
endif

ifneq (,$(filter emb6_netdev2,$(USEMODULE)))
DIRS += $(EMB6_CONTRIB)/netdev2
endif

ifneq (,$(filter emb6_rpl,$(USEMODULE)))
DIRS += $(EMB6_DIR)/emb6/src/net/rpl
INCLUDES += -I$(EMB6_DIR)/emb6/inc/net/rpl
endif

ifneq (,$(filter emb6_sicslowpan,$(USEMODULE)))
DIRS += $(EMB6_DIR)/emb6/src/net/sicslowpan
INCLUDES += -I$(EMB6_DIR)/emb6/inc/net/sicslowpan
endif

ifneq (,$(filter emb6_sock,$(USEMODULE)))
DIRS += $(EMB6_DIR)/emb6/src/tport
INCLUDES += -I$(EMB6_DIR)/emb6/inc/tport
endif

ifneq (,$(filter emb6_utils,$(USEMODULE)))
DIRS += $(EMB6_DIR)/utils/src
INCLUDES += -I$(EMB6_DIR)/utils/inc
endif
3 changes: 3 additions & 0 deletions pkg/emb6/contrib/Makefile
@@ -0,0 +1,3 @@
MODULE = emb6_contrib

include $(RIOTBASE)/Makefile.base
37 changes: 37 additions & 0 deletions pkg/emb6/contrib/board_conf.c
@@ -0,0 +1,37 @@
/*
* Copyright (C) Freie Universität Berlin
*
* This file is subject to the terms and conditions of the GNU Lesser
* General Public License v2.1. See the file LICENSE in the top level
* directory for more details.
*/

/**
* @{
*
* @file
* @author Martine Lenders <mlenders@inf.fu-berlin.de>
*/

#include "emb6/netdev2.h"

#include "etimer.h"
#include "board_conf.h"

#define ENABLE_DEBUG (0)
#include "debug.h"

uint8_t board_conf(s_ns_t *ps_nStack)
{
if (ps_nStack != NULL) {
ps_nStack->inif = &emb6_netdev2_driver;
etimer_init();
return ps_nStack->inif->init(ps_nStack);
}
else {
DEBUG("Network stack pointer is NULL");
return 0;
}
}

/** @} */
3 changes: 3 additions & 0 deletions pkg/emb6/contrib/conn/udp/Makefile
@@ -0,0 +1,3 @@
MODULE = emb6_conn_udp

include $(RIOTBASE)/Makefile.base

0 comments on commit 8ab89c4

Please sign in to comment.