MSP430F449烧程序出现的问题

zhuhao0914   2008-5-26 13:07 楼主
Mon May 26 12:59:07 2008: MSP430.DLL version 1.15
Mon May 26 12:59:07 2008: Device : MSP430F44x
Mon May 26 12:59:10 2008: Loaded module
Mon May 26 12:59:10 2008: Target reset
Mon May 26 12:59:10 2008: Driver does not support code coverage.
Mon May 26 12:59:10 2008: Error: Operation error.
Mon May 26 12:59:10 2008: Couldn't go to 'main'.

请大家帮帮忙?

回复评论 (5)

程序贴出来
点赞  2008-5-26 14:42
/*************************LED 显示程序******************************************/
/* 此程序是针对于msp447学习班编写,对led显示进行测试, 程序中有一个测试测试led数码管*/
/* 是否正常的test()函数。本程序根据电路板上led的设置,可显示6位数字和小数点,显示范围*/
/*推荐为0.0 ~ 999999,大于此范围的数字自动截取右边高6位,当显示的数字大于6位时,高6位*/
/*显示,低位去掉 */
/************************结束**************************************************/
//MSP-Test44x Demo lcd ,led dishplay the timer
//
// MSP430F449
// -----------------
// /|\| XIN|-
// | | | 74HC373(1)&(2)
// --|RST XOUT|- -------------
// | | | |
// | P3.1|------>|D0 |
// | . | . | |
// | P3.7|------>|D7 |
// | P4.0|------>| |
// | P4.1|------>| |
// | |
//
// Zhang Chong
// Lierda, Inc
// MAY 2004
// Built with IAR Embedded Workbench Version: 1.26B
//****************************************************************************
#include "msp430x44x.h"

#define LED1 0x3E;
#define LED2 0x3D;
#define LED3 0x3B;
#define LED4 0x37;
#define LED5 0x2F;
#define LED6 0x1F;

int Digit[10]={0XD7,0X14,0XCD,0X5D,0X1E,0X5B,0XBB,0X15,0XDF,0X5F};

void Delay(int m)
{
while(m-->0);
}

void Display(int pos,int x,int point)
{

int BitSel;
int temp;
switch (pos)
{
case 1:
BitSel = LED1;
break;
case 2:
BitSel = LED2;
break;
case 3:
BitSel = LED3;
break;
case 4:
BitSel = LED4;
break;
case 5:
BitSel = LED5;
break;
case 6:
BitSel = LED6;
break;
default:
break;
}
P3DIR = 0XFF;
if(point)
P3OUT = Digit[x]+ 0x20; //display point
else
P3OUT = Digit[x];
temp = P3OUT;
P3OUT = 0X00;
P4OUT = 0X02; //DATA CHOOSE BIT SET;
P4OUT = 0X00; //DATA CHOOSE BIT RESET,CLOSE;
P3OUT = temp;
P4OUT = 0X02;
P4OUT = 0X00;
P3OUT = BitSel;
P4OUT = 0x01;
P4OUT = 0X00;
Delay(500);
}

void Send_Data(float Data)
{
unsigned long xx;
int temp;
int i = 6;
if(Data<1.0)
{
xx = Data * 100000;

while(xx !=0)
{
temp = xx % 10;
if(temp != 0)
{
Display(i,temp,0);
i--;
}

xx = xx / 10;
}
Display(i,0,1);
i = 6;
}
else if(Data<10.0)
{
xx = Data * 100000;
while(xx !=0)
{
temp = xx % 10;
if(temp != 0)
{
if(xx<10 && i<6)
Display(i,temp,1);
else
Display(i,temp,0);
i--;
}

xx = xx / 10;
}
i = 6;
}
else if(Data<100.0)
{
{
xx = Data * 10000;
while(xx !=0)
{
temp = xx % 10;
if(temp != 0)
{
if(xx> 9 && xx<100 && i<6)
Display(i,temp,1);
else
Display(i,temp,0);
i--;
}

xx = xx / 10;
}
i = 6;
}
}
else if(Data<1000.0)
{
{
xx = Data * 1000;
while(xx !=0)
{
temp = xx % 10;
if(temp != 0)
{
if(xx>99 && xx<1000 && i<6)
Display(i,temp,1);
else
Display(i,temp,0);
i--;
}

xx = xx / 10;
}
i = 6;
}
}
else if(Data<10000.0)
{
{
xx = Data * 100;
while(xx !=0)
{
temp = xx % 10;
if(temp != 0)
{
if(xx>999 && xx<10000 && i<6)
Display(i,temp,1);
else
Display(i,temp,0);
i--;
}

xx = xx / 10;
}
i = 6;
}
}
else if(Data<100000.0)
{
{
xx = Data * 10;
while(xx !=0)
{
temp = xx % 10;
if(temp != 0)
{
if(xx>9999 && xx<100000 && i<6)
Display(i,temp,1);
else
Display(i,temp,0);
i--;
}

xx = xx / 10;
}
i = 6;
}
}
else if(Data<1000000.0)
{
{
xx = Data;
while(xx !=0)
{
temp = xx % 10;
if(temp != 0)
{
Display(i,temp,0);
i--;
}

xx = xx / 10;
}
i = 6;
}
}
}
//***************test of segment of led ***********//

/*void test(void)
{
int i;
int temp;
P3OUT = 0x01;
for(i=0;i<8;i++)
{
temp = P3OUT;
P4OUT = 0X02;
P4OUT = 0X00;
P3OUT = 0X3e;
P4OUT = 0X01;
P4OUT = 0X00;
Delay(20000);
P3OUT = 0x00;
P4OUT = 0X02;
P4OUT = 0X00;
P3OUT = 0X3e;
P4OUT = 0X01;
P4OUT = 0X00;
Delay(20000);
P3OUT = temp;
P3OUT = P3OUT << 1;
}
}
*/

void main(void)
{
while(1)
{
WDTCTL = WDTHOLD+WDTPW;
P4DIR = 0X03;
P3DIR = 0XFF;
P3OUT = 0X00; //clear all the leds display
P4OUT = 0X02; //data select choose
P4OUT = 0X00;
Send_Data(1118.88888);
}
}
点赞  2008-5-26 21:15
lz的程序在我这里编译下载运行没问题的
点赞  2008-5-27 10:52
我的编译器是3.42A
点赞  2008-5-27 10:54
我现在解决了,从IAR主页上下载了最新软件安装上以后就没问题了,不过是4K代码限制的。让我贴代码却不会回答,真是没话说,谢谢hzuser
点赞  2008-5-27 19:20
电子工程世界版权所有 京B2-20211791 京ICP备10001474号-1 京公网安备 11010802033920号
    写回复