Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

boards/stm32f4discovery: default to stdio via CDC ACM #19259

Merged
merged 2 commits into from
Feb 10, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions boards/stm32f4discovery/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,21 @@ config BOARD_STM32F4DISCOVERY
# Various other features (if any)
select HAS_ARDUINO
select HAS_TINYUSB_DEVICE
select HAS_HIGHLEVEL_STDIO

# Clock configuration
select BOARD_HAS_HSE

select HAVE_SAUL_GPIO

select MODULE_USBUS if TEST_KCONFIG && !PACKAGE_TINYUSB
select MODULE_USBUS_CDC_ACM if TEST_KCONFIG && !PACKAGE_TINYUSB

choice STDIO_IMPLEMENTATION
default MODULE_STDIO_CDC_ACM if MODULE_USBUS
default MODULE_STDIO_TINYUSB_CDC_ACM if PACKAGE_TINYUSB
endchoice

source "$(RIOTBOARD)/common/stm32/Kconfig"

config ERROR_MODULES_CONFLICT
Expand Down
2 changes: 2 additions & 0 deletions boards/stm32f4discovery/Makefile.dep
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
ifneq (,$(filter saul_default,$(USEMODULE)))
USEMODULE += saul_gpio
endif

include $(RIOTBOARD)/common/makefiles/stdio_cdc_acm.dep.mk
2 changes: 2 additions & 0 deletions boards/stm32f4discovery/Makefile.features
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ FEATURES_PROVIDED += periph_usbdev
FEATURES_PROVIDED += arduino
FEATURES_PROVIDED += tinyusb_device

FEATURES_PROVIDED += highlevel_stdio

# TODO: re-think concept for conflicts based on actual used peripherals...
FEATURES_CONFLICT += periph_spi:periph_dac
FEATURES_CONFLICT_MSG += "On stm32f4discovery boards there are the same pins for the DAC and/or SPI_0."
4 changes: 4 additions & 0 deletions boards/stm32f4discovery/doc.txt
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,11 @@ arbitrary and can be altered by editing the
LEDs LD7 and LD8 are used by the USB connector for over-current (LD8) and
data (LD7) indication.

### USB Device Interface

The board has a micro USB port that can be used for USB device mode.
As the ST-Link on the board does not provide a USB-UART interface, the STDIO is
mapped to the micro USB port by default (via CDC ACM).

### Accelerometer

Expand Down
1 change: 1 addition & 0 deletions tests/xtimer_now32_overflow/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ BOARD_BLACKLIST += \
pinetime \
ruuvitag \
stm32f429i-disco \
stm32f4discovery \
thingy52 \
waspmote-pro \
weact-f401cc \
Expand Down
1 change: 1 addition & 0 deletions tests/xtimer_now64_continuity/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ BOARD_BLACKLIST += \
pinetime \
ruuvitag \
stm32f429i-disco \
stm32f4discovery \
thingy52 \
waspmote-pro \
weact-f401cc \
Expand Down