CN116501193A - Method for calculating touch position, electronic equipment and storage medium - Google Patents

Method for calculating touch position, electronic equipment and storage medium Download PDF

Info

Publication number
CN116501193A
CN116501193A CN202310437275.0A CN202310437275A CN116501193A CN 116501193 A CN116501193 A CN 116501193A CN 202310437275 A CN202310437275 A CN 202310437275A CN 116501193 A CN116501193 A CN 116501193A
Authority
CN
China
Prior art keywords
touch
sensing data
calculating
touch position
contact
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.)
Pending
Application number
CN202310437275.0A
Other languages
Chinese (zh)
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.)
Shanghai Awinic Technology Co Ltd
Original Assignee
Shanghai Awinic Technology 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 Shanghai Awinic Technology Co Ltd filed Critical Shanghai Awinic Technology Co Ltd
Priority to CN202310437275.0A priority Critical patent/CN116501193A/en
Publication of CN116501193A publication Critical patent/CN116501193A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/03Arrangements for converting the position or the displacement of a member into a coded form
    • G06F3/041Digitisers, e.g. for touch screens or touch pads, characterised by the transducing means
    • G06F3/0414Digitisers, e.g. for touch screens or touch pads, characterised by the transducing means using force sensing means to determine a position
    • G06F3/04142Digitisers, e.g. for touch screens or touch pads, characterised by the transducing means using force sensing means to determine a position the force sensing means being located peripherally, e.g. disposed at the corners or at the side of a touch sensing plate

Landscapes

  • Engineering & Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Position Input By Displaying (AREA)

Abstract

The application is applied to the technical field of touch control, and provides a method for calculating a touch control position, electronic equipment and a storage medium, wherein the method for calculating the touch control position comprises the following steps: acquiring sensing data corresponding to contact of a touch area on the electronic equipment; determining the shape of a fitting curve according to the sensing data and the position of a sensor for acquiring the sensing data; and corresponding to the parabola with the downward opening of the fitting curve, and calculating the touch position by adopting a parabola fitting method. According to the method for calculating the touch position, for the contact with part of the contact exceeding the touch area, the coordinate of the touch position can be obtained more accurately.

Description

