[go: up one dir, main page]

TW201401106A - Keyboard apparatus and detection method for status of keys of the keyboard apparatus - Google Patents

Keyboard apparatus and detection method for status of keys of the keyboard apparatus Download PDF

Info

Publication number
TW201401106A
TW201401106A TW101122439A TW101122439A TW201401106A TW 201401106 A TW201401106 A TW 201401106A TW 101122439 A TW101122439 A TW 101122439A TW 101122439 A TW101122439 A TW 101122439A TW 201401106 A TW201401106 A TW 201401106A
Authority
TW
Taiwan
Prior art keywords
enabled
scan
button
state
input signals
Prior art date
Application number
TW101122439A
Other languages
Chinese (zh)
Inventor
Pak-Man Ma
Ming-Hsuing Hu
Original Assignee
Holtek Semiconductor Inc
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Holtek Semiconductor Inc filed Critical Holtek Semiconductor Inc
Priority to TW101122439A priority Critical patent/TW201401106A/en
Priority to CN201210215518.8A priority patent/CN103513775B/en
Publication of TW201401106A publication Critical patent/TW201401106A/en

Links

Landscapes

  • Input From Keyboards Or The Like (AREA)

Abstract

A keyboard apparatus and a detection method for status of the keys of the keyboard apparatus are disclosed. The keys of the keyboard apparatus respectively receive a plurality of scan output signals, and respectively transport a plurality of scan input signals. The steps of the detection method include: calculating a plurality of time differences between a time point which each of the scan output signals is enabled and time points which the scan input signals are enabled; obtaining a status of each of the keys which is corresponding to each of the time differences by comparing each of the time differences and a preset value.

Description

鍵盤裝置以及按鍵狀態的偵測方法 Keyboard device and method for detecting button status

本發明是有關於一種鍵盤裝置的按鍵狀態的偵測方法,且特別是有關於一種可避免鬼鍵現象的鍵盤裝置的按鍵狀態的偵測方法。 The present invention relates to a method for detecting a button state of a keyboard device, and more particularly to a method for detecting a button state of a keyboard device capable of avoiding a ghost key phenomenon.

請參照圖1,圖1繪示習知的鍵盤裝置100。鍵盤裝置100中包括四個按鍵SW1~SW4。在進行按鍵SW1~SW4的被按壓狀態的偵測動作時,掃描輸出信號SCO1以及SCO2會依序被致能。按鍵SW1及SW2則在掃描輸出信號SCO1被致能時依據其被按壓的狀態傳送出掃描輸入信號SCI1以及SCI2,而按鍵SW3及SW4則在掃描輸出信號SCO2被致能時依據其被按壓的狀態傳送出掃描輸入信號SCI1以及SCI2。因此,透過不同的掃描輸出信號SCO1、SCO2被致能時來偵測掃描輸入信號SCI1以及SCI2是否也對應被致能,就可以得知按鍵SW1~SW4的被按壓狀態。 Please refer to FIG. 1 , which illustrates a conventional keyboard device 100 . The keyboard device 100 includes four buttons SW1 to SW4. When the detection operation of the pressed state of the buttons SW1 to SW4 is performed, the scan output signals SCO1 and SCO2 are sequentially enabled. The buttons SW1 and SW2 transmit the scan input signals SCI1 and SCI2 according to the pressed state when the scan output signal SCO1 is enabled, and the buttons SW3 and SW4 are pressed according to the state when the scan output signal SCO2 is enabled. The scan input signals SCI1 and SCI2 are transmitted. Therefore, when the different scan output signals SCO1 and SCO2 are enabled to detect whether the scan input signals SCI1 and SCI2 are also enabled, the pressed state of the buttons SW1 to SW4 can be known.

由於按鍵SW1及SW3是透過相同的傳輸導線來分時傳送出掃描輸入信號SCI1,且按鍵SW2及SW4是透過相同的傳輸導線來分時傳送出掃描輸入信號SCI2的。因此,由圖1的繪示可以清楚得知,在當按鍵SW1、SW3及SW4被按壓且按鍵SW2未被按壓的狀態,且掃描輸出信號SCO1被致能時,被致能的掃描輸出信號SCO1會依序通 過被按壓的按鍵SW1、SW3以及SW4來產生掃描輸入信號SCI2。也就是說,雖然按鍵SW2未被按壓,但在掃描輸出信號SCO1被致能時,掃描輸入信號SCI2還是產生被致能的情況,並使得按鍵SW2會被誤判為有被按壓的狀態。這種誤判的現象,就是所謂的鬼鍵(ghost key)的現象。 Since the buttons SW1 and SW3 transmit the scan input signal SCI1 through the same transmission line, and the buttons SW2 and SW4 transmit the scan input signal SCI2 through the same transmission line. Therefore, as can be clearly seen from the drawing of FIG. 1, when the buttons SW1, SW3, and SW4 are pressed and the button SW2 is not pressed, and the scan output signal SCO1 is enabled, the enabled scan output signal SCO1 is enabled. Will follow through The scan input signal SCI2 is generated by the pressed buttons SW1, SW3, and SW4. That is, although the button SW2 is not pressed, when the scan output signal SCO1 is enabled, the scan input signal SCI2 is still activated, and the button SW2 is erroneously judged to be pressed. This phenomenon of misjudgment is the phenomenon of the so-called ghost key.

