diff --git a/boards/adafruit-clue/Kconfig b/boards/adafruit-clue/Kconfig index dcfad32ed9..a92ae326da 100644 --- a/boards/adafruit-clue/Kconfig +++ b/boards/adafruit-clue/Kconfig @@ -16,6 +16,6 @@ config BOARD_ADAFRUIT_CLUE select HAS_PERIPH_SPI select HAS_PERIPH_UART select HAS_PERIPH_USBDEV - select HAS_BOOTLOADER_NRFUTIL + select HAS_HIGHLEVEL_STDIO source "$(RIOTBOARD)/common/nrf52/Kconfig" diff --git a/boards/adafruit-clue/Makefile.dep b/boards/adafruit-clue/Makefile.dep index 130b71241b..b3b6754b6b 100644 --- a/boards/adafruit-clue/Makefile.dep +++ b/boards/adafruit-clue/Makefile.dep @@ -9,7 +9,7 @@ endif # use nrfutil-bootloader/stdio_cdc_acm only if no other stdio_% other than stdio_cdc_acm # is requested ifeq (,$(filter-out stdio_cdc_acm,$(filter stdio_% slipdev_stdio,$(USEMODULE)))) - FEATURES_REQUIRED += bootloader_nrfutil + FEATURES_REQUIRED += highlevel_stdio USEMODULE += usb_board_reset USEMODULE += stdio_cdc_acm endif diff --git a/boards/adafruit-clue/Makefile.features b/boards/adafruit-clue/Makefile.features index 83012828ed..1f4969f6d9 100644 --- a/boards/adafruit-clue/Makefile.features +++ b/boards/adafruit-clue/Makefile.features @@ -7,6 +7,6 @@ FEATURES_PROVIDED += periph_uart FEATURES_PROVIDED += periph_usbdev # Various other features (if any) -FEATURES_PROVIDED += bootloader_nrfutil +FEATURES_PROVIDED += highlevel_stdio include $(RIOTBOARD)/common/nrf52/Makefile.features diff --git a/boards/adafruit-itsybitsy-nrf52/Kconfig b/boards/adafruit-itsybitsy-nrf52/Kconfig index 622df25665..24655e4205 100644 --- a/boards/adafruit-itsybitsy-nrf52/Kconfig +++ b/boards/adafruit-itsybitsy-nrf52/Kconfig @@ -16,6 +16,6 @@ config BOARD_ADAFRUIT_ITSYBITSY_NRF52 select HAS_PERIPH_SPI select HAS_PERIPH_UART select HAS_PERIPH_USBDEV - select HAS_BOOTLOADER_NRFUTIL + select HAS_HIGHLEVEL_STDIO source "$(RIOTBOARD)/common/nrf52/Kconfig" diff --git a/boards/adafruit-itsybitsy-nrf52/Makefile.dep b/boards/adafruit-itsybitsy-nrf52/Makefile.dep index 18e5d17c60..6c6293050f 100644 --- a/boards/adafruit-itsybitsy-nrf52/Makefile.dep +++ b/boards/adafruit-itsybitsy-nrf52/Makefile.dep @@ -9,7 +9,7 @@ endif # enable bootloader reset over USB, requires USB bootloader to be used ifneq (,$(filter stdio_cdc_acm,$(USEMODULE))) - FEATURES_REQUIRED += bootloader_nrfutil + FEATURES_REQUIRED += highlevel_stdio USEMODULE += usb_board_reset endif diff --git a/boards/adafruit-itsybitsy-nrf52/Makefile.features b/boards/adafruit-itsybitsy-nrf52/Makefile.features index 83012828ed..1f4969f6d9 100644 --- a/boards/adafruit-itsybitsy-nrf52/Makefile.features +++ b/boards/adafruit-itsybitsy-nrf52/Makefile.features @@ -7,6 +7,6 @@ FEATURES_PROVIDED += periph_uart FEATURES_PROVIDED += periph_usbdev # Various other features (if any) -FEATURES_PROVIDED += bootloader_nrfutil +FEATURES_PROVIDED += highlevel_stdio include $(RIOTBOARD)/common/nrf52/Makefile.features diff --git a/boards/arduino-nano-33-ble/Kconfig b/boards/arduino-nano-33-ble/Kconfig index b3dcc23c49..0c943d1d7f 100644 --- a/boards/arduino-nano-33-ble/Kconfig +++ b/boards/arduino-nano-33-ble/Kconfig @@ -16,6 +16,6 @@ config BOARD_ARDUINO_NANO_33_BLE select HAS_PERIPH_SPI select HAS_PERIPH_UART select HAS_PERIPH_USBDEV - select HAS_BOOTLOADER_ARDUINO + select HAS_HIGHLEVEL_STDIO source "$(RIOTBOARD)/common/nrf52/Kconfig" diff --git a/boards/arduino-nano-33-ble/Makefile.dep b/boards/arduino-nano-33-ble/Makefile.dep index f13bbd3c9b..6d4f260117 100644 --- a/boards/arduino-nano-33-ble/Makefile.dep +++ b/boards/arduino-nano-33-ble/Makefile.dep @@ -9,7 +9,7 @@ ifeq (,$(filter-out stdio_cdc_acm,$(filter stdio_% slipdev_stdio,$(USEMODULE)))) USEMODULE += stdio_cdc_acm # This board requires support for Arduino bootloader. - FEATURES_REQUIRED += bootloader_arduino + FEATURES_REQUIRED += highlevel_stdio USEMODULE += usb_board_reset endif diff --git a/boards/arduino-nano-33-ble/Makefile.features b/boards/arduino-nano-33-ble/Makefile.features index a116c39cbb..1f4969f6d9 100644 --- a/boards/arduino-nano-33-ble/Makefile.features +++ b/boards/arduino-nano-33-ble/Makefile.features @@ -7,6 +7,6 @@ FEATURES_PROVIDED += periph_uart FEATURES_PROVIDED += periph_usbdev # Various other features (if any) -FEATURES_PROVIDED += bootloader_arduino +FEATURES_PROVIDED += highlevel_stdio include $(RIOTBOARD)/common/nrf52/Makefile.features diff --git a/boards/common/arduino-mkr/Kconfig b/boards/common/arduino-mkr/Kconfig index 7ba19c6de8..e9f9185348 100644 --- a/boards/common/arduino-mkr/Kconfig +++ b/boards/common/arduino-mkr/Kconfig @@ -18,4 +18,4 @@ config BOARD_COMMON_ARDUINO_MKR select HAS_PERIPH_USBDEV select HAS_ARDUINO select HAS_ARDUINO_PWM - select HAS_BOOTLOADER_ARDUINO + select HAS_HIGHLEVEL_STDIO diff --git a/boards/common/arduino-mkr/Makefile.features b/boards/common/arduino-mkr/Makefile.features index 08c79c508c..9888bd0a69 100644 --- a/boards/common/arduino-mkr/Makefile.features +++ b/boards/common/arduino-mkr/Makefile.features @@ -16,4 +16,4 @@ FEATURES_PROVIDED += periph_usbdev # Various other features (if any) FEATURES_PROVIDED += arduino FEATURES_PROVIDED += arduino_pwm -FEATURES_PROVIDED += bootloader_arduino +FEATURES_PROVIDED += highlevel_stdio diff --git a/boards/common/samd21-arduino-bootloader/Makefile.dep b/boards/common/samd21-arduino-bootloader/Makefile.dep index d1c9d54246..8d7365a9d2 100644 --- a/boards/common/samd21-arduino-bootloader/Makefile.dep +++ b/boards/common/samd21-arduino-bootloader/Makefile.dep @@ -2,4 +2,4 @@ USEMODULE += usb_board_reset USEMODULE += stdio_cdc_acm -FEATURES_REQUIRED += bootloader_arduino +FEATURES_REQUIRED += highlevel_stdio diff --git a/boards/common/sodaq/Kconfig b/boards/common/sodaq/Kconfig index 20e893ce21..5199c476e7 100644 --- a/boards/common/sodaq/Kconfig +++ b/boards/common/sodaq/Kconfig @@ -15,4 +15,4 @@ config BOARD_COMMON_SODAQ select HAS_PERIPH_UART select HAS_PERIPH_USBDEV select HAS_ARDUINO - select HAS_BOOTLOADER_ARDUINO + select HAS_HIGHLEVEL_STDIO diff --git a/boards/common/sodaq/Makefile.features b/boards/common/sodaq/Makefile.features index 4cc1f1a620..4f6613e8d7 100644 --- a/boards/common/sodaq/Makefile.features +++ b/boards/common/sodaq/Makefile.features @@ -12,4 +12,4 @@ FEATURES_PROVIDED += periph_usbdev # Various other features (if any) FEATURES_PROVIDED += arduino -FEATURES_PROVIDED += bootloader_arduino +FEATURES_PROVIDED += highlevel_stdio diff --git a/boards/feather-m0-wifi/Kconfig b/boards/feather-m0-wifi/Kconfig index 1cac9ec03b..ba275b78a4 100644 --- a/boards/feather-m0-wifi/Kconfig +++ b/boards/feather-m0-wifi/Kconfig @@ -20,4 +20,4 @@ config BOARD_FEATHER_M0_WIFI select HAS_PERIPH_TIMER select HAS_PERIPH_UART select HAS_PERIPH_USBDEV - select HAS_BOOTLOADER_ARDUINO + select HAS_HIGHLEVEL_STDIO diff --git a/boards/feather-m0/Kconfig b/boards/feather-m0/Kconfig index 73190a0167..cded0d326b 100644 --- a/boards/feather-m0/Kconfig +++ b/boards/feather-m0/Kconfig @@ -20,4 +20,4 @@ config BOARD_FEATHER_M0 select HAS_PERIPH_TIMER select HAS_PERIPH_UART select HAS_PERIPH_USBDEV - select HAS_BOOTLOADER_ARDUINO + select HAS_HIGHLEVEL_STDIO diff --git a/boards/feather-m0/Makefile.features b/boards/feather-m0/Makefile.features index e1044fadd8..c43f111ff1 100644 --- a/boards/feather-m0/Makefile.features +++ b/boards/feather-m0/Makefile.features @@ -13,4 +13,4 @@ FEATURES_PROVIDED += periph_uart FEATURES_PROVIDED += periph_usbdev # Put other features for this board (in alphabetical order) -FEATURES_PROVIDED += bootloader_arduino +FEATURES_PROVIDED += highlevel_stdio diff --git a/boards/nrf52840dongle/Kconfig b/boards/nrf52840dongle/Kconfig index 0aa02499dd..e8f64a9a70 100644 --- a/boards/nrf52840dongle/Kconfig +++ b/boards/nrf52840dongle/Kconfig @@ -15,6 +15,6 @@ config BOARD_NRF52840DONGLE select HAS_PERIPH_PWM select HAS_PERIPH_UART select HAS_PERIPH_USBDEV - select HAS_BOOTLOADER_NRFUTIL + select HAS_HIGHLEVEL_STDIO source "$(RIOTBOARD)/common/nrf52/Kconfig" diff --git a/boards/nrf52840dongle/Makefile.dep b/boards/nrf52840dongle/Makefile.dep index 18e5d17c60..6c6293050f 100644 --- a/boards/nrf52840dongle/Makefile.dep +++ b/boards/nrf52840dongle/Makefile.dep @@ -9,7 +9,7 @@ endif # enable bootloader reset over USB, requires USB bootloader to be used ifneq (,$(filter stdio_cdc_acm,$(USEMODULE))) - FEATURES_REQUIRED += bootloader_nrfutil + FEATURES_REQUIRED += highlevel_stdio USEMODULE += usb_board_reset endif diff --git a/boards/nrf52840dongle/Makefile.features b/boards/nrf52840dongle/Makefile.features index 80543d4ff7..bd678939fe 100644 --- a/boards/nrf52840dongle/Makefile.features +++ b/boards/nrf52840dongle/Makefile.features @@ -6,6 +6,6 @@ FEATURES_PROVIDED += periph_uart FEATURES_PROVIDED += periph_usbdev # Various other features (if any) -FEATURES_PROVIDED += bootloader_nrfutil +FEATURES_PROVIDED += highlevel_stdio include $(RIOTBOARD)/common/nrf52/Makefile.features diff --git a/boards/serpente/Kconfig b/boards/serpente/Kconfig index 01af3e2cad..bec12c8bdf 100644 --- a/boards/serpente/Kconfig +++ b/boards/serpente/Kconfig @@ -11,7 +11,7 @@ config BOARD_SERPENTE bool default y select CPU_MODEL_SAMD21E18A - select HAS_BOOTLOADER_ARDUINO + select HAS_HIGHLEVEL_STDIO select HAS_PERIPH_ADC select HAS_PERIPH_I2C select HAS_PERIPH_PWM diff --git a/boards/serpente/Makefile.features b/boards/serpente/Makefile.features index d7a00f01b2..ec13b2408e 100644 --- a/boards/serpente/Makefile.features +++ b/boards/serpente/Makefile.features @@ -2,7 +2,7 @@ CPU = samd21 CPU_MODEL = samd21e18a # Put defined MCU peripherals here (in alphabetical order) -FEATURES_PROVIDED += bootloader_arduino +FEATURES_PROVIDED += highlevel_stdio FEATURES_PROVIDED += periph_adc FEATURES_PROVIDED += periph_i2c FEATURES_PROVIDED += periph_pwm diff --git a/boards/wemos-zero/Kconfig b/boards/wemos-zero/Kconfig index bd6e7e4455..82ccc05f9f 100644 --- a/boards/wemos-zero/Kconfig +++ b/boards/wemos-zero/Kconfig @@ -12,6 +12,6 @@ config BOARD_WEMOS_ZERO bool default y select BOARD_COMMON_ARDUINO_ZERO - select HAS_BOOTLOADER_ARDUINO + select HAS_HIGHLEVEL_STDIO source "$(RIOTBOARD)/common/arduino-zero/Kconfig" diff --git a/boards/wemos-zero/Makefile.features b/boards/wemos-zero/Makefile.features index d92557f453..2dbb57c787 100644 --- a/boards/wemos-zero/Makefile.features +++ b/boards/wemos-zero/Makefile.features @@ -1,3 +1,3 @@ include $(RIOTBOARD)/common/arduino-zero/Makefile.features -FEATURES_PROVIDED += bootloader_arduino +FEATURES_PROVIDED += highlevel_stdio diff --git a/cpu/nrf5x_common/Kconfig b/cpu/nrf5x_common/Kconfig index 1e725db870..473da08d67 100644 --- a/cpu/nrf5x_common/Kconfig +++ b/cpu/nrf5x_common/Kconfig @@ -21,11 +21,6 @@ config CPU_COMMON_NRF5X select HAS_RADIO_NRFMIN ## Definition of specific features -config HAS_BOOTLOADER_NRFUTIL - bool - help - Indicates that the nRF Util bootloader is being used. - config HAS_BLE_NIMBLE bool help diff --git a/kconfigs/Kconfig.features b/kconfigs/Kconfig.features index 1ce168aebb..c0f321edbc 100644 --- a/kconfigs/Kconfig.features +++ b/kconfigs/Kconfig.features @@ -42,11 +42,6 @@ config HAS_BACKUP_RAM help Indicates that Backup RAM is supported. -config HAS_BOOTLOADER_ARDUINO - bool - help - Indicates that the Arduino bootloader is used. - config HAS_CPP bool help @@ -67,6 +62,13 @@ config HAS_ETHERNET help Indicates that Ethernet connectivity is present. +config HAS_HIGHLEVEL_STDIO + bool + help + Indicates that a high-level stdio method (such as CDC ACM) is used. + This requires a running thread and set-up and will not print during + a crash. + config HAS_LIBSTDCPP bool help diff --git a/makefiles/stdio.inc.mk b/makefiles/stdio.inc.mk index 5c1d3bff22..1073ad3745 100644 --- a/makefiles/stdio.inc.mk +++ b/makefiles/stdio.inc.mk @@ -44,13 +44,6 @@ ifneq (,$(filter stdio_uart,$(USEMODULE))) FEATURES_REQUIRED += periph_uart endif -ifeq (,$(filter stdio_cdc_acm,$(USEMODULE))) - # The arduino and nrfutil bootloader features cannot be used if the - # stdio_cdc_acm module is not used - FEATURES_BLACKLIST += bootloader_arduino - FEATURES_BLACKLIST += bootloader_nrfutil -endif - ifneq (,$(filter stdio_semihosting,$(USEMODULE))) USEMODULE += xtimer FEATURES_REQUIRED += cpu_core_cortexm diff --git a/tests/ssp/Makefile b/tests/ssp/Makefile index 2dacca7f28..8c13adedf6 100644 --- a/tests/ssp/Makefile +++ b/tests/ssp/Makefile @@ -2,10 +2,9 @@ include ../Makefile.tests_common USEMODULE += ssp -# This test intentionally crashes the firmware and when using a board with a -# preflashed bootloader, it cannot be reflashed automatically afterwards. -FEATURES_BLACKLIST += bootloader_arduino -FEATURES_BLACKLIST += bootloader_nrfutil +# This test intentionally crashes the firmware and when using a board with +# stdio via CDC ACM, RIOT can't print anything after the crash. +FEATURES_BLACKLIST += highlevel_stdio include $(RIOTBASE)/Makefile.include diff --git a/tests/unittests/Makefile b/tests/unittests/Makefile index cee2d25466..e8a82e3638 100644 --- a/tests/unittests/Makefile +++ b/tests/unittests/Makefile @@ -13,12 +13,9 @@ endif DISABLE_MODULE += auto_init auto_init_% -# boards using a preflashed bootloader require auto_init to -# automatically initialize stdio over USB. Without this, the bootloader -# management feature cannot be used (auto reset and auto reboot in bootloader -# mode) -FEATURES_BLACKLIST += bootloader_arduino -FEATURES_BLACKLIST += bootloader_nrfutil +# boards using stdio via CDC ACM require auto_init to automatically +# initialize stdio over USB. +FEATURES_BLACKLIST += highlevel_stdio # Pull in `Makefile.include`s from the test suites: -include $(UNIT_TESTS:%=$(RIOTBASE)/tests/unittests/%/Makefile.include)