1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00
RIOT/makefiles/tools/pic32prog.inc.mk
Gaëtan Harter afdddfda14
pic32prog.inc.mk: add support for pic32prog flasher
Define a RIOT_PIC32PROG to allow setting 'PIC32PROG' globally from environment.

https://github.com/sergev/pic32prog

For PICkit3 it requires having it with scripting mode firware.

Source
------

https://github.com/RIOT-OS/RIOT/pull/6092#issuecomment-261987955
2019-09-24 17:43:12 +02:00

35 lines
794 B
Makefile

# pic32prog flasher
# =================
#
# https://github.com/sergev/pic32prog
#
# Allow flashing pic32 boards using:
# * Microchip PICkit2
# * Microchip PICkit3 with script firmware
#
#
# PICkit-3
# --------
#
# This requires changing the firmware to 'scripting mode'
# Should be done from a Windows computer/virtual machine as described here
#
# https://github.com/RIOT-OS/RIOT/blob/master/dist/tools/pic32prog/doc.md
RIOT_PIC32PROG = $(RIOTTOOLS)/pic32prog/pic32prog
PIC32PROG ?= $(RIOT_PIC32PROG)
FLASHFILE ?= $(HEXFILE)
FLASHER ?= $(PIC32PROG)
FFLAGS ?= $(FLASHFILE)
# No reset command, but the board resets on terminal open
RESET ?=
RESET_FLAGS ?=
# Compile pic32prog if using the one provided in RIOT
ifeq ($(PIC32PROG),$(RIOT_PIC32PROG))
FLASHDEPS += $(RIOT_PIC32PROG)
endif