Method for calculating touch position, electronic equipment and storage medium
Technical Field
The present disclosure relates to the field of touch technologies, and in particular, to a method for calculating a touch position, an electronic device, and a storage medium.
Background
On a touch panel of an electronic device, sensing data generated after a user touches the touch panel is generally collected by a multichannel sensor, and then coordinates of a touch position of the user are calculated according to a gravity center method and the sensing data so as to respond to an operation corresponding to the touch position. For example, capacitance data generated after a user touches the touch panel may be collected by using a capacitive sensor, and then weighted calculation is performed according to the capacitance data collected by each sensor and the position coordinates of each sensor, so as to obtain a barycentric coordinate, that is, a coordinate of the touch position.
At present, the size of a touch panel of most electronic devices is relatively small, when a user operates the touch panel, conductors such as fingers used for operation easily slide out of the range of the touch panel, and as no sensor is arranged outside the touch panel, if a part of the user in operation on the touch panel exceeds the boundary of the touch panel, the touch position of the user is calculated through a gravity center method and sensing data, and the real touch position of the user cannot be acquired due to the lack of the boundary sensing data, so that false sensing of the electronic device can be possibly caused.
Disclosure of Invention
The application provides a method for calculating a touch position, electronic equipment and a storage medium, and more accurate coordinates of the touch position can be obtained through a more accurate mathematical model.
In a first aspect, the present application provides a method for calculating a touch position, which is applied to an electronic device, and includes: acquiring sensing data corresponding to contact of a touch area on the electronic equipment; determining the shape of a fitting curve according to the sensing data and the position of a sensor for acquiring the sensing data; and corresponding to the parabola with the downward opening of the fitting curve, and calculating the touch position by adopting a parabola fitting method.
With reference to the first aspect, in some possible implementations, determining a shape of the fitted curve according to the sensing data and a position of a sensor that collects the sensing data includes: setting a parabolic equation, setting a y-axis as sensing data acquired by a capacitive sensor in response to contact, and setting an x-axis as a position of the sensor in response to contact; substituting the positions of the at least three sensing data and the sensors for acquiring the at least three sensing data into a parabolic equation to obtain a final parabolic equation.
With reference to the first aspect, in some possible implementations, the at least three sensing data includes three sensing data having a largest value among the at least three sensing data.
With reference to the first aspect, in some possible implementations, calculating the touch location using a parabolic fit method includes: and taking the coordinate on the x axis corresponding to the vertex of the parabola as the coordinate of the touch position.
With reference to the first aspect, in some possible implementations, the method further includes: and if the history induction data is stored in the electronic equipment, calculating the touch position by adopting a linear fitting method.
With reference to the first aspect, in some possible implementations, calculating the touch location using a linear fitting method includes: setting a linear equation, setting a y-axis as sensing data acquired by a capacitive sensor in response to contact, and setting an x-axis as a position of the sensor in response to contact; substituting the at least two sensing data and the positions of the sensors for acquiring the at least two sensing data into a linear equation to obtain a final linear equation; substituting the largest sensing data in the historical sensing data of the electronic equipment into a final linear equation to obtain a corresponding coordinate on an x-axis; and taking the corresponding coordinate on the x axis as the coordinate of the touch position.
With reference to the first aspect, in some possible implementations, at least two of the sensing data include two sensing data having a largest value among sensing data collected in response to a capacitive sensor in contact.
With reference to the first aspect, in some possible implementations, the method further includes: and if the electronic equipment does not store historical induction data, calculating the coordinates of the touch position by adopting a gravity center method.
In a second aspect, the present application provides an electronic device comprising a controller and a memory; the memory stores computer-executable instructions; the controller executes the computer-executable instructions stored in the memory to cause the controller to perform the method as described above.
In a third aspect, the present application provides a computer storage medium having stored thereon instructions that, when executed on an electronic device, cause the electronic device to perform the above-described method.
In summary, according to the method for calculating the touch position provided by the application, through a more accurate mathematical model, particularly for the contact of a user when a part of the user is beyond the boundary of the touch panel in the operation on the touch panel, the coordinate of the more accurate touch position is calculated according to the obtained sensing data, so that the operation corresponding to the coordinate of the touch position is responded according to the coordinate of the more accurate touch position, and the situation of error response possibly caused by the coordinate of the wrong touch position is avoided.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present application, the following will briefly introduce the drawings that are required to be used in the embodiments or the description of the prior art. It is apparent that the drawings in the following description are only some embodiments of the present application, and that other drawings may be obtained from these drawings without inventive effort for a person of ordinary skill in the art.
FIG. 1 illustrates a schematic view of an operational scenario of an LED lamp, according to some embodiments of the present application;
FIG. 2 illustrates a schematic diagram of a method of calculating touch location, according to some embodiments of the present application;
FIG. 3 illustrates a schematic diagram of coordinates of a touch location, according to some embodiments of the present application;
FIG. 4 illustrates a schematic diagram of another method of calculating touch location, according to some embodiments of the present application;
FIG. 5a illustrates a schematic diagram of a touch trajectory calculated according to a gravity method, according to some embodiments of the present application;
fig. 5b illustrates a schematic diagram of a touch trajectory obtained by a method of calculating a touch position according to a parabolic method, according to some embodiments of the present application.
Detailed Description
Various aspects of the illustrative embodiments will be described using terms commonly employed by those skilled in the art.
It is understood that the illustrative embodiments of the present application include, but are not limited to, a method of calculating a touch location, an electronic device, and a storage medium.
In the following description, for purposes of explanation and not limitation, specific details are set forth, such as particular system configurations, techniques, etc. in order to provide a thorough understanding of the embodiments of the present application. However, it will be apparent to those skilled in the art that the present application may be practiced in other embodiments that depart from these specific details. In other instances, detailed descriptions of well-known systems, devices, circuits, and methods are omitted so as not to obscure the description of the present application with unnecessary detail.
The terminology used in the following embodiments is for the purpose of describing particular embodiments only and is not intended to be limiting of the application. As used in the specification and the appended claims, the singular forms "a," "an," "the," and "the" are intended to include, for example, "one or more" such forms of expression, unless the context clearly indicates to the contrary. It should also be understood that in embodiments of the present application, "one or more" means one, two, or more than two; "and/or", describes an association relationship of the association object, indicating that three relationships may exist; for example, a and/or B may represent: a alone, a and B together, and B alone, wherein A, B may be singular or plural. The character "/" generally indicates that the context-dependent object is an "or" relationship.
For ease of understanding, a scene of a user operating a touch panel of an electronic device described in the background art will be explained with reference to fig. 1.
As shown in fig. 1, a user may operate on an electronic device, such as a touch panel 110 on an LED lamp 100, for example, the user may touch a switch 111 with a finger to turn on or off the LED lamp 100, and the user may also slide with the finger on a touch area 113 of a brightness adjustment 112 to adjust the brightness of the LED lamp. Because the size of the touch panel 110 of the LED lamp is small, if the user's finger slides to the boundary of the touch area 113 when the user's finger is operated on the touch area 113 of the brightness adjustment 112, the user's finger may have a portion beyond the boundary of the touch area 113, and since no sensor is provided outside the boundary of the touch area 113, sensing data cannot be obtained for a contact outside the boundary of the touch area 113, and thus, for a contact when the user's finger has a portion beyond the boundary of the touch area 113, the coordinates of the corresponding accurate touch position cannot be obtained.
Since the brightness of the LED lamp 100 is adjusted, the brightness of the LED lamp 100 will be proportional to the size of the contact track of the user on the touch area 113, if the existing gravity center method is used to calculate the touch position of the user, the obtained sliding distance of the finger of the final user may have errors due to the fact that the coordinates of the touch position of the user, which are contacted when the finger of the user is partially beyond the boundary of the touch area 113, cannot be obtained, for example, if the sliding distance of the user is 10mm, and the length of the contact track obtained after the coordinates of the touch position of the user are calculated by the gravity center method may be 8mm, then the brightness of the LED lamp 100 may be darker than the brightness desired by the user, and the use experience of the user is affected. The method of calculating the coordinates of the touch position of the user by the gravity center method and thus calculating the touch trajectory may be described as follows.
For example, one capacitive sensor is disposed at each preset distance on the touch area 113 of the brightness adjustment 112 on the LED lamp 100, and all the capacitive sensors are aligned. If the finger of the user touches the touch area 113, four capacitive sensors, such as capacitive sensor m, may be triggered 1 Capacitance sensor m 2 Capacitance sensor m 3 And capacitive sensor m 4 Capacitance sensing data1, data2, data3 and data4 are respectively generated, and a capacitance sensor m 1 Capacitance sensor m 2 Capacitance sensor m 3 And capacitive sensor m 4 The coordinates on the two-dimensional coordinate axis x are p respectively 1 、p 2 、p 3 And p 4 The coordinate p of the barycentric position when the user's finger touches the touch area 113 can be calculated according to formula (1) by barycentric method 01
p 01 =(p 1 ×data1+p 2 ×data2+p 3 ×data3+p 4 ×data4)/(data1+data2+data3+data4) (1)
If the preset time intervals can be set in the processor of the LED lamp 100, the coordinates of the barycenter positions of the touch area 113 contacted by the finger of the user are calculated once, and the coordinates p of the barycenter positions of all contacts of the user in the whole operation are obtained 01 ,p 02 ,…,p 0n . Connecting all the center of gravity positions is the contact track of the user's finger on the touch area 113.
It will be appreciated that if p 01 'when there is a part of the user's finger beyond the boundary of the touch area 113The coordinates of the touch location of the contact, which may result in only 3 capacitive sensors, such as capacitive sensor m, when the user's finger has a portion beyond the boundary of the touch area 113 1 Capacitance sensor m 2 Capacitance sensor m 3 The capacitance sensing data1, data2 and data3 are generated, and the fourth capacitance sensing data to be obtained cannot be acquired because a part of the contact area of the finger is outside the boundary of the touch area 113. Then the barycenter method is used to calculate the coordinate p of the barycenter position of the contact of the user's finger 01 ' will be:
p 01 ′=(p 1 ×data1+p 2 ×data2+p 3 ×data3)/(data1+data2+data3) (2)
as can be seen from comparing the formula (1) and the formula (2), if a part of the contact between the finger of the user and the touch area 113 occurs outside the boundary of the touch area 113, if the coordinates of the contact position are calculated using the existing gravity center method, the accuracy of the coordinates of the obtained contact position will decrease, and the accuracy of the contact trajectory obtained by connecting all the contact positions will also decrease.
For example, if the actual contact track corresponding to the sliding operation of the user is 10mm, and the contact track of the user calculated by the gravity center method is only 8mm, the brightness of the LED lamp 100 after the sensing adjustment under the sliding operation of the user is not the brightness actually required by the user, which reduces the use experience of the user.
Therefore, the application provides a method for calculating the touch position, which is different from the traditional method for calculating the coordinate of the touch position of the contact by adopting a gravity center method, and the method for combining parabolic fitting, linear fitting and the gravity center method is adopted to calculate the coordinate of the touch position of the contact. In general, since the distribution of capacitance sensing data caused by the finger of the user on the touch panel should conform to the shape of a parabola with a downward opening, that is, the capacitance sensing data generated by the central position of the finger touching the touch panel should be the largest, the coordinates of the touch position can be calculated by a parabolic fitting method, so that even if a part of the contact between the finger of the user and the touch area appears outside the boundary of the touch area, the coordinates of the accurate touch position can be obtained.
For example, a specific method may be:
setting a parabolic equation of the relation between capacitance sensing data acquired according to the current contact and the position of the responsive capacitance sensor to be y=ax 2 +bx+c, the y-axis is taken as capacitance sensing data acquired by the capacitive sensor in response to the current contact, and the x-axis is taken as the position of the capacitive sensor in response to the current contact.
Substituting the position of at least three capacitive sensors responding to the contact and the acquired capacitance sensing data into a parabolic equation to obtain values of a parameter a, a parameter b and a parameter c, and obtaining a final parabolic equation.
If the parameter a is smaller than 0, the distribution rule of the capacitance sensing data collected by the three capacitance sensors is a parabolic equation with downward openings, and the distribution rule accords with the normal distribution rule of the capacitance sensing data generated after the finger contacts the touch panel. And the coordinate of the vertex of the parabolic equation on the x axis can be used as the coordinate of the touch position of the touch according to the maximum capacitance sensing data represented by the y axis corresponding to the touch position.
In addition, if the parabolic equation obtained according to the acquired capacitance sensing data and the position of the sensor for acquiring the capacitance sensing data is the parabolic equation with the opening facing upwards or other abnormal conditions, the coordinates of the touch position can be calculated according to a linear fitting method or a gravity center method.
The method for calculating the coordinates of the touch position by adopting the parabolic fitting mode can be used for calculating the coordinates of the touch unknown of the touch area on the touch electronic equipment, and particularly can obtain the coordinates of the accurate touch position under the condition that the accuracy of calculating the touch position by adopting the gravity center method is not high aiming at the contact when the part of the finger of the user exceeds the boundary of the touch area. Meanwhile, aiming at the condition that the acquired capacitance sensing data is abnormal, a linear fitting method or a gravity center method can be adopted to calculate the coordinates of the touch position. The combined application of the three calculation methods improves the precision of calculating the coordinates of the touch position and improves the use experience of the user.
In order to explain a method for calculating a touch position in detail in the embodiments of the present application, a specific method will be described below with reference to fig. 2 to 5.
As shown in fig. 2, when a finger of a user touches a boundary of a touch panel of an electronic device, wherein a portion of the finger exceeds the boundary of the touch panel, the touch panel has three capacitive sensors m, for example, the sensors are capacitive sensors 01 、m 02 And m 03 The capacitance induction data01, data02 and data03 are respectively acquired in response to the contact, and three capacitance sensors m 01 、m 02 And m 03 The coordinates of (a) are p respectively 10 、p 11 P of sum 12
Since the sensing effect formed after the finger of the user approaches the touch panel approximately accords with the basic shape of the finger, namely, the distribution rule of the capacitance sensing data caused by the finger of the user on the touch panel, the shape of a parabola with downward opening is supposed to be met, namely, the capacitance sensing data corresponding to the touch position is supposed to be the largest, and in consideration of the contact, part of the finger exceeds the boundary of the touch panel, the contact outside the boundary cannot collect the capacitance sensing data, if the barycenter method is adopted to calculate the coordinate of the touch position, the coordinate can only be p in fig. 3 10 、p 11 P of sum 12 Between these three coordinates, there may be a discrepancy with the coordinates of the actual touch location.
Therefore, it can be assumed that the relationship between the capacitance sensing data collected from this contact and the position of the responsive capacitance sensor conforms to parabolic equation (3):
y=ax 2 +bx+c (3)。
the y axis is capacitance sensing data collected by the capacitive sensor in response to the touch, the x axis is the position of the capacitive sensor in response to the touch, and the values of the parameter a, the parameter b and the parameter c are real numbers.
Three capacitance sensors m 01 、m 02 And m 03 The acquired capacitance senseData01, data02 and data03, and three capacitance sensors m 01 、m 02 And m 03 P of (2) 10 、p 11 P of sum 12 Respectively substituting parabolic equation (3), i.e. assuming a point (x 1 ,y 1 ) Is (p) 10 Data 01), point (x) on parabola 2 ,y 2 ) Is (p) 11 Data 02), point (x) on parabola 3 ,y 3 ) Is (p) 12 Data 03), and then point (x 1 ,y 1 ) Point (x) 2 ,y 2 ) Sum point (x) 3 ,y 3 ) Substituting the coordinates of the parameters a, b and c in the formula (3) into the formula (3), and calculating the values of the parameters a, b and c in the formula (3) to obtain the final parabolic equation (3).
(1) If the parameter a is less than 0, three capacitive sensors m are illustrated 01 、m 02 And m 03 The rule of the collected capacitance sensing data accords with a parabolic equation with a downward opening, and in this case, the coordinate of the touch position can be obtained in a parabolic fitting mode.
Since the capacitance sensing data of the touch position where the finger of the user touches the touch panel is the largest, i.e., the point (x 0 ,y 0 ) The coordinates of (2) are the coordinates of the vertex of the parabola (3), so y 0 =y max ,x 0 =b/(-2a),x 0 The coordinates of the touch position where the user touches the touch panel at this time are the coordinates of the touch position.
It will be appreciated that the point (x 0 ,y 0 ) Is p of the abscissa of (2) 001 At p 10 、p 11 P of sum 12 To the left of the capacitive sensor m, i.e. the touch position calculated by the method of the present embodiment 01 、m 02 And m 03 To the left of (2), the coordinates of the touch position calculated by adopting the gravity center method can be calculated only at p 10 、p 11 And p 12 Between the three coordinates, namely, the touch position calculated by adopting a gravity center method is in the capacitance sensor m 01 、m 02 And m 03 Between them.
For example, referring to fig. 3, a finger of a user touches the touch area 113 of the brightness adjustment 112 of the LED lamp 100 in fig. 1, a part of the finger in one touch is located outside the boundary of the touch area 113, in response to the touch, capacitance sensing data collected by four capacitive sensors on the touch area 113 are 100149, 105705 and 79896, respectively, and coordinates of the four capacitive sensors on the x-axis are 1.0, 2.0, 3.0 and 4.0, respectively.
Calculating the coordinates of the touch position by adopting a gravity center method through a formula (1)
P 01 =(100149×1+105705×2+79896×3+16004×4)/(100149+105705+79896+16004)=2.04。
By adopting the parabolic model in the embodiment, the coordinates of the touch area are calculated by the formula (3), and the parabolic equation is calculated as y= -17362x2+58986x+58189. Thus, the coordinates of the x-axis corresponding to the vertex of the parabola, i.e. the coordinates x of the touch position 0 =-58986/(2×17362)=1.70。
(2) If the parameter a is greater than 0, three capacitive sensors m are illustrated 01 、m 02 And m 03 The collected capacitance sensing data rule is a parabolic equation with upward opening, and the distribution rule of the parabolic equation with upward opening is not the distribution rule of the capacitance sensing data caused by the actual user's finger on the touch panel, so that the coordinate of the touch position can be obtained in a linear fitting mode.
Referring to fig. 4, it is assumed that when a finger of a user touches a boundary of a touch panel of an electronic device, wherein a portion of the finger exceeds the boundary of the touch panel, and the touch panel has three capacitive sensors m, for example, the sensors are capacitive sensors 04 、m 05 And m 06 The capacitance induction data04, data05 and data06 are respectively acquired in response to the contact, and three capacitance sensors m 04 、m 05 And m 06 The coordinates of (a) are p respectively 14 、p 15 P of sum 16
It can be assumed that the relationship between capacitance sensing data acquired from this contact and the position of the responsive capacitive sensor corresponds to the linear equation (4), i.e
y=cx+d (4)。
The y axis is capacitance sensing data acquired by the capacitive sensor in response to the touch, the x axis is the position of the capacitive sensor in response to the touch, and the values of the parameter c and the parameter d are real numbers.
Three capacitive sensors m are taken 04 、m 05 And m 06 Two data04 and data05 with maximum capacitance sensing data in collected capacitance sensing data04, data05 and data06, and two corresponding capacitance sensors m 04 And m 05 The coordinate p of (2) 14 And p 15 Respectively substituting linear equation (4), i.e. assuming a point (x 4 ,y 4 ) Is (p) 14 Data 04), point on a straight line (x 5 ,y 5 ) Is (p) 15 Data 05), and then point (x 4 ,y 4 ) Sum point (x) 5 ,y 5 ) Substituting the coordinates of the parameter c and the parameter d into the formula (4), and calculating the values of the parameter c and the parameter d in the formula (4) to obtain a final linear equation (4).
It can be appreciated that due to the capacitive sensor m 06 The acquired capacitance sensing data06 have smaller values, so that the influence on the calculation of the coordinates of the touch position is smaller, and therefore, the maximum two of the three capacitance sensing data can be used for calculating the values of the parameter c and the parameter d in the linear equation (4).
Due to the coordinates x of the touch position of the finger 00 Ordinate y on the corresponding straight line (4) 00 In response to the maximum value of all capacitance sensing data of the contact, the historical maximum capacitance sensing data collected in the contact of the user with the touch panel of the electronic device can be used as the ordinate y 00 And then y is the ordinate 00 The value of (2) is substituted into a linear equation (4) to obtain the coordinate x of the touch position corresponding to the capacitance sensing data 00
In addition, for some practical scenarios, if the parameter a is greater than 0 and there is no sensing data corresponding to the historical capacitance value of the touch panel of the electronic device, and the touch position cannot be calculated by using the linear fitting method, the existing gravity center method, such as the method represented in the formula (1), may be adopted to calculate the coordinates of the touch position.
For example, table 1 shows that the finger of the user touches the boundary of the touch panel of the electronic device, and some of the finger touches the boundary of the touch panel, and the capacitance sensing data acquired by the 4 capacitance sensors on the touch panel is 9 times. According to the capacitance sensing data in table 1 and the coordinates of the 4 capacitive sensors, the coordinates of the touch position are calculated by adopting the existing gravity center method and the method in the embodiment of the application. Fig. 5a shows a schematic diagram of a result of calculating a touch position by using a gravity center method according to capacitance sensing data acquired for 9 times, and fig. 5b shows a schematic diagram of a result of calculating a touch position by using a method of combining parabolic fitting, linear fitting and a gravity center method according to capacitance sensing data acquired for 9 times.
TABLE 1
As shown in fig. 5a and fig. 5b, the horizontal axis is the number of times that the capacitive sensor collects capacitance sensing data, and the vertical axis is the relative coordinates of the position on the touch panel, it can be obtained that the conventional gravity center method is adopted to calculate the coordinates of the touch position and the method of combining the parabolic fit, the linear fit and the gravity center method in the embodiment of the application is adopted to calculate the coordinates of the touch position, so that the obtained results have a larger difference, and therefore, for the method of calculating the touch position with a part of contacts exceeding the boundary of the touch panel, the accuracy of the method in the embodiment of the application is higher, and the satisfaction of the user is also higher.
The technical solutions provided by the embodiments disclosed herein are applied to various electronic devices, for example, the electronic devices may include, but are not limited to, lamps, user Equipment (UE), terminals (terminal), and the like, and the electronic devices may be mobile terminals or fixed terminals such as tablet computers (portable android device, PAD), personal digital processing (personal digital assistant, PDA), handheld devices with wireless communication functions, computing devices, vehicle-mounted devices, or wearable devices, virtual Reality (VR) terminal devices, augmented reality (augmented reality, AR) terminal devices, wireless terminals in industrial control (industrial control), wireless terminals in unmanned driving (self driving), wireless terminals in remote medical (remote media), wireless terminals in smart grid (smart grid), wireless terminals in transportation security (transportation safety), wireless terminals in smart city (smart city), wireless terminals in smart home (smart home), and the like. The form of the terminal device in the embodiment of the present application is not specifically limited.
It will be apparent to one skilled in the art that some of the specific details presented above with respect to an electronic device may not be required to practice a particular described embodiment or equivalent thereof. Similarly, other electronic devices may include a greater number of subsystems, modules, components, etc. Some of the sub-modules may be implemented as software or hardware, where appropriate. It should be understood, therefore, that the foregoing description is not intended to be exhaustive or to limit the disclosure to the precise form described herein. On the contrary, many modifications and variations will be apparent to those of ordinary skill in the art in light of the above teachings.
Embodiments disclosed herein may be implemented in hardware, software, firmware, or a combination of these implementations. Embodiments of the present application may be implemented as a computer program or program code that is executed on a programmable system including at least one processor, a storage system (including volatile and non-volatile memory and/or storage elements), at least one input device, and at least one output device.
Program code may be applied to input instructions to perform the functions described herein and generate output information. The output information may be applied to one or more output devices in a known manner. For purposes of this application, a controller may include any system having a processor such as, for example, a Digital Signal Processor (DSP), a microcontroller, an Application Specific Integrated Circuit (ASIC), or a microprocessor.
Embodiments disclosed herein may be implemented in hardware, software, firmware, or a combination of these implementations. Embodiments of the present application may be implemented as a computer program or program code that is executed on a programmable system including at least one processor, a storage system (including volatile and non-volatile memory and/or storage elements), at least one input device, and at least one output device.
Program code may be applied to input instructions to perform the functions described herein and generate output information. The output information may be applied to one or more output devices in a known manner. For purposes of this application, a processing system includes any system having a processor such as, for example, a Digital Signal Processor (DSP), microcontroller, application Specific Integrated Circuit (ASIC), or microprocessor.
The program code may be implemented in a high level procedural or object oriented programming language to communicate with a processing system. Program code may also be implemented in assembly or machine language, if desired. Indeed, the mechanisms described in the present application are not limited in scope to any particular programming language. In either case, the language may be a compiled or interpreted language.
In some cases, the disclosed embodiments may be implemented in hardware, firmware, software, or any combination thereof. The disclosed embodiments may also be implemented as instructions carried by or stored on one or more transitory or non-transitory machine-readable (e.g., computer-readable) storage media, which may be read and executed by one or more processors. For example, the instructions may be distributed over a network or through other computer readable media. Thus, a machine-readable medium may include any mechanism for storing or transmitting information in a form readable by a machine (e.g., a computer), including but not limited to floppy diskettes, optical disks, read-only memories (CD-ROMs), magneto-optical disks, read-only memories (ROMs), random Access Memories (RAMs), erasable programmable read-only memories (EPROMs), electrically erasable programmable read-only memories (EEPROMs), magnetic or optical cards, flash memory, or tangible machine-readable memory for transmitting information (e.g., carrier waves, infrared signal digital signals, etc.) in an electrical, optical, acoustical or other form of propagated signal using the internet. Thus, a machine-readable medium includes any type of machine-readable medium suitable for storing or transmitting electronic instructions or information in a form readable by a machine (e.g., a computer).
In the drawings, some structural or methodological features may be shown in a particular arrangement and/or order. However, it should be understood that such a particular arrangement and/or ordering may not be required. Rather, in some embodiments, these features may be arranged in a different manner and/or order than shown in the illustrative figures. Additionally, the inclusion of structural or methodological features in a particular figure is not meant to imply that such features are required in all embodiments, and in some embodiments, may not be included or may be combined with other features.
It should be noted that, in the embodiments of the present application, each unit/module is a logic unit/module, and in physical aspect, one logic unit/module may be one physical unit/module, or may be a part of one physical unit/module, or may be implemented by a combination of multiple physical units/modules, where the physical implementation manner of the logic unit/module itself is not the most important, and the combination of functions implemented by the logic unit/module is the key to solve the technical problem posed by the present application. Furthermore, to highlight the innovative part of the present application, the above-described device embodiments of the present application do not introduce units/modules that are less closely related to solving the technical problems presented by the present application, which does not indicate that the above-described device embodiments do not have other units/modules.
It should be noted that in the examples and descriptions of this patent, relational terms such as first and second, and the like are used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Moreover, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising" does not exclude the presence of other like elements in a process, method, article, or apparatus that comprises an element.
While the present application has been shown and described with reference to certain preferred embodiments thereof, it will be understood by those skilled in the art that various changes in form and details may be made therein without departing from the scope of the present application.

