circuitpython/ports/stm32/boards/NUCLEO_L432KC/mpconfigboard.h
Damien George 799b6d1e0c extmod: Consolidate FAT FS config to MICROPY_VFS_FAT across all ports.
This commit removes the Makefile-level MICROPY_FATFS config and moves the
MICROPY_VFS_FAT config to the Makefile level to replace it.  It also moves
the include of the oofatfs source files in the build from each port to a
central place in extmod/extmod.mk.

For a port to enabled VFS FAT support it should now set MICROPY_VFS_FAT=1
at the level of the Makefile.  This will include the relevant oofatfs files
in the build and set MICROPY_VFS_FAT=1 at the C (preprocessor) level.
2019-11-11 11:37:38 +11:00

68 lines
2.2 KiB
C

#define MICROPY_HW_BOARD_NAME "NUCLEO-L432KC"
#define MICROPY_HW_MCU_NAME "STM32L432KC"
#define MICROPY_EMIT_THUMB (0)
#define MICROPY_EMIT_INLINE_THUMB (0)
#define MICROPY_PY_BUILTINS_COMPLEX (0)
#define MICROPY_PY_USOCKET (0)
#define MICROPY_PY_NETWORK (0)
#define MICROPY_PY_STM (0)
#define MICROPY_PY_PYB_LEGACY (0)
#define MICROPY_HW_ENABLE_INTERNAL_FLASH_STORAGE (0)
#define MICROPY_HW_ENABLE_RTC (1)
#define MICROPY_HW_ENABLE_ADC (1)
#define MICROPY_HW_ENABLE_DAC (1)
#define MICROPY_HW_ENABLE_USB (0) // requires a custom USB connector on PA11/PA12
#define MICROPY_HW_ENABLE_TIMER (1)
#define MICROPY_HW_HAS_SWITCH (0)
// MSI is used and is 4MHz
#define MICROPY_HW_CLK_PLLM (1)
#define MICROPY_HW_CLK_PLLN (16)
#define MICROPY_HW_CLK_PLLR (2)
#define MICROPY_HW_CLK_PLLP (7)
#define MICROPY_HW_CLK_PLLQ (2)
// The board has an external 32kHz crystal
#define MICROPY_HW_RTC_USE_LSE (1)
// UART config
#define MICROPY_HW_UART1_TX (pin_B6)
#define MICROPY_HW_UART1_RX (pin_B7)
#define MICROPY_HW_UART2_TX (pin_A2) // VCP TX
#define MICROPY_HW_UART2_RX (pin_A15) // VCP RX
#define MICROPY_HW_UART_REPL PYB_UART_2
#define MICROPY_HW_UART_REPL_BAUD 115200
#define MICROPY_HW_FLASH_LATENCY FLASH_LATENCY_4
// I2C busses
#define MICROPY_HW_I2C1_SCL (pin_A9)
#define MICROPY_HW_I2C1_SDA (pin_A10)
#define MICROPY_HW_I2C3_SCL (pin_A7)
#define MICROPY_HW_I2C3_SDA (pin_B4)
// SPI busses
#define MICROPY_HW_SPI1_NSS (pin_B0)
#define MICROPY_HW_SPI1_SCK (pin_A5)
#define MICROPY_HW_SPI1_MISO (pin_A6)
#define MICROPY_HW_SPI1_MOSI (pin_A7)
#define MICROPY_HW_SPI3_NSS (pin_A4)
#define MICROPY_HW_SPI3_SCK (pin_B3)
#define MICROPY_HW_SPI3_MISO (pin_B4)
#define MICROPY_HW_SPI3_MOSI (pin_B5)
// LEDs
#define MICROPY_HW_LED1 (pin_B3) // Green LD3 LED on Nucleo
#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_FS (MICROPY_HW_ENABLE_USB)
#define MICROPY_HW_USB_MSC (0)
#define MICROPY_HW_USB_HID (0)
#define USBD_CDC_RX_DATA_SIZE (256)
#define USBD_CDC_TX_DATA_SIZE (256)