Exemplo n.º 1
0
void main( void )
{
  WDTCTL     = WDTPW + WDTHOLD                                     ; // 关看门狗
  BoardConfig(0xf0);
  Init_Port();
  InitUART();
  _EINT()                                            ;
  PcdReset();//复位RC522
  PcdAntennaOn();//开启天线发射 
  DisplayConfigMenu();
  while(1)
  {
        Send1Char('>');
        Send1Char('\n');
        i=Get1Char();
        HandleConfigMenu(i);
  }
}
Exemplo n.º 2
0
/*******************************************
函数名称:PutSting
功    能:向PC机发送字符串
参    数:ptr--指向发送字符串的指针
返回值  :无
********************************************/
void PutString(char *ptr)
{
    while(*ptr != '\0')
    {
        Send1Char(*ptr++);                     // 发送数据
    }
    while (!(IFG1 & UTXIFG0));
    TXBUF0 = '\n';                              //发送换行指令
}