libuav original

Dependents:   UAVCAN UAVCAN_Subscriber

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers build_config.hpp Source File

build_config.hpp

00001 /*
00002  * Copyright (C) 2015 Pavel Kirienko <pavel.kirienko@gmail.com>
00003  */
00004 
00005 #pragma once
00006 
00007 /**
00008  * OS detection
00009  */
00010 #ifndef UAVCAN_STM32_CHIBIOS
00011 # define UAVCAN_STM32_CHIBIOS 0
00012 #endif
00013 
00014 #ifndef UAVCAN_STM32_NUTTX
00015 # define UAVCAN_STM32_NUTTX 0
00016 #endif
00017 
00018 #ifndef UAVCAN_STM32_BAREMETAL
00019 # define UAVCAN_STM32_BAREMETAL 0
00020 #endif
00021 
00022 #ifndef UAVCAN_STM32_FREERTOS
00023 # define UAVCAN_STM32_FREERTOS 0
00024 #endif
00025 
00026 /**
00027  * Number of interfaces must be enabled explicitly
00028  */
00029 #if !defined(UAVCAN_STM32_NUM_IFACES) || (UAVCAN_STM32_NUM_IFACES != 1 && UAVCAN_STM32_NUM_IFACES != 2)
00030 # error "UAVCAN_STM32_NUM_IFACES must be set to either 1 or 2"
00031 #endif
00032 
00033 /**
00034  * Any General-Purpose timer (TIM2, TIM3, TIM4, TIM5)
00035  * e.g. -DUAVCAN_STM32_TIMER_NUMBER=2
00036  */
00037 #ifndef UAVCAN_STM32_TIMER_NUMBER
00038 // In this case the clock driver should be implemented by the application
00039 # define UAVCAN_STM32_TIMER_NUMBER 0
00040 #endif