Fix errors and some compiler warnings with HAL_STM32 PlatformIO build (#12869)

This commit is contained in:
Karl Andersson
2019-01-11 02:01:31 +01:00
committed by Scott Lahteine
parent e6484d9dab
commit 8ae6f1e556
5 changed files with 14 additions and 16 deletions

View File

@ -24,10 +24,6 @@
#define CPU_32_BIT
#ifndef vsnprintf_P
#define vsnprintf_P vsnprintf
#endif
// --------------------------------------------------------------------------
// Includes
// --------------------------------------------------------------------------
@ -105,8 +101,6 @@
#define NUM_SERIAL 1
#endif
#define _BV(b) (1 << (b))
/**
* TODO: review this to return 1 for pins that are not analog input
*/
@ -177,7 +171,7 @@ void _delay_ms(const int delay);
extern "C" char* _sbrk(int incr);
static int freeMemory() {
static inline int freeMemory() {
volatile char top;
return &top - reinterpret_cast<char*>(_sbrk(0));
}

View File

@ -43,7 +43,6 @@ void FastIO_init(); // Must be called before using fast io macros
// Defines
// --------------------------------------------------------------------------
#define _BV(b) (1 << (b))
#define _BV32(b) (1UL << (b))
#if defined(STM32F0xx) || defined(STM32F1xx) || defined(STM32F3xx) || defined(STM32L0xx) || defined(STM32L4xx)