本發明提供一種按鍵狀態的偵測方法,有效解決所可能產生的鬼鍵的問題。 The invention provides a method for detecting a button state, which effectively solves the problem of ghost keys that may be generated.

本發明提出一種按鍵狀態的偵測方法,適用於具有多數個按鍵的鍵盤,其中,按鍵分別接收多個掃描輸出信號,並分別傳送出多個掃描輸入信號。按鍵狀態的偵測方法的步驟包括:計算各掃描輸出信號被致能時,各掃描輸出信號被致能的時間點與掃描輸入信號被致能的時間點的時間差;接著,再依據比較時間差以及預設值以獲得對應各時間差的各按鍵的被按壓狀態。 The invention provides a method for detecting a button state, which is suitable for a keyboard having a plurality of buttons, wherein the buttons respectively receive a plurality of scan output signals and respectively transmit a plurality of scan input signals. The step of detecting the button state includes: calculating a time difference between a time point when each scan output signal is enabled and a time point at which the scan input signal is enabled when each scan output signal is enabled; and then, according to the comparison time difference and The preset value is obtained to obtain the pressed state of each button corresponding to each time difference.

本發明提出一種鍵盤裝置,包括多數個按鍵以及按鍵狀態偵測器。按鍵分別接收多個掃描輸出信號,並分別傳送出多個掃描輸入信號。按鍵狀態偵測器耦接按鍵,按鍵狀態偵測器計算各掃描輸出信號被致能時,各掃描輸出信號被致能的時間點與掃描輸入信號被致能的時間點的多數個時間差,並依據比較時間差以及預設值以獲得接收對應各時間差的各掃描輸入信號的各按鍵的被按壓狀態。 The invention provides a keyboard device comprising a plurality of buttons and a button state detector. The buttons respectively receive a plurality of scan output signals and respectively transmit a plurality of scan input signals. The button state detector is coupled to the button, and the button state detector calculates a time difference between the time at which each scan output signal is enabled and the time at which the scan input signal is enabled, when the scan output signals are enabled, and The pressed state of each button of each scan input signal corresponding to each time difference is obtained according to the comparison time difference and the preset value.

基於上述,本發明藉由傳送至按鍵的偵測掃描輸出信 號與按鍵所傳送出的掃描輸入信號的被致能的時間點的時間差,來判別按鍵是為真的產生被按壓的動作或者是所謂的鬼鍵的誤判斷。如此一來,鍵盤裝置的按壓狀態將可以更準確的被偵測出來,可使所有的按鍵都可以有效的產生輸出。 Based on the above, the present invention detects the scan output signal by transmitting to the button. The time difference between the number and the enabled time point of the scan input signal transmitted by the button determines whether the button is genuinely pressed or the so-called ghost key is misjudged. In this way, the pressing state of the keyboard device can be detected more accurately, so that all the buttons can effectively generate the output.

為讓本發明之上述特徵和優點能更明顯易懂,下文特舉實施例,並配合所附圖式作詳細說明如下。 The above described features and advantages of the present invention will be more apparent from the following description.

請參照圖2繪示本發明實施例的按鍵狀態的偵測方法的流程圖。本實施例的按鍵狀態的偵測方法是用於具有多個按鍵的鍵盤。其中,按鍵排列方式可以參照圖1的繪示,而排列在相同行的按鍵(例如按鍵SW1及SW3)透過相同的傳輸導線傳送出掃描輸入信號(例如掃描輸入信號SCI1),而排列在相同列的按鍵(例如按鍵SW2及SW4)則透過相同的傳輸導線來接收個掃描輸出信號(例如掃描輸出信號SCO2)。 Please refer to FIG. 2 , which is a flowchart of a method for detecting a button state according to an embodiment of the present invention. The method for detecting the state of the button of this embodiment is for a keyboard having a plurality of buttons. The key arrangement may refer to FIG. 1 , and the buttons arranged in the same row (for example, the buttons SW1 and SW3 ) transmit the scan input signal (for example, the scan input signal SCI1 ) through the same transmission line, and are arranged in the same column. The buttons (such as buttons SW2 and SW4) receive a scan output signal (eg, scan output signal SCO2) through the same transmission line.

