Other Parts Discussed in Thread: MSP-TS430DA38
Hello.
I have a question.
Is there a way to reduce the current consumption of my code while observing the following conditions?
MCLK = 500KHz
MCLK sourced from 4MHz crystal
VCC = 3.0V
My code is as follows.
Measurement result while my code running was 1428 uA when the DVcc was 3.0 V in the MSP-TS430DA38 on which 4 MHz crystal and MSP430G2955 were mounted(Debugger is disconnected).
This current consumption seems to be very high compared to the value described in the datasheet.
#include <msp430.h>
volatile unsigned int i;
int main(void)
{
WDTCTL = WDTPW | WDTHOLD;
P1DIR |= 0xFF;
P1OUT = 0;
P2DIR |= 0xBF;
P2OUT = 0;
P2SEL |= BIT6 + BIT7;
P3DIR |= 0xFF;
P3OUT = 0;
P4DIR |= 0xFF;
P4OUT = 0;
BCSCTL1 |= XTS;
BCSCTL2 |= SELM_3 +DIVM_3 + SELS + DIVS_3;
BCSCTL3 |= LFXT1S_2;
do
{
IFG1 &= ~OFIFG;
for (i = 0xFF; i > 0; i--);
}
while (IFG1 & OFIFG);
while(1);
}
For example, if the crystal is lowered to 1 MHz, can the current consumption be reduced?
In addition, please tell me if there is a way to reduce the current consumption.
Regards,
uchida-k