Classes | Namespaces | Macros | Typedefs | Variables
libuavcan/libuavcan/include/uavcan/build_config.hpp File Reference

Go to the source code of this file.

Classes

struct  uavcan::IsDynamicallyAllocatable< T >
 

Namespaces

 uavcan
 

Macros

#define UAVCAN_ASSERT(x)   assert(x)
 
#define UAVCAN_CPP03   2003
 
#define UAVCAN_CPP11   2011
 
#define UAVCAN_CPP14   2014
 
#define UAVCAN_CPP17   2017
 
#define UAVCAN_CPP_VERSION   UAVCAN_CPP03
 
#define UAVCAN_DEBUG   0
 
#define UAVCAN_EXCEPTIONS   UAVCAN_GENERAL_PURPOSE_PLATFORM
 
#define UAVCAN_EXPORT
 
#define UAVCAN_GENERAL_PURPOSE_PLATFORM   0
 
#define UAVCAN_IMPLEMENT_PLACEMENT_NEW   0
 
#define UAVCAN_LIKELY(x)   (x)
 
#define UAVCAN_NO_ASSERTIONS   0
 
#define UAVCAN_NO_GLOBAL_DATA_TYPE_REGISTRY   0
 
#define UAVCAN_NOEXCEPT
 
#define UAVCAN_NULLPTR   NULL
 
#define UAVCAN_TINY   0
 
#define UAVCAN_TOSTRING   0
 
#define UAVCAN_UNLIKELY(x)   (x)
 
#define UAVCAN_USE_EXTERNAL_FLOAT16_CONVERSION   0
 
#define UAVCAN_USE_EXTERNAL_SNPRINTF   0
 
#define UAVCAN_VERSION_MAJOR   1
 
#define UAVCAN_VERSION_MINOR   0
 

Typedefs

typedef char uavcan::_alignment_check_for_MEM_POOL_BLOCK_SIZE[((MemPoolBlockSize &(MemPoolAlignment - 1))==0) ? 1 :-1]
 

Variables

static const unsigned uavcan::FloatComparisonEpsilonMult = 10
 
static const unsigned uavcan::MaxCanAcceptanceFilters = 32
 Default that should be OK for any platform. More...
 
static const unsigned uavcan::MemPoolAlignment = 16
 
static const unsigned uavcan::MemPoolBlockSize = 64
 Safe default that should be OK for any platform. More...
 

Macro Definition Documentation

◆ UAVCAN_ASSERT

#define UAVCAN_ASSERT (   x)    assert(x)

◆ UAVCAN_CPP03

#define UAVCAN_CPP03   2003

◆ UAVCAN_CPP11

#define UAVCAN_CPP11   2011

◆ UAVCAN_CPP14

#define UAVCAN_CPP14   2014

◆ UAVCAN_CPP17

#define UAVCAN_CPP17   2017

UAVCAN_CPP_VERSION - version of the C++ standard used during compilation. This definition contains the integer year number after which the standard was named:

  • 2003 for C++03
  • 2011 for C++11

This config automatically sets according to the actual C++ standard used by the compiler.

In C++03 mode the library has almost zero dependency on the C++ standard library, which allows to use it on platforms with a very limited C++ support. On the other hand, C++11 mode requires many parts of the standard library (e.g. <functional>), thus the user might want to force older standard than used by the compiler, in which case this symbol can be overridden manually via compiler flags.

Definition at line 28 of file libuavcan/libuavcan/include/uavcan/build_config.hpp.

◆ UAVCAN_CPP_VERSION

#define UAVCAN_CPP_VERSION   UAVCAN_CPP03

◆ UAVCAN_DEBUG

#define UAVCAN_DEBUG   0

This macro enables built-in runtime checks and debug output via printf(). Should be used only for library development.

Definition at line 75 of file libuavcan/libuavcan/include/uavcan/build_config.hpp.

◆ UAVCAN_EXCEPTIONS

#define UAVCAN_EXCEPTIONS   UAVCAN_GENERAL_PURPOSE_PLATFORM

This option allows to select whether libuavcan should throw exceptions on fatal errors, or try to handle errors differently. By default, exceptions will be enabled only if the library is built for a general-purpose OS like Linux. Set UAVCAN_EXCEPTIONS explicitly to override.

Definition at line 84 of file libuavcan/libuavcan/include/uavcan/build_config.hpp.

◆ UAVCAN_EXPORT

#define UAVCAN_EXPORT

