This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

TMS320F28384D: TMS320F2837xD Launchpad EMIF NOR flash example help

Part Number: TMS320F28384D
Other Parts Discussed in Thread: C2000WARE, SYSCONFIG

Hello, 

I have a question about the EMIF examples for this launchpad. I need to connect a 16 bit nor flash chip to the launchpad (i also have a stand alond controller on a dev board i designed that i will do this to after it works on the launchpad).

I see the examples in the c2000 ware folders for emif, but they all say "ram" in them. Is one of these for NOR flash? If not can you provide me with direction on how to set this project up in CCS to get my nor flash connected and working? I have the nor flash on a breakout board and plan to wire it over to either the laucnhapd (if that is possible) or to my stand alone c2000 2838xD controller if that is not possible. 

any direction would be appreciated. 

thanks.

  • Hello Silas,

    There do not appear to be any NOR Flash examples with the EMIF, but you can treat it similar to external SRAM without the need for refresh. Please take a look at the Design and Usage Guidelines for the C2000 EMIF for details on what steps need to be done to connect an EMIF to an external memory device and what design considerations are important. For software, there shouldn't be much deviation besides the difference in initial configuration of the EMIF signals. Let me know if you have specific questions on certain registers or any errors you see.

  • I guess i am just confused about the SRAM examples. I want to add ROM to my board, and tell the processor to use the external ROM for code memory. I don't want to store that code on the actual memory of the chip. does that make sense? I want the chip to run off of external ROM for its code space. is this possible? and if so which example should i follow from the RAM examples?

  • Hello Silas,

    does that make sense? I want the chip to run off of external ROM for its code space. is this possible? and if so which example should i follow from the RAM examples?

    Is there a specific reason that you can't execute the code on the device? Is the code too large to fit into the internal memory, even piecemeal?

  • I plan on expanding the functionality of the device i am building with the controller in the future and I will most assuredly run out of memory especially if i am adding a RTOS to the chip and so on. I already have ran out of space multiple times just doing some simple things with a RTOS. I just want to put external meomory on it that i can use as code space. I can fit some code on the device, but i want to expand the code space with the external chip.

  • Hello Silas,

    We currently don't have an existing example for something like this, I checked with another expert and execution in-place is not supported by our device. You would need to copy the code from external memory to internal memory ad hoc to execute it.

  • Hello Amir, 

    is the following example not using it as flash? I think this example shows how to do it right? If not then what is the below example for?


    C:\ti\c2000\C2000Ware_5_01_00_00\device_support\f2837xd\examples\cpu1\emif_dc_flash

    thanks

  • Hello Silas,

    is the following example not using it as flash? I think this example shows how to do it right?

    Sure, it's using Flash. But you're asking to execute code from external Flash. This example from my quick review only reads/erases Flash, it's not executing code that's on the external memory. It's reading values from the external memory.

    If not then what is the below example for?

    The example shows an EMIF example with a custom daughtercard, it demonstrates how to use external Flash with EMIF.

  • Interesting. Do you any other recommendations for me if i reach a point later on where I don't have enough code memory? I suppose i will just use my flash chip to store information then during program execution. 

  • Hello Silas,

    Do you any other recommendations for me if i reach a point later on where I don't have enough code memory?

    Since I don't know your program, my main recommendation would be to use the Flash to store your entire program and only copy time-sensitive code to RAM to execute it. This would include any main loops, interrupts, etc. Functions which are called in certain locations occasionally which aren't likely to be interrupted can be stored in Flash (i.e. initialization code).

    There is an example for the F2838x device that shows how to do this without even needing to use memcpy, the same code applies to F2837xD, the only difference being the memory sizes/names (see C2000Ware_5_01_00_00_Copy\driverlib\f2838x\examples\c28x\flash\flash_ex3_flash_to_ram). This is the main method recommended to utilize Flash and still have a program that executes according to timing constraints. Let me know if you have questions about this example (you can also migrate it to the F2837xD device by using the migration feature within SysConfig in the example).

  • Awesome. This essentially mocks the functionality of giving me more code space! I will attempt to do this and reach out for help if i run into snags. You should be hearing from me on this in about a week or two (I am working on the hardware design right now).