d9fa12bcda6791e581c04af3818399d54cd37331
[tmk_keyboard.git] / converter / ps2_usb / Makefile.vusb
1 # Target file name (without extension).
2 TARGET = ps2_usb_vusb
3
4 # Directory common source filess exist
5 TMK_DIR = ../../tmk_core
6
7 # Directory keyboard dependent files exist
8 TARGET_DIR = .
9
10 # keyboard dependent files
11 SRC = keymap_common.c \
12 matrix.c \
13 led.c
14
15 ifdef KEYMAP
16 SRC := keymap_$(KEYMAP).c $(SRC)
17 else
18 SRC := keymap_plain.c $(SRC)
19 endif
20
21 CONFIG_H = config.h
22
23
24 # Use USART for PS/2. With V-USB INT and BUSYWAIT code is not useful.
25 PS2_USE_USART = yes
26
27
28 # V-USB debug level: To use ps2_usart.c level must be 0
29 # ps2_usart.c requires USART to receive PS/2 signal.
30 OPT_DEFS += -DDEBUG_LEVEL=0
31
32
33 # MCU name, you MUST set this to match the board you are using
34 # type "make clean" after changing this, so all files will be rebuilt
35 #MCU = at90usb162 # Teensy 1.0
36 #MCU = atmega32u4 # Teensy 2.0
37 #MCU = at90usb646 # Teensy++ 1.0
38 #MCU = at90usb1286 # Teensy++ 2.0
39 MCU = atmega168
40
41
42 # Processor frequency.
43 # Normally the first thing your program should do is set the clock prescaler,
44 # so your program will run at the correct speed. You should also set this
45 # variable to same clock speed. The _delay_ms() macro uses this, and many
46 # examples use this variable to calculate timings. Do not add a "UL" here.
47 F_CPU = 20000000
48
49
50 # Build Options
51 # comment out to disable the options.
52 #
53 MOUSEKEY_ENABLE = yes # Mouse keys
54 EXTRAKEY_ENABLE = yes # Audio control and System control
55 #NKRO_ENABLE = yes # USB Nkey Rollover
56 NO_UART = yes # UART is unavailable
57
58
59
60 #---------------- Programming Options --------------------------
61 AVRDUDE = avrdude
62 # Type: avrdude -c ? to get a full listing.
63 AVRDUDE_PROGRAMMER = usbasp
64 AVRDUDE_PORT =
65 AVRDUDE_WRITE_FLASH = -U flash:w:$(TARGET).hex
66 #AVRDUDE_WRITE_EEPROM = -U eeprom:w:$(TARGET).eep
67
68 # Uncomment the following if you want avrdude's erase cycle counter.
69 # Note that this counter needs to be initialized first using -Yn,
70 # see avrdude manual.
71 #AVRDUDE_ERASE_COUNTER = -y
72
73 # Uncomment the following if you do /not/ wish a verification to be
74 # performed after programming the device.
75 #AVRDUDE_NO_VERIFY = -V
76
77 # Increase verbosity level. Please use this when submitting bug
78 # reports about avrdude. See <http://savannah.nongnu.org/projects/avrdude>
79 # to submit bug reports.
80 #AVRDUDE_VERBOSE = -v -v
81
82 #AVRDUDE_FLAGS = -p $(MCU) -P $(AVRDUDE_PORT) -c $(AVRDUDE_PROGRAMMER)
83 AVRDUDE_FLAGS = -p $(MCU) -c $(AVRDUDE_PROGRAMMER)
84 AVRDUDE_FLAGS += $(AVRDUDE_NO_VERIFY)
85 AVRDUDE_FLAGS += $(AVRDUDE_VERBOSE)
86 AVRDUDE_FLAGS += $(AVRDUDE_ERASE_COUNTER)
87
88 PROGRAM_CMD = $(AVRDUDE) $(AVRDUDE_FLAGS) $(AVRDUDE_WRITE_FLASH) $(AVRDUDE_WRITE_EEPROM)
89
90
91 # Boot Section Size in bytes
92 # Teensy halfKay 512
93 # Atmel DFU loader 4096
94 # LUFA bootloader 4096
95 # USBasp 2048
96 OPT_DEFS += -DBOOTLOADER_SIZE=2048
97
98
99 # Search Path
100 VPATH += $(TARGET_DIR)
101 VPATH += $(TMK_DIR)
102
103
104 include $(TMK_DIR)/protocol.mk
105 include $(TMK_DIR)/common.mk
106 include $(TMK_DIR)/protocol/vusb.mk
107 include $(TMK_DIR)/rules.mk
Imprint / Impressum