Blame view

Giac_maj/epsilon-giac/build/platform.device.mak 583 Bytes
6663b6c9   adorian   projet complet av...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
  TOOLCHAIN ?= arm-gcc
  USE_LIBA = 0
  EXE = elf
  PORT ?= /dev/ttyACM0
  
  .PHONY: %_run
  %_run: %.$(EXE)
  	$(GDB) -x gdb_script.gdb $<
  
  .PHONY: %_flash
  %_flash: %.bin
  	@echo "DFU     $@"
  	@echo "INFO    About to flash your device. Please plug your device to your computer"
  	@echo "        using an USB cable and press the RESET button the back of your device."
  	@until dfu-util -l | grep "Internal Flash" > /dev/null 2>&1; do sleep 1;done
  	@echo "DFU     $@"
  	@dfu-util -i 0 -a 0 -s 0x08000000:leave -D $<
  
  .PHONY: %_extflash
  %_extflash: %-extflash.bin
  	@flashrom -p serprog:dev=$(PORT) -w $<