mirror of
https://github.com/RIOT-OS/RIOT.git
synced 2024-12-29 04:50:03 +01:00
makefiles/tools/serial.inc.mk: Improve PORT selection
When `stdio_cdc_acm` is used, assume `"RIOT-os\.org"` as vendor string
and `$(BOARD)` being used as model string. This is the default
behavior in RIOT since eaace28804
This commit is contained in:
parent
eaace28804
commit
78de9a3f53
@ -1,7 +1,11 @@
|
||||
# Select the most recently attached tty interface
|
||||
ifeq (1,$(MOST_RECENT_PORT))
|
||||
ifneq (,$(filter stdio_cdc_acm,$(USEMODULE)))
|
||||
TTY_BOARD_FILTER ?= --model $(BOARD) --vendor 'RIOT-os\.org'
|
||||
endif
|
||||
TTYS_FLAGS := --most-recent --format path $(TTY_BOARD_FILTER)
|
||||
PORT ?= $(shell $(RIOTTOOLS)/usb-serial/ttys.py $(TTYS_FLAGS))
|
||||
PORT_DETECTED := $(shell $(RIOTTOOLS)/usb-serial/ttys.py $(TTYS_FLAGS))
|
||||
PORT ?= $(PORT_DETECTED)
|
||||
endif
|
||||
# Otherwise, use as default the most commonly used ports on Linux and OSX
|
||||
PORT_LINUX ?= /dev/ttyACM0
|
||||
|
Loading…
Reference in New Issue
Block a user