關於按鍵狀態的偵測方法的步驟中,首先,在進行按鍵SW1~SW4的按壓狀態偵測動作時,會依序使掃描輸出信號SCO1~SCO2在不同的時間區間中被致能,並藉以偵測接收被致能的掃描輸出信號的按鍵的被按壓狀態。舉例來說,先在第一個時間區間使掃描輸出信號SCO1被致能,並透過量測掃描輸入信號SCI1及SCI2來得知接收掃描輸出信號SCO1的按鍵SW1及SW2的被按壓狀態。並 且,在掃描輸出信號SCO1轉換為被禁能後的時間區間中,使掃描輸出信號SCO2被致能,並透過量測掃描輸入信號SCI1及SCI2來得知接收掃描輸出信號SCO2的按鍵SW2及SW4的被按壓狀態。 In the step of detecting the state of the button state, first, when the pressing state detection operation of the buttons SW1 to SW4 is performed, the scan output signals SCO1 to SCO2 are sequentially enabled in different time intervals, and the detection is performed. The pressed state of the button that receives the enabled scan output signal is measured. For example, the scan output signal SCO1 is enabled in the first time interval, and the pressed state of the buttons SW1 and SW2 receiving the scan output signal SCO1 is known by measuring the scan input signals SCI1 and SCI2. and And, in the time interval after the scan output signal SCO1 is converted to disabled, the scan output signal SCO2 is enabled, and the scan input signals SCI1 and SCI2 are measured to know the buttons SW2 and SW4 of the scan output signal SCO2. Pressed state.

上述關於掃描輸出信號SCO1及SCO2的被致能動作,例如是使掃描輸出信號SCO1及SCO2由邏輯低準位轉換成邏輯高準位,相對的,掃描輸出信號SCO1及SCO2的被禁能動作,則可以是使掃描輸出信號SCO1及SCO2由邏輯高準位轉換成邏輯低準位。當然,掃描輸出信號SCO1及SCO2的被致能動作也可以被定義為由邏輯高準位轉換成邏輯低準位,掃描輸出信號SCO1及SCO2的被禁能動作,則可以是使掃描輸出信號SCO1及SCO2由邏輯低準位轉換成邏輯高準位。 The above-mentioned enabled actions on the scan output signals SCO1 and SCO2 are, for example, converting the scan output signals SCO1 and SCO2 from a logic low level to a logic high level, and in contrast, the scan output signals SCO1 and SCO2 are disabled. Then, the scan output signals SCO1 and SCO2 can be converted from the logic high level to the logic low level. Of course, the enabled actions of the scan output signals SCO1 and SCO2 can also be defined as being converted from the logic high level to the logic low level, and the scan output signals SCO1 and SCO2 being disabled, the scan output signal SCO1 can be made. And SCO2 is converted to a logic high level by a logic low level.

其中,在本實施例的步驟S210中,計算各掃描輸出信號被致能時,各掃描輸出信號被致能的時間點以及掃描輸入信號被致能的時間點的時間差。具體來說明,請參照圖3,圖3繪示本發明實施例的按鍵狀態的偵測方法的波形圖。其中,以按鍵SW2、SW3以及SW4被按壓而按鍵SW1未被按壓為範例,掃描輸出信號SCO1在時間點T1被致能,而在掃描輸出信號SCO1被致能的期間TEN中,掃描輸入信號SCI2及SCI1依序在時間點T3及T2轉換成被致能的狀態(由邏輯低準位轉態至邏輯高準位)。 In the step S210 of the present embodiment, the time difference between the time when each scan output signal is enabled and the time point at which the scan input signal is enabled is calculated when each scan output signal is enabled. Specifically, please refer to FIG. 3. FIG. 3 is a waveform diagram of a method for detecting a button state according to an embodiment of the present invention. Wherein, the buttons SW2, SW3, and SW4 are pressed and the button SW1 is not pressed as an example, the scan output signal SCO1 is enabled at the time point T1, and during the period TEN during which the scan output signal SCO1 is enabled, the input signal SCI2 is scanned. And SCI1 is sequentially converted to an enabled state (from a logic low level to a logic high level) at time points T3 and T2.

關於時間點T1與時間點T3,以及時間點T1與時間點T2的時間差的計算方法,可以藉由計時動作所產生的 計時結果CNT1來獲得。計時動作可在掃描輸出信號SCO1被致能的時間點啟動,並使計時結果CNT1由0開始進行計時,並分別在時間點T3以及時間點T2來擷取計時結果CNT1的數值,就可以獲得時間點T1與時間點T3,以及時間點T1與時間點T2的時間差。 The calculation method of the time difference between the time point T1 and the time point T3, and the time point T1 and the time point T2 can be generated by the timing action The timing result is obtained by CNT1. The timing action can be started at the time when the scan output signal SCO1 is enabled, and the timing result CNT1 is counted from 0, and the time value CNT1 is obtained at the time point T3 and the time point T2, respectively, and the time can be obtained. Point T1 and time point T3, and the time difference between time point T1 and time point T2.

