?? receivebyte.c
字號(hào):
//*****************************************************************************
// Title : Software Interrupt-driven UART function library
// Author : Pascal Stang - Copyright (C) 2002-2003
//
// This code is distributed under the GNU Public License
// which can be found at http://www.gnu.org/licenses/gpl.txt
//
//*****************************************************************************
#include "../uartsw.h"
//! gets a byte (if available) from the uart receive buffer
u08 UARTSW_ReceiveByte(u08* rxData)
{
// make sure we have a receive buffer
if(UARTSW_RxBuffer.size)
{
// make sure we have data
if(UARTSW_RxBuffer.datalength)
{
// get byte from beginning of buffer
*rxData = bufferGetFromFront(&UARTSW_RxBuffer);
return TRUE;
}
else
{
// no data
return FALSE;
}
}
else
{
// no buffer
return FALSE;
}
}
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號(hào)
Ctrl + =
減小字號(hào)
Ctrl + -