50e46552c0
This includes: - Configuration file for the cyw43-driver. - Integration of cyw43-driver into the build, using lwIP. - Enhancements to machine.Pin to support extension IO pins provided by the CYW43xx. - More mp-hal pin helper functions. - mp_hal_get_mac_ascii MAC address helper function. - Addition of rp2.country() function to set the country code. A board can enable this driver by setting MICROPY_PY_NETWORK_CYW43 in their cmake snippet. Work done in collaboration with Graham Sanderson and Peter Harper. Signed-off-by: Damien George <damien@micropython.org>
46 lines
1.3 KiB
Makefile
46 lines
1.3 KiB
Makefile
# Makefile for micropython on Raspberry Pi RP2
|
|
#
|
|
# This is a simple wrapper around cmake
|
|
|
|
BOARD ?= PICO
|
|
|
|
BUILD ?= build-$(BOARD)
|
|
|
|
$(VERBOSE)MAKESILENT = -s
|
|
|
|
CMAKE_ARGS = -DMICROPY_BOARD=$(BOARD)
|
|
|
|
ifdef USER_C_MODULES
|
|
CMAKE_ARGS += -DUSER_C_MODULES=${USER_C_MODULES}
|
|
endif
|
|
|
|
ifneq ($(FROZEN_MANIFEST),)
|
|
CMAKE_ARGS += -DMICROPY_FROZEN_MANIFEST=${FROZEN_MANIFEST}
|
|
endif
|
|
|
|
ifeq ($(DEBUG),1)
|
|
CMAKE_ARGS += -DCMAKE_BUILD_TYPE=Debug
|
|
endif
|
|
|
|
all:
|
|
[ -e $(BUILD)/CMakeCache.txt ] || cmake -S . -B $(BUILD) -DPICO_BUILD_DOCS=0 ${CMAKE_ARGS}
|
|
$(MAKE) $(MAKESILENT) -C $(BUILD)
|
|
|
|
clean:
|
|
$(RM) -rf $(BUILD)
|
|
|
|
GIT_SUBMODULES += lib/mbedtls lib/tinyusb
|
|
|
|
submodules:
|
|
# lib/pico-sdk is required for the cmake build to function (as used for boards other than PICO below)
|
|
$(MAKE) -f ../../py/mkrules.mk GIT_SUBMODULES="lib/pico-sdk" submodules
|
|
ifeq ($(BOARD),PICO)
|
|
# Run the standard submodules target with minimum required submodules above
|
|
$(MAKE) -f ../../py/mkrules.mk GIT_SUBMODULES="$(GIT_SUBMODULES)" submodules
|
|
else
|
|
# Run submodules task through cmake interface to pick up any board specific dependencies.
|
|
GIT_SUBMODULES=$$(cmake -B $(BUILD)/submodules -DECHO_SUBMODULES=1 -DGIT_SUBMODULES="$(GIT_SUBMODULES)" ${CMAKE_ARGS} -S . 2>&1 | \
|
|
grep 'GIT_SUBMODULES=' | cut -d= -f2); \
|
|
$(MAKE) -f ../../py/mkrules.mk GIT_SUBMODULES="$${GIT_SUBMODULES}" submodules
|
|
endif
|