Claims (10)

1. A method for calculating a touch position, applied to an electronic device, comprising:
acquiring sensing data corresponding to contact of a touch area on the electronic equipment;
determining the shape of a fitting curve according to the sensing data and the position of a sensor collecting the sensing data;
and calculating the touch position by adopting a parabolic fitting method corresponding to the fact that the fitting curve is a parabolic curve with a downward opening.
2. The method of claim 1, wherein determining the shape of the fitted curve based on the sensed data and the location of the sensor that acquired the sensed data comprises:
setting a parabolic equation, setting a y-axis as sensing data acquired by a capacitive sensor in response to contact, and setting an x-axis as a position of the sensor in response to contact;
substituting the positions of at least three sensing data and the sensors for acquiring the at least three sensing data into a parabolic equation to obtain a final parabolic equation.
3. The method of claim 2, wherein said at least three of said sensed data comprises the three of the at least three sensed data having the largest value.
4. The method of claim 1, wherein calculating the touch location using a parabolic fit method comprises:
and taking the coordinate on the x axis corresponding to the vertex of the parabola as the coordinate of the touch position.
5. The method as recited in claim 1, further comprising:
and if the electronic equipment stores historical induction data, calculating the touch position by adopting a linear fitting method.
6. The method of claim 5, wherein the calculating the touch location using a linear fitting method comprises:
setting a linear equation, setting a y-axis as sensing data acquired by a capacitive sensor in response to contact, and setting an x-axis as a position of the sensor in response to contact;
substituting the at least two sensing data and the positions of the sensors for acquiring the at least two sensing data into a linear equation to obtain a final linear equation;
substituting the largest sensing data in the historical sensing data of the electronic equipment into the final linear equation to obtain a corresponding coordinate on an x-axis;
and taking the coordinate on the corresponding x axis as the coordinate of the touch position.
7. The method of claim 6, wherein the at least two sensed data comprise two sensed data having a greatest value of the sensed data collected by the touch responsive capacitive sensor.
8. The method as recited in claim 5, further comprising:
and if the electronic equipment does not store history induction data, calculating the coordinates of the touch position by adopting a gravity center method.
9. An electronic device comprising a controller and a memory;
the memory stores computer-executable instructions;
the controller executing computer-executable instructions stored in the memory causing the controller to perform the method of any one of claims 1 to 8.
10. A computer readable storage medium having stored thereon instructions that, when executed on an electronic device, cause the electronic device to perform the method of any of claims 1 to 8.
CN202310437275.0A 2023-04-21 2023-04-21 Method for calculating touch position, electronic equipment and storage medium Pending CN116501193A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310437275.0A CN116501193A (en) 2023-04-21 2023-04-21 Method for calculating touch position, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310437275.0A CN116501193A (en) 2023-04-21 2023-04-21 Method for calculating touch position, electronic equipment and storage medium

