CN101943958B - Method for avoiding faulty operation of track ball and terminal equipment - Google Patents

Method for avoiding faulty operation of track ball and terminal equipment Download PDF

Info

Publication number
CN101943958B
CN101943958B CN201010296221XA CN201010296221A CN101943958B CN 101943958 B CN101943958 B CN 101943958B CN 201010296221X A CN201010296221X A CN 201010296221XA CN 201010296221 A CN201010296221 A CN 201010296221A CN 101943958 B CN101943958 B CN 101943958B
Authority
CN
China
Prior art keywords
trackball
state information
direction state
track ball
scanning
Prior art date
Legal status (The legal status 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 status listed.)
Active
Application number
CN201010296221XA
Other languages
Chinese (zh)
Other versions
CN101943958A (en
Inventor
林华坚
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Yulong Computer Telecommunication Scientific Shenzhen Co Ltd
Original Assignee
Yulong Computer Telecommunication Scientific Shenzhen Co Ltd
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 Yulong Computer Telecommunication Scientific Shenzhen Co Ltd filed Critical Yulong Computer Telecommunication Scientific Shenzhen Co Ltd
Priority to CN201010296221XA priority Critical patent/CN101943958B/en
Publication of CN101943958A publication Critical patent/CN101943958A/en
Application granted granted Critical
Publication of CN101943958B publication Critical patent/CN101943958B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Position Input By Displaying (AREA)

Abstract

The invention relates to a method for avoiding faulty operation of a track ball and terminal equipment. The method for avoiding the faulty operation of the track ball comprises the following steps of: detecting a track ball operating signal; scanning the current movement direction of the track ball when the track ball operating signal is detected and saving the first direction state information; delaying for a first preset time, rescanning the current movement direction of the track ball and saving second direction state information; comparing the first direction state information with the second direction state information; and discarding the track ball operating signal when the first direction state information is different from the second direction state information. The method and the terminal equipment have the following advantages: by detecting the movement direction of the track ball, delaying for the first preset time, re-detecting the movement direction of the track ball and comparing the two pieces of movement direction information of the track ball detected in turn, the faulty operation event is differentiated and discarded; and the faulty operation of the track ball can be effectively avoided by only transmitting the correct faulty operation event of the track ball to an upper application layer.

Description

Method for preventing track ball misoperation and terminal equipment
Technical Field
The present invention relates to the field of communications technologies, and in particular, to a method and a terminal device for preventing a trackball from being misoperated.
Background
The trackball is another type of mouse, the internal structure of which is the same as that of a mechanical mouse, the working principle is similar, and the trackball is positioned by reading the rolling direction and speed of the rollable ball. The difference is that when the track ball works, the ball is directly stirred by hands on the track ball to roll, and the ball seat is fixed. Therefore, the trackball occupies a relatively small space, and is mainly used for portable machines such as notebook computers.
Many current terminal devices are equipped with a trackball for the convenience of user operation and carrying, so as to achieve accurate positioning. Most trackballs are too sensitive in operation, so that misoperation often occurs when the user uses the trackballs.
Disclosure of Invention
The technical problem to be solved by the present invention is to provide a method and a terminal device for preventing a trackball from being misoperated, aiming at the defect that the trackball in the prior art is easy to be misoperated, so as to effectively prevent the trackball from being misoperated.
The technical scheme adopted by the invention for solving the technical problems is as follows:
a method for preventing misoperation of a track ball is constructed and used in a terminal device with the track ball, wherein the method comprises the following steps:
detecting a trackball operating signal; the trackball operation signal is an electrical signal converted from a physical signal of the trackball according to a user operation;
when the trackball operation signal is detected, scanning the current motion direction of the trackball and storing the current motion direction as first direction state information;
after delaying the first preset time, scanning the current motion direction of the trackball again and storing the current motion direction as second direction state information;
comparing the first direction state information and the second direction state information;
and when the first direction state information is different from the second direction state information, discarding the trackball operating signal.
The invention discloses a method for preventing misoperation of a track ball, which further comprises the following steps:
and when the first direction state information and the second direction state information are the same, sending the track ball operation signal to an upper application layer for processing.
The method for preventing the misoperation of the track ball comprises the following steps of: a trackball operating signal is detected.
The method for preventing the misoperation of the trackball, provided by the invention, is characterized in that the first preset time is 50-150 ms.
The method for preventing the misoperation of the track ball is characterized in that the first preset time is 100 ms.
The invention also provides terminal equipment which comprises the trackball, a signal detection module, a state scanning module and an event processing module; wherein,
the signal detection module is used for detecting a trackball operating signal; the trackball operation signal is an electrical signal converted from a physical signal of the trackball according to a user operation;
the state scanning module is used for scanning the current motion direction of the trackball and storing the current motion direction as first direction state information when the trackball operation signal is detected, scanning the current motion direction of the trackball again after delaying for a first preset time and storing the current motion direction as second direction state information, and comparing the first direction state information with the second direction state information;
the event processing module is configured to discard the trackball operating signal when the first direction state information is different from the second direction state information, or send the trackball operating signal to an upper application layer for processing when the first direction state information is the same as the second direction state information.
The terminal equipment comprises a state scanning module, a state detecting module and a state detecting module, wherein the state scanning module comprises a scanning unit, a timing unit and a comparing unit; wherein,
the scanning unit is used for scanning the current motion direction of the trackball, storing the current motion direction as first direction state information, and scanning the current motion direction of the trackball again after delaying for a first preset time, and storing the current motion direction as second direction state information;
the timing unit is used for timing the first preset time;
the comparison unit is used for comparing the first direction state information with the second direction state information.
The invention has the following beneficial effects: by detecting the movement direction of the trackball, delaying the first preset time, detecting the movement direction of the trackball again, comparing the movement direction information of the trackball detected twice, distinguishing and discarding the misoperation event of the trackball, and only sending the correct operation event of the trackball to the upper application layer, the misoperation of the trackball can be effectively prevented.
Drawings
The invention will be further described with reference to the accompanying drawings and examples, in which:
FIG. 1 is a flow chart of a method for preventing trackball malfunction in accordance with a preferred embodiment of the present invention;
FIG. 2 is a schematic structural diagram of a terminal device according to a preferred embodiment of the present invention;
fig. 3 is a schematic structural diagram of a status scanning module in a terminal device according to a preferred embodiment of the invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, the present invention is further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
FIG. 1 is a flow chart of a method 100 for preventing trackball malfunction according to a preferred embodiment of the present invention. As shown in fig. 1, the method 100 starts in step 101 for use in a terminal device with a trackball.
Subsequently, in a next step 102, a trackball operation signal is detected. The trackball operation signal is an electric signal converted by the trackball device according to a physical signal operated by the user, which is output from an output port of the trackball device. The detection operation of the step can be carried out in real time or at preset time intervals, and the trackball operation signal can be detected from the output port as long as the user operates the trackball.
Subsequently, in the next step 103, when the trackball operation signal is detected, which indicates that the user is operating the trackball, the current moving direction of the trackball is scanned and stored as the first direction state information. The first direction state information comprises the current motion direction data information of the trackball. It is understood that the first direction state information may be other information capable of indicating the operation of the trackball motion than the motion direction data information, and is not limited thereto.
Subsequently, in the next step 104, after delaying for the first predetermined time, the current direction of motion of the trackball is scanned again and stored as second direction state information. And similarly, the second direction state information comprises the current motion direction data information of the trackball. It is understood that the second direction state information may be other information capable of indicating the operation of the trackball motion than the motion direction data information, which is not limited herein.
The first predetermined time interval may be 50-150ms, preferably 100ms, which is reasonable and not obvious to the user, and if there is a malfunction, the user will generally make a quick operation correction within the time interval. If the time is too long, although the trackball is prevented from being operated by mistake, the correct operation signal is delayed for a long time to be sent to the upper application layer, and the user will perceive that the sensitivity of the trackball is seriously reduced.
Subsequently, in a next step 105, the above detected first direction state information and second direction state information are compared. The method mainly compares whether the trackball motion direction data in the first direction state information and the second direction state information are the same.
In a next step 106, the trackball operating signal is discarded when the first direction state information is not the same as the second direction state information. The first direction state information is different from the second direction state information, which indicates that the user has changed the operation on the trackball within the first predetermined time interval, the moving direction of the trackball has changed, and the detected trackball operation signal is an erroneous operation, so that the operation event needs to be discarded. Specifically, the "discarding" may refer to not sending the operation event information to the upper application layer, that is, not performing any processing, but continuing to detect the trackball operation signal, waiting for a new operation event of the trackball to arrive, and repeating step 102.
In a next step 107, the trackball operation signal is sent to the upper application layer for processing when the first direction status information and the second direction status information are the same. The first direction state information is the same as the second direction state information, which indicates that the user does not change the operation on the trackball within the first preset time interval, and the detected trackball operation signal is correct operation, and then the operation event is sent to the upper application layer for processing.
Finally, the method 100 ends at step 108.
Fig. 2 is a schematic structural diagram of a terminal device 200 adopting the above method for preventing a trackball from misoperation, which includes a trackball 204, a signal detection module 201 connected to a signal output end of the trackball 204, a state scanning module 202 connected to the signal detection module 201, and an event processing module 203 connected to the state scanning module 202. When the user operates the trackball 204, the trackball 204 converts a physical operation signal of the user into an electric signal and outputs the electric signal from the output port.
The signal detection module 201 is configured to detect a trackball operating signal output from the output port. The detection may be continuous or may be performed at predetermined intervals.
The state scanning module 202 is configured to scan the current moving direction of the trackball and store the current moving direction as first direction state information when the signal detection module detects the trackball operating signal, scan the current moving direction of the trackball again after a first predetermined time delay, store the current moving direction as second direction state information, and compare the first direction state information and the second direction state information. The first direction state information comprises the current motion direction data information of the trackball. Similarly, the second direction state information includes data information of the current moving direction of the trackball. It is to be understood that the first direction state information and the second direction state information may be other information capable of indicating the trackball moving operation than the moving direction data information, and are not limited herein.
And the event processing module 203 is configured to discard the trackball operating signal when the first direction state information is different from the second direction state information. The first direction state information is different from the second direction state information, which indicates that the user has changed the operation on the trackball within the first predetermined time interval, the moving direction of the trackball has changed, and the detected trackball operation signal is an erroneous operation, so that the operation event needs to be discarded. The specific discarding step may be to not send the operation event information to the upper application layer, that is, to continue to detect the trackball operation signal and wait for a new operation event of the trackball to arrive without any processing.
The event processing module 203 is further configured to send the trackball operating signal to the upper application layer for processing when the first direction state information and the second direction state information are the same. The first direction state information is the same as the second direction state information, which indicates that the user does not change the operation on the trackball within the first preset time interval, and the detected trackball operation signal is correct operation, and then the operation event is sent to the upper application layer for processing.
In one embodiment, as shown in FIG. 3, the status scan module 202 may include a scan unit 212, a timing unit 222 and a comparison unit 232.
A scanning unit 212, configured to scan a current moving direction of the trackball, store the current moving direction as first direction state information, and scan the current moving direction of the trackball again after delaying for a first predetermined time, and store the current moving direction as second direction state information;
a timing unit 222 for timing a first predetermined time; the first predetermined time interval may be 50-150ms, preferably 100ms, which is reasonable and not noticeable by the user, and if there is a malfunction, the user will generally make a quick operation correction within the time interval. If the time is too long, although the trackball is prevented from being operated by mistake, the correct operation signal is delayed for a long time to be sent to the upper application layer, and the user will perceive that the sensitivity of the trackball is seriously reduced.
The comparing unit 232, which may be a timer, is used to compare the first direction status information and the second direction status information. The method mainly compares whether the trackball motion direction data in the first direction state information and the second direction state information are the same, and sends the comparison result to the event processing module 203 for processing.
The invention has the following beneficial effects: by detecting the movement direction of the trackball, delaying the first preset time, detecting the movement direction of the trackball again, comparing the movement direction information of the trackball detected twice, distinguishing and discarding the misoperation event of the trackball, and only sending the correct operation event of the trackball to the upper application layer, the misoperation of the trackball can be effectively prevented.
It will be understood that modifications and variations can be made by persons skilled in the art in light of the above teachings and all such modifications and variations are intended to be included within the scope of the invention as defined in the appended claims.

Claims (6)

1. A method for preventing misoperation of a track ball is used in a terminal device with the track ball, and is characterized by comprising the following steps:
detecting a trackball operation signal, which is an electrical signal converted from the trackball according to a physical signal operated by a user;
when the trackball operation signal is detected, scanning the current motion direction of the trackball and storing the current motion direction as first direction state information;
after delaying the first preset time, scanning the current motion direction of the trackball again and storing the current motion direction as second direction state information;
comparing the first direction state information and the second direction state information;
discarding the trackball operating signal when the first direction state information is different from the second direction state information;
wherein the first predetermined time is 50-150 ms.
2. The method of preventing trackball malfunction according to claim 1, further comprising the steps of:
and when the first direction state information and the second direction state information are the same, sending the track ball operation signal to an upper application layer for processing.
3. A method of preventing trackball malfunction according to claim 1, characterized in that after discarding the trackball operating signal, the step of: a trackball operating signal is detected.
4. A method of preventing trackball malfunction according to claim 1, characterized in that the first predetermined time is 100 ms.
5. A terminal device comprises a track ball, and is characterized by further comprising a signal detection module, a state scanning module and an event processing module; wherein,
the signal detection module is used for detecting a trackball operating signal; the trackball operation signal is an electrical signal converted from a physical signal of the trackball according to a user operation;
the state scanning module is used for scanning the current motion direction of the trackball and storing the current motion direction as first direction state information when the trackball operation signal is detected, scanning the current motion direction of the trackball again after first preset time is delayed and storing the current motion direction as second direction state information, and comparing the first direction state information with the second direction state information, wherein the first preset time is 50-150 ms;
the event processing module is configured to discard the trackball operating signal when the first direction state information is different from the second direction state information, or send the trackball operating signal to an upper application layer for processing when the first direction state information is the same as the second direction state information.
6. The terminal device of claim 5, wherein the status scanning module comprises a scanning unit, a timing unit and a comparing unit; wherein,
the scanning unit is used for scanning the current motion direction of the trackball, storing the current motion direction as first direction state information, and scanning the current motion direction of the trackball again after delaying for a first preset time, and storing the current motion direction as second direction state information;
the timing unit is used for timing the first preset time;
the comparison unit is used for comparing the first direction state information with the second direction state information.
CN201010296221XA 2010-09-29 2010-09-29 Method for avoiding faulty operation of track ball and terminal equipment Active CN101943958B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201010296221XA CN101943958B (en) 2010-09-29 2010-09-29 Method for avoiding faulty operation of track ball and terminal equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201010296221XA CN101943958B (en) 2010-09-29 2010-09-29 Method for avoiding faulty operation of track ball and terminal equipment

Publications (2)

Publication Number Publication Date
CN101943958A CN101943958A (en) 2011-01-12
CN101943958B true CN101943958B (en) 2012-03-07

Family

ID=43435980

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201010296221XA Active CN101943958B (en) 2010-09-29 2010-09-29 Method for avoiding faulty operation of track ball and terminal equipment

Country Status (1)

Country Link
CN (1) CN101943958B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102609323B (en) * 2012-02-22 2018-02-06 康佳集团股份有限公司 A kind of trace ball sensitivity adjustment method

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1085357C (en) * 1995-12-19 2002-05-22 华隆微电子股份有限公司 Anti-interference circuit for mouse
CN1267016A (en) * 1999-03-11 2000-09-20 将盟股份有限公司 Indicator with input of more axle signals
JP4136417B2 (en) * 2002-03-28 2008-08-20 富士通株式会社 Position detection device
US7315299B2 (en) * 2002-08-01 2008-01-01 Nissan Motor Co., Ltd. Multi-way input device and operating failure avoidance method using the same
JP4482269B2 (en) * 2002-08-28 2010-06-16 ソニー株式会社 Electronic device apparatus, signal compensation apparatus, and signal compensation method
CN2771928Y (en) * 2004-11-01 2006-04-12 联想(北京)有限公司 Mouse

Also Published As

Publication number Publication date
CN101943958A (en) 2011-01-12

Similar Documents

Publication Publication Date Title
CN105518590B (en) System and method for improved processing of touch sensor data
US9367185B2 (en) Method and system for discriminating stylus and touch interactions
US10380402B2 (en) Low power navigation devices, systems and methods
EP2748693B1 (en) Method for detecting false wake conditions of a portable electronic device
CN103401961B (en) A kind of method and system automatically lighting mobile phone screen
US20110242043A1 (en) Device with capacitive touchscreen panel and method for power management
WO2013159483A1 (en) Apparatus and method for performing proximity detection according to capacitive sensing output and status output
CN104978133A (en) Screen capturing method and screen capturing device for intelligent terminal
CN102402329A (en) Method to parameterize and recognize circular gestures on touch sensitive surfaces
US9037433B2 (en) Portable device and orientation detection method therefor
US20150116258A1 (en) Method and device for locating touch point and electronic equipment
US9696850B2 (en) Denoising touch gesture input
CN104020852A (en) Mobile terminal movement recognition method based on infrared
CN106383684A (en) Display method, display device and terminal
US20150049035A1 (en) Method and apparatus for processing input of electronic device
CN101943958B (en) Method for avoiding faulty operation of track ball and terminal equipment
CN104423661B (en) A kind of mobile terminal and the method for preventing touch screen mistaken touch
US9501183B2 (en) Method, apparatus and computer program product for distinguishing a touch event from a gesture
CN103312869A (en) Method and system for mobile terminal screen to be unlocked and standby state conversion
CN102306060A (en) Input method and system of mobile equipment
CN109739339A (en) Control method and device
CN104793881A (en) Handheld electronic device and operation method of same
WO2021179960A1 (en) Method for detecting touch-control position of active pen, and electronic terminal
US20230359281A1 (en) Wearable device and screen wake-up method thereof, and readable storage medium
CN104636287B (en) Data acquisition facility and mobile terminal

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant