Background
With the development of information technology, electronic devices such as portable mobile devices are increasingly closely related to the lives of people. Such portable mobile devices may receive user input and perform functions desired by the user in accordance with the input. As an input device for receiving user input, a touch device is widely used due to its advantages of small size, light weight, and easy operation.
Touch devices are mainly classified into two types, a resistive touch device and a capacitive touch device. Resistive touch devices are low cost, easy to manufacture, but can only support single finger operation. The capacitive touch device has strong operability and supports multi-finger functions, and thus becomes the first choice of the current touch devices.
The capacitive touch device comprises a capacitive touch screen, and the capacitive touch screen can sense capacitance change caused by touch of a finger (or a stylus) through orthogonal capacitance graphs distributed on the capacitive touch screen, so that a touch position and touch strength are measured. The capacitive touch screen can be a transparent panel positioned in front of the capacitive touch device, and can also be an opaque man-machine interaction panel.
The problem of inaccurate positioning is caused because the conductor capable of being sensed by the touch screen needs a large contact area, and the support of the pen is not ideal. Therefore, it is expected that the capacitive touch device can support writing with a pen, and at least includes the functions of fine pen point, suspension sensing, precise positioning, precise pressure sensing, and the like.
The active capacitance pen solves the problems and is used in cooperation with a capacitance touch screen. The active capacitance pen can send high-voltage pulse signals synchronous with the capacitance touch screen, capacitance induction is enhanced, so that the contact area can be reduced, and the user experience is obviously enhanced by the thin pen point.
Fig. 1 shows a schematic diagram of the working principle of a capacitive stylus and a touch screen.
As shown in fig. 1, the touch device includes: a panel on which parallel capacitor plates orthogonal to each other are arranged for transmitting and receiving signals; a transmitting capacitor plate arranged on the panel for transmitting the probe wave outwards; the pen 11 receives the synchronization and command information sent by the panel through the pen point and sends a signal wave to the panel through the pen point; the receiving capacitor plate is arranged on the panel and used for receiving the detection wave of the sending capacitor plate and the signal wave of the pen; the analog signal processing unit sends corresponding waveforms according to the capacitor plates selected by the control processing unit or preprocesses signals from the receiving capacitor plates; and a control processing unit 14, which converts the preprocessed received signal into a digital signal through AD, and obtains the touch position through processing, and obtains the position of the pen and the information returned by the pen in the case that the pen is a capacitive pen.
Therefore, the information interaction between the capacitive pen and the touch screen is mostly realized through capacitive coupling with the touch screen, that is, the capacitive pen interacts with the touch screen through the metal structure at the pen point position.
With the rapid development of touch applications in recent years, users sometimes need to consider the inclination angle of the capacitive pen relative to the touch screen in some painting applications so as to perform special-effect painting, such as spraying effect. In the prior art, a method for measuring an inclination angle of a capacitive pen relative to a touch screen includes: the inclination angle of the capacitive pen is estimated by determining the position of the pen point of the capacitive pen on the touch screen and the position of the touch screen contacted by the palm and fingers of the user holding the capacitive pen, however, the technology needs to detect the positions of the palm and the fingers of the user, has large calculation amount and low detection precision, and also causes estimation errors due to the habit of holding the capacitive pen by a person; the method comprises the steps of arranging a ring electrode separated from a pen point, and measuring capacitive coupling between the pen point and the ring electrode and a touch screen to estimate the inclination angle of the capacitive pen.
Disclosure of Invention
The invention provides a touch device and a method for measuring an inclination angle of a capacitive pen relative to a touch screen. The touch device has the advantages of simple structure, convenient control, small calculated amount and higher precision.
The invention provides a touch device, which comprises a capacitance pen and a touch screen, wherein the capacitance pen comprises: a pen holder; a nib comprising a first portion at least partially inside the barrel and a second portion connected to the first portion; a shielding unit surrounding the first portion of the pen tip to shield communication between the first portion and the touch screen; a control unit for enabling/disabling the shielding unit; in each communication cycle, the touch screen sends a switching command to the control unit of the capacitive pen, the control unit of the capacitive pen enables/disables the shielding unit according to the switching command, the touch screen respectively obtains the gravity centers of the projections of the pen tips on the touch screen in the shielded state and the unshielded state of the first part, and the inclination angle of the capacitive pen relative to the touch screen is obtained by comparing the deviation of the gravity centers.
Preferably, the touch screen comprises a plurality of parallel X-axis electrodes and a plurality of parallel Y-axis electrodes, and the X-axis electrodes and the Y-axis electrodes are perpendicular to each other, wherein the touch screen acquires the center of gravity of the projection of the pen tip by determining the positions of the X-axis electrodes and the Y-axis electrodes that are capacitively coupled with the pen tip.
Preferably, the touch screen obtains the inclination angle of the capacitive pen relative to the touch screen by querying a pre-stored offset-angle mapping table.
Preferably, the first portion and the second portion are both cylindrical, the length of the first portion is greater than the length of the second portion, and the diameter of the first portion is greater than the diameter of the second portion.
Preferably, the first portion is cylindrical, the second portion is conical, and the diameter of the first portion is equal to or greater than the maximum diameter of the second portion.
Preferably, the first portion is in a shape of a truncated cone, the second portion is in a shape of a cone, and a minimum diameter of the first portion is equal to or greater than a maximum diameter of the second portion.
Preferably, the shielding unit is a metal sleeve.
Preferably, the shielding unit is a metal spring.
Preferably, the capacitive pen further includes a switch connecting the shielding unit and ground, and the control unit enables/disables the shielding unit by controlling the switch.
Preferably, an IO port of the control unit is directly connected to the shielding unit, and the control unit enables/disables the shielding unit by controlling an output voltage or an output impedance of the IO port.
Another aspect of the present invention provides a method of measuring an inclination angle between a capacitive pen and a touch screen, the capacitive pen including: a pen holder; a nib including a first portion at least partially inside the barrel and a second portion connected to the first portion; a shielding unit surrounding the first portion of the pen tip to shield communication between the first portion and the touch screen; and a control unit for enabling/disabling the shielding unit, the method comprising the steps of: in each communication period, the touch screen sends an enabling switching command to the control unit of the capacitive pen, and the control unit of the capacitive pen enables the shielding unit according to the enabling switching command; the touch screen acquires the center of gravity of the projection of the pen point on the touch screen; the touch screen sends a disabling switching command to the capacitive pen, and the control unit of the capacitive pen disables the shielding unit according to the disabling switching command; the touch screen acquires the center of gravity of the projection of the pen point on the touch screen; the touch screen obtains the inclination angle of the capacitive pen relative to the touch screen by calculating the shift of the gravity center of the projection of the pen point on the touch screen under the two states of enabling and disabling the shielding unit.
Preferably, the touch screen comprises a plurality of parallel X-axis electrodes and a plurality of parallel Y-axis electrodes, and the X-axis electrodes and the Y-axis electrodes are perpendicular to each other, wherein the center of gravity of the projection of the pen tip is obtained by determining the positions of the X-axis electrodes and the Y-axis electrodes that are capacitively coupled with the pen tip.
Preferably, after obtaining the center of gravity offset of the projection of the pen tip, the touch screen obtains the inclination angle of the capacitive pen relative to the touch screen by querying a pre-stored offset-angle mapping table.
The touch device can continuously obtain the inclination angle of the capacitive pen relative to the touch screen in the writing process of the capacitive pen, and has the advantages of simple structure of the capacitive pen, simple and convenient method for measuring the inclination angle, small calculated amount, high detection precision and no dependence on the habit of holding the pen by a user.
Detailed Description
In order to make the technical solutions of the present invention better understood by those skilled in the art, the capacitive stylus and the method for measuring a tilt angle provided by the present invention are described in detail below with reference to the accompanying drawings and the detailed description. In these drawings, the same or corresponding components are denoted by the same reference numerals. The following is only a preferred embodiment of the capacitance pen and the method for measuring a tilt angle of the present invention, and the present invention is not limited to the following structure.
[ touch control device ]
Referring to fig. 2, the touch device of the present invention includes a capacitive pen 10 and a touch screen 20. The capacitive stylus 10 will be described in detail below.
Fig. 3 shows a block diagram of a capacitive stylus according to an embodiment of the present invention.
As shown in fig. 3, the capacitance pen 10 of the present invention includes: a barrel 100; a tip 102, the tip 102 including a first portion 1020 at least partially inside the barrel 100 and a second portion 1022 connected to the first portion; a shielding unit 104 surrounding the first portion 1020 of the pen tip 102 to shield communication between the first portion 1020 and the touch screen; and a control unit 108 for enabling/disabling the shielding unit 104.
In fig. 3, a part of the first portion 1020 is located inside the barrel 100, but in other embodiments, the first portion 1020 may be entirely located inside the barrel 100, and a part of the second portion 1022 may be located inside the barrel 100.
In each communication cycle between the capacitive stylus 10 and the touch screen 20, the touch screen 20 sends a switching command to the capacitive stylus 10, and the control unit 108 of the capacitive stylus 10 enables/disables the shielding unit 104 according to the switching command. The touch screen 20 obtains the centers of gravity of the projections of the pen tip 102 on the touch screen 20 in the shielded state and the unshielded state of the first portion 1020, respectively, and obtains the inclination angle of the capacitive pen 10 relative to the touch screen 20 by comparing the shifts of the centers of gravity.
The structure of the capacitive stylus 10 of the present invention is described in detail below with reference to fig. 4.
FIG. 4 shows a schematic diagram of a tip of a capacitive pen according to an embodiment of the present invention.
As shown in fig. 4, the first portion 1020 and the second portion 1022 are each cylindrical. First portion 1020 has a length L1 that is greater than a length L2 of second portion 1022. Also, the diameter of the first portion 1020 is greater than the diameter of the second portion 1022. For example, the diameter of the first portion 1020 is about 4.5mm and the diameter of the first portion 1022 is about 1.5 mm.
Additionally, although not shown, in an alternative embodiment of the present invention, the first portion 1020 may be cylindrical and the second portion 1022 may be conical. Also, the diameter of the first portion 1020 is equal to or greater than the maximum diameter of the second portion 1022.
Additionally, although not shown, in an alternative embodiment of the present invention, the first portion 1020 may be frustoconical and the second portion 1022 may be conical. Also, the minimum diameter of the first portion 1020 is equal to or greater than the maximum diameter of the second portion 1022.
The working principle of the shielding unit of the capacitive stylus of the present invention will be described with reference to fig. 5.
Fig. 5A and 5B illustrate the operation principle of the shielding unit of the capacitive stylus according to the embodiment of the present invention. For convenience, the cartridge 100 is not shown in fig. 5.
As shown in fig. 5A, the shielding element 104 is a metal sleeve surrounding the first portion 1020. The second portion 1022 is not surrounded by the shield unit 104.
In fig. 5A and 5B, the capacitive stylus 10 further includes a switch 106 connecting the shielding unit 104 and the ground, and the control unit 108 enables/disables the shielding unit 104 by controlling the switch 106.
The shielding unit 104 is connected to one end of the switch 106, and the other end of the switch 106 is grounded. In the state of fig. 5A, the shielding function of the shielding unit 104 is enabled, and the first portion 1020 of the pen tip cannot be capacitively coupled to the touch screen 20.
As shown in fig. 5B, the switch 106 may disconnect the shielding unit 104 from the ground. In the state of fig. 5B, the shielding function of the shielding unit 104 is disabled, and the first portion 1020 of the pen tip can be capacitively coupled to the touch screen 20.
Additionally, although the shielding element 104 is shown as a metal sleeve in fig. 5A and 5B, in an alternative embodiment of the invention, the shielding element 104 may also be a metal spring surrounding the first portion 1020.
Although in fig. 5A and 5B, the shield unit 104 is enabled/disabled by the switch 106 connecting the shield unit 104 and the ground. It should be noted that according to the present invention, the IO port of the control unit 108 may be directly connected to the shielding unit 104, and the control unit 108 enables/disables the shielding unit 104 by controlling an output voltage or an output impedance of the IO port. For example, the control unit 108 enables the shielding unit 104 by grounding or setting the IO port to a high impedance.
[ MEASURING ANGLE METHOD ]
The method for measuring the tilt angle between the capacitive stylus and the touch screen according to the present invention is described below.
As shown in fig. 6, a writing plane of the touch screen 20 is defined as x0y plane, and a contact point between the capacitive stylus 10 and the touch screen 20 is defined as a coordinate origin 0. When the capacitive stylus 10 is writing on the touch screen 20, the capacitive stylus 10 is generally tilted as shown in fig. 6.
In order to determine the tilt angle between the capacitive stylus 10 and the touch screen 20, the tilt angle of the capacitive stylus 10 with respect to the x-axis and the y-axis of the touch screen 20 needs to be determined.
Referring to FIG. 7A, the projection P of the capacitive pen 10 in the x0z planexzThe included angle with the x-axis is the tilt angle θ of the capacitive pen 10 relative to the x-axis of the touch screen 20x。
Referring to fig. 7B, an included angle between a projection Pyz of the capacitive pen 10 on the y0z plane and the y-axis is an inclination angle θ of the capacitive pen 10 with respect to the y-axis of the touch screen 20y。
The touch screen 20 has a plurality of electrodes 70 distributed along the x-axis and a plurality of electrodes 72 distributed along the y-axis, as shown in fig. 8. When capacitive pen 10 writes on touch screen 20, through electrodes 70 and 72, is able to detect a location 74 projected on touch screen 20 of the center of gravity of tip 102.
This is because the stylus 102 transmits a high-voltage ac signal, the touch panel 20 can detect the signal transmitted from the stylus 102 through the electrodes 70 and 72 that are capacitively coupled to the stylus 102, and the position of the stylus 102 can be detected through the distribution of the centers of gravity of the signals on the electrodes.
As described above, the tip 102 of the stylus 10 of the present invention has the first portion 1020 and the second portion 1022, the length of the first portion 1020 is greater than the length of the second portion 1020, and the diameter of the first portion 1020 is greater than the diameter of the second portion 1020. In this case, the center of gravity of the stylus 102 projected onto the touch screen 20 may be significantly offset. The following description is made with reference to fig. 9A and 9B.
Fig. 9A shows a state in which the capacitive stylus 10 of the present invention is not tilted. In this state, the projection P of the pen tip 102 on the touch screen 20 is located directly below the pen tip 102.
Fig. 9B shows a state in which the capacitive pen 10 is tilted, that is, a state in which a user performs writing or the like using the capacitive pen 10. In this state, the projection P' of the pen tip 102 on the touch screen 20 is shifted from P. For comparison, the projection P is also shown in fig. 9B.
Just because the tip 102 of the capacitive pen 10 of the present invention has the structure described above with reference to fig. 3-4, when the capacitive pen 10 is tilted, the deviation of the projection P' from P is magnified and can be easily detected by the touch screen 20.
Since the capacitive pen 10 of the present invention employs the shielding unit 104 and the control unit 108, in each communication cycle between the capacitive pen 10 and the touch screen 20, the capacitive coupling between the first portion 1020 of the pen tip 102 and the touch screen 20 can be shielded to obtain the projected gravity center of the pen tip 102, and then the capacitive coupling between the first portion 1020 and the touch screen 20 can be generated to obtain the projected gravity center of the pen tip 102. The touch screen 20 can obtain the inclination angle of the capacitive pen 10 relative to the touch screen 20 by comparing the shifts of the two centers of gravity.
The method for measuring the tilt angle of the present invention will be described in detail with reference to fig. 10. It should be noted that the following steps are performed in each communication cycle between the capacitive stylus 10 and the touch screen 20, and by continuously repeating these steps, the touch screen 20 can continuously obtain the tilt angle parameter of the capacitive stylus 10 at any time.
In step S1000, the touch screen 20 sends an enable switch command to the capacitive stylus 10.
In step S1002, the control unit 108 of the capacitive pen 10 enables the shielding unit 104 according to the enable switching command. For example, switch 106 is turned on, thereby grounding metal sleeve 104.
In step S1004, the touch screen 20 acquires the center of gravity of the projection of the pen tip 102 on the touch screen 20. For example, referring to fig. 9A, the coordinates (x1, y1) of the projection P are acquired.
In step S1006, the touch screen 20 sends a disable switching command to the capacitive pen 10.
In step S1008, the control unit 108 of the capacitive stylus 10 disables the shielding unit 104 according to the disable switching command. For example, switch 106 is open, thereby disconnecting metal sleeve 104 from ground.
In step S1010, the touch screen 20 acquires the center of gravity of the projection of the pen tip 102 on the touch screen 20. For example, referring to fig. 9B, the coordinates (x2, y2) of the projection P' are acquired.
In step S1012, the touch panel 20 calculates the shift of the center of gravity by comparison.
In step S1014, the touch screen 20 obtains the inclination angle of the capacitive stylus 10 relative to the touch screen 20 by querying a pre-stored offset-angle mapping table.
Referring to fig. 11, the projection coordinates of the pen tip 102 with respect to the touch screen 20 obtained in steps S1004 and S1010 are (x1, y1) and (x2, y2), respectively, and according to the geometrical relationship described with reference to fig. 6 to 7, the tilt angle of the capacitive pen 10 with respect to the x-axis of the touch screen 20 is proportional to the difference value (x2-x1), and the tilt angle with respect to the y-axis of the touch screen 20 is proportional to the difference value (y2-y 1).
Therefore, the coordinate differences (x2-x1) and (x2-x1) at a plurality of prescribed angles may be measured in advance, thereby obtaining the barycentric shift-tilt angle map. In step S1014, the touch screen 20 may quickly obtain the tilt angle of the capacitive stylus 10 relative to the touch screen 20 by querying the barycentric offset-tilt angle mapping table.
Alternatively, coordinate differences (x2-x1) and (x2-x1) at a plurality of prescribed angles may be measured in advance, thereby fitting the center of gravity shift to the inclination angle. In step S1014, the tilt angle of the capacitive pen 10 with respect to the touch screen 20 may be obtained by substituting the corresponding function for the measured coordinate difference values (x2-x1) and (x2-x 1).
In the case where the shield unit 104 is a metallic shield case, as shown in fig. 12, the shield case may be opened upward, and the rear end of the pen tip 102 may be brought into contact with the pressure sensor after protruding from the opening.
By using the touch device and the method for measuring the inclination angle of the capacitive pen, a user can perform operation based on the inclination angle on the touch screen, so that special effects such as spraying in soft pen calligraphy and drawing applications are realized, and the application range of the touch device is expanded.
The above embodiments are merely exemplary embodiments adopted to illustrate the principles of the present invention, but the present invention is not limited thereto. It will be apparent to those skilled in the art that various changes and modifications may be made without departing from the spirit and scope of the invention. Such variations and modifications are also to be considered within the scope of the present invention.