As I was debugging the program for MSP430F6736 using MSP-FET430UIF,
I got the message below.
I use spy by wire (4wire) connection to MSP430F6736.
Below lines are the Debug Log.
*****
Wed Apr 03, 2013 16:59:03: Using license: Standalone license - IAR Embedded Workbench for Texas Instruments MSP430, 4K KickStart Edition 5.51
Wed Apr 03, 2013 16:59:04: Firmware version 30205004
Wed Apr 03, 2013 16:59:04: Interface dll version 3.2.5.4
Wed Apr 03, 2013 16:59:05: Security Fuse has been blow
Wed Apr 03, 2013 16:59:11: Fatal error: Could not find device (or device not supported) Session aborted!
****
Now I can't debug anymore.
I think I was able to start the 32.768kHz X'tal OSC all right.
I think the DCO frequency is about 14.75MHz all right.
As I often get the message
What should I do?
Below are the source code I wrote.
I got the message "you can't write to xxx table descriptor ..." when I quit debugging before I got the message next time.
What shoud I do?
// strain1 - measure strain guage bridge voltage using 24bit sigma-delta ADC and send it over bluetooth
// Written by Koyo Kegasa. start on Monday, April the 1st 2013.
#include "MSP430F6736.h"
int main( void )
{
// Stop watchdog timer to prevent time out reset
WDTCTL = WDTPW + WDTHOLD;
// 32.768kHz X'tal OSC setting
UCSCTL6 &= ~XT1OFF; // XT1 ON
// FLL frequency lock loop setting
UCSCTL1 &= DCORSEL_5;
UCSCTL1 |= DCORSEL_5 | DISMOD; // DCO range = 5 = 6.0MHz - 23.7MHz, FLL modulation OFF
UCSCTL2 &= ~FLLD_1; // FLLD = 0, 32.768kHz/1
UCSCTL2 &= ~0x3ff;
UCSCTL2 |= 449; // FLLN = 449, 450 times 32.768kHz = 14.7456 MHz, FLLD = 0, 32.768kHz/1
// 32.786kHz X'tal OSC XT1CLK to ACLK and output to PJ.3 pin 79
UCSCTL4 |= SELS2 | SELM2; // ACLK = XT1CLK, SMCLK = DCLKDIV, MCLK = DCLKDIV
PJSEL |= BIT3; // select PJ.3 ACLK
PJDIR |= BIT3; // select PJ.3 ACLK
// MCLK to PJ.1 = pin 77
PJSEL |= BIT1; // select PJ.1 MCLK
PJDIR |= BIT1; // select PJ.1 MCLK
while( UCSCTL7 & XT1LFOFFG )
{
UCSCTL7 &= ~XT1LFOFFG; // if XT1LFOFFG is ON, clear it
// if( UCSCTL7 & DCOFFG ) UCSCTL7 &= ~DCOFFG; // if DCOFFG is ON, clear it
if( SFRIFG1 & OFIFG ) SFRIFG1 &= ~OFIFG; // if OFIFG is ON, clear it
__delay_cycles(100);
}
if( SFRIFG1 & OFIFG ) SFRIFG1 &= ~OFIFG;
// LED on/off port P1.6 and P1.7 2013-4-2 by Koyo Kegasa MSP430F6736 strain1
while(1)
{
P1DIR |= BIT6; // output port
P1OUT |= BIT6; // turn red LED off
__delay_cycles(100000);
P1OUT &= ~BIT6; // turn red LED on
__delay_cycles(100000);
P1OUT |= BIT6; // turn red LED off
P1DIR |= BIT7; // optput port
P1OUT |= BIT7; // turn green LED off
__delay_cycles(100000);
P1OUT &= ~BIT7; // turn green LED on
__delay_cycles(100000);
P1OUT |= BIT7; // turn green LED off
}
return 0;
}