We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
I own a ULINK Pro. Managed to get ETM trace working on my STM32F4, but when I stop the CPU or run into a breakpoint, I can only look back about 1ms (at 168MHz) or about 2ms at 100MHz. How much I can see in the trace window seems to depend on the complexity of the code. More function calls or even function pointers seem to reduce the number of instructions.
It seems to me that I can not use streaming trace, but only the buffer in the ULINK Pro, which seems to be very small (around 64KB?) With streaming trace, the number of instructions should be unlimited since my harddrive can be used as buffer.
Any way to get streaming trace up and running?
Anybody has similar experiences? To me, the whole unit is not worth a thing. All I seem to be able to use is the little bit of memory in the unit (Actually the FPGA) That gives me a few ms, which is way too little. Also streaming (real time) does not work.
Help me out ... The hardware itself is working, as I am getting SWO stuff,
PC samples etc. and also correct trace data, just too little and not real time.
Does anybody have any clue or is Keil promising things that do not work?
~1MB/s must not be the streaming trace transaction. I doubt if you have enabled streaming tracing properly. Check ULINKpro User's Guide for detailed information and directions.
Streaming Trace need your ULINKpro, your uVision and your target microcontroller properly configured. So you must confirm:
1. If your processor has got the Embedded Trace Macrocell. Not all the Cortex-M devices integrated this macrocell !
2. Check your Trace settings. For ETM tracing you must select the right Trace Port. Also you MUST tick Unlimited Trace and ETM Trace Enable.
3. Configure your processor to enable 4-pin Trace. It means you must modify DBGMCU_CR to enable ETM. And your PE3~PE6 porperly conncected.
Jack,
Thanks for trying, but this is not the reason: Of course my chip has ETM. STM32F4 does have it, besides I said that I do get trace data, only not a lot and not life. Seems like I only get whatever the FPGA can store. And yes, I did enable ETM (again, otherwise I would not get anything!) Unlimited trace is also enabled. Processor is properly configured. I checked with scope, settings are correct as I get data on all 4 Trace-data lines.
I am starting to think that it simply does not work, that with ULINK PRO I can only get the trace data that the FPGA can store and only after halting the target CPU, which would be a very severe limitation.
Does ANYONE HAVE STREAMING TRACE actually working?
It would be helpful if Bob Boys jumped in here to provide some definitive statement about the function and configuration of the trace modes.
One of the compelling cases for trace is a long term buffer that can run indefinitely and provide postmortem data about just how the heck the code got to where it is, and why.
As Sven points out, the STM32 family has a complete debug instantiated with the core. The STM3240G board has trace headers as I recall.
Bob Boys, where are you?
And again: Does ANYBODY HAVE STREAMING TRACE ACTUALLY WORKING ???
Does not seem like it. If not, I will probably have to use J-Trace from Segger and/or switch to another tool chain (Who? Do not want to use IAR ...) as I need a bigger trace buffer.