Add missing define

This commit is contained in:
Hierophect 2019-11-15 13:19:37 -05:00
parent ee1559b921
commit 98fd372d5b
2 changed files with 15 additions and 0 deletions

View File

@ -31,6 +31,17 @@
#include "stm32f4/pins.h" #include "stm32f4/pins.h"
#include "stm32f4xx_hal.h" #include "stm32f4xx_hal.h"
#ifdef MICROPY_HW_NEOPIXEL
bool neopixel_in_use;
#endif
#ifdef MICROPY_HW_APA102_MOSI
bool apa102_sck_in_use;
bool apa102_mosi_in_use;
#endif
#ifdef SPEAKER_ENABLE_PIN
bool speaker_enable_in_use;
#endif
#if MCU_PACKAGE == 144 #if MCU_PACKAGE == 144
#define GPIO_PORT_COUNT 7 #define GPIO_PORT_COUNT 7
GPIO_TypeDef * ports[GPIO_PORT_COUNT] = {GPIOA, GPIOB, GPIOC, GPIOD, GPIOE, GPIOF, GPIOG}; GPIO_TypeDef * ports[GPIO_PORT_COUNT] = {GPIOA, GPIOB, GPIOC, GPIOD, GPIOE, GPIOF, GPIOG};

View File

@ -34,6 +34,10 @@
#ifdef MICROPY_HW_NEOPIXEL #ifdef MICROPY_HW_NEOPIXEL
extern bool neopixel_in_use; extern bool neopixel_in_use;
#endif #endif
#ifdef MICROPY_HW_APA102_MOSI
extern bool apa102_sck_in_use;
extern bool apa102_mosi_in_use;
#endif
void reset_all_pins(void); void reset_all_pins(void);
// reset_pin_number takes the pin number instead of the pointer so that objects don't // reset_pin_number takes the pin number instead of the pointer so that objects don't