urtware / urtware.h @ 621aa0b6
History | View | Annotate | Download (2.971 KB)
| 1 | 42470f0a | Thomas Schöpping | /*
|
|---|---|---|---|
| 2 | µRtWare is a lightweight publish/subscribe middleware for real-time
|
||
| 3 | applications. It was developed as part of the software habitat for the
|
||
| 4 | Autonomous Mini Robot [1] (AMiRo) but can be used for other purposes as well.
|
||
| 5 | |||
| 6 | 46471486 | Thomas Schöpping | Copyright (C) 2018..2020 Thomas Schöpping et al.
|
| 7 | 42470f0a | Thomas Schöpping | |
| 8 | This program is free software: you can redistribute it and/or modify
|
||
| 9 | it under the terms of the GNU General Public License as published by
|
||
| 10 | the Free Software Foundation, either version 3 of the License, or
|
||
| 11 | (at your option) any later version.
|
||
| 12 | |||
| 13 | This program is distributed in the hope that it will be useful,
|
||
| 14 | but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||
| 15 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||
| 16 | GNU General Public License for more details.
|
||
| 17 | |||
| 18 | You should have received a copy of the GNU General Public License
|
||
| 19 | along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||
| 20 | */
|
||
| 21 | |||
| 22 | 46471486 | Thomas Schöpping | #ifndef URTWARE_H
|
| 23 | #define URTWARE_H
|
||
| 24 | 42470f0a | Thomas Schöpping | |
| 25 | /**
|
||
| 26 | * @brief µRtWare identification macro.
|
||
| 27 | */
|
||
| 28 | #define _uRtWare_
|
||
| 29 | |||
| 30 | 46471486 | Thomas Schöpping | /*============================================================================*/
|
| 31 | 42470f0a | Thomas Schöpping | /**
|
| 32 | * @name µRtWare version and release information.
|
||
| 33 | * @{
|
||
| 34 | */
|
||
| 35 | 46471486 | Thomas Schöpping | /*============================================================================*/
|
| 36 | 42470f0a | Thomas Schöpping | |
| 37 | /**
|
||
| 38 | * @brief Release type of this version.
|
||
| 39 | * @note Possible values are "pre-alpha", "alpha", "beta", "release candidate", and "release".
|
||
| 40 | */
|
||
| 41 | #define URTWARE_RELEASE_TYPE "pre-alpha" |
||
| 42 | |||
| 43 | /**
|
||
| 44 | * @brief The µRtWare major version.
|
||
| 45 | * @note Changes of the major version imply incompatibilities.
|
||
| 46 | */
|
||
| 47 | #define URTWARE_VERSION_MAJOR 0 |
||
| 48 | |||
| 49 | /**
|
||
| 50 | * @brief The µRtWare minor version.
|
||
| 51 | * @note A higher minor version implies new functionalities, but all old interfaces are still available.
|
||
| 52 | */
|
||
| 53 | #define URTWARE_VERSION_MINOR 1 |
||
| 54 | |||
| 55 | /**
|
||
| 56 | * @brief The µRtWare patch level.
|
||
| 57 | */
|
||
| 58 | #define URTWARE_VERSION_PATCH 0 |
||
| 59 | |||
| 60 | /**
|
||
| 61 | * @brief The µRtWare operating system abstraction layer interface required major version.
|
||
| 62 | * @note Any other major version is assumed to be incompatible.
|
||
| 63 | */
|
||
| 64 | #define URT_OSAL_REQUIRED_MAJOR 0 |
||
| 65 | |||
| 66 | /**
|
||
| 67 | * @brief The µRtWare operating system abstraction layer interface required minor version.
|
||
| 68 | * @note Higher minor version values are assumed to be compatible, too.
|
||
| 69 | */
|
||
| 70 | #define URT_OSAL_REQUIRED_MINOR 1 |
||
| 71 | |||
| 72 | /** @} */
|
||
| 73 | |||
| 74 | 46471486 | Thomas Schöpping | /*============================================================================*/
|
| 75 | /* CONFIGURATION & VERIFICATION */
|
||
| 76 | /*============================================================================*/
|
||
| 77 | |||
| 78 | 42470f0a | Thomas Schöpping | #include <urtwareconf.h> |
| 79 | 46471486 | Thomas Schöpping | |
| 80 | 42470f0a | Thomas Schöpping | #if !defined(_URTWARE_CFG_)
|
| 81 | 46471486 | Thomas Schöpping | # error "invalid µRtWare configuration file" |
| 82 | #elif (URTWARE_CFG_VERSION_MAJOR != URTWARE_VERSION_MAJOR) || (URTWARE_CFG_VERSION_MAJOR < URTWARE_VERSION_MAJOR)
|
||
| 83 | # error "incompatible µRtWare configuration file" |
||
| 84 | 42470f0a | Thomas Schöpping | #endif
|
| 85 | 46471486 | Thomas Schöpping | |
| 86 | 42470f0a | Thomas Schöpping | #include <urt_confcheck.h> |
| 87 | |||
| 88 | 46471486 | Thomas Schöpping | #include <urt_primitives.h> |
| 89 | |||
| 90 | #if defined(URT_CFG_OSAL_HEADER)
|
||
| 91 | # include URT_CFG_OSAL_HEADER
|
||
| 92 | 42470f0a | Thomas Schöpping | #endif
|
| 93 | 46471486 | Thomas Schöpping | #include <urt_osal.h> |
| 94 | |||
| 95 | /*
|
||
| 96 | * TODO: Add further µRtWare includes here (e.g. urt_core.h).
|
||
| 97 | */
|
||
| 98 | 42470f0a | Thomas Schöpping | |
| 99 | 46471486 | Thomas Schöpping | #endif /* URTWARE_H */ |