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.

Can the CSL (Huge memory model) and HWAFFT (small memory model) be used together?

Hello,
I am using the C5535 eZdsp. I was trying to use the hwafft functions, and they were not working. After searching the E2E forums, I discovered that the HWAFFT functions might only work with a small memory model. So I changed my memory model to "small,"and tried again - and then I got undefined symbol errors with respect to the CSL functions I was using. After looking on the E2E forums again, I saw that the CSL only supports large/huge memory models.

So my question is: is it possible to use HWAFFT functions and CSL functions in the same project? if so, how do I resolve the issue of the CSL needing a large/huge memory model, and the HWAFFT needing a small memory model? 

as it is, I would very much like to use both the HWAFFT and the CSL, but if this is not possible, can I just use the cfft functions instead of the HWAFFT functions? 

Thanks,

Nathan 

  • All of small, large, and huge memory models are mutually incompatible and may not be used together.

    I don't know why HWAFFT and CSL are not available in a mutually compatible memory model.

    I'm sorry I cannot be of more help on this matter.

  • See this thread:

    Missing Detail in C5515 HWAFFT Documentation

    for a work around to run hwafft in large/huge memory model.

    I tried it with my code but it does not work (yet).

    Alex

  • Archaeologist said:

    I don't know why HWAFFT and CSL are not available in a mutually compatible memory model.



    Thanks for the response - That is very disappointing to hear. 

     http://e2e.ti.com/support/dsp/c5000/f/109/t/54489.aspx suggests (from what I can tell) creating a .asm file and placing code into it, however, asm files cannot be compiled in mnemonic compilations, and using the CSL requires mnemonic compilation (I believe, correct me if I am wrong), which means that I cant use asm commands and also use the CSL. 

    That post also says this:

    In order to use HWAFFT for large/huge memory models and allow allocating HWAFFT buffers in different data pages, I created the following wrapper: 



    Does this mean that I can use the large/huge memory model with HWAFFT, IF I allocate my HWAFFT buffers on the same data page? 

    Im not even exactly sure what that entails, but I thought it meant  using statements like #pragma DATA_SECTION(complex_buffer, "cmplxBuf"); for each HWAFFT buffer and then allocating all my HWAFFT buffers as such:

    MEMORY {

    DARAM_0 (RW) : origin = 00000c0h length = 001f40h
    DARAM_1 (RW) : origin = 0002000h length = 004000h
    DARAM_3 (RW) : origin = 0006000h length = 002000h }
     
    SECTIONS { 

    BufL : > DARAM_1
    BufR : > DARAM_1
    cmplxBuf : > DARAM_1
    PSD : > DARAM_1
    tmpBuf : > DARAM_1
    brBuf : > DARAM_1
    rfftL : > DARAM_1
    ifftL : > DARAM_1
    rfftR : > DARAM_1
    ifftR : > DARAM_1
    }



    Well, I tried this, and it did not work. the HWAFFT just fills my FFT_Result buffers (the real one, and the imaginary one) with 1's and 0's. 

    I am new to DSP's, and CCS, and would appreciate if someone from TI could provide a definitive reply, or a step-by-step solution to using both the CSL and the HWAFFT together with the 5535. 
    I do not think this is unreasonable, as I assume most users would want to use the CSL to set up peripherals and modules, and then use the HWAFFT. My project is due in two weeks, and I still cannot take an FFT!


    As it stands, My choices are to use the CSL and not use the HWAFFT OR use the HWAFFT and not use the CSL. 
    Can I use the cfft and cbrev functions using a huge memory model (so I can use the CSL as well)? That would be the easiest route for me to take. Are the CFFT functions really slow? 


    if so, then I will just use the cfft.

    eagerly waiting a reply,

    Nathan


     

  • nathan zorndorf1 said:
    asm files cannot be compiled in mnemonic compilations

    There are two assembly syntaxes, mnemonic and algebraic, both supported by the compiler.  The only restriction is that in one compilation unit you must stick to one or the other.  If you have algebraic assembly code (or want algebraic assembly code from the compiler), use the compiler option --algebraic.  Otherwise, let the compiler use the default mnemonic assembly code mode.

    As to your questions about HWAFFT and CSL, those are outside of my expertise.

  • Archaeologist said:

    As to your questions about HWAFFT and CSL, those are outside of my expertise.



    I see - Where do you recommend I go/who do you recommend I contact for these answers?

    Thanks,
    Nate 

  • Hello Nathan,

    I have the same issue like you.
    Did you find any solution ?

    Thank you

    Korbi