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

debug bare metal software on the Raspberry Pi 4 using Arm develop stdui by dstream

i use ARM develop studio 2021.2,  debug by dstream. 

when i connect the rasperry PI4 .  it report this error message:

Unable to stop device Cortex-A72_0
Cannot attain state requested.
Unable to stop device Cortex-A72_0

config.txt

[pi4]
kernel=loop.bin

[all]
arm_64bit=1 #enable 64bit image
enable_uart=1 #enable pl uart
uart_2ndstage=1 #enable FW debug info

enable_jtag_gpio=1
gpio=22-27=a4
init_uart_clock=48000000
init_uart_baud=115200
#kernel_old=1 # if we set it, the image will be load at 0x0, otherwise the 64bit image will be load on 0x80000
#disable_commandline_tags=1 #Fix me, when set it, the image will be load on 0x0 ?

  • Hi Danny

    My name is Stephen and I work at Arm.

    There is an example for Raspberry Pi 3 provided in the Arm DS examples (named "Raspberry-Pi-3_RAM" in Bare-metal_examples_Armv8.zip) that I would expect to work similarly for Raspberry Pi 4.

    In the Debug Configurations view, have you selected the configdb for Raspberry Pi 4 that is provided with Arm DS, or have you created your own?

    Please can you check that the jumper wires to connect the JTAG signals between DSTREAM/ULINK and Raspberry Pi are as described in the readme for Raspberry-Pi-3_RAM, and that config.txt contains just these lines:
    arm_64bit=1
    kernel_old=1
    enable_jtag_gpio=1
    disable_commandline_tags=1
                
    I will try to verify bare-metal debug on Raspberry Pi 4 myself in the next day or two.

    Stephen
         

  • hi Stephen:


    thanks you very much

    1. I have selected the configdb for Rasperrby Pi4

    2. my config.txt contains  arm_64bit=1 and enable_jtag_gpio=1, because my code is running at 0x8000, so i do not cantains kernel_old=1 and disable_commandline_tags=1

    3. I put my program in that raspberry pi and it works

    4、I use openocd and jlink on ubuntu is debuggable

  • hi Stephen:


    thanks you very much

    I found the reason, I didn't connect the ground of the raspberry pi4 and dstream,
    I thought the common ground was fine, only connect the ground of the raspberry pi4 and the computer.