2018-05-24 11:36:20 +02:00
|
|
|
/*
|
|
|
|
* Copyright (C) 2018 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.
|
|
|
|
*/
|
|
|
|
|
|
|
|
/**
|
2019-08-29 10:04:08 +02:00
|
|
|
* @defgroup pkg_nimble_contrib RIOT Integration
|
|
|
|
* @ingroup pkg_nimble
|
2019-06-04 16:14:41 +02:00
|
|
|
* @brief Basic RIOT integration of NimBLE, including e.g. stack
|
|
|
|
* configuration and (auto)initialization code
|
2018-05-24 11:36:20 +02:00
|
|
|
* @{
|
|
|
|
*
|
|
|
|
* @file
|
|
|
|
* @brief RIOT specific glue functions for integrating NimBLE
|
|
|
|
*
|
|
|
|
* @author Hauke Petersen <hauke.petersen@fu-berlin.de>
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef NIMBLE_RIOT_H
|
|
|
|
#define NIMBLE_RIOT_H
|
|
|
|
|
2019-03-26 14:24:15 +01:00
|
|
|
#include <stdint.h>
|
|
|
|
|
2018-05-24 11:36:20 +02:00
|
|
|
#ifdef __cplusplus
|
|
|
|
extern "C" {
|
|
|
|
#endif
|
|
|
|
|
|
|
|
/**
|
2018-10-19 13:59:28 +02:00
|
|
|
* @brief Priority used for NimBLE's controller thread
|
2018-05-24 11:36:20 +02:00
|
|
|
*
|
|
|
|
* This should be as high as possible.
|
|
|
|
*/
|
|
|
|
#ifndef NIMBLE_CONTROLLER_PRIO
|
|
|
|
#define NIMBLE_CONTROLLER_PRIO (0)
|
|
|
|
#endif
|
|
|
|
|
|
|
|
/**
|
2018-10-19 13:59:28 +02:00
|
|
|
* @brief Stacksize used for NimBLE's controller thread
|
2018-05-24 11:36:20 +02:00
|
|
|
*/
|
2018-10-19 13:59:28 +02:00
|
|
|
#ifndef NIMBLE_CONTROLLER_STACKSIZE
|
|
|
|
#define NIMBLE_CONTROLLER_STACKSIZE (THREAD_STACKSIZE_DEFAULT)
|
|
|
|
#endif
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @brief Priority used for NimBLE's host thread
|
|
|
|
*/
|
|
|
|
#ifndef NIMBLE_HOST_PRIO
|
|
|
|
#define NIMBLE_HOST_PRIO (THREAD_PRIORITY_MAIN - 2)
|
|
|
|
#endif
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @brief Stacksize used for NimBLE's host thread
|
|
|
|
*/
|
|
|
|
#ifndef NIMBLE_HOST_STACKSIZE
|
|
|
|
#define NIMBLE_HOST_STACKSIZE (THREAD_STACKSIZE_DEFAULT)
|
|
|
|
#endif
|
|
|
|
|
2019-03-07 16:20:36 +01:00
|
|
|
/**
|
|
|
|
* @brief Export our own address type for later usage
|
|
|
|
*/
|
|
|
|
extern uint8_t nimble_riot_own_addr_type;
|
|
|
|
|
2018-10-19 13:59:28 +02:00
|
|
|
/**
|
|
|
|
* @brief Setup and run NimBLE's controller and host threads
|
|
|
|
*/
|
|
|
|
void nimble_riot_init(void);
|
2018-05-24 11:36:20 +02:00
|
|
|
|
|
|
|
#ifdef __cplusplus
|
|
|
|
}
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#endif /* NIMBLE_RIOT_H */
|
|
|
|
/** @} */
|