1
0
mirror of git://projects.qi-hardware.com/ben-wpan.git synced 2024-11-23 04:45:19 +02:00

atusb/fw/Makefile: abstract host so that one can use HOST=ben instead of jlime

This commit is contained in:
Werner Almesberger 2011-03-04 21:50:01 -03:00
parent 7258e10a9a
commit 2f85fa9d14

View File

@ -18,6 +18,7 @@ CFLAGS = -g -Wall -Wextra -Wshadow -Werror -Wno-unused-parameter \
-Wmissing-prototypes -Wmissing-declarations -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -Wstrict-prototypes
CHIP=atmega32u2 CHIP=atmega32u2
HOST=jlime
AVR_PREFIX = $(BIN_PATH) avr- AVR_PREFIX = $(BIN_PATH) avr-
CC = $(AVR_PREFIX)gcc CC = $(AVR_PREFIX)gcc
@ -102,19 +103,19 @@ version.c:
# ----- Programming and device control ---------------------------------------- # ----- Programming and device control ----------------------------------------
upload: $(NAME).bin upload: $(NAME).bin
scp $(NAME).bin jlime: scp $(NAME).bin $(HOST):
prog: prog:
ssh jlime avrdude -F -p $(CHIP) -c nanonote_atusb -e \ ssh $(HOST) avrdude -F -p $(CHIP) -c nanonote_atusb -e \
-U flash:w:$(NAME).bin:r \ -U flash:w:$(NAME).bin:r \
-U lfuse:w:0x60:m # external clock, slow start-up -U lfuse:w:0x60:m # external clock, slow start-up
on: on:
ssh jlime poke 0x10010318 4 ssh $(HOST) poke 0x10010318 4
off: off:
ssh jlime poke 0x10010314 4 ssh $(HOST) poke 0x10010314 4
reset: reset:
ssh jlime poke 0x10010318 2048 ssh $(HOST) poke 0x10010318 2048
ssh jlime poke 0x10010314 2048 ssh $(HOST) poke 0x10010314 2048