summaryrefslogtreecommitdiff
path: root/examples/dual
diff options
context:
space:
mode:
authorhathach <[email protected]>2023-03-24 14:08:57 +0700
committerhathach <[email protected]>2023-03-24 14:08:57 +0700
commit76dae8d8c1764e94c99effe5d3f4f9b0ec0d4c99 (patch)
tree5d5a220a3a7d6d25f2e4b9339fb3c11d23220435 /examples/dual
parent71fb6469d4997347f2014daa41839391cc070a74 (diff)
update host example to use new tuh mem macros
Diffstat (limited to 'examples/dual')
-rw-r--r--examples/dual/host_hid_to_device_cdc/src/tusb_config.h16
1 files changed, 12 insertions, 4 deletions
diff --git a/examples/dual/host_hid_to_device_cdc/src/tusb_config.h b/examples/dual/host_hid_to_device_cdc/src/tusb_config.h
index 604cc6681..2185cd1f1 100644
--- a/examples/dual/host_hid_to_device_cdc/src/tusb_config.h
+++ b/examples/dual/host_hid_to_device_cdc/src/tusb_config.h
@@ -95,12 +95,12 @@
* - CFG_TUSB_MEM SECTION : __attribute__ (( section(".usb_ram") ))
* - CFG_TUSB_MEM_ALIGN : __attribute__ ((aligned(4)))
*/
-#ifndef CFG_TUSB_MEM_SECTION
-#define CFG_TUSB_MEM_SECTION
+#ifndef CFG_TUD_MEM_SECTION
+#define CFG_TUD_MEM_SECTION
#endif
-#ifndef CFG_TUSB_MEM_ALIGN
-#define CFG_TUSB_MEM_ALIGN __attribute__ ((aligned(4)))
+#ifndef CFG_TUD_MEM_ALIGN
+#define CFG_TUD_MEM_ALIGN __attribute__ ((aligned(4)))
#endif
//--------------------------------------------------------------------
@@ -128,6 +128,14 @@
// Size of buffer to hold descriptors and other data used for enumeration
#define CFG_TUH_ENUMERATION_BUFSIZE 256
+#ifndef CFG_TUH_MEM_SECTION
+#define CFG_TUH_MEM_SECTION
+#endif
+
+#ifndef CFG_TUH_MEM_ALIGN
+#define CFG_TUH_MEM_ALIGN __attribute__ ((aligned(4)))
+#endif
+
#define CFG_TUH_HUB 1
// max device support (excluding hub device)
#define CFG_TUH_DEVICE_MAX (CFG_TUH_HUB ? 4 : 1) // hub typically has 4 ports