2019-12-05 22:45:53 -05:00
|
|
|
# All linking can be done with this common templated linker script, which has
|
|
|
|
# parameters that vary based on chip and/or board.
|
|
|
|
LD_TEMPLATE_FILE = boards/common.template.ld
|
|
|
|
|
2017-12-21 07:49:14 -05:00
|
|
|
# Define an equivalent for MICROPY_LONGINT_IMPL, to pass to $(MPY-TOOL) in py/mkrules.mk
|
|
|
|
# $(MPY-TOOL) needs to know what kind of longint to use (if any) to freeze long integers.
|
|
|
|
# This should correspond to the MICROPY_LONGINT_IMPL definition in mpconfigport.h.
|
|
|
|
MPY_TOOL_LONGINT_IMPL = -mlongint-impl=mpz
|
2018-01-02 21:25:41 -05:00
|
|
|
|
2019-02-15 18:55:10 -05:00
|
|
|
INTERNAL_LIBM = 1
|
2018-01-02 21:25:41 -05:00
|
|
|
|
2018-10-19 21:46:22 -04:00
|
|
|
USB_SERIAL_NUMBER_LENGTH = 16
|
2019-02-15 18:55:10 -05:00
|
|
|
|
2019-02-17 17:29:28 -05:00
|
|
|
# All nRF ports have longints.
|
|
|
|
LONGINT_IMPL = MPZ
|
|
|
|
|
2019-07-15 20:56:21 -04:00
|
|
|
# Audio via PWM
|
2019-11-22 15:44:51 -05:00
|
|
|
ifndef CIRCUITPY_AUDIOCORE
|
2019-07-15 20:56:21 -04:00
|
|
|
CIRCUITPY_AUDIOCORE = 1
|
2019-11-22 15:44:51 -05:00
|
|
|
endif
|
|
|
|
|
2019-02-15 18:55:10 -05:00
|
|
|
CIRCUITPY_AUDIOIO = 0
|
2019-11-22 15:44:51 -05:00
|
|
|
|
2019-12-05 22:45:53 -05:00
|
|
|
|
2019-11-22 16:30:10 -05:00
|
|
|
# The ifndef's allow overriding in mpconfigboard.mk.
|
|
|
|
|
2019-12-05 22:45:53 -05:00
|
|
|
ifndef
|
|
|
|
CIRCUITPY_BLEIO = 1
|
|
|
|
endif
|
|
|
|
|
2019-11-22 15:44:51 -05:00
|
|
|
ifndef CIRCUITPY_AUDIOMIXER
|
2019-08-25 08:32:48 -04:00
|
|
|
CIRCUITPY_AUDIOMIXER = 1
|
2019-11-22 15:44:51 -05:00
|
|
|
endif
|
|
|
|
|
|
|
|
ifndef CIRCUITPY_AUDIOPWMIO
|
2019-07-15 20:56:21 -04:00
|
|
|
CIRCUITPY_AUDIOPWMIO = 1
|
2019-11-22 15:44:51 -05:00
|
|
|
endif
|
|
|
|
|
|
|
|
ifndef CIRCUITPY_AUDIOBUSIO
|
2019-08-14 20:52:55 -04:00
|
|
|
CIRCUITPY_AUDIOBUSIO = 1
|
2019-11-22 15:44:51 -05:00
|
|
|
endif
|
2019-02-15 18:55:10 -05:00
|
|
|
|
|
|
|
# No I2CSlave implementation
|
|
|
|
CIRCUITPY_I2CSLAVE = 0
|
|
|
|
|
2019-03-28 12:29:18 -04:00
|
|
|
# enable RTC
|
2019-11-22 15:44:51 -05:00
|
|
|
ifndef CIRCUITPY_RTC
|
2019-02-02 02:38:10 -05:00
|
|
|
CIRCUITPY_RTC = 1
|
2019-11-22 15:44:51 -05:00
|
|
|
endif
|
2019-03-01 23:46:57 -05:00
|
|
|
|
|
|
|
# frequencyio not yet implemented
|
|
|
|
CIRCUITPY_FREQUENCYIO = 0
|
2019-03-21 11:22:58 -04:00
|
|
|
|
2019-12-05 22:45:53 -05:00
|
|
|
# nRF52840-specific
|
|
|
|
|
2019-12-10 17:57:17 -05:00
|
|
|
ifeq ($(MCU_CHIP),nrf52840)
|
2019-12-05 22:45:53 -05:00
|
|
|
MCU_SERIES = m4
|
|
|
|
MCU_VARIANT = nrf52
|
|
|
|
MCU_SUB_VARIANT = nrf52840
|
|
|
|
|
|
|
|
SD ?= s140
|
|
|
|
SOFTDEV_VERSION ?= 6.1.0
|
|
|
|
|
|
|
|
BOOT_SETTING_ADDR = 0xFF000
|
|
|
|
NRF_DEFINES += -DNRF52840_XXAA -DNRF52840
|
|
|
|
|
2019-03-21 11:22:58 -04:00
|
|
|
# CircuitPython doesn't yet support NFC so force the NFC antenna pins to be GPIO.
|
|
|
|
# See https://github.com/adafruit/circuitpython/issues/1300
|
|
|
|
# Defined here because system_nrf52840.c doesn't #include any of our own include files.
|
|
|
|
CFLAGS += -DCONFIG_NFCT_PINS_AS_GPIOS
|
2019-12-05 22:45:53 -05:00
|
|
|
|
2020-02-04 11:24:37 -05:00
|
|
|
MICROPY_PY_ULAB = 1
|
2019-12-05 22:45:53 -05:00
|
|
|
endif
|