cancel
Showing results for 
Search instead for 
Did you mean: 

How to use the DWT_CYCCNT and DWT_CONTROL

LMI2
Lead
3 REPLIES 3
Posted on September 01, 2016 at 20:30

They are ARM core registers, but optional for the licensee, ST choose to use them in the STM32 designs for the M3 and M4 cores, and their address is fixed and define in the ARM TRM. One might not choose to use them to reduce silicon, power, or fit in an FPGA, or meet timing goals (critical paths).

The M7 might be slightly different, or require magic unlock sequences

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
LMI2
Lead
Posted on September 01, 2016 at 21:45

So, these addresses are defined somewhere else and I don't need to put them in code the myself like in one of the examples?

With M3 and M4.

Posted on September 01, 2016 at 22:51

They are defined in the manual, you'd need to set up the appropriate variable or structure. They are not in core_cm3.h or core_cm4.h like some of the ITM stuff at 0xE0000000

http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.ddi0337h/BABJFFGJ.html

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..