aboutsummaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorFrançois Cartegnie <281376+fcartegnie@users.noreply.github.com>2024-08-20 13:43:09 +0700
committerGitHub <noreply@github.com>2024-08-20 13:43:09 +0700
commitf5874d607315ff88b27414299089b8528b5bb07c (patch)
tree9db23b8e6cdfb06d8bab77e83224e604f20c4629 /Makefile
parentb25d62d1362cfd711e6617a9212e3eddc4e9fddd (diff)
parentc3912e01a2767334103cd139d875d50c834f3f05 (diff)
Merge pull request #35 from kienvo/usb
feat: Receive data over USB
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile15
1 files changed, 10 insertions, 5 deletions
diff --git a/Makefile b/Makefile
index ea1a881..f0d8a0e 100644
--- a/Makefile
+++ b/Makefile
@@ -7,8 +7,8 @@ TARGET = badgemagic-ch582
######################################
# building variables
######################################
-# debug build?
-DEBUG = 1
+# Uncomment below line to enable debugging
+# DEBUG = 1
# optimization for size
OPT = -Os
@@ -37,7 +37,6 @@ CH5xx_ble_firmware_library/StdPeriphDriver/CH58x_uart0.c \
CH5xx_ble_firmware_library/StdPeriphDriver/CH58x_timer1.c \
CH5xx_ble_firmware_library/StdPeriphDriver/CH58x_pwm.c \
CH5xx_ble_firmware_library/StdPeriphDriver/CH58x_usbhostClass.c \
-CH5xx_ble_firmware_library/StdPeriphDriver/CH58x_usbdev.c \
CH5xx_ble_firmware_library/StdPeriphDriver/CH58x_adc.c \
CH5xx_ble_firmware_library/StdPeriphDriver/CH58x_usbhostBase.c \
CH5xx_ble_firmware_library/StdPeriphDriver/CH58x_timer3.c \
@@ -58,7 +57,13 @@ src/ble/profile/devinfo.c \
src/ble/setup.c \
src/ble/peripheral.c \
src/data.c \
-
+src/usb/utils.c \
+src/usb/setup.c \
+src/usb/ctrl.c \
+src/usb/debug.c \
+src/usb/dev.c \
+src/usb/composite/hiddev.c \
+src/usb/composite/cdc-serial.c \
# ASM sources
ASM_SOURCES = \
@@ -108,7 +113,7 @@ ASFLAGS = $(MCU) $(AS_INCLUDES) $(OPT) -Wall -fdata-sections -ffunction-sections
CFLAGS = $(MCU) $(C_INCLUDES) $(OPT) -Wall -fdata-sections -ffunction-sections
ifeq ($(DEBUG), 1)
-CFLAGS += -g -gdwarf-2
+CFLAGS += -g -gdwarf-2 -DDEBUG=$(DEBUG)
endif