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.

[Concerto F28M35x] Can I use standard vector template?



Hi,

I would like use the standard vector template. Does the compiler support this C++ template?

If I compile my code with the vector template I get "warning #10247-D: creating output section ".init_array" without a SECTIONS specification". After that I defined in my linker cmd file .init_array section. I looked like that:

...

SECTIONS
{
    .intvecs:   > INTVECS
    .resetisr:  > RESETISR
    .text   :   >> FLASH1 | FLASH2
    .const  :   >> FLASH1 | FLASH2
    .cinit  :   >  FLASH1 | FLASH2
    .pinit  :   >> FLASH1 | FLASH2
    .init_array : > FLASH1 | FLASH2

...

I programmed the M3 with the new defined linker cmd file. Now the M3 get password locked (was lucky to read that I can unlock the M3 again). How do I have to define the linker cmd file correct?

I would be glad if someone could me give some advice how to use the vector template on the M3.

Thank you

Matt

  • Hi Matt,

    I've moved your thread to the compiler forum - the experts here should have some advice.

    Regards

    Lori

  • Yes, the compiler supports std::vector

    That seems like a perfectly fine way to place .init_array.  Note: .pinit should be placed with ">", not ">>", but that isn't affecting this program.

    I have no idea what's causing M3 to get "password locked".  I'm not even familiar with the conditions that would cause "password lock."  Most likely the problem is many layers removed from the linker command file, and might not even have anything to do with it directly.  We will probably need a complete test case which reproduces the problem.

    STL classes dynamically allocate memory.  Make sure you have a generous heap.