Important Notice: Our web hosting provider recently started charging us for additional visits, which was unexpected. In response, we're seeking donations. Depending on the situation, we may explore different monetization options for our Community and Expert Contributors. It's crucial to provide more returns for their expertise and offer more Expert Validated Answers or AI Validated Answers. Learn more about our hosting issue here.

How can I use C to Access Data Stored in Program Space Memory on the TMS320C24x DSP?

0
Posted

How can I use C to Access Data Stored in Program Space Memory on the TMS320C24x DSP?

0

On TMS320C24x devices, it is sometimes desirable to place data in program space memory rather than in data space memory. In particular, the on-chip flash (or ROM) in the program space provides a large nonvolatile memory for storing constant arrays, look-up tables, and string tables. When working in the C programming language, however, it is not sufficient to simply link the data into the program space, as the C-compiler expects all constants (and variables) to be in data space memory. No mechanism exists in the C-compiler for accessing program space memory, other than at code-initialization time. One method for overcoming this problem is to copy the data from the flash (or ROM) into data space RAM as part of the code-initialization process. This could be done using a custom assembly code routine, or the C-compiler does provide some built-in capability for initializing global and static variables and constants. The C-code could then access the copies of the data in the data space during

Related Questions

What is your question?

*Sadly, we had to bring back ads too. Hopefully more targeted.

Experts123