diff options
Diffstat (limited to 'stmhal/boards/STM32F4DISC')
-rw-r--r-- | stmhal/boards/STM32F4DISC/mpconfigboard.h | 5 | ||||
-rw-r--r-- | stmhal/boards/STM32F4DISC/staccel.py | 1 |
2 files changed, 3 insertions, 3 deletions
diff --git a/stmhal/boards/STM32F4DISC/mpconfigboard.h b/stmhal/boards/STM32F4DISC/mpconfigboard.h index 01202e0c95..841bf7d15b 100644 --- a/stmhal/boards/STM32F4DISC/mpconfigboard.h +++ b/stmhal/boards/STM32F4DISC/mpconfigboard.h @@ -82,9 +82,8 @@ #define MICROPY_HW_LED2 (pin_D12) // green #define MICROPY_HW_LED3 (pin_D13) // orange #define MICROPY_HW_LED4 (pin_D15) // blue -#define MICROPY_HW_LED_OTYPE (GPIO_MODE_OUTPUT_PP) -#define MICROPY_HW_LED_ON(pin) (pin->gpio->BSRRL = pin->pin_mask) -#define MICROPY_HW_LED_OFF(pin) (pin->gpio->BSRRH = pin->pin_mask) +#define MICROPY_HW_LED_ON(pin) (mp_hal_pin_high(pin)) +#define MICROPY_HW_LED_OFF(pin) (mp_hal_pin_low(pin)) // USB config #define MICROPY_HW_USB_VBUS_DETECT_PIN (pin_A9) diff --git a/stmhal/boards/STM32F4DISC/staccel.py b/stmhal/boards/STM32F4DISC/staccel.py index 7296662cac..2f2561d1cb 100644 --- a/stmhal/boards/STM32F4DISC/staccel.py +++ b/stmhal/boards/STM32F4DISC/staccel.py @@ -14,6 +14,7 @@ See: STM32Cube_FW_F4_V1.1.0/Projects/STM32F4-Discovery/Demonstrations/Src/main.c """ +from micropython import const from pyb import Pin from pyb import SPI |