◆ UAVCAN_GENERAL_PURPOSE_PLATFORM

#define UAVCAN_GENERAL_PURPOSE_PLATFORM   0

By default, libuavcan enables all features if it detects that it is being built for a general-purpose target like Linux. Value of this macro influences other configuration options located below in this file. This macro can be overriden if needed.

Definition at line 66 of file libuavcan/libuavcan/include/uavcan/build_config.hpp.

◆ UAVCAN_IMPLEMENT_PLACEMENT_NEW

#define UAVCAN_IMPLEMENT_PLACEMENT_NEW   0

Some C++ implementations are half-broken because they don't implement the placement new operator. If UAVCAN_IMPLEMENT_PLACEMENT_NEW is defined, libuavcan will implement its own operator new (std::size_t, void*) and its delete() counterpart, instead of relying on the standard header <new>.

Definition at line 153 of file libuavcan/libuavcan/include/uavcan/build_config.hpp.

◆ UAVCAN_LIKELY

#define UAVCAN_LIKELY (   x)    (x)

◆ UAVCAN_NO_ASSERTIONS

#define UAVCAN_NO_ASSERTIONS   0

Run time checks. Resolves to the standard assert() by default. Disabled completely if UAVCAN_NO_ASSERTIONS is defined.

Definition at line 179 of file libuavcan/libuavcan/include/uavcan/build_config.hpp.

◆ UAVCAN_NO_GLOBAL_DATA_TYPE_REGISTRY

#define UAVCAN_NO_GLOBAL_DATA_TYPE_REGISTRY   0

Disable the global data type registry, which can save some space on embedded systems.

Definition at line 125 of file libuavcan/libuavcan/include/uavcan/build_config.hpp.

◆ UAVCAN_NOEXCEPT

#define UAVCAN_NOEXCEPT

This specification is used by some error reporting functions like in the Logger class. The default can be overriden by defining the macro UAVCAN_NOEXCEPT explicitly, e.g. via compiler options.

Definition at line 99 of file libuavcan/libuavcan/include/uavcan/build_config.hpp.

◆ UAVCAN_NULLPTR

#define UAVCAN_NULLPTR   NULL

The library uses UAVCAN_NULLPTR instead of UAVCAN_NULLPTR and nullptr in order to allow the use of -Wzero-as-null-pointer-constant.

Definition at line 51 of file libuavcan/libuavcan/include/uavcan/build_config.hpp.

◆ UAVCAN_TINY

#define UAVCAN_TINY   0

Trade-off between ROM/RAM usage and functionality/determinism. Note that this feature is not well tested and should be avoided. Use code search for UAVCAN_TINY to find what functionality will be disabled. This is particularly useful for embedded systems with less than 40kB of ROM.

Definition at line 118 of file libuavcan/libuavcan/include/uavcan/build_config.hpp.

◆ UAVCAN_TOSTRING

#define UAVCAN_TOSTRING   0

toString() methods will be disabled by default, unless the library is built for a general-purpose target like Linux. It is not recommended to enable toString() on embedded targets as code size will explode.

Definition at line 136 of file libuavcan/libuavcan/include/uavcan/build_config.hpp.

◆ UAVCAN_UNLIKELY

#define UAVCAN_UNLIKELY (   x)    (x)

◆ UAVCAN_USE_EXTERNAL_FLOAT16_CONVERSION

#define UAVCAN_USE_EXTERNAL_FLOAT16_CONVERSION   0

Allows the user's application to provide a custom implementation of IEEE754Converter::nativeIeeeToHalf and IEEE754Converter::halfToNativeIeee.

Definition at line 169 of file libuavcan/libuavcan/include/uavcan/build_config.hpp.

◆ UAVCAN_USE_EXTERNAL_SNPRINTF

#define UAVCAN_USE_EXTERNAL_SNPRINTF   0

Allows the user's application to provide custom implementation of uavcan::snprintf(), which is often useful on deeply embedded systems.

Definition at line 161 of file libuavcan/libuavcan/include/uavcan/build_config.hpp.

◆ UAVCAN_VERSION_MAJOR

#define UAVCAN_VERSION_MAJOR   1

UAVCAN version definition

Definition at line 11 of file libuavcan/libuavcan/include/uavcan/build_config.hpp.

◆ UAVCAN_VERSION_MINOR

#define UAVCAN_VERSION_MINOR   0


uavcan_communicator
Author(s):
autogenerated on Fri Dec 13 2024 03:10:03