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.

CCS/RF430FRL152H: CCS coding issue (Printf)

Part Number: RF430FRL152H
Other Parts Discussed in Thread: MSP430G2553

Tool/software: Code Composer Studio

I am using RF430-TMPSNS-EVM connected to TRF7970ABP+MSP430G2553
I would like to output the ADC0 value received from the RF430-TMPSNS-EVM via CCS.
But I certainly don't know which example code to use.
www.ti.com/.../SLAC691
Once I downloaded the above firmware, I added all the files in the RF430FRL15xH NFC Projects folder to the CCS.
Then I changed the code in main.c.
The following code has been added at the bottom of the example code:

#pragma vector=ADC12_VECTOR

__interrupt void ADC12_ISR (void)

{

adc12_data = ADC12MEM0; // Move results, IFG is cleared

adc12_int_flg = 1; // a/d data flag on

}

printf("ad_data : %x\r\n",adc12_data);

But nothing happened when we did the debug.
Is the example code I chose wrong? Or should other conditions be met for this code to be executed?

  • Hello,

    Have you considered using another method to monitor the ADC0 value received from the sensor? As this E2E post ( e2e.ti.com/.../518039 ) points out, printf() is not recommended as it requires a lot of overhead to run. You can monitor the value of the ADC12MEM0 register inside of the "register viewer" in CCS if you'd like to check the value while in a debug session. Another option is to send the adc12_data value over UART to the PC where you can display the value on a terminal. There are UART examples, as referenced in the linked E2E post, which provide software for utilizing the back-channel UART.

    Best regards,

    Matt

**Attention** This is a public forum