Good Mornig:
I'mtry tu check the SRS1_JTAG flag of MK60FN1M0VMD12 by Keil environment.
this flag is inside of System Reset Status Register 1.
And when I am debugging with ULINK 2 by UVision, this flag is not activated.
That is the raison?
for check the debug mode is activated, Who can i Used this flag?
There is another way to check if jtag is connected?
Thank you very much.
It can be very userful.
解決済! 解決策の投稿を見る。
Hello Albert Martin:
I did not get the first part of your question very well. But if you want to detect when the K60F MCU is in Debug mode, I guess you can use the ARM register DHCSR (Debug Halting Control and Status Register), which is at address 0xE000EDF0. Example below:
#define DHCSR_REG (*(uint32_t*)(0xE000EDF0))
int main (void)
{
if(DHCSR_REG & (uint32_t)(0x1))
{
// Debug mode
}
else
{
// Standalone mode
}
}
I hope this helps!
Regards,
Jorge Gonzalez
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------
Hello Albert Martin:
I did not get the first part of your question very well. But if you want to detect when the K60F MCU is in Debug mode, I guess you can use the ARM register DHCSR (Debug Halting Control and Status Register), which is at address 0xE000EDF0. Example below:
#define DHCSR_REG (*(uint32_t*)(0xE000EDF0))
int main (void)
{
if(DHCSR_REG & (uint32_t)(0x1))
{
// Debug mode
}
else
{
// Standalone mode
}
}
I hope this helps!
Regards,
Jorge Gonzalez
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------
Perfect.
Thank you very much for all.:smileyhappy:
It is just what I needed.
my problem is, I did not find this information in the manual (K60P144M150SF3RM.pdf)
Thank you very much.
you are the best!.