2015-04-22 15:41:37 +02:00
|
|
|
# set default port depending on operating system
|
|
|
|
ifeq ($(OS),Linux)
|
2018-11-06 18:59:15 +01:00
|
|
|
PORT ?= $(call ensure_value,$(PORT_LINUX),No port set)
|
2015-04-22 15:41:37 +02:00
|
|
|
else ifeq ($(OS),Darwin)
|
2018-11-06 18:59:15 +01:00
|
|
|
PORT ?= $(call ensure_value,$(PORT_DARWIN),No port set)
|
2015-04-22 15:41:37 +02:00
|
|
|
endif
|
|
|
|
|
2019-10-15 14:17:47 +02:00
|
|
|
# Default PROG_DEV is the same as PORT
|
|
|
|
PROG_DEV ?= $(PORT)
|
|
|
|
|
2015-04-22 15:41:37 +02:00
|
|
|
export BAUD ?= 115200
|
|
|
|
|
2017-10-23 15:19:30 +02:00
|
|
|
RIOT_TERMINAL ?= pyterm
|
|
|
|
ifeq ($(RIOT_TERMINAL),pyterm)
|
2019-02-25 16:46:44 +01:00
|
|
|
TERMPROG ?= $(RIOTTOOLS)/pyterm/pyterm
|
2019-08-27 12:07:00 +02:00
|
|
|
TERMFLAGS ?= -p "$(PORT)" -b "$(BAUD)" $(PYTERMFLAGS)
|
2019-02-20 08:30:33 +01:00
|
|
|
else ifeq ($(RIOT_TERMINAL),socat)
|
|
|
|
SOCAT_OUTPUT ?= -
|
2019-02-25 16:46:44 +01:00
|
|
|
TERMPROG ?= $(RIOT_TERMINAL)
|
|
|
|
TERMFLAGS ?= $(SOCAT_OUTPUT) open:$(PORT),b$(BAUD),echo=0,raw
|
2017-10-23 15:19:30 +02:00
|
|
|
else ifeq ($(RIOT_TERMINAL),picocom)
|
2019-02-25 16:46:44 +01:00
|
|
|
TERMPROG ?= picocom
|
2019-02-25 16:56:00 +01:00
|
|
|
TERMFLAGS ?= --nolock --imap lfcrlf --baud "$(BAUD)" "$(PORT)"
|
2019-11-19 15:06:46 +01:00
|
|
|
else ifeq ($(RIOT_TERMINAL),miniterm)
|
|
|
|
TERMPROG ?= miniterm.py
|
|
|
|
# The RIOT shell will still transmit back a CRLF, but at least with --eol LF
|
|
|
|
# we avoid sending two lines on every "enter".
|
|
|
|
TERMFLAGS ?= --eol LF "$(PORT)" "$(BAUD)"
|
2017-10-18 12:24:24 +02:00
|
|
|
endif
|