值得注意的,由圖1的繪示可以發現,當按鍵SW2、SW3以及SW4被按壓而按鍵SW1未被按壓時,掃描輸入信號SCI1是依據掃描輸出信號SCO1依序經過按鍵SW2、SW4以及SW3來傳送至按鍵SW1產生掃描輸入信號SCI1的傳輸導線而產生的。也就是說,掃描輸入信號SCI1等同於掃描輸出信號SCO1經過一個較長的時間延遲而產生的。 It should be noted that, as shown in FIG. 1 , when the buttons SW2 , SW3 , and SW4 are pressed and the button SW1 is not pressed, the scan input signal SCI1 is sequentially passed through the buttons SW2 , SW4 , and SW3 according to the scan output signal SCO1 . It is generated by transmitting to the button SW1 to generate a transmission line for scanning the input signal SCI1. That is, the scan input signal SCI1 is equivalent to the scan output signal SCO1 being generated by a long time delay.

由上述的說明可以得知,有發生鬼鍵現象的按鍵SW1所傳送的掃描輸入信號SCI1的被致能時間點T2顯然會比未發生鬼鍵現象的按鍵SW3所傳送的掃描輸入信號SCI2的被致能時間點T3來得晚。據此,在步驟S220中,則依據比較步驟S210所計算出來的時間差以及預設值,就可以獲得對應各時間差的各按鍵的被按壓狀態。 As can be understood from the above description, the enabled time point T2 of the scan input signal SCI1 transmitted by the button SW1 in which the ghost key phenomenon occurs is apparently higher than that of the scan input signal SCI2 transmitted by the button SW3 in which the ghost key phenomenon has not occurred. The time T3 is late to be enabled. According to this, in step S220, according to the time difference calculated by the comparison step S210 and the preset value, the pressed state of each button corresponding to each time difference can be obtained.

具體來說,同樣以圖3為範例,在掃描輸出信號SCO1被致能的期間TEN中,藉由偵測出掃描輸入信號SCI1及SCI2被致能的時間點T2以及T3,並透過在時間點T3以及時間點T2來擷取計時動作所產生的計時結果CNT1以分別獲得掃描輸出信號SCO1被致能的時間點T1以及掃描輸入信號SCI1以及SCI2被致能的時間點T2及T3的時 間差。透過比較時間點T1與時間點T2間的時間差大於預設值就可以判斷出在掃描輸出信號SCO1被致能的期間TEN中,產生掃描輸入信號SCI1的按鍵SW1發生所謂的鬼鍵的現象,實際上並未被按壓。相對的,透過比較時間點T1與時間點T3間的時間差小於預設值就可以判斷出在掃描輸出信號SCO1被致能的期間TEN中,產生掃描輸入信號SCI2的按鍵SW2實際上是有被按壓的。 Specifically, in the same manner as FIG. 3, in the period TEN during which the scan output signal SCO1 is enabled, by detecting the time points T2 and T3 at which the scan input signals SCI1 and SCI2 are enabled, and at the time point T3 and time point T2 are used to capture the timing result CNT1 generated by the timing operation to obtain the time point T1 at which the scan output signal SCO1 is enabled and the time points T2 and T3 at which the scan input signals SCI1 and SCI2 are enabled, respectively. The difference between. By comparing the time difference between the time point T1 and the time point T2 to be greater than the preset value, it can be determined that in the period TEN during which the scan output signal SCO1 is enabled, the so-called ghost key occurs in the button SW1 that generates the scan input signal SCI1, actually It was not pressed. In contrast, the time difference between the comparison time point T1 and the time point T3 is less than the preset value, and it can be determined that the button SW2 that generates the scan input signal SCI2 is actually pressed during the period TEN during which the scan output signal SCO1 is enabled. of.

附帶一提的,當掃描輸出信號SCO1由致能狀態轉換為禁能狀態的瞬間,計時動作會被重置而計時結果CNT1則被歸零。 Incidentally, when the scan output signal SCO1 is switched from the enabled state to the disabled state, the timing action is reset and the timing result CNT1 is reset to zero.

以下請參照圖4,圖4繪示本發明的按鍵狀態的偵測方法的另一實施例的流程圖。首先,在步驟S410中,致能掃描輸出信號,並在步驟S420中同步啟動計時動作。接著,偵測掃描輸入信號的被致能時間點,並藉此換算出掃描輸入信號的被致能時間點與掃描輸出信號的被致能時間點的時間差。在步驟S430中,則針對時間差與預先設定的預設值進行比較,若時間差大於或等於預設值,則表示這個按鍵有發生鬼鍵的現象,並在步驟S440中記錄這個鍵為鬼鍵,並執行步驟S450。若步驟S430的判斷結果為時間差小預設值時,同樣執行步驟S450。 Referring to FIG. 4, FIG. 4 is a flowchart of another embodiment of a method for detecting a button state according to the present invention. First, in step S410, the output signal is enabled to be scanned, and the timing operation is synchronously started in step S420. Then, the enabled time point of the scan input signal is detected, and thereby the time difference between the enabled time point of the scan input signal and the enabled time point of the scan output signal is converted. In step S430, the time difference is compared with a preset preset value. If the time difference is greater than or equal to the preset value, it indicates that the button has a ghost key occurrence, and the key is recorded as a ghost key in step S440. And step S450 is performed. If the result of the determination in step S430 is that the time difference is small, the step S450 is also performed.

