void Conut(void) //測量函數
{
time=TH0*256+TL0; //距離計數
TH0=0; //定時器清零
TL0=0; //定時器清零
S=(time*1.87)/10; //算出來是CM、轉換
if((S>=700)||flag==1) //超出測量范圍顯示“-”
{
flag=0; //數據無效標志
}
else
{
Table1[0]= S/1000+0X30; //顯示當前值
Table1[1]= S/100%10+0X30; //顯示當前值
Table1[2]= S/10/10+0X30; //顯示當前值
Table1[3]= '.'; //顯示當前值
Table1[4]= S%10+0X30; //顯示當前值
LCD1602_Disp_ZF(0x88,Table1,5); //顯示當前值
程序.C(48): warning C206: 'LCD1602_Disp_ZF': missing function-prototype
程序.C(48): error C267: 'LCD1602_Disp_ZF': requires ANSI-style prototype
|