This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

The CC3200 device does not wake up from LPDS when the debugging is run

Other Parts Discussed in Thread: CC3200

Hi Guys,

Could you help me with one issue. I am trying to debug the CC3200 in LPDS mode with J-Link from IAR 7.80.2.

The process look like that:

1. Run debugging from IAR.

2. CC3200 init.

3. CC3200 goes to LPDS. For LPDS mode I use "PRCMLPDSEnterKeepDebugIf()" function to go to the LPDS. In this case the JTAG will not be disconnected. So I am able to stop program while CC3200 in LPDS mode and read memory, etc.

4. Then I make interruption, but CC3200 does want to wake up and continue looping in the PRCMLPDSEnterKeepDebugIf() function.

Notes, if I run the same code without debugging, the CC3200 works well and wake ups successfully.  

In debugger mode I check the INTCTRL register before and after interruption it has next value:

 - before interruption: 0x0400f000

- after interruption: 0x04411000 

register: INTCTRL
[26 bit ] PENDSTSET = 1 - On a read, indicates a SysTick exception is pending.
[22 bit ] ISRPEND = 1 - An interrupt is pending.
[19-12 bits ] VECPEND = 11h - Interrupt Vector 1

Do I miss something? Why the process does not want to exit from the LPDS mode while the debugging? Should enable something in CC3200?

Thanks! 

  • Hi Mark,

    I agree that the behavior seems wrong, but why do you need to debug the device while it is in LPDS? you mentioned that the wakeup mechanism works fine.

    This mode was provided mainly in order to restore the JTAG connection after waking up from LPDS  (as it was not disconnected). If you enter LPDS using the regular API (w/o keeping the debuig interface), the JTAG connection will be lost and is unrecoverable.

    Attempts to access the device during LPDS can cause issues (when trying to access a non-retained memory or register).

    Br,

    Kobi

  • Hi Kobi,

    Sorry, that my thoughts was not clear. I mean, that the issue not in debugging the LPDS mode (which is works fine for me). The problem in wake up process while debugging. The CC3200 does not want to wake up from the LPDS while debugging. I expect that the CC3200 wake up, but it does not occurs.

    I interested how can I debug CC3200 during full cycle. I mean, I need to debug CC3200 before and after LPDS mode. But currently I can debug CC3200 only until it enter to LPDS mode, because it does not want to exit from the LPDS mode  and jump to the function that I set.  

    So, what I miss?

    Best regards,

    Mark

  • So you just replaced PRCMLPDSEnter()with PRCMLPDSEnterKeepDebugIf() and the device stopped waking up?

    This is the only change? you are not trying to read anything while in LPDS?

  • Basically, yes, I simply replace PRCMLPDSEnter() with PRCMLPDSEnterKeepDebugIf() and the device stopped waking up but only if the debugging is running.

    In case if I run the same code without debugging? CC3200 wake ups well.

    The PRCMLPDSEnterKeepDebugif() look like this:

    void
    PRCMLPDSEnterKeepDebugIf()
    {
      unsigned long ulChipId;
    
      //
      // Read the Chip ID
      //
      ulChipId = ((HWREG(GPRCM_BASE + GPRCM_O_GPRCM_EFUSE_READ_REG2) >> 16) & 0x1F);
    
      //
      // Check if flash exists
      //
      if( (0x11 == ulChipId) || (0x19 == ulChipId))
      {
    
        //
        // Disable the flash
        //
        FlashDisable();
      }
    
      //
      // Set bandgap duty cycle to 1
      //
      HWREG(HIB1P2_BASE + HIB1P2_O_BGAP_DUTY_CYCLING_EXIT_CFG) = 0x1;
    
      //
      // Request LPDS
      //
      HWREG(ARCM_BASE + APPS_RCM_O_APPS_LPDS_REQ)
              = APPS_RCM_APPS_LPDS_REQ_APPS_LPDS_REQ;
    
      //
      // Wait for system to enter LPDS
      //
      __asm("    wfi\n");
    
      //
      // Infinite loop
      //
      while(1)
      {
    
      }
    
    }

    In case if I run CC3200 in debug, the CC3200 calls PRCMLPDSEnterKeepDebugIf() and stays at command "__asm(" wfi\n");". After that I was trying to make GPIO interruption, but CC3200 does not wake up. I can stop debugging process and after that the CC3200 is waking up, goes to the "while(1){}" and stays there forever. 

    Best regards,

    Mark 

  • I'll check internally about this.

    I'm not familiar with such issues.

    I'll let you know when i find anything. 

  • Hi Mark,

    I've verified that there are issues in regards to this API.

    Since it is not relevant for production, the priority for solving such issues is low.

    You will have to use other debugging methods when LPDS is used.

      

    Br,

    Kobi