Hi everyone,I am using R7FA6M5BF3CFB as MCU and J-Link segger plus v11 in SWD mode. I configured a flat zone project, when I try to debug this project I receive "Failed to retrieve all the IDAU secure/non-secure regions." warning from the console. I think it is about serial programming(p110,p109 pins) I tried various combination in configurator but the result not changed. My related pin config (in configuration.xml)listed asp300 SWCLKp108 SWDIOp109 TRACESWOP110 Disabled
P200 an application pin(not used as NMI)
P201 system0_MDI am open to any advice about wiring the jlink or configurator or script(.ld)Schematics of my board
I want to update my question. After some hw changes this fault eliminated but another fault continue on my side. I want to use ethernet in my project and using ethernet stacks but as shown in image my nonsecure zone boundaries are not set so my edmac not work properly so my ethernet not work properly as mentioned in this issue
https://community.renesas.com/mcu-mpu/ra/f/forum/30502/ra6e1---jlink-debugger-disconnected-when-configured-p109-as-gpio-output-pin
Am I suppose to do extras for setting boundaries of nonsecure zone
What HW changes did you make?
To use Ethernet on an RA6M5 the trustzone boundaries MUST be set (even on a flat project). The trustzone boundaries can only be set via the boot firmware. The interfaces to the boot firmware are shown in the HW Users manual :-
since on your schematic P1_10 is not connected to anything, and the USB USB_DP and USB_DM are not connected to anything, you have no way of actually setting the trustzone boundaries, so everything is marked as Secure, and the Ethernet will not work.
The suggested debug interface connection is shown in the HW users manual :-
I connected the p110 and I have no issue about
now. You are saying you have to set the boundaries but how I suppose the set boundaries is that an automatic process that debugger do or I should do it manually.
If there is the required HW connection between the RA6M5 and the debugger, then at the launch of the debug session in e2studio, the debugger will set the trustzone boundaries, if the highlighted option is set in the debug configuration :-
Your HW does not have the required HW connection between the RA6M5 and the debugger. The missing connections are P1_10 is not connected between the RA6M5 and the debugger, and P3_00 and P2_01 are not wired OR (i.e. connected together), the EK-RA6M5 has these connections :-
I am saying again I connected p110 and shorted md with p300. Back then I was receiving the serial comm isue but after this changes I am not receiving it but just can not set the nonsecure zone and my settings are as shown below
The debug connection will use the information in the .rpd file, in the build output directory to set the trustzone boundaries. What is the contents of the .rpd file in your project?
It looks like .rpd file is not auto generated. How to generate this file.
The .rpd file should be generated by the DDSC Bundle builder :-
Is the DDSC Bundle Builder enabled in your project?
Our project consist of 2 project a library creator project and an application project. Library files created in library generator project with auto generator and used by application project . DDSC Builder is present in the library generator project but not in the application project due to this I think we can not create rpd file. But for your question I created a new flat zone project and screenshot the memory_regions.ld and .rpd files then I add a http client stack(since it uses nonsecure area) and take the screenshots again If these files are normal, I diagnose that problem is about our dual project architecture and I will try to fix it otherwise I am open to suggestionsFiles before http clientAfter HTTP client
Probably the easiest thing is to set the boundaries manually, using Renesas Device Partition Manager (RDPM) in e2studio. Disable setting the trustzone boundaries in the debug configuration :-
Then use RDPM to set the boundaries manually. In e2studio got Run->Renesas Debug Tools->Renesas Device Partition Manager, select "Set TrustZone secure / non secure boundaries, check the "Use Renesas Partition Data file" box, select the .rpd file from the library project, and click "Run" to set the boundaries :-
You will only need to re-set the boundaries if you change the size of the Ethernet buffers, or if the device is initialised back to default settings.
Thank you for your help.