1 USB_HID_DIR = protocol/usb_hid
7 USB_HOST_SHIELD_DIR = $(USB_HID_DIR)/USB_Host_Shield_2.0
8 USB_HOST_SHIELD_SRC = \
9 $(USB_HOST_SHIELD_DIR)/Usb.cpp \
10 $(USB_HOST_SHIELD_DIR)/hid.cpp \
11 $(USB_HOST_SHIELD_DIR)/usbhub.cpp \
12 $(USB_HOST_SHIELD_DIR)/parsetools.cpp \
13 $(USB_HOST_SHIELD_DIR)/message.cpp
20 ARDUINO_DIR = $(USB_HID_DIR)/arduino-1.0.1
21 ARDUINO_CORES_DIR = $(ARDUINO_DIR)/cores/arduino
23 $(ARDUINO_CORES_DIR)/Print.cpp \
24 $(ARDUINO_CORES_DIR)/Stream.cpp
26 # replaced with override_Serial.c
27 # $(ARDUINO_CORES_DIR)/CDC.cpp \
28 # $(ARDUINO_CORES_DIR)/HID.cpp \
29 # $(ARDUINO_CORES_DIR)/USBCore.cpp \
31 # replaced with override_wiring.c and common/timer.c
32 # $(ARDUINO_CORES_DIR)/wiring.c \
39 SRC += $(USB_HID_DIR)/parser.cpp
41 # replace arduino/CDC.cpp
42 SRC += $(USB_HID_DIR)/override_Serial.cpp
44 # replace arduino/wiring.c
45 SRC += $(USB_HID_DIR)/override_wiring.c
46 SRC += common/avr/timer.c
48 SRC += $(USB_HOST_SHIELD_SRC)
49 SRC += $(ARDUINO_CORES_SRC)
52 OPT_DEFS += -DARDUINO=101
53 # Arduino USBCore needs USB_VID and USB_PID.
54 #OPT_DEFS += -DARDUINO=101 -DUSB_VID=0x2341 -DUSB_PID=0x8036
61 VPATH += $(TOP_DIR)/$(USB_HID_DIR)
62 VPATH += $(TOP_DIR)/$(USB_HOST_SHIELD_DIR)
64 # for #include "Arduino.h"
65 VPATH += $(TOP_DIR)/$(ARDUINO_CORES_DIR)
67 # for #include "pins_arduino.h"
68 VPATH += $(TOP_DIR)/$(ARDUINO_DIR)/variants/leonardo
70 # ad hoc workaround for compile problem on Windows:
71 # Windows doesn't know difference between common/print.h and arduino/Print.h.
72 # On Linux no problem.
73 # Change file name common/print.h to console.h ?
74 VPATH := $(TOP_DIR)/common $(VPATH)