I'm using keil with STLINK, connected to a GD32F130C8.
I can see, in debug, by means of Watch, variables changing in real time.
Everything works fine.
Now I would like to enable trace, in order to see the evolution of a variable in time domain, thru logic analyzer.
I enabled trace flag on trace tab (setting menu), I set, on trace tab, the processor speed (72MHZ).
The problem is that logic analyzer doesn't show requested float variable, and on the bottom of the screen I read the sentence "Trace: No Synchronization".
The output of SystemCoreClock() function gives 72Mhz.
any hint?
lujji.github.io/.../
yes - that looks like the kind of thing.
Please let me better understand trace:
now I use clock and data to flash firmware and to watch variables.
do I need to use one more pin to receive trace data?
according to the previous shared link I can add SWO pin to my cheap st link clone.
Then where should I connect SWO ? On which pin of my GD32 chip?
Again, why don't you go back to the example you cited earlier - get that working, and then you'll have the understanding to know what to do ...
There is something i’m Not understanding:
the example that I cited says:
Additional Serial Wire Viewer (SWV) Information:Serial Wire Viewer data (frames) are output on the 1 pin SWO. This pin is located on 13 on the 20 pin legacy connector (the BIG one). It is also available on the 10 or 20 pin CoreSight Debug connectors. SWO is on pin 6 on the 10 pin and pin 14 on the 20 pin. SWO is multiplexed with JTAG TDO pin. This means SWD (Serial Wire Debug) must be used and not JTAG mode. This is easily set in μVision. SWD = SW in μVision. ST-Link/V2 supports SWD only and not JTAG.
This information don’t tells me where should I connect each pin of the stlinkV2. It just tells which pin of stlinkV2 shall be used.
to be more clear, i’m not using a development board with ST chip on it, but a board of a developed board. So I need to know which pin of the processor should I connect to the stlinkV2.
looking at darasheet of my processor, I can’t find any reference to SVW or SWO.
For that example, you can look at the schematics and/or the User Manual of the board.
ema vac said:looking at darasheet of my processor, I can’t find any reference to SVW or SWO
As I asked before, what makes you think that your processor does support it?
You would need to contact the chip manufacturer for specific details ...
Search “trace” on this page:
www2.keil.com/gigadevice
In the user manual of gd32 processor I can also read the following:
The CortexTM-M3 processor is based on the ARMv7 architecture and supports both Thumb and Thumb-2 instruction sets. Some system peripherals listed below are also provided by CortexTM-M3: Internal Bus Matrix connected with I-Code bus, D-Code bus, System bus, Private Peripheral Bus (PPB) and debug accesses (AHB-AP) Nested Vectored Interrupt Controller (NVIC) Flash Patch and Breakpoint (FPB) Data Watchpoint and Trace (DWT) Instrumentation Trace Macrocell (ITM) Serial Wire JTAG Debug Port (SWJ-DP) Trace Port Interface Unit (TPIU)
ema vac said:Search “trace” on this page
The only mention of trace on that page is saying that you can use the ULINK-pro - which has trace capability.
It doesn't say that the chip has trace capability.
ema vac said:In the user manual of gd32 processor I can also read
Again, for clarification of their documentation, and/or their chip's features & capabilities - you need to contact them.