混合编程问题

2019-03-24 14:59发布

//主程序
#include "msp430x44x.h"      
extern cheng
//====================================
      NAME  main
      ORG   0FFFEh
      DW    RESET
//---------------------------------
      RSEG  CSTACK
      RSEG  CODE
;---------------------------------
RESET mov.w #SFE(CSTACK),SP;CSTACK=0200-0A00
main  mov.w #WDTPW+WDTHOLD,&WDTCTL
//-------------------------------------
      mov.w #20,R14;
      mov.w #40,R12;
      call #cheng//结果在R12
//-------------------------------------
main1
      jmp main1  
//--------------------------------     
      END


//子程序
#include "msp430x44x.h"
//extern unsigned int ?Mul16Hw(unsigned int,unsigned int);
unsigned int cheng(unsigned int i1,unsigned int i2)
{
    return(i1*i2);
}


错误提示:
//Error[e46]: Undefined external "?Mul16Hw" referred in chengc

如何解决 此帖出自小平头技术问答
友情提示: 此问题已得到解决,问题已经关闭,关闭后问题禁止继续编辑,回答。
4条回答
jhw3378
2019-03-25 03:17
< :TI_MSP430_内容页_SA7 --> 我用的是
IAR Assembler for MSP430
V3.42A/W32 (3.42.1.9)

一周热门 更多>

相关问题

    相关文章