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.

HALCoGen tool with GHS MULTI IDE

Other Parts Discussed in Thread: TMS570LS3137, HALCOGEN

Hello

I am using a TMS570LS3137 micro-controller based custom designed board. I have been using Code Composer Studio for application software development.

Recently we have migrated to GHS MULTI for ARM ver 6.1.6. I have ported the source files generated with HALCoGen onto GHS MULTI successfully. 

The issue is that application code is executing fine but the interrupts are not working. 

Can anyone help in this regard.

Thanks in advance..

-- Suresh Kumar

  • Suresh,


    Out of reset, both FIQ and IRQ are disable from a CPU standpoint.

    It is necessary in your application to enable IRQ and or FIQ.

    When Halcogen is used to create a project targeting GHS, you will find in sys_core.asm the following functions:

    _enable_interrupt_                      Enable both IRQ and FIQ
    _disable_IRQ_interrupt_           Disable IRQ
    _disable_FIQ_interrupt_            Disable FIQ. (This will not work on Hercules product. FIQ once enable are treated as NMI.)
    _disable_interrupt_                     Disable both IRQ and FIQ. (This will not work on Hercules product. FIQ once enable are treated as NMI.)

    Please let me know if I've answered your question.

  • Dear Jean-Marc,

    Thanks for your valuable input.

    I have tried and it works but i am facing a peculiar problem.

    The problem is that, interrupts are working some times and doesn't work sometimes.

    I mean the system hangs whenever an interrupt occurs. If i download the same code after some time it  works(without any change).

    that is there is a random behaviour. I am not suspecting my board since the same board is perfectly working with code composer studio projects.

    Any pointers in this regard.

    Thanks in advance.

    --- Suresh

  • Hi Suresh,
    Can you please elaborate on the behaviour when "system hangs"?
    Can you also check the reset entry in that condition, Is it a data abort condition?

    Regards,
    Sai
  • Hi Suresh,

    Could you please create a new post for this question?

    It will be necessary to know what your application is doing. Otherwise debug is almost impossible.

    If you can share your application (on this forum or directly with me) it will also be much easier to figure out what is going on.

  • Dear Jean-Marc
    As suggested I have attached the MULTI project which I am using now.
    It contains the Readme.txt file. Please go through once.

    Regards
    Suresh Kumar
  • 0844.arm_sbc_multi_ide_v1.tar.gzDear Sai

    Kindly go through the attached multi project files.

    also go through the Readme.txt file in root folder.

    Regards

    Suresh

  • Suresh,

    Thanks for sharing your project.

    I don't have GHS Multi installed so I've just tried to follow the code execution and here is my finding.

    The reset entry point at 0x0000_0000 is defined in sys_intvecs.asm and will branch to _c_int00 on reset.
    _c_int00 is the startup entry point located in sys_startup.c

    At the end of _c_int00 there is a call to _start(). This is not in the source files part of your project so I assume it is some GHS runtime function.

    By looking to the map file: aboc_newhal_ram.map the address of _start() is:

     .text            08000000+0000a4 _start

    So this _start is located in RAM..... During startup, I don't see any copy of code from Flash to RAM so when the CPU jumps to _start() it will abort.

    A possibility why your code seems to work after a download (using GHD IDE) is, the _start() may be downloaded to RAM via the Debugger.
    So when you run the code after a download, _start() is in RAM and the code works.
    What is strange, during startup, the RAM is initialized to 0 so even if the debugger was able to download some code, it will be erased at run time.

    Do you know what this _start() is doing?