Publications (1)

Publication Number Publication Date
CN116501193A true CN116501193A (en) 2023-07-28

Family

ID=87319603

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310437275.0A Pending CN116501193A (en) 2023-04-21 2023-04-21 Method for calculating touch position, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN116501193A (en)

Similar Documents

Publication Publication Date Title
US9288373B2 (en) System and method for human computer interaction
US11003753B2 (en) Method for recognizing fingerprint, and electronic device and storage medium therefor
KR101696602B1 (en) Biometric authentication using gesture
CN102055836B (en) Mobile terminal with action recognition function and action recognition method thereof
CN108759892B (en) Sensor calibration method, electronic device and computer-readable storage medium
US20150355750A1 (en) Method for authenticating capacitive touch
CN109614016B (en) Touch identification method and device of capacitive touch screen and electronic equipment
CN106681636A (en) Method and device capable of preventing wrong touch, and mobile terminal
CN106131334B (en) Method and device for controlling screen state of mobile terminal
CN116069192B (en) Touch positioning method, system and equipment based on multiple touch electrodes
CN109002230A (en) Touch screen calibration method, apparatus and electronic equipment
WO2020135816A1 (en) Sensing array-based control method and apparatus, storage medium and computer device
CN116501193A (en) Method for calculating touch position, electronic equipment and storage medium
CN109782616B (en) Control method and device based on induction array, storage medium and computer equipment
KR101494269B1 (en) Touch Stamp Including Bluetooth Broadcasting Function
CN112990163B (en) Fingerprint calibration method, electronic device and storage medium
US20180364866A1 (en) Method for calibrating touchscreen panel with industrial robot and system, industrial robot and touchscreen using the same
CN108760042A (en) Optical sensor calibration method and device, mobile device, medium and electronic equipment
CN112539718A (en) Position detection method, air conditioner and control method thereof
WO2017187629A1 (en) Information processing device, information processing method, and information processing program
US9830499B2 (en) Method of executing function of electronic device and electronic device using same
CN106095317B (en) Touch screen response method and terminal
WO2024016809A1 (en) Palm scan verification guidance method and apparatus, terminal, storage medium, and program product
WO2020061393A1 (en) Techniques for calibrating a stereoscopic camera in a device
CN109032429B (en) Touch screen control method and device, control device, equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination