Курсовая работа: Разработка измерителя температуры жидкости
}
//=================================
char TimeDelay_us(char x) //near 1us time delay
{
char i,j,k,n;
j=1;
for (i=0;i<x;i++)
{
k=j+1;
n=k-j;
}
return n;
}
//== Circular Buffer Write =====================
void CircBufPut (unsigned char data)
{
unsigned char tmphead;
tmphead = CircBufHead + 1;
if (tmphead>=CircBufLen)
{
tmphead=0;
}
CircBuf[tmphead] = data;
CircBufHead = tmphead;
}
//== Circular Buffer Read ==========
unsigned char CircBufGet(void)
{
unsigned char tmptail;