Advertisement
Guest User

houbysoft

a guest
Oct 25th, 2008
1,842
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.37 KB | None | 0 0
  1. void mouse_wait(unsigned char type)
  2. {
  3.   unsigned int _time_out=100000;
  4.   if(type==0)
  5.   {
  6.     while(_time_out--) //Data
  7.     {
  8.       if((inportb(0x64) & 1)==1)
  9.       {
  10.         return;
  11.       }
  12.     }
  13.     return;
  14.   }
  15.   else
  16.   {
  17.     while(_time_out--) //Signal
  18.     {
  19.       if((inportb(0x64) & 2)==0)
  20.       {
  21.         return;
  22.       }
  23.     }
  24.     return;
  25.   }
  26. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement