summaryrefslogtreecommitdiff
path: root/demos
diff options
context:
space:
mode:
authorhathach <[email protected]>2013-11-19 16:41:30 +0700
committerhathach <[email protected]>2013-11-19 16:41:30 +0700
commit2dafeee585e0a90675359e83de4e197c84cd3f5d (patch)
tree6c73e124db9998bf878d96627573c2eba078fb4d /demos
parent94854f805aa8c80ffe77d8cef3ecfd45a3a9f253 (diff)
complete dcd for lpc175x_6x
cdc device demo can work but there is hardfault with dma descriptor with fast typing
Diffstat (limited to 'demos')
-rw-r--r--demos/device/device_os_none/cdcd_app.c2
-rw-r--r--demos/device/device_os_none/tusb_descriptors.h21
2 files changed, 13 insertions, 10 deletions
diff --git a/demos/device/device_os_none/cdcd_app.c b/demos/device/device_os_none/cdcd_app.c
index 1500d1497..def783435 100644
--- a/demos/device/device_os_none/cdcd_app.c
+++ b/demos/device/device_os_none/cdcd_app.c
@@ -46,7 +46,7 @@
// INCLUDE
//--------------------------------------------------------------------+
enum {
- CDCD_APP_BUFFER_SIZE = 16
+ CDCD_APP_BUFFER_SIZE = 64
};
//--------------------------------------------------------------------+
diff --git a/demos/device/device_os_none/tusb_descriptors.h b/demos/device/device_os_none/tusb_descriptors.h
index 022ea50bc..b69c8e590 100644
--- a/demos/device/device_os_none/tusb_descriptors.h
+++ b/demos/device/device_os_none/tusb_descriptors.h
@@ -44,25 +44,28 @@
//--------------------------------------------------------------------+
// Endpoints Address & Max Packet Size
//--------------------------------------------------------------------+
+#define EDPT_IN(x) (0x80 | x)
+#define EDPT_OUT(x) (x)
+
//------------- CDC -------------//
-#define CDC_EDPT_NOTIFICATION_ADDR ENDPOINT_IN_LOGICAL_TO_PHYSICAL(2)
-#define CDC_EDPT_NOTIFICATION_PACKETSIZE 64
+#define CDC_EDPT_NOTIFICATION_ADDR EDPT_IN(1)
+#define CDC_EDPT_NOTIFICATION_PACKETSIZE 64
-#define CDC_EDPT_DATA_OUT ENDPOINT_OUT_LOGICAL_TO_PHYSICAL(3)
-#define CDC_EDPT_DATA_IN ENDPOINT_IN_LOGICAL_TO_PHYSICAL(3)
-#define CDC_EDPT_DATA_PACKETSIZE 64
+#define CDC_EDPT_DATA_OUT EDPT_OUT(2)
+#define CDC_EDPT_DATA_IN EDPT_IN(2)
+#define CDC_EDPT_DATA_PACKETSIZE 64
//------------- HID Keyboard -------------//
-#define HID_EDPT_KEYBOARD_ADDR ENDPOINT_IN_LOGICAL_TO_PHYSICAL(1)
+#define HID_EDPT_KEYBOARD_ADDR EDPT_IN(3)
//------------- HID Mouse -------------//
-#define HID_MOUSE_EP_IN ENDPOINT_IN_LOGICAL_TO_PHYSICAL(4)
+#define HID_MOUSE_EP_IN EDPT_IN(4)
//------------- HID Generic -------------//
//------------- Mass Storage -------------//
-#define MSC_EDPT_IN ENDPOINT_IN_LOGICAL_TO_PHYSICAL(3)
-#define MSC_EDPT_OUT ENDPOINT_OUT_LOGICAL_TO_PHYSICAL(3)
+#define MSC_EDPT_IN EDPT_IN(3)
+#define MSC_EDPT_OUT EDPT_OUT(3)
//--------------------------------------------------------------------+