步驟S450則執行掃描輸出信號是否轉為禁能的動作,若掃描輸出信號轉為禁能時,則在執行步驟S460的計時動作的重置動作。若掃描輸出信號持續維持為致能狀態時,則持續執行步驟S450。 Step S450 performs an operation of whether the scan output signal is turned off, and if the scan output signal is disabled, the reset operation of the timed operation of step S460 is performed. If the scan output signal continues to be enabled, step S450 is continuously performed.

以下請參照圖5,圖5繪示本發明實施例的鍵盤裝置500的示意圖。鍵盤裝置500包括鍵盤陣列510以及按鍵狀態偵測器520。鍵盤陣列510中具有多數個按鍵,用以接收掃描輸出信號SCO1~SCON並輸出掃描輸入信號SCI1~SCIM。按鍵狀態偵測器520耦接至鍵盤陣列510中的按鍵,並接收掃描輸出信號SCO1~SCON以及掃描輸入信號SCI1~SCIM。按鍵狀態偵測器500計算各掃描輸出信號SCO1~SCON被致能時,各掃描輸出信號SCO1~SCON被致能的時間點與掃描輸入信號SCI1~SCIM被致能的時間點的多數個時間差,並依據比較時間差以及預設值以獲得接收對應各時間差的各掃描輸入信號SCI1~SCIM的各按鍵的被按壓狀態。 Referring to FIG. 5, FIG. 5 is a schematic diagram of a keyboard device 500 according to an embodiment of the present invention. The keyboard device 500 includes a keyboard array 510 and a button state detector 520. The keyboard array 510 has a plurality of buttons for receiving the scan output signals SCO1~SCON and outputting the scan input signals SCI1~SCIM. The button state detector 520 is coupled to the buttons in the keyboard array 510 and receives the scan output signals SCO1 S SCON and the scan input signals SCI1 SCSCIM. The button state detector 500 calculates a plurality of time differences between the time point at which each of the scan output signals SCO1 to SCON is enabled and the time at which the scan input signals SCI1 to SCIM are enabled when each of the scan output signals SCO1 to SCON is enabled. And according to the comparison time difference and the preset value, the pressed state of each button of each scan input signal SCI1~SCIM corresponding to each time difference is received.

關於按鍵狀態偵測器520進行按鍵是否有發生鬼鍵現象的偵測動作在前述的實施例中都有詳細的說明,以下不多贅述。另外,按鍵狀態偵測器520中可以內建計時器521,用來進行執行計時動作,並獲得各掃描輸出信號SCO1~SCON被致能的時間點與掃描輸入信號SCI1~SCIM被致能的時間點的多個時間差。 The detection operation of whether the button state detector 520 performs a ghost key phenomenon in the button is described in detail in the foregoing embodiments, and will not be described below. In addition, the button state detector 520 can have a built-in timer 521 for performing the timing operation, and obtain the time point when each scan output signal SCO1~SCON is enabled and the time when the scan input signals SCI1~SCIM are enabled. Multiple time differences for points.

綜上所述,本發明藉由計算各掃描輸出信號被致能的時間點與掃描輸入信號被致能的時間點的時間差來獲知鍵盤裝置中的各按鍵是否有發生鬼鍵的現象。如此一來,因鬼鍵現象而產生的按鍵按壓的誤判斷動作將可以被排除。據此,所有的按鍵狀態都可以有效的被正確輸出,大幅提升鍵盤裝置的效能。 In summary, the present invention determines whether a key of a keyboard device has a ghost key by calculating a time difference between a time point at which each scan output signal is enabled and a time point at which the scan input signal is enabled. As a result, the misjudgment action of the button press due to the ghost key phenomenon can be eliminated. According to this, all the button states can be effectively output correctly, which greatly improves the performance of the keyboard device.

雖然本發明已以實施例揭露如上,然其並非用以限定本發明,任何所屬技術領域中具有通常知識者,在不脫離本發明之精神和範圍內,當可作些許之更動與潤飾,故本發明之保護範圍當視後附之申請專利範圍所界定者為準。 Although the present invention has been disclosed in the above embodiments, it is not intended to limit the invention, and any one of ordinary skill in the art can make some modifications and refinements without departing from the spirit and scope of the invention. The scope of the invention is defined by the scope of the appended claims.

100、500‧‧‧鍵盤裝置 100, 500‧‧‧ keyboard device

510‧‧‧鍵盤陣列 510‧‧‧Keyboard Array

520‧‧‧按鍵狀態偵測器 520‧‧‧Key Status Detector

SW1~SW4‧‧‧按鍵 SW1~SW4‧‧‧ button

SCO1~SCON‧‧‧掃描輸出信號 SCO1~SCON‧‧‧ scan output signal

SCI1~SCIM‧‧‧掃描輸入信號 SCI1~SCIM‧‧‧ scan input signal

S210~S220、S410~S460‧‧‧按鍵狀態的偵測方法的步驟 S210~S220, S410~S460‧‧‧ steps of detecting the state of the button

T1~T3‧‧‧時間點 T1~T3‧‧‧ time point

CNT1‧‧‧計時結果 CNT1‧‧‧ timing results

圖1繪示習知的鍵盤裝置100。 FIG. 1 illustrates a conventional keyboard device 100.

圖2繪示本發明實施例的按鍵狀態的偵測方法的流程圖。 2 is a flow chart of a method for detecting a button state according to an embodiment of the present invention.

圖3繪示本發明實施例的按鍵狀態的偵測方法的波形圖。 FIG. 3 is a waveform diagram of a method for detecting a state of a button according to an embodiment of the present invention.

圖4繪示本發明的按鍵狀態的偵測方法的另一實施例的流程圖。 4 is a flow chart showing another embodiment of a method for detecting a button state according to the present invention.

圖5繪示本發明實施例的鍵盤裝置500的示意圖。 FIG. 5 is a schematic diagram of a keyboard device 500 according to an embodiment of the present invention.

S210~S220‧‧‧按鍵狀態的偵測方法的步驟 S210~S220‧‧‧Steps for detecting the state of the button

Claims (13)

一種按鍵狀態的偵測方法,適用於具有多數個按鍵的一鍵盤,其中該些按鍵分別接收多數個掃描輸出信號,並分別傳送出多數個掃描輸入信號,包括:計算各該掃描輸出信號被致能時,各該掃描輸出信號被致能的時間點與該些掃描輸入信號被致能的時間點的多數個時間差;以及依據比較該些時間差以及一預設值以獲得接收對應各該時間差的各該掃描輸入信號的各該按鍵的被按壓狀態。 A method for detecting a button state is applicable to a keyboard having a plurality of buttons, wherein the buttons respectively receive a plurality of scan output signals and respectively transmit a plurality of scan input signals, including: calculating each scan output signal is caused a time difference between a time point at which each of the scan output signals is enabled and a time point at which the scan input signals are enabled; and comparing the time differences and a preset value to obtain a corresponding time difference The pressed state of each of the buttons of the scan input signal. 如申請專利範圍第1項所述之按鍵狀態的偵測方法,其中計算各該掃描輸出信號被致能時,各該掃描輸出信號被致能的時間點與該些掃描輸入信號被致能的時間點的該些時間差的步驟包括:依據各該掃描輸出信號的被致能狀態以啟動一計時動作;以及分別在該些掃描輸入信號被致能時擷取該計時動作所產生的多數個計時結果以獲得該些時間差。 The method for detecting a button state as described in claim 1, wherein when each of the scan output signals is enabled, each of the scan output signals is enabled and the scan input signals are enabled. The step of the time difference of the time points includes: starting a timing action according to the enabled state of each of the scan output signals; and extracting a plurality of timings generated by the timing action when the scan input signals are enabled respectively The result is to obtain the time differences. 如申請專利範圍第2項所述之按鍵狀態的偵測方法,其中依據各該掃描輸出信號的被致能狀態以啟動該計時動作的步驟包括:當各該掃描輸出信號的被致能時,啟動該計時動作。 The method for detecting a button state as described in claim 2, wherein the step of initiating the timing action according to the enabled state of each of the scan output signals comprises: when each of the scan output signals is enabled, Start the timing action. 如申請專利範圍第3項所述之按鍵狀態的偵測方法,其中更包括: 當各該掃描輸入信號由被致能轉換到被禁能時,重置該計時動作。 For example, the method for detecting the state of a button as described in claim 3 of the patent application includes: The timing action is reset when each of the scan input signals is enabled to be disabled. 如申請專利範圍第2項所述之按鍵狀態的偵測方法,其中分別在該些掃描輸入信號被致能時擷取該計時動作所產生的該些計時結果以獲得該些時間差的步驟包括:偵測該些掃描輸入信號是否被致能;當各該掃描輸入信號被致能時,擷取該計時動作所產生的該計時結果以獲得該些時間差。 The method for detecting a state of a button as described in claim 2, wherein the step of capturing the timing results generated by the timing action to obtain the time differences when the scan input signals are enabled includes: Detecting whether the scan input signals are enabled; and when each of the scan input signals is enabled, capturing the timing result generated by the timing action to obtain the time differences. 如申請專利範圍第1項所述之按鍵狀態的偵測方法,其中依據比較該些時間差以及該預設值以獲得接收對應各該時間差的各該掃描輸入信號的各該按鍵的被按壓狀態的步驟包括:判斷該些時間差是否大於或等於該預設值;當各該時間差大於或等於該預設值時,各該時間差對應的各該按鍵為未被按壓的狀態;以及當各該時間差小於該預設值時,各該時間差對應的各該按鍵為被按壓的狀態。 The method for detecting a button state according to claim 1, wherein the comparing the time differences and the preset value to obtain a pressed state of each button of each of the scan input signals corresponding to each of the time differences is obtained. The step of determining whether the time difference is greater than or equal to the preset value; when each time difference is greater than or equal to the preset value, each of the buttons corresponding to the time difference is in an unpressed state; and when each time difference is less than In the preset value, each of the buttons corresponding to the time difference is in a pressed state. 一種鍵盤裝置,包括:多數個按鍵,該些按鍵分別接收多數個掃描輸出信號,並分別傳送出多數個掃描輸入信號;以及一按鍵狀態偵測器,耦接該些按鍵,該按鍵狀態偵測器計算各該掃描輸出信號被致能時,各該掃描輸出信號被致能的時間點與該些掃描輸入信號被致能的時間點的多數個時間差,並依據比較該些時間差以及一預設值以獲得接 收對應各該時間差的各該掃描輸入信號的各該按鍵的被按壓狀態。 A keyboard device includes: a plurality of buttons respectively receiving a plurality of scan output signals and respectively transmitting a plurality of scan input signals; and a button state detector coupled to the buttons, the button state detection Calculating, when the respective scan output signals are enabled, a time difference between a time point at which each of the scan output signals is enabled and a time point at which the scan input signals are enabled, and comparing the time differences and a preset Value to get The pressed state of each of the buttons corresponding to each of the scan input signals corresponding to the time difference is received. 如申請專利範圍第7項所述之鍵盤裝置,其中該按鍵狀態偵測器依據各該掃描輸出信號的被致能狀態以啟動一計時動作,並分別在該些掃描輸入信號被致能時擷取該計時動作所產生的多數個計時結果以獲得該些時間差。 The keyboard device of claim 7, wherein the button state detector activates a timing action according to an enabled state of each of the scan output signals, and respectively when the scan input signals are enabled. A plurality of timing results generated by the timing action are taken to obtain the time differences. 如申請專利範圍第8項所述之鍵盤裝置,其中該按鍵狀態偵測器包括:一計時器,該計時器用以進行該計時動作。 The keyboard device of claim 8, wherein the button state detector comprises: a timer for performing the timing action. 如申請專利範圍第9項所述之鍵盤裝置,其中該計時器在各該掃描輸出信號的被致能時啟動該計時動作。 The keyboard device of claim 9, wherein the timer initiates the timing action when each of the scan output signals is enabled. 如申請專利範圍第9項所述之鍵盤裝置,其中當各該掃描輸入信號由被致能轉換到被禁能時,該計時器重置該計時動作。 The keyboard device of claim 9, wherein the timer resets the timing action when each of the scan input signals is enabled to be disabled. 如申請專利範圍第8項所述之鍵盤裝置,其中該按鍵狀態偵測器偵測該些掃描輸入信號是否被致能,並在當各該掃描輸入信號被致能時,擷取該計時動作所產生的計數值以獲得對應各該掃描輸入信號的各該按鍵的各該計時結果。 The keyboard device of claim 8, wherein the button state detector detects whether the scan input signals are enabled, and captures the timing action when each of the scan input signals is enabled. The generated count value is used to obtain each of the timing results of each of the buttons corresponding to each of the scan input signals. 如申請專利範圍第8項所述之鍵盤裝置,其中該按鍵狀態偵測器判斷該些時間差是否大於或等於該預設值,並在當各該時間差大於或等於該預設值時,該按鍵狀態偵測器判定各該時間差對應的各該按鍵為未被按壓的狀態,在當各該時間差小於該預設值時,該按鍵狀態偵測器判定各該時間差對應的各該按鍵為被按壓的狀態。 The keyboard device of claim 8, wherein the button state detector determines whether the time differences are greater than or equal to the preset value, and when each time difference is greater than or equal to the preset value, the button The state detector determines that each of the buttons corresponding to the time difference is in an unpressed state. When each of the time differences is less than the preset value, the button state detector determines that each button corresponding to the time difference is pressed. status.
TW101122439A 2012-06-22 2012-06-22 Keyboard apparatus and detection method for status of keys of the keyboard apparatus TW201401106A (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
TW101122439A TW201401106A (en) 2012-06-22 2012-06-22 Keyboard apparatus and detection method for status of keys of the keyboard apparatus
CN201210215518.8A CN103513775B (en) 2012-06-22 2012-06-27 Keyboard device and method for detecting key state

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
TW101122439A TW201401106A (en) 2012-06-22 2012-06-22 Keyboard apparatus and detection method for status of keys of the keyboard apparatus

Publications (1)

Publication Number Publication Date
TW201401106A true TW201401106A (en) 2014-01-01

Family

ID=49896637

Family Applications (1)

Application Number Title Priority Date Filing Date
TW101122439A TW201401106A (en) 2012-06-22 2012-06-22 Keyboard apparatus and detection method for status of keys of the keyboard apparatus

Country Status (2)

Country Link
CN (1) CN103513775B (en)
TW (1) TW201401106A (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TWI547832B (en) * 2015-07-06 2016-09-01 Dexin Corp An input device with adaptive adjustment and its adjustment method
TWI612444B (en) * 2017-01-06 2018-01-21 群光電子股份有限公司 Ghost key detecting circuit
TWI612443B (en) * 2015-11-25 2018-01-21 達方電子股份有限公司 Keyboard apparatus
US9921664B2 (en) 2015-11-25 2018-03-20 Darfon Electronics Corp. Keyboard device

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105094375B (en) * 2014-05-23 2018-07-03 宏景科技股份有限公司 Trigger judgment method, device, input device and input system of mechanical key
CN108650535B (en) * 2018-05-11 2021-01-15 青岛海信宽带多媒体技术有限公司 Intelligent device and control method thereof

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5914677A (en) * 1997-01-15 1999-06-22 Chips & Technologies, Inc. Apparatus and method for scanning a switch array
CN101714052B (en) * 2008-10-06 2011-11-09 鸿富锦精密工业(深圳)有限公司 Electronic equipment and screen display control method
TWI485991B (en) * 2009-04-06 2015-05-21 Lite On Electronics Guangzhou Ghost key detecting circuit and related method
TWI501114B (en) * 2009-12-31 2015-09-21 Universal Scient Ind Shanghai Keyboard scanning apparatus and key matrix circuit thereof and method for scanning the key matrix circuit
TWM403696U (en) * 2010-10-20 2011-05-11 Sunrex Technology Corp Input device capable of eliminating ghost key
CN201917871U (en) * 2010-11-10 2011-08-03 精元电脑股份有限公司 Input device that eliminates ghost keys

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TWI547832B (en) * 2015-07-06 2016-09-01 Dexin Corp An input device with adaptive adjustment and its adjustment method
TWI612443B (en) * 2015-11-25 2018-01-21 達方電子股份有限公司 Keyboard apparatus
US9921664B2 (en) 2015-11-25 2018-03-20 Darfon Electronics Corp. Keyboard device
US10073539B2 (en) 2015-11-25 2018-09-11 Darfon Electronics Corp. Keyboard device
TWI612444B (en) * 2017-01-06 2018-01-21 群光電子股份有限公司 Ghost key detecting circuit

Also Published As

Publication number Publication date
CN103513775B (en) 2016-08-03
CN103513775A (en) 2014-01-15

Similar Documents

Publication Publication Date Title
TW201401106A (en) Keyboard apparatus and detection method for status of keys of the keyboard apparatus
US10609296B1 (en) Electronic device and automatic exposure convergence method
US10281565B2 (en) Distance measuring device and solid-state image sensor used therein
JP5985372B2 (en) Target detection apparatus and target detection method
CN102833488A (en) Image pickup apparatus, image pickup apparatus control method, and program
CN107219945A (en) Circuit and method for detecting dormancy and wake-up of optical mouse
TWI439892B (en) Methods for detecting touch points on touch panel and touch devices
WO2019026457A1 (en) Image monitoring device, image monitoring method, image monitoring program, and recording medium
US10911657B2 (en) Image sensor chip having function of generating frame synchronization signal, electronic device including the image sensor chip, and method for operating the image sensor chip
US9606243B2 (en) Radiation imaging apparatus, method of determining radiation irradiation, and storage medium
TWI540485B (en) Touch apparatus, touch controller thereof and noise detection method
CN105530444B (en) Detect the method, apparatus and video conferencing system of the vision signal of identical standard
CN111551827A (en) Wave head initial time detection method and monitoring system applied to partial discharge positioning
JP2005354676A (en) SIGNAL PROCESSING CIRCUIT AND METHOD OR TIME DELAY DETECTING DEVICE AND OBJECT POSITIONING DEVICE USING THE METHOD
RU2014153034A (en) DEVICE AND METHOD FOR PROCESSING SCAN DATA IN THE EVENT OF INPUT ELECTROSTATIC DISCHARGE (ESD)
JP4697431B2 (en) Radio wave monitoring apparatus and method, radio wave monitoring program
KR102516666B1 (en) Pulse system verification
US20220346708A1 (en) Dementia determination system
CN108270447A (en) Keyboard disappears fluttering method, scanning monitor, master controller and measuring instrument
JP2017187743A5 (en)
US9459140B2 (en) Optical detecting device and related method of adjusting synchronization
JP5429685B2 (en) Logic signal measuring device
CN119007083A (en) Scene change detection method, device, monitoring system and storage medium
US20130155288A1 (en) Imaging apparatus and imaging method
CN119105262A (en) Signal transition edge rise time detection device and method