- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
It is generally accepted that the data section of code in a 512kB FX3 or FX3s is divided roughly into two halves, the first being program and data memory etc, and the second devoted to DMA. Seeing as this quantity of DMA space is excessive for most applications, the ability to expand data memory into this section is attractive. I've done so without catastrophic failure, but I also have several strange problems which I am working through. Can someone please confirm that the FX3 memory can be divided as such without issue?
In "fx3.ld":
MEMORY
{
I-TCM : ORIGIN = 0x100 LENGTH = 0x3F00
SYS_MEM : ORIGIN = 0x40003000 LENGTH = 0x30000
DATA : ORIGIN = 0x40033000 LENGTH = 0x12000
}
In "cyfxtx.c"
/*
The MEM heap is a Memory byte pool which is used to allocate OS objects
such as thread stacks and memory for message queues. The Cypress FX3
libraries require a Mem heap size of at least 32 KB.
*/
#define CY_U3P_MEM_HEAP_BASE ((uint8_t *)0x40045000)
#define CY_U3P_MEM_HEAP_SIZE (0x8000)
/* The last 32 KB of RAM is reserved for 2-stage boot operation. This value can be changed to
0x40080000 if 2-stage boot is not used by the application. */
//#define CY_U3P_SYS_MEM_TOP (0x40078000)
#define CY_U3P_SYS_MEM_TOP (0x40080000)
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
Yes, you can divide Fx3 Memory like as mentioned above.
I have modified the bulksourcesink example to the values mentioned above and build the firmware successfully.
And the device enumeration is also fine.
I attached the example project for your reference.
Please let me know the errors/problems that you have faced in your case.
Regards,
Anil Srinivas
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
Yes, you can divide Fx3 Memory like as mentioned above.
I have modified the bulksourcesink example to the values mentioned above and build the firmware successfully.
And the device enumeration is also fine.
I attached the example project for your reference.
Please let me know the errors/problems that you have faced in your case.
Regards,
Anil Srinivas
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thank you. If there are no underlying hardware issues with arbitrary RAM allocation, my problems are likely unrelated. I have asked about them in separate discussions.