update credits
[librepilot.git] / flight / pios / stm32f30x / inc / pios_architecture.h
blobdddc4df639bda20ffbdb59b6a1bc72c5f21d17a5
1 /**
2 ******************************************************************************
4 * @file pios_architecture.h
5 * @author The OpenPilot Team, http://www.openpilot.org Copyright (C) 2013.
6 * @brief Architecture specific macros and definitions
7 * --
8 * @see The GNU Public License (GPL) Version 3
10 *****************************************************************************/
12 * This program is free software; you can redistribute it and/or modify
13 * it under the terms of the GNU General Public License as published by
14 * the Free Software Foundation; either version 3 of the License, or
15 * (at your option) any later version.
17 * This program is distributed in the hope that it will be useful, but
18 * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
19 * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
20 * for more details.
22 * You should have received a copy of the GNU General Public License along
23 * with this program; if not, write to the Free Software Foundation, Inc.,
24 * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
27 #ifndef PIOS_ARCHITECTURE_H
28 #define PIOS_ARCHITECTURE_H
30 // defines for adc
31 #define PIOS_ADC_VOLTAGE_SCALE 3.30f / 4096.0f
33 // defines for Temp measurements
34 #define PIOS_ADC_STM32_TEMP_V25 0.76f /* V */
35 #define PIOS_ADC_STM32_TEMP_AVG_SLOPE 2.5f /* mV/C */
36 #define PIOS_CONVERT_VOLT_TO_CPU_TEMP(x) ((x - PIOS_ADC_STM32_TEMP_V25) * 1000.0f / PIOS_ADC_STM32_TEMP_AVG_SLOPE + 25.0f)
39 #endif /* PIOS_ARCHITECTURE_H */