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.

Watch variable in Code Compressor Studio

Hi all, 

I have a MSP430's EZ430-F2013 kit which was working well with IAR studio. But in Code Compressor Studio V 4,  I am having problem with watch variables of Registers . I can neither watch ( they are always of same value) nor can i change variables from watch window.  For example in watch window i can see any variable like "int i" but i cannot watch /change compiler defined variables TACTL, CCTL0 etc....

Same code compressor studio works well with my Blackhawk programmer for F28335 processor for all kind of variables.

I have played around with optimization level, heap size and other project settings but with no luck.

Can someone suggest a solution....

Regards.

 

Following is the simple code i have used for testing.....



#include <msp430x20x3.h>

void main(void)
{
    int i;
      WDTCTL = WDTPW + WDTHOLD;                 // Stop WDT
      P1DIR |= 0x01;                            // P1.0 output
    //BCSCTL2 = SELM_1 + DIVM_3; 
      CCTL0 = CCIE;                            // CCR0 interrupt enabled
      i = 20;
      //CCR0 = 50000;
      TACTL = TASSEL_2 + MC_2;                  // SMCLK, contmode
     //BCSCTL2 =  0xff; //SELM_1 + DIVM_3;
      _BIS_SR(LPM0_bits + GIE);                 // Enter LPM0 w/ interrupt
}

// Timer A0 interrupt service routine
#pragma vector=TIMERA0_VECTOR
__interrupt void Timer_A (void)
{
  P1OUT ^= 0x01;                            // Toggle P1.0
  //CCR0 += 50000;                            // Add Offset to CCR0
  //BCSCTL2 = SELM_1 + DIVM_3;
}

  • Which version of CCS are you using? I have CCS 4.1.2 and I've tried examples for other MSP430 devices where I can view and modify registers from the watch window successfully. To add registers to the watch window, I normally open the register view, then right-click on the register and select "Create Watch Expression". This displays the address of the register and value contained at that address in the watch window.

  • HI Aarti,

    Thanks for the response. I am using V 4.0.2.01003

    I actually got around this problem by using view registery i.e. View -> Registers.  In this view I can easily watch and change Register variables like WDTCTL, BCSCTL1 etc...  where as that was/is not possible to view and change these varialbes in Watch window.

    But since I can do the same in Registers window, i.e. change WDTCTL, BCSCTL1 etc, my problem is solved.

     

**Attention** This is a public forum