Hello,
I'm having an issue with the JLink not being able to automatically detect the RTT control block.
If I set an exact control block address in J-Link RTT Viewer, the control block is located and RTT log output is as expected. If I set a search range which includes the known RTT control block address, the RTT control block is not found. Similarly, automatic detection does not locate the control block.
My setup is as follows:
Device: STM32F746IG. Linker specifies internal RAM @ 0x20000000, length 320K
JLink tool version v6.94, JLink Plus probe
Windows 10 Host
SEGGER_RTT_Conf.h is configured to place the control block and RTT buffers in a linker section named .segger_rtt. Using a linker script, this section has been placed at a fixed known location in RAM with the RTT control block located at 0x2004ef78.
Entering 0x2004ef78 as the RTT control block address in RTT viewer results in immediate RTT location and RTT log output.
If using a manual search range of '0x2004EF00 0x100' instead of manually specifying an exact location, the RTT control block is not found. Same result for automatic detection. When viewing the RTT search status at localhost:19080/rtt.hml, the Status shows 'Looking for RTT CB @ 0x2004EF00 (Range 1/1)' indicating that the search range has been received, but RTT control block is not found.
My preference is to support auto detection to make it easier for our testers. Do you why this is not working and other things to try?
Answers to the following questions may also assist debugging:
Thank you
Austin
I'm having an issue with the JLink not being able to automatically detect the RTT control block.
If I set an exact control block address in J-Link RTT Viewer, the control block is located and RTT log output is as expected. If I set a search range which includes the known RTT control block address, the RTT control block is not found. Similarly, automatic detection does not locate the control block.
My setup is as follows:
Device: STM32F746IG. Linker specifies internal RAM @ 0x20000000, length 320K
JLink tool version v6.94, JLink Plus probe
Windows 10 Host
SEGGER_RTT_Conf.h is configured to place the control block and RTT buffers in a linker section named .segger_rtt. Using a linker script, this section has been placed at a fixed known location in RAM with the RTT control block located at 0x2004ef78.
Entering 0x2004ef78 as the RTT control block address in RTT viewer results in immediate RTT location and RTT log output.
If using a manual search range of '0x2004EF00 0x100' instead of manually specifying an exact location, the RTT control block is not found. Same result for automatic detection. When viewing the RTT search status at localhost:19080/rtt.hml, the Status shows 'Looking for RTT CB @ 0x2004EF00 (Range 1/1)' indicating that the search range has been received, but RTT control block is not found.
My preference is to support auto detection to make it easier for our testers. Do you why this is not working and other things to try?
Answers to the following questions may also assist debugging:
- Are there any alignment requirements for the RTT control block? e.g. Does the 'SEGGER RTT' signature need to be located on a 16 byte boundary, 4 byte etc? (I have tried various alignment with no success).
- Do you publish standard RTT search ranges for each processor or have a method to find out this information?
- If specifying an exact RTT control block address, does the JLink still attempt to validate the RTT control block signature and report an error if the control block isn't found?
- Does the JLink perform a linear search through all addresses in the configured search ranges, or is only a partial search executed?
- When checking the control block, does the JLink perform further validation of control block contents in addition to the signature? e.g. Does the Jlink validate that the buffer addresses are also located in RAM?
Thank you
Austin