Skip to main content
Apill
Associate III
August 20, 2018
Question

how can i solve the problem that" cannot access the target shutting down debugging session"

  • August 20, 2018
  • 2 replies
  • 2105 views

Hello, 

       I am using cortex M microcontroller, working with STM32F051 microcontroller on discovery kit. IDE- Keil. I am trying to do a project using ADC. I have assigned one pin as ADC using an industrial accelerometer. when I am trying to operate the accelerometer and note the readings of it while debugging i am getting an error that." cannot access target shutting down debugging session". But when I am trying to operate the same pin with variable resistor( potentiometer) it works!!!. How can I solve this problem? 

One thing I would like to mention is, when ever I am making any movement it can be traced in multimeter but I cannot able to access in keil

-

Thanks,

Ashok

    This topic has been closed for replies.

    2 replies

    Tesla DeLorean
    Guru
    August 20, 2018

    Going into Low Power state is a frequent problem. ie WFI in idle/wait loop

    Interfering with the SWDIO/SWCLK GPIO pins. ie GPIOA PA13/PA14

    DBGMCU settings

    WATCHDOG, STANDBY or RESET

    Tips, Buy me a coffee, or three.. PayPal Venmo (See Profile) Up vote any posts that you find helpful, it shows what's working..
    Tesla DeLorean
    Guru
    August 21, 2018

    >>Could you elaborate your answer to the question cannot access the target. You are saying I will have to use SCLK? or use an external oscillator instead of inbuilt oscillator ?

    No, I'm saying that if the interface to SWDIO/SWCLK powers down or the pin configuration is messed with connection to the device will be lost.

    The alternative to using the debuggers SWD interface is to output telemetry via a USART.

    Make sure you moving the system about isn't cause a power issue, or loss of continuity, and causing the core to reset.

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