ëŠ×Ó¹¤³Ì¾W(w¨£ng)

˜Ëî}: Ü›¼þžV²¨Çó½â [´òÓ¡±¾í“(y¨¨)]

×÷Õß: richard1983    •r(sh¨ª)ég: 2010-11-25 21:22
˜Ëî}: Ü›¼þžV²¨Çó½â
¸÷λ¿´¹Ù£¬ÔÚÏÂÓÐÒ»†–(w¨¨n)î}²»ÉõÃ÷ÁË£¬ÍüÖªÇéÕßÖ¸üc(di¨£n)ÃÔ½ò¡£ß@ÊÇÒ»‚€(g¨¨)Ü›¼þžV²¨µÄËã·¨£¬±¾ÈË¿´²»´ó¶®£¬¶®µÄÈË¿ÉÒÔÖvÒ»ÏÂËã·¨µÄ¾«Ë裬ÖxÖx£¡
     void Key_Debounce(TkeyIndex enKey,u8 input)  
  
    {  
  
  
  
  
  
   
  u8 keycount;  
  
  
  
   
  T_KeyCtl* p_stKey;  
  
  
   
  
  
  
  
  
  
   
  p_stKey=&keyIndex[enKey];  
  
  
   
  keycount= p_stKey->count;  
  
  
   
  
  
  
  
  
  
   
  if (input != FALSE) {  
  
  
   
  
  if (keycount <  KEY_HOLD_THRESHOLD) {   
  
  
  keycount++;  
  
   
  
  }  
  
  
  
   
  
  else{  
  
  
  
   
  
  }  
  
  
  
   
  
  if (keycount >=  KEY_HOLD_THRESHOLD) {   
  
  
  if (p_stKey->ctl.Bits.press_s ==  FALSE) {   
  
  
  
  p_stKey->ctl.Bits.press_s = TRUE;   
  
  
  
  p_stKey->ctl.Bits.press = TRUE;   
  
  
  }  
  
  
   
  
  
  p_stKey->ctl.Bits.status = TRUE;   
  
  }  
  
  
  
   
  }  
  
  
  
  
   
  else {  
  
  
  
  
   
  
  if (keycount >  KEY_PRESS_THRESHOLD) {   
  
  
  keycount = KEY_PRESS_THRESHOLD;   
  
  }  
  
  
  
   
  
  if (keycount > KEY_RELEASE_MIN) {  
   
  
  
  keycount--;  
  
   
  
  }  
  
  
  
   
  
  if (keycount <= KEY_RELEASE_MIN)  {  
   
  
  
  if (p_stKey->ctl.Bits.press_s) {   
  
  
  
  p_stKey->ctl.Bits.release = TRUE;   
  
  
  
  p_stKey->ctl.Bits.press_s =  FALSE;   
  
  
  }  
  
  
   
  
  
  p_stKey->ctl.Bits.status = FALSE;   
  
  }  
  
  
  
   
  }  
  
  
  
  
   
  p_stKey->count = keycount;  
  
  
    }
×÷Õß: mikeshao    •r(sh¨ª)ég: 2010-12-23 16:34
½çÃæŽì
×÷Õß: mikeshao    •r(sh¨ª)ég: 2010-12-23 16:35
½çÃæŽì
×÷Õß: xyj    •r(sh¨ª)ég: 2010-12-28 19:13

ß@ÅŰæÔõô¿´µÄÄÇô„eŤĨ¡£
×÷Õß: lzy89c55    •r(sh¨ª)ég: 2011-2-14 16:00

×÷Õß: ljc424    •r(sh¨ª)ég: 2011-2-16 13:38
¿´Öø(zh¨´)ºÃÀÛŶ
×÷Õß: ywwork2011    •r(sh¨ª)ég: 2011-2-19 15:51
º¹
×÷Õß: liuhs    •r(sh¨ª)ég: 2011-2-22 09:03
¿´Öø(zh¨´)ºÃÀÛŶ
×÷Õß: hustchenjing    •r(sh¨ª)ég: 2011-2-22 09:32
·ÀÖ¹¶¶„Ó(d¨°ng)µÄÒ»‚€(g¨¨)Ëã·¨¡£
×÷Õß: lianwazi    •r(sh¨ª)ég: 2011-2-26 19:49
ºÃºÃŒW(xu¨¦)Á•Ŷ£¡£¡£¡ÖxÖx£¡£¡£¡




šgÓ­¹âÅR ëŠ×Ó¹¤³Ì¾W(w¨£ng) (http://selenalain.com/) Powered by Discuz! X3.4
午夜高清国产拍精品福利|亚洲色精品88色婷婷七月丁香|91久久精品无码一区|99久久国语露脸精品|动漫卡通亚洲综合专区48页