Cart New Account Login

HomeAbout usProductsSupportForumsBlogCustomer Service

search inside this forum
search inside all forums
loading of RAM image in S-Record format
. migrated on Dec 31, 2013 at 11:00 AM
No staff assigned yet

  • Hi,

    I built a RAM image for MPC5674 processor and could able to load the image in .elf format to target and dubug using ICD Nexus debugger.

    Then I tried to load the image in S37 format (we cann't debug the code in C in S37), image is successfully loading into RAm, but the PC register is not automatically updated to start address of the image. If I do manual update of PC through debugger, image is perfectly running. Can any one explains why the PC register is not updated automatically to start address of the RAM image. Is there any problem in creation of S37 regard.


    I tried to download the same image to RAM through BAM via CAN interface. I could able to download it, but again application is not been started. Any help?

    Note: Image is build in book-E configuration.

    Regards,
    Ramakrishna




    Comments

  • Hi Ramakrishna,

    If you load the image in .ELF format, the debugger will automatically set the program counter the start address.

    If you use an S-record (eg. S37), the debugger will not change the program counter because there is no debug information in S-record files. To make debugging easier, you could write a simple macro that loads the S-record and sets the PC for you:

    hload mySRecord.s37
    pc $100 (replace this with the real starting address)

    Save this as a .mac file and you can run this macro in ICDPPCNEXUS by using the "macro" command.

    Let me know if you have any questions.

    Best regards,
    Edison

  • Hi Edison,

    Thanks for your reply. I was on vacation and just now I seen your reply. the problem is solved.


    Now I am facing another problem. This time, it is with a flash image. I created both S37 and .elf files and programmed the flash with S37 format. Then I tried to debug the application by loading corresponding .elf file. The debugger is loading the PC with correct application start address and then loading the symbols. As when the symbols are loading, the status window is showing the error " Error in ONCE status register during instruction execution" continuously.

    Could you please let me know what went wrong.

    thanks in advance.

    Regards,
    Ramakrishna

    QUOTE (Edison Tam @ Dec 10 2009, 12:53 PM) [legacy comment]
    Hi Ramakrishna,

    If you load the image in .ELF format, the debugger will automatically set the program counter the start address.

    If you use an S-record (eg. S37), the debugger will not change the program counter because there is no debug information in S-record files. To make debugging easier, you could write a simple macro that loads the S-record and sets the PC for you:

    hload mySRecord.s37
    pc $100 (replace this with the real starting address)

    Save this as a .mac file and you can run this macro in ICDPPCNEXUS by using the "macro" command.

    Let me know if you have any questions.

    Best regards,
    Edison



  • Hi Ramakrishna,

    If you already programmed the flash and only want to load the debug information, you should use the HLOADMAP command:

    hloadmap myFile.elf

    - The HLOAD command loads binary AND debug information
    - The HLOADMAP command only loads debug information

    Best regards,
    Edison

  • Hi Edison,

    Thank you very much. It is working.

    Regards,
    Ramakrishna

Add comment


   Want to comment? Please login or create a new PEMicro account.







© 2018 P&E Microcomputer Systems Inc.
Website Terms of Use and Sales Agreement