Tool/software: Code Composer Studio
Hi,
I’m working with the MSP430FG6626 and I have 2 questions concerning the visibility of registers of the CTSD16 in debugging mode and the access to these registers in general:
1. When I’m debugging I can only view registers of Channel 0 in the register tab, e.g. CTSD16CCTL0.
How can I make the registers of the other AD-channels visible, e.g. CTSD16CCTL1?
As an IDE I’m using CCS 10.1.0.
2. How can I get access to the registers of the other channels?
I defined the ADC-registers of channel 1 in the msp430fg6626.h file of the include folder in ...ti/ccs1010/ccs/ccs_base/msp430/include and tried to debug the example project msp430fg662x_ctsd16_04 by replacing channel 0 registers with channel 1 registers. Unfortunately the results variable is always 0. How can I solve this problem?
#include <msp430.h>
unsigned int results; // CTSD16 Conversion Results
void main(void) {
WDTCTL = WDTPW | WDTHOLD; // Stop WDT
P6SEL |= BIT6 | BIT7; // Select AD1+/- analog input pins
CTSD16CTL = CTSD16REFS; // Internal ref
CTSD16CCTL1 |= CTSD16SNGL | CTSD16DF; // Single sample, 2's complement
CTSD16INCTL1 |= CTSD16INCH_11; // Select AD1+ / AD1- for CH1
__delay_cycles(2000); // Delay ~120us for 1.2V ref to settle
while(1) {
CTSD16CCTL1 |= CTSD16SC; // Set bit to start conversion
while(!(CTSD16IFG & CTSD16IFG)); // Poll IFG until conversion completes
results = CTSD16MEM1; // Save CTSD16 conversion results
__no_operation(); // SET BREAKPOINT HERE
}
}
Thank you very much.

