2022-10-25 06:45 AM
We have a custom PCB application that uses the STM32MP151CAC1 as the main CPU. We have tried to use an STLink v3 to connect to the chip over SWD, but have been unable to do so. The chip (through UART4) throws the following error when I try to connect:
ERROR: Illegal access to 0xe000edf0:
ERROR: FAIL_ID = 0x2
ERROR: Non-Secure
ERROR: Privilege
ERROR: Write
PANIC at PC : 0x2ffc9b61
Exception mode=0x00000016 at: 0x2ffc9b61
Meanwhile, on the STCube Programmer, depending on what settings I have, I get one of the following error messages:
Error: Cannot connect to access port 1 If you are trying to connet to a device with TrustZone enabled please try to connect with HotPlug mode
Error: DEV_UNKNOWN_MCU_TARGET
Error: Cannot identify the device
Some additional information:
The signals I'm trying to communicate over are:
JTMS (pin C20 on the STM32MP1)
JTCK (B20)
JTDI (A20)
JTDO (A19)
JTRST (19)
Of those, JTMS and JTRST are pulled up to VDD through 10K resistors. JTCK is pulled down to ground through another 10K resistor. Let me know if that shouldn't be the case.
Solved! Go to Solution.
2022-10-28 07:46 AM
Hi @TCros.1 ,
it's seems you are trying to use STM32CubeProgrammer with ST-Link, which is not supported with STM32MPx. USB (or UART) must be used with CubeProgrammer.
Nevertheless, STLINK connection could be tested using the openocd command used in https://wiki.st.com/stm32mpu/wiki/STM32_MPU_ROM_trace_analyzer#On_STM32MP15x_lines (to be done in either Engi boot or when BootROM is waiting for USB/serial boot).
For HW, checks please refer to AN5031 Figure 18. JTAG/SWD MIPI10 connector implementation example
Olivier
2022-10-28 07:46 AM
Hi @TCros.1 ,
it's seems you are trying to use STM32CubeProgrammer with ST-Link, which is not supported with STM32MPx. USB (or UART) must be used with CubeProgrammer.
Nevertheless, STLINK connection could be tested using the openocd command used in https://wiki.st.com/stm32mpu/wiki/STM32_MPU_ROM_trace_analyzer#On_STM32MP15x_lines (to be done in either Engi boot or when BootROM is waiting for USB/serial boot).
For HW, checks please refer to AN5031 Figure 18. JTAG/SWD MIPI10 connector implementation example
Olivier
2022-11-03 07:30 AM
Good to know, thanks!!