AM335x JTag Debugging GDBinit

This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

  • AM335x JTag Debugging GDBinit

    Hello
    i try to debug uboot on an board with AM3356 and DDR Ram. I use Ubuntu12.04, JLinkGDBServer and eclipse. I can connect to the target, but i can not debug. When i start debugging the server sends an errror, that it is not possible to write to the ram. I think the problem is, that i need a gdbinit-file which initialises the core and the memory interface before starting the debugging. Has anyone an template file for the AM3356 ?
    "screenshot"
    root@ubuntu:/opt/SEGGER/JLink# ./JLinkGDBServer -device AM3356
    SEGGER J-Link GDB Server V4.78j Command Line Version
    JLinkARM.dll V4.78j (DLL compiled Nov 22 2013 20:10:16)
    -----GDB Server start settings-----
    GDBInit file: none
    GDB Server Listening port: 2331
    SWO raw output listening port: 2332
    Terminal I/O port: 2333
    Accept remote connection: yes
    Generate logfile: on
    Verify download: off
    Init regs on start: on
    Silent mode: off
    Single run mode: off
    ------J-Link related settings------
    J-Link script: none
    Target interface: JTAG
    Host interface: USB
    Target endian: little
    Target interface speed: 500kHz
    Connecting to J-Link...
    J-Link is connected.
    Firmware: J-Link V9 compiled Oct 18 2013 17:37:30
    Hardware: V9.00
    S/N: 609100526
    Feature(s): RDI, FlashBP, FlashDL, JFlash, GDB
    Checking target voltage...
    Listening on TCP/IP port 2331
    Connecting to target...
    J-Link found 2 JTAG devices, Total IRLen = 10
    JTAG ID: 0x3BA00477 (Cortex-A8)
    Connected to target
    Waiting for GDB connection...Connected to 127.0.0.1
    Reading all registers
    Reading all registers
    WARNING: Failed to read memory @ address 0x00000000
    Read 4 bytes @ address 0x00000000 (Data = 0xAAAAAAAA)
    WARNING: Failed to read memory @ address 0xFFFFFFFC
    Read 4 bytes @ address 0xFFFFFFFC (Data = 0xAAAAAAAA)
    WARNING: Failed to read memory @ address 0x00000000
    Read 4 bytes @ address 0x00000000 (Data = 0xAAAAAAAA)
    WARNING: Failed to read memory @ address 0xFFFFFFFC
    Read 4 bytes @ address 0xFFFFFFFC (Data = 0xAAAAAAAA)
    WARNING: Failed to read memory @ address 0x00000000
    Read 4 bytes @ address 0x00000000 (Data = 0xAAAAAAAA)
    WARNING: Failed to read memory @ address 0xFFFFFFFC
    Read 4 bytes @ address 0xFFFFFFFC (Data = 0xAAAAAAAA)
    WARNING: Failed to read memory @ address 0x00000000
    Read 4 bytes @ address 0x00000000 (Data = 0xAAAAAAAA)
    WARNING: Failed to read memory @ address 0xFFFFFFFC
    Read 4 bytes @ address 0xFFFFFFFC (Data = 0xAAAAAAAA)
    WARNING: Failed to read memory @ address 0x00000000
    Read 4 bytes @ address 0x00000000 (Data = 0xAAAAAAAA)
    WARNING: Failed to read memory @ address 0x00000000
    Read 4 bytes @ address 0x00000000 (Data = 0xAAAAAAAA)
    WARNING: Failed to read memory @ address 0x00000000
    Read 4 bytes @ address 0x00000000 (Data = 0xAAAAAAAA)
    Downloading 16304 bytes @ address 0x80800000
    Downloading 16304 bytes @ address 0x80803FB0
    Downloading 16304 bytes @ address 0x80807F60
    Downloading 16304 bytes @ address 0x8080BF10
    Downloading 16256 bytes @ address 0x8080FEC0
    Downloading 16320 bytes @ address 0x80813E40
    Downloading 16288 bytes @ address 0x80817E00
    Downloading 16320 bytes @ address 0x8081BDA0
    Downloading 16240 bytes @ address 0x8081FD60
    Downloading 4304 bytes @ address 0x80823CD0
    Downloading 16128 bytes @ address 0x80824DA0
    Downloading 16272 bytes @ address 0x80828CA0
    Downloading 11650 bytes @ address 0x8082CC30
    Downloading 68 bytes @ address 0x8082F9B4
    Downloading 2996 bytes @ address 0x8082F9F8
    Downloading 12 bytes @ address 0x808305AC
    Downloading 1960 bytes @ address 0x808305B8
    Downloading 16288 bytes @ address 0x80830D60
    Downloading 5448 bytes @ address 0x80834D00
    Downloading 192 bytes @ address 0x80836248
    Writing register (PC = 0x80800000)
    WARNING: Failed to read memory @ address 0x80800000
    Read 4 bytes @ address 0x80800000 (Data = 0xAAAAAAAA)
    WARNING: Failed to read memory @ address 0x807FFFFC
    Read 4 bytes @ address 0x807FFFFC (Data = 0xAAAAAAAA)
    WARNING: Failed to read memory @ address 0x80800000
    Read 4 bytes @ address 0x80800000 (Data = 0xAAAAAAAA)
    WARNING: Failed to read memory @ address 0x807FFFFC
    Read 4 bytes @ address 0x807FFFFC (Data = 0xAAAAAAAA)
    WARNING: Failed to read memory @ address 0x80800000
    Read 4 bytes @ address 0x80800000 (Data = 0xAAAAAAAA)
    WARNING: Failed to read memory @ address 0x807FFFFC
    Read 4 bytes @ address 0x807FFFFC (Data = 0xAAAAAAAA)
    WARNING: Failed to read memory @ address 0x80800000
    Read 4 bytes @ address 0x80800000 (Data = 0xAAAAAAAA)
    WARNING: Failed to read memory @ address 0x807FFFFC
    Read 4 bytes @ address 0x807FFFFC (Data = 0xAAAAAAAA)
    WARNING: Failed to read memory @ address 0x80800000
    Read 4 bytes @ address 0x80800000 (Data = 0xAAAAAAAA)
    WARNING: Failed to read memory @ address 0x80800000
    Read 4 bytes @ address 0x80800000 (Data = 0xAAAAAAAA)
    WARNING: Failed to read memory @ address 0x80800000
    Read 4 bytes @ address 0x80800000 (Data = 0xAAAAAAAA)
  • Hi,

    Yes, of course you need an init script which initialises the SDRAM/DDRAM, before you can access it.
    Unfortunately, I do not have such an init script ready...
    As an alternative, you may load & execute a second level boot loader ELF file that performs all initialization
    prior to downloading the main application. This becomes more and more popular for complex target systems that require a lot of initialization.

    The process would look like this:
    file btl.elf
    load
    break <EndOfBTL>
    c
    file Application.elf
    load
    break main
    c


    Best regards
    Alex
    Please read the forum rules before posting.

    Keep in mind, this is *not* a support forum.
    Our engineers will try to answer your questions between their projects if possible but this can be delayed by longer periods of time.
    Should you be entitled to support you can contact us via our support system: segger.com/ticket/

    Or you can contact us via e-mail.
  • Hi,

    You're welcome. Good to hear that it is working on your side now.


    Best regards
    Alex
    Please read the forum rules before posting.

    Keep in mind, this is *not* a support forum.
    Our engineers will try to answer your questions between their projects if possible but this can be delayed by longer periods of time.
    Should you be entitled to support you can contact us via our support system: segger.com/ticket/

    Or you can contact us via e-mail.