This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Semihosting with Cortex-A5 and T32

Note: This was originally posted on 9th August 2013 at http://forums.arm.com

With Semihosting enabled, after seeing SVC 0xAB (for SYS_WRITE; R0=5) by Cortex-A5, how the message is passed to the DAP/debugger? In the code, I'm not handling SVC exception. Even I'm not able to do a 'vector catch' here.

Prints are coming on T32.
Parents
  • Note: This was originally posted on 12th August 2013 at http://forums.arm.com


    Can you explain more about what you are trying to do, what you want to happen and what is happening?  In particular I can't tell if you are having trouble with a different debugger (if so which one) or when using no debugger.

    When a debugger that does semihosting is attached (and correctly configured) it will place a vector catch or breakpoint on the SVC vector.  When the target does a semihosting operation the debugger will stop the target, do the operation and resume the target.


    I'm using Lauterbach(T32) debugger and am trying to understand the functionality of how a message is passed from ARM->DAP->JTAG.   e.g. a printf("hello")
    So, the current understanding is:
    1. In printf ARM library, SYS_WRITE is used
    2. SYS_WRITE modifies r0 and r1 followed by SVC 0xAB instruction
    3. After seeing SVC 0xAB, vector catch is used by the debugger and some arm library file uses DBGDTRTX register to write the bytes to the DAP/host registers
    4. Finally  T32 application, through JTAG, read these bytes

    Is this understanding current?
Reply
  • Note: This was originally posted on 12th August 2013 at http://forums.arm.com


    Can you explain more about what you are trying to do, what you want to happen and what is happening?  In particular I can't tell if you are having trouble with a different debugger (if so which one) or when using no debugger.

    When a debugger that does semihosting is attached (and correctly configured) it will place a vector catch or breakpoint on the SVC vector.  When the target does a semihosting operation the debugger will stop the target, do the operation and resume the target.


    I'm using Lauterbach(T32) debugger and am trying to understand the functionality of how a message is passed from ARM->DAP->JTAG.   e.g. a printf("hello")
    So, the current understanding is:
    1. In printf ARM library, SYS_WRITE is used
    2. SYS_WRITE modifies r0 and r1 followed by SVC 0xAB instruction
    3. After seeing SVC 0xAB, vector catch is used by the debugger and some arm library file uses DBGDTRTX register to write the bytes to the DAP/host registers
    4. Finally  T32 application, through JTAG, read these bytes

    Is this understanding current?
Children
No data