Writing input effect detection method and device of touch equipment and electronic equipment

By calculating the difference between the test trajectory written on the touch device and the preset writing trajectory, the problem of difficulty in detecting the writing input effect of the touch device in the prior art is solved, efficient and accurate evaluation is achieved, and user experience is improved.

CN119883019APending Publication Date: 2025-04-25GUANGZHOU SHIYUAN ELECTRONICS CO LTD +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311386508.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-10-24
Publication Date
2025-04-25

AI Technical Summary

Technical Problem

The prior art is difficult to effectively detect the writing input effect of touch devices, affecting the user experience.

Method used

By obtaining the preset writing trajectory and the corresponding testing trajectory, the difference between the two is calculated and the writing input effect of the touch device is detected based on the difference.

Benefits of technology

It realizes rapid and efficient evaluation of the writing input effect of touch devices, improves evaluation efficiency, reduces time and human resources consumption, and eliminates interference from human factors, ensuring the stability and repeatability of test results.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119883019A_ABST
    Figure CN119883019A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of computers, and discloses a writing input effect detection method and device of touch equipment and electronic equipment. The method comprises the steps of obtaining a preset writing track; acquiring a test track corresponding to the preset writing track; calculating the difference between the test track and the preset writing track; and detecting a writing input effect of the touch device according to the difference, wherein the test track is generated when the writing device writes on the touch device according to the preset writing track. According to the method, the mode of evaluating the writing effect of the touch equipment is enriched, and the rapid and efficient test and evaluation process is realized, so that the evaluation efficiency is improved, and time and human resources are saved; in addition, the method can be automatically completed through execution equipment such as a computer and machinery, interference of human factors is eliminated, and a test result is more stable and reproducible.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of computer technology, and in particular to a writing input effect detection method and device for a touch device, and an electronic device. Background Art

[0002] With the development of various touch input technologies, more and more electronic devices have the ability to write input, and people are becoming more and more accustomed to using such devices for operations such as teaching, meeting discussions, taking notes, etc. Among them, the writing input effect of touch devices (such as fidelity, restoration, etc.) is an important factor affecting the user experience of touch devices. Therefore, it is of great significance to detect the writing input effect of touch devices. Summary of the invention

[0003] The main technical problem solved by the implementation methods of the present application is how to detect the writing input effect of a touch device.

[0004] To solve the above technical problems, a technical solution adopted in the implementation mode of the present application is: to provide a writing input detection method for a touch device, comprising: obtaining a preset writing trajectory; obtaining a test trajectory corresponding to the preset writing trajectory, wherein the test trajectory is generated when the writing device writes on the touch device according to the preset writing trajectory; calculating the difference between the test trajectory and the preset writing trajectory; and detecting the writing input effect of the touch device based on the difference.

[0005] In order to solve the above technical problems, another technical solution adopted in the implementation mode of the present application is: to provide a writing input detection device for a touch device, including: a preset writing trajectory acquisition module, used to obtain a preset writing trajectory; a test trajectory acquisition module, used to obtain a test trajectory corresponding to the preset writing trajectory, wherein the test trajectory is generated when the writing device writes on the touch device according to the preset writing trajectory; a trajectory difference calculation module, used to calculate the difference between the test trajectory and the preset writing trajectory; a writing input effect detection module, used to detect the writing input effect of the touch device according to the difference.

[0006] To solve the above technical problems, another technical solution adopted in the implementation mode of the present application is: to provide an electronic device, comprising: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the method as described above.

[0007] Different from the related art, the embodiments of the present application provide a writing input detection method, device and electronic device for a touch device, by obtaining a preset writing trajectory and obtaining a test trajectory corresponding to the preset writing trajectory, the test trajectory is generated when the writing device writes on the touch device according to the preset writing trajectory, and then compares the difference between the test trajectory and the preset writing trajectory, and finally evaluates the writing input effect of the touch device based on the calculated trajectory difference. The writing input detection method, device and electronic device for a touch device provided by the embodiments of the present application enrich the way to evaluate the writing effect of a touch device, and the method realizes a fast and efficient testing and evaluation process, thereby improving the efficiency of the evaluation and saving time and human resources; in addition, it can be completed automatically through execution equipment such as computers and machinery, eliminating the interference of human factors, making the test results more stable and reproducible. BRIEF DESCRIPTION OF THE DRAWINGS

[0008] One or more embodiments are exemplarily described by corresponding drawings, which do not constitute limitations on the embodiments. Elements with the same reference numerals in the drawings represent similar elements, and the figures in the drawings do not constitute proportional limitations unless otherwise stated.

[0009] Figure 1 It is an architecture diagram of a writing input effect detection system for a touch device provided in an embodiment of the present application;

[0010] Figure 2 is a flow chart of a writing input effect detection method for a touch device provided in an embodiment of the present application;

[0011] Figure 3 is a schematic diagram including a preset writing track and a test track provided in an embodiment of the present application;

[0012] Figure 4 is a flow chart of a method for calculating the difference between the test track and the preset writing track provided in an embodiment of the present application;

[0013] Figure 5 is a flow chart of a method for obtaining a mapping ratio coefficient according to the preset writing trajectory and the test trajectory provided in an embodiment of the present application;

[0014] Figure 6 is a flow chart of a method for obtaining a mapping point sequence according to the mapping ratio coefficient and the test point sequence provided in an embodiment of the present application;

[0015] Figure 7 is a schematic diagram including a preset writing track, a test track, and a mapping relationship and distance between a test point and a mapping point on the preset writing track provided by an embodiment of the present application;

[0016] Figure 8 It is a structural block diagram of a writing input effect detection device for a touch device provided in an embodiment of the present application;

[0017] Fig. 9 It is a schematic diagram of the hardware structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0018] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.

[0019] It should be noted that, if there is no conflict, the various features in the embodiments of the present application can be combined with each other, all within the protection scope of the present application. In addition, although the functional modules are divided in the device schematic diagram and the logical order is shown in the flow chart, in some cases, the steps shown or described can be performed in a sequence different from the module division in the device schematic diagram or the flow chart. Unless otherwise defined, all technical and scientific terms used in this specification are the same as those generally understood by technicians in the technical field of the present application. The terms used in the specification of the present application are only for the purpose of describing specific embodiments and are not used to limit the present application.

[0020] With the development of technology, the use of touch devices is becoming more and more widespread, such as smartphones and tablets, which use touch screen technology to interact with the screen through fingers or stylus, etc. They are widely used in various fields, including communication, social media, games, entertainment, office and learning. Another example is laptops. Many laptops now also have touch screen functions. Touch laptops can interact with the screen through fingers or stylus, etc., allowing users to operate applications, draw and perform handwriting input more directly. Another example is an interactive electronic whiteboard, which is a large touch device that can be used for education and business presentations, etc. It allows users to write, draw and operate applications on the whiteboard through fingers or special stylus, providing a more intuitive and interactive user experience. Another example is game controllers, car navigation and entertainment systems, etc., various fields use touch technology to provide users with more intuitive and convenient ways of interaction.

[0021] Among them, an important factor affecting the user experience of touch devices is that the content written and input by the user on the touch device cannot be accurately reflected on the touch screen of the touch device. For example, when users use a stylus or finger to write on the touch screen, they may find that the written content has a certain delay or inaccuracy with their actual actions, resulting in the writing results being inconsistent with their expectations. The reason for this phenomenon may be that the sensing technology of the touch screen may have a certain delay, which may be caused by aspects such as signal processing, screen refresh rate, or the performance of the touch controller. The reason for this phenomenon may also be that the accuracy of the touch device for handwriting input is limited, resulting in some deviations or deformations of the written content on the touch screen. It may also be that the software algorithm of the touch device has an impact on the processing method of writing input, such as using a simplified algorithm to process writing input, resulting in the loss or deformation of some writing features. It may also be interference from the external environment, such as dust, grease, or water droplets that affect the sensitivity and accuracy of the touch screen, resulting in a decrease in the accuracy of writing input.

[0022] Therefore, in order to determine the cause of inaccurate writing input on the touch device and how to solve this problem, it is first necessary to detect the writing input effect of the touch device to determine whether there is a problem of inaccurate writing input content.

[0023] By detecting written input, possible problems with touch devices can be identified, such as delays, offsets, inaccurate handwriting, etc. Further analysis and investigation can help determine the specific causes of these problems, such as technical limitations, handwriting accuracy, software algorithms, or external interference. Then, according to the specific causes of the problem, corresponding solutions can be taken, such as improving touch screen technology, optimizing software algorithms, enhancing handwriting input accuracy, or strengthening screen cleaning.

[0024] Therefore, by detecting the writing input effect of the touch device, the existence of the problem can be determined and guidance can be provided for solving the problem, which is an important step to ensure that the touch device provides an accurate and good user experience in writing input. Based on this, the embodiment of the present application provides a writing input effect detection method and device for a touch device.

[0025] See also Figure 1 , Figure 11 is an architecture diagram of a writing input effect detection system for a touch device provided in an embodiment of the present application. When the computing device is independent of the touch device, the system includes: a computing device 10, a touch device 20, and a writing device 30. The computing device 10 is connected to the touch device 20 and the writing device 30 in a wired or wireless manner. The writing device 30 is used in conjunction with the touch device 20 as a tool for writing and forming handwriting, and is used to write input content on the touch screen of the touch device 20, and the content is displayed on the touch screen of the touch device 20.

[0026] The computing device 10 may include but is not limited to a personal computer, a tablet computer, a smart phone, a desktop computer, a handheld computer, an all-in-one computer, a vehicle-mounted multimedia device, etc. The detection software may be installed on the computing device 10, and the detection of the writing input effect of the touch device 20 may be triggered by the detection software. The detection software may interact with the touch device 20 to record and analyze the effect of the writing input. By triggering the writing input, the detection software may measure and evaluate the accuracy, delay, precision and other parameters of the writing, so as to determine whether there is a problem of inaccurate writing input. The detection software may provide various functions and options, such as displaying the writing track, recording the writing speed, detecting the pressure sensitivity, measuring the handwriting accuracy, etc., and by analyzing these parameters, detailed information on the writing input quality and performance of the touch device 20 may be obtained. By installing the detection software on the computing device 10 and performing the detection of the writing input, the writing input effect of the touch device 20 may be effectively evaluated, and useful data and guidance may be provided for determining and solving existing problems, which may help improve the performance of the touch device 20, and improve the accuracy of the writing input and the user experience.

[0027] Alternatively, the computing device 10 can be a module integrated into the touch device 20. In this integrated case, the computing device 10, as a part of the touch device 20, communicates and collaborates with the touch screen and writing device 30 of the touch device 20. It is responsible for triggering the detection of writing input, recording and analyzing the effects of writing input, and providing functions and options similar to detection software. This integrated design can provide a more compact and portable solution, integrating computing and touch functions into the same device, allowing users to perform writing input and other computing tasks on one device. Among them, when the computing device 10 is integrated into the touch device 20, an interactive electronic whiteboard system can be formed.

[0028] The touch device 20 can be any intelligent terminal including a touch screen, such as a computer, a mobile phone, a tablet computer, an interactive tablet, etc. Figure 1In the corresponding embodiment, the touch device 20 is an interactive tablet, especially an interactive tablet with a large-sized touch screen. Optionally, the touch screen has the characteristics of large screen size, multi-touch, high resolution, strong sensitivity and response speed, pen support, etc. Among them, for example, the screen size can be larger than 10 inches, so that users can touch and write input on a larger display space. The touch screen has a multi-touch function and can recognize and respond to multiple touch points at the same time, so that users can use multi-finger gestures to perform complex operations, such as zooming, rotating, etc. The touch screen also has a high resolution and provides a clear and delicate display effect. The touch screen also has the characteristics of high sensitivity and fast response to capture the user's touch input and quickly convert it into corresponding operations or graphics. The touch screen also supports a stylus or other writing input tools (such as Figure 1 The writing device 30 shown in the figure) can be a capacitive touch screen, which uses capacitive sensing to detect touch input. When a user touches the screen, a capacitance is formed between the finger and the conductive layer, and this change is detected by the sensor, and the touch position is determined. The touch screen can also be an infrared touch screen, which uses an infrared sensor to detect touch input. It places a set of infrared transmitters and receivers on the frame of the screen. When the user touches the screen, the touch point blocks the infrared light, which is detected by the receiver and the touch position is determined.

[0029] The writing device 30 may include a writing module and a writing mobile device. The writing module is disposed on the writing mobile device. The writing module faces the touch screen of the touch device 20. When the writing module contacts the touch screen, the writing module forms writing traces on the touch screen as the writing mobile device moves. During the writing process, the touch device 20 may obtain the writing position coordinates of the writing mobile device and the writing sampling point coordinates of the touch screen. The touch device 20 may upload the obtained writing position coordinates of the writing mobile device and the writing sampling point coordinates of the touch screen to the computing device 10. The writing position coordinates of the writing mobile device refer to the actual position coordinates of the writing device 30 on the touch screen, and the writing sampling point coordinates of the touch screen refer to the touch position coordinates recorded by the touch screen within a specific time interval.

[0030] The writing sampling point coordinates of the touch screen may be touch input data captured and recorded by the touch screen. The touch screen usually detects touch input through different technologies (such as capacitive touch screen, resistive touch screen, ultrasonic touch screen, infrared touch screen, etc.) and samples the touch position at a specific time interval.

[0031] In the embodiments of the present application, Figure 1As shown, the preset writing trajectory obtained by the computing device 10 is directly transmitted to the writing device 30, for example, the preset writing trajectory is converted into GCode, and then the GCode is given to the writing device 30 through a serial port, USB, SD card, etc. After obtaining the preset writing trajectory, the writing device 30 writes the preset writing trajectory on the touch device 20 according to the execution order of the preset writing trajectory, thereby generating a test trajectory. The generated test trajectory can be transmitted to the computing device 10 by the touch device 20, and the computing device 10 is used to calculate the difference between the test trajectory and the preset writing trajectory, and detect the writing input effect of the touch device according to the difference. The embodiment of the present application can be used to evaluate the accuracy and consistency of the writing input of the touch device 20. By comparing the test trajectory with the preset writing trajectory, the writing input effect of the touch device 20 can be quantified, such as accuracy, offset, etc. The computing device 10 can analyze the difference and provide information about the writing input performance of the touch device 20.

[0032] In some embodiments, the computing device 10 and the touch control device 20 may also be in the form of an integrated machine, and are not limited to Figure 1 As shown. The all-in-one machine can be a device that integrates a computing device and a touch screen, and has computing capabilities and direct touch input interaction functions. In addition, Figure 1 The writing device 30 shown is also only an example, and the writing device 30 may also be presented in other ways, such as a stylus pen, a digital pen, a smart stylus, a finger or a palm, etc.

[0033] The writing input effect detection method of the touch device applied to the writing input effect detection system of the touch device is described in detail below. The writing input effect detection method of the touch device can be executed by the computing device 10 or by an integrated machine integrating a computing device and a touch screen.

[0034] See also Figure 2 , Figure 2 1 is a flow chart of a method for detecting writing input effect of a touch device provided in an embodiment of the present application. Figure 2 As shown, the method includes:

[0035] S11, obtaining a preset writing trajectory.

[0036] The preset writing trajectory refers to a predefined or pre-set handwriting path or stroke, etc. Depending on the specific application and requirements, the preset writing trajectory can be in various forms, including but not limited to: the writing trajectory of letters or numbers: for example, simulating the writing trajectory of the letter A or the writing trajectory of the number 1. The writing trajectory of strokes: for example, simulating the writing trajectory of Chinese characters, the preset writing trajectory can simulate the order and shape of the strokes of Chinese characters. The writing trajectory of the signature: can be composed of at least one of letters, numbers, and Chinese characters. The writing trajectory of geometric shapes: for example, geometric shapes such as circles, squares, or arrows.

[0037] GCode can be used to create the preset writing trajectory. GCode is a control instruction language commonly used in CNC machine tools (such as 3D printers, CNC milling machines, etc.), which is used to describe the motion trajectory and operation instructions of the machine tool. Although GCode is mainly used for machine tool control, it can also be applied to other fields that require trajectory control, such as simulating handwriting trajectory. The following are GCode instructions that can be used to create the preset writing trajectory:

[0038] G0 / G1: For linear motion, you can use this command to define the path of the handwriting trajectory, determine the starting and ending points of the handwriting, and control the lifting and lowering of the pen. G2 / G3: For circular motion, if the preset writing trajectory includes a curve part, this command can be used to define the starting point, end point, center point and direction of the arc. G4: For delay, you can use this command to add a delay during the writing process to control the pen's dwell time or simulate the speed of handwriting. G90 / G91: For setting the coordinate mode, you can select the appropriate coordinate mode to define the writing trajectory. M3 / M5: For controlling the opening and closing of the pen.

[0039] The steps of creating the preset writing trajectory according to the GCode technology may include: creating a text file for storing the GCode sequence; setting a coordinate system, which is used by GCode to describe the position and movement, and the coordinate system may be an absolute coordinate system or a relative coordinate system; setting the initial position, which requires moving the writing device to the desired initial position before writing, which can be achieved by specifying coordinate values, for example, using the GCode command G0 / G1 to move to the initial position; controlling the writing speed, which can use the GCode command to set the feed speed; describing the writing trajectory, which can use the GCode command to describe the movement of a straight line or arc; controlling the writing action, which can use the GCode command to control the up, down, left, right, etc. of the writing tool; ending the writing, which can use the GCode command to move the writing device to the specified end position or return to the initial position. The GCode commands used in the above process are all recorded in the created text file to form a GCode file. Thus, the preset writing trajectory is represented by a GCode file.

[0040] Other methods may also be used to establish the preset writing trajectory. For example, when establishing the writing trajectory, an interpolation algorithm is used to calculate the middle points between a given starting point and an end point, and these points are connected in a smooth manner to generate a continuous trajectory.

[0041] Optionally, the preset writing trajectory may be displayed on the touch screen of the touch device for user reference.

[0042] S12. Obtain a test track corresponding to the preset writing track, wherein the test track is generated when the writing device writes on the touch device according to the preset writing track.

[0043] Among them, obtaining the test trajectory corresponding to the preset writing trajectory includes: generating instructions executable by the writing device according to the preset writing trajectory; sending the instructions to the writing device so that the writing device performs writing operations according to the instructions; obtaining the test trajectory generated when the writing device writes on the touch device according to the instructions.

[0044] Specifically, the preset writing trajectory can be converted into a GCode file in GCode format; the GCode instruction is executed to load the GCode file into the writing device, and the writing device is controlled to start the writing process; the writing device performs the writing operation according to the GCode file; and the test trajectory generated by the writing device when writing on the touch device according to the GCode file is obtained.

[0045] The detailed process of converting the preset writing trajectory into a GCode file in GCode format may refer to the above steps.

[0046] Among them, the preset writing trajectory can be written by the above-mentioned writing device. The writing device moves according to the shape and path of the preset writing trajectory, and simulates a similar writing effect on the touch screen of the touch device, so that a writing effect consistent with or similar to the preset writing trajectory can be generated on the touch device. Specifically, first, the writing device obtains the GCode file corresponding to the preset writing trajectory, and then the writing device reads and parses the GCode file to obtain the GCode instructions, and then interprets each GCode instruction one by one, and converts it into a motion instruction that the writing device can understand, such as the rotation angle of the stepper motor or the moving distance of the linear axis. Then based on the parsed motion instructions, the writing device controls the relevant actuators (such as electric pens, pen holders, stepper motors, etc.) to perform corresponding movements, and these movements will cause the writing device to generate the current writing trajectory on the touch device, and the writing trajectory is also the test trajectory. At the same time, the preset writing trajectory can be displayed on the touch device, and the trajectory written by the above-mentioned writing device will be synchronized with the preset writing trajectory displayed on the touch device as much as possible. The movement of the writing device will reproduce the preset writing trajectory on the touch device as accurately as possible according to the GCode instructions and the characteristics of the device itself.

[0047] In addition to the above writing devices, electronic pens, robot arms, etc. can also be used to write the preset writing trajectory. The electronic pen can write the preset writing trajectory by controlling the position and pressure of the pen. For the robot arm, the position and motion trajectory of its end effector can be controlled to write the preset writing trajectory.

[0048] The writing result of the preset writing trajectory can obtain the test trajectory, which includes a number of test points. In this process, the coordinates of the test points on the touch screen of the touch device can also be obtained and recorded.

[0049] Among them, the preset writing track provided to the writing device is the actual physical coordinate based on the display screen. The touch device is the logical coordinate relative to the display screen. Before comparing the preset writing track with the test track, the logical coordinates reported by the touch device can be converted into the actual physical coordinates based on the display screen, and then the difference comparison is performed. Specifically, when the writing device is writing, the coordinates of the test points of the test track generated by it are defined relative to the actual physical coordinate system of the display screen. The display screen is regarded as the reference of the coordinate system, and the position and movement of the writing device are determined relative to the position of the display screen. The touch device (such as a touch screen) uses a logical coordinate system, which means that the touch screen converts the touch input of the writing device into an abstract coordinate system relative to the display screen, that is, a logical coordinate. The logical coordinates can be pixel coordinates or other abstract coordinate units, and do not have to correspond exactly to the actual physical size. Before comparing the preset writing track with the test track, the parameters of the touch device can be used to convert the logical coordinates reported by the touch device into the same actual physical coordinates as the writing device. In this way, comparison and analysis can be performed under the same coordinate system to ensure accuracy and consistency. Among them, the display screen refers to a specific display device used in conjunction with a writing device or a touch device, which can be a computer screen or other similar device screen. The display screen may specifically be a touch screen of a touch device.

[0050] When the touch screen is a capacitive screen, obtaining the coordinates of the test point of the test track on the touch screen includes: registering a touch event, by registering a touch event listener or handler to capture the touch event; monitoring the touch event, including touch press, touch move and touch release, etc.; when a touch event occurs, the coordinates of the touch point can be obtained from the event data.

[0051] When the touch screen is an infrared screen, obtaining the coordinates of the test points of the test track on the touch screen includes: registering infrared touch events, similar to capacitive screens, and registering infrared touch event listeners or handlers in the application to capture touch events; monitoring touch events, including touch press, touch move, and touch release; when an infrared touch event occurs, the coordinates of the touch point can be obtained from the event data.

[0052] The event data contains information about multiple touch points. For each touch point, the event data will provide corresponding coordinate information, which may include X and Y coordinate values ​​to indicate the position of the touch point on the screen. The above method of obtaining the coordinates of the touch point from the event data may vary depending on the operating system and programming language. For example, in Android, the information of the touch event can be obtained through the MotionEvent object, including the number of touch points and the coordinates of each touch point. The getX() and getY() methods can be used to obtain the X and Y coordinate values ​​of each touch point.

[0053] In the embodiments of the present application, the movement trajectory and position information of the writing device on the touch device can be obtained, and the recorded coordinates can be used for further analysis, visualization, or regeneration of the writing trajectory, as well as for other related data processing and applications.

[0054] For example, as Figure 3 shown, the black trajectory without points is "written" as the preset writing trajectory, and another trajectory including points and connecting lines is "written" as the test trajectory of writing. Figure 3 The abscissa and ordinate in [reference] can specifically be the abscissa and ordinate of the touch screen. In this coordinate system, the coordinates of each test point on the test trajectory can be recorded.

[0055] S13. Calculate the difference between the test trajectory and the preset writing trajectory.

[0056] Calculating the difference between the test trajectory and the preset writing trajectory can be achieved by comparing their positions, shapes, or other related features.

[0057] Wherein, if the difference is a position difference, the distance between each test point on the test trajectory and the corresponding point on the preset writing trajectory can be calculated. A larger distance indicates a greater difference in position between the test trajectory and the preset writing trajectory. Among them, the Euclidean distance or Manhattan distance can be used to measure the position difference.

[0058] Wherein, if the difference is a shape difference, the difference between the shape of the test trajectory and the shape of the preset writing trajectory can be compared. If the test trajectory deviates greatly from the preset writing trajectory in shape, it indicates a large difference in shape between the test trajectory and the preset writing trajectory. Among them, it can be achieved by calculating the curvature, angle, or other geometric features of the curve. Specifically, for example, the three-point method is used to calculate the curvature. By selecting two adjacent points at each point and then using the curvature formula for calculation, a larger curvature difference indicates a difference in the degree of bending between the test trajectory and the preset writing trajectory. The angle difference between the test trajectory and the preset writing trajectory can also be calculated, which can be achieved by selecting adjacent line segments on the curve and calculating the included angle between them. A larger angle difference indicates that the test trajectory deviates from the preset trajectory in direction.

[0059] Wherein, if the difference is a time difference. In this embodiment, the test trajectory is a real-time simulation based on the preset writing trajectory, and the time difference between the two can be compared. Specifically, the generation time of each test point and the expected time of the corresponding point on the preset writing trajectory can be compared. If there is a large time difference between the corresponding times of the two, it may indicate a speed change or time delay during the simulation process. For example, the generation of the test trajectory lags behind the preset writing trajectory in time.

[0060] The difference is the pressure difference. When the writing device has pressure sensitivity, the difference between the pressure value on the test track and the expected pressure on the preset writing track can be compared. A large difference may indicate a pressure control problem during the simulation or a performance difference of the writing device.

[0061] Among them, the difference can also be a weighted value or average value of the above-mentioned position difference, shape difference, time difference and pressure difference. In order to comprehensively consider the position difference, shape difference, time difference and pressure difference, their weighted value or average value can be calculated to obtain a comprehensive difference measurement. In this way, different types of differences can be taken into account and given different importance. Specifically, a weight or weight coefficient can be defined for each difference type to indicate its relative importance. Then, for each test point, its position difference, shape difference, time difference and pressure difference are multiplied by the corresponding weight, and they are weighted summed, or their average value is calculated. The weight factor can be determined according to the needs of the specific application and the importance of the difference type.

[0062] In some embodiments, the test track includes a plurality of test points, and the plurality of test points form a test point sequence, such as Figure 4 As shown, the calculating the difference between the test track and the preset writing track includes:

[0063] S131. Obtain a mapping ratio coefficient according to the preset writing trajectory and the test trajectory.

[0064] Among them, Figure 5 As shown, the step of obtaining a mapping ratio coefficient according to the preset writing trajectory and the test trajectory includes:

[0065] S1311, calculating the first track length of each stroke in the preset writing track;

[0066] S1312, calculating the second track length of each stroke in the test track;

[0067] S1313: Select a first track length and a second track length corresponding to the same stroke, and calculate a ratio of the first track length to the second track length, where the ratio is a mapping proportional coefficient corresponding to the same stroke.

[0068] Among them, the Euclidean distance between two adjacent points on a stroke on the preset writing trajectory can be calculated, and then all the Euclidean distances are added together to obtain the length of the stroke. Similarly, the length of the stroke of the test trajectory can also be calculated in this way.

[0069] Since the test track is obtained by writing the preset writing track, there are corresponding identical strokes between the two. The ratio of the length of the first track to the length of the second track corresponding to the identical stroke is calculated, and the ratio is the mapping ratio coefficient of the stroke. The mapping ratio coefficient is used to describe the mapping relationship between the test track and the preset writing track in terms of length.

[0070] For example, assuming that in the preset writing trajectory, the length of the first trajectory of a stroke is L1, and in the test trajectory, the length of the second trajectory of the corresponding stroke is L2, then the mapping ratio coefficient is L1 / L2. If L1 / L2=1, it means that the length of the first trajectory of the preset writing trajectory is equal to the length of the second trajectory of the test trajectory; if L1 / L2<1, it means that the length of the first trajectory of the preset writing trajectory is shortened in the test trajectory; if L1 / L2>1, it means that the length of the first trajectory of the preset writing trajectory is lengthened in the test trajectory.

[0071] The definition of the mapping ratio coefficient can be used to understand the correspondence between the preset writing trajectory and the test trajectory in length. By calculating the mapping ratio coefficients of different strokes, the length mapping between the two trajectories can be evaluated, and then their similarities or differences in overall shape can be understood.

[0072] S132: Obtain a mapping point sequence according to the mapping ratio coefficient and the test point sequence.

[0073] Specifically, Figure 6 As shown, obtaining a mapping point sequence according to the mapping ratio coefficient and the test point sequence includes:

[0074] S1321, obtaining a preprocessed test point sequence;

[0075] The preprocessing includes removing repeated points and discrete points in the test point sequence, thereby improving the consistency and continuity of the data.

[0076] S1322, taking the starting point of the preset writing trajectory as the starting point of the mapping point sequence;

[0077] The starting point of the preset writing track refers to the starting position or starting point of the track during the writing or drawing process, which indicates the starting position of the writing or drawing, at a specific position on the screen.

[0078] S1323, calculating the distance between the current test point and the previous test point based on the preprocessed test point sequence;

[0079] If the current test point is the first point of the test point sequence, that is, its starting point, then the distance between the current test point and its previous test point is zero. Starting from the second point of the test point sequence, calculate the distance between the current test point and its previous test point, which can be the Euclidean distance of the two points. And so on, until the distances between all test points in the test point sequence and their previous test points are obtained. Among them, the arrangement order of the test points in the test point sequence is the same as the moving direction of the test trajectory. Among them, in addition to the Euclidean distance, the distance between two adjacent points can also be measured using other metrics, such as Manhattan distance. The distance metric can choose an appropriate method to calculate the distance between two adjacent points according to the specific problem and data characteristics.

[0080] S1324, calculating a mapping distance corresponding to the distance according to the distance and a mapping ratio coefficient of the stroke corresponding to the current test point;

[0081] For example, the midpoint pt in the test point sequence k To the previous point pt k-1 The distance is dt k , the mapping distance of this distance on the preset stroke is ds k =dt k *S, S is the mapping ratio coefficient corresponding to the preset stroke. Wherein, the mapping distance is the product of the distance and the mapping ratio coefficient, and the mapping ratio coefficient is the mapping ratio coefficient corresponding to the stroke where the current test point is located.

[0082] The mapping distances corresponding to all the distances can be calculated and obtained by the above method.

[0083] S1325. Intercept a line segment of the mapping distance on the preset writing trajectory corresponding to the stroke, and determine an end point of the line segment as a mapping point of the current test point on the preset writing trajectory.

[0084] Among them, taking the last point in the mapping point sequence as the starting point, intercept a length of ds on the preset writing stroke k The end point of the line segment is pt s That is the test point pt k At the mapping point on the preset writing stroke, change pt s Add to the end of the mapping point sequence.

[0085] The starting point of the preset writing trajectory is used as the starting point of the mapping point sequence. If the mapping point sequence does not currently include other mapping points, the starting point is also the end point. That is, the starting point of the preset writing trajectory is used as the starting point, and a length of ds is intercepted on the preset stroke. k The end point of the line segment is pt sThis is the second point in the mapping point sequence. When looking for the next mapping point, this pt is used. s As the starting point, a line segment with a length of the corresponding mapping distance is intercepted on the preset writing stroke, and the end point of the line segment is the second mapping point, and so on, so as to find all the mapping points, and all the mapping points constitute a mapping point sequence.

[0086] Repeat the above steps S1323 to S1325 until all the test points in the preprocessed test point sequence obtain corresponding mapping points.

[0087] In this embodiment, firstly, by preprocessing the test point sequence and removing duplicate points and discrete points, the quality and continuity of the data can be improved, so as to ensure the accuracy of subsequent mapping calculations and results. Secondly, by taking the starting point of the preset writing trajectory as the starting point of the mapping point sequence, the alignment of the starting point can be achieved, which helps to ensure that the mapping point sequence is consistent with the shape and direction of the preset writing trajectory and maintain overall consistency. Furthermore, according to the distance between the current test point and the previous test point, combined with the mapping ratio coefficient of the stroke corresponding to the current test point, the mapping distance corresponding to the distance is calculated, so that the distance of the test trajectory can be mapped to the preset writing trajectory according to the characteristics of the stroke and the mapping ratio, so as to achieve the transformation and mapping of the trajectory. Finally, according to the calculated mapping distance, the corresponding line segment is intercepted on the preset writing trajectory, and the end point of the line segment is taken as the mapping point of the current test point on the preset writing trajectory, so that the position of the test trajectory can be accurately mapped to the preset writing trajectory, and the mapping point matching the preset trajectory can be obtained. In general, this method realizes the process of mapping the test points to the preset writing trajectory through steps such as preprocessing, starting point alignment, distance mapping and line segment interception. This method has the advantages of accuracy, consistency and controllability, and can effectively perform trajectory mapping and comparative analysis.

[0088] S133. Based on the test point sequence and the mapping point sequence, respectively calculate a metric value between each test point and its corresponding mapping point.

[0089] Wherein, based on the test point sequence and the mapping point sequence, the distance or the square of the distance between each test point and its corresponding mapping point can be calculated respectively, and the distance or the square of the distance is the metric value.

[0090] S134. Calculate the mean of all measurement values, where the mean is used to measure the difference between the test trajectory and the preset writing trajectory.

[0091] In this embodiment, by calculating the distance or the square of the distance between each test point and its corresponding mapping point, and calculating the mean of all metric values, the difference between the entire test track and the preset writing track can be comprehensively considered. This method does not only focus on the difference of a single point, but quantifies the difference of the entire track into a unified metric value. In addition, the distance or the square of the distance is used as an indicator to measure the difference, which can reflect the degree of closeness or deviation between the test track and the preset writing track. A smaller distance or the square of the distance indicates that the test track is closer to the preset writing track, while a larger value indicates that the difference between them is larger. This method is more sensitive to the change of the difference and can more accurately reflect the degree of difference between the tracks.

[0092] like Figure 7 As shown, the preset writing track, the test track, and the mapping relationship and distance between the test point and the mapping point on the preset writing track are shown. The mapping relationship and distance can reflect the difference between the test track and the preset writing track.

[0093] S14: Detecting a writing input effect of the touch device according to the difference.

[0094] The difference between each stroke corresponding to the test track and the preset writing track can be obtained; the average of the differences of all the strokes is calculated to obtain the total difference; the total difference is compared with the preset threshold to determine the writing input effect of the touch device. If the total difference is less than the preset threshold, it means that the writing input effect of the touch device is ideal; otherwise, the writing input effect of the touch device may not be ideal.

[0095] Among them, the above-mentioned preset threshold can be determined according to the application scenario, user needs and the standard of the preset writing trajectory. For example, if highly accurate writing input is required, the threshold should be relatively small; if a certain error or change is tolerated, the threshold can be relatively large. In addition, different users may have different acceptance levels for errors or differences in writing input. Therefore, the value of the threshold can be determined by considering the user's expectations and tolerance. Specifically, relevant data can be collected through user surveys, experiments or feedback to better understand the user's expectations and tolerance. Furthermore, actual testing and evaluation can be carried out to collect a certain amount of test trajectory data and preset writing trajectory data, and calculate their difference metrics, observe the test results under different difference metric values, and determine the value of the threshold according to the actual situation. It can be comprehensively considered based on the distribution of test data, statistical indicators and consistency with user feedback. Optionally, the preset threshold can be appropriately adjusted according to actual needs, and continuous optimization and improvement are important steps to ensure the rationality of the preset threshold.

[0096] In some embodiments, if the writing input effect of the touch device is not ideal, the interactive design can be optimized to improve the user's writing experience and input accuracy, for example, consider improving the interface layout, adjusting the sensitivity of the handwriting, optimizing gesture recognition, etc., to provide a more intuitive, flexible and easy-to-use writing input method. It is also possible to actively collect user feedback and opinions to understand the problems and confusions they encounter when using touch devices for writing input. User testing and user surveys can be conducted to gain a deep understanding of user needs and expectations, and make corresponding improvements based on feedback.

[0097] The writing input effect detection method of the touch device provided in the embodiment of the present application measures the difference between each test point and its corresponding mapping point by calculating the metric value, thereby measuring the difference between their corresponding trajectories, and this difference reflects the degree of deviation of the test trajectory from the preset writing trajectory. Among them, the metric value reflects the difference in shape, position, proportion, etc. of the test trajectory relative to the preset writing trajectory. The smaller the metric value or the smaller the mean, the smaller the difference between the test trajectory and the preset writing trajectory.

[0098] See also Figure 8 , Figure 8 2 is a structural block diagram of a writing input effect detection device 20 for a touch device provided in an embodiment of the present application. Figure 8 As shown, the writing input effect detection device 20 of the touch device includes:

[0099] A preset writing track acquisition module 21, used to acquire a preset writing track;

[0100] A test track acquisition module 22, used to acquire a test track corresponding to the preset writing track, wherein the test track is generated when the writing device writes on the touch device according to the preset writing track;

[0101] A trajectory difference calculation module 23, used to calculate the difference between the test trajectory and the preset writing trajectory;

[0102] The writing input effect detection module 24 is used to detect the writing input effect of the touch device according to the difference.

[0103] Among them, the test trajectory includes a number of test points, and the number of test points constitute a test point sequence. The trajectory difference calculation module 23 is specifically used to: obtain a mapping ratio coefficient according to the preset writing trajectory and the test trajectory; obtain a mapping point sequence according to the mapping ratio coefficient and the test point sequence; based on the test point sequence and the mapping point sequence, respectively calculate the measurement value between each test point and its corresponding mapping point; calculate the mean of all measurement values, and the mean is used to measure the difference between the test trajectory and the preset writing trajectory.

[0104] Among them, obtaining the mapping ratio coefficient according to the preset writing trajectory and the test trajectory includes: calculating the first trajectory length of each stroke in the preset writing trajectory; calculating the second trajectory length of each stroke in the test trajectory; selecting the first trajectory length and the second trajectory length corresponding to the same stroke, and calculating the ratio of the first trajectory length to the second trajectory length, and the ratio is the mapping ratio coefficient corresponding to the same stroke.

[0105] Among them, the step of obtaining a mapping point sequence according to the mapping ratio coefficient and the test point sequence includes: obtaining a preprocessed test point sequence; taking the starting point of the preset writing trajectory as the starting point of the mapping point sequence; calculating the distance between a current test point and a previous test point based on the preprocessed test point sequence; calculating a mapping distance corresponding to the distance according to the distance and the mapping ratio coefficient of the stroke corresponding to the current test point; intercepting a line segment of the mapping distance on the preset writing trajectory corresponding to the stroke, and determining the end point of the line segment as the mapping point of the current test point on the preset writing trajectory; repeating the above steps of calculating the distance between the current test point and the previous test point, calculating the mapping distance according to the distance and the mapping ratio coefficient, and obtaining a mapping point according to the mapping distance, until all test points in the preprocessed test point sequence obtain corresponding mapping points, wherein all mapping points constitute the mapping point sequence.

[0106] The calculating of the metric value between each test point and its corresponding mapping point based on the test point sequence and the mapping point sequence includes: calculating the distance or the square of the distance between each test point and its corresponding mapping point based on the test point sequence and the mapping point sequence.

[0107] Among them, the test trajectory acquisition module 22 is specifically used to: generate instructions executable by the writing device according to the preset writing trajectory; send the instructions to the writing device so that the writing device performs writing operations according to the instructions; and obtain the test trajectory generated when the writing device writes on the touch device according to the instructions.

[0108] Optionally, the test trajectory acquisition module 22 is also used to obtain the coordinate information of the test point corresponding to the test trajectory on the touch screen of the touch device; wherein, when the writing device writes on the touch device according to the instruction, the touch device records the coordinate information of the test point generated during the writing process.

[0109] Among them, the writing input effect detection module 24 is specifically used to: obtain the difference between each stroke corresponding to the test trajectory and the preset writing trajectory; calculate the mean of the differences of all strokes to obtain the total difference; compare the total difference with the preset threshold to determine the writing input effect of the touch device.

[0110] It should be noted that the writing input effect detection device of the touch device can execute the writing input effect detection method of the touch device provided in the embodiment of the present application, and has the corresponding functional modules and beneficial effects of the execution method. For technical details not fully described in the embodiment of the writing input effect detection device of the touch device, please refer to the writing input effect detection method of the touch device provided in the embodiment of the present application.

[0111] Fig. 9 is a schematic diagram of the hardware structure of an electronic device provided in an embodiment of the present application, and the electronic device can be used to execute the writing input effect detection method of the touch device in the above embodiment. Fig. 9 As shown, the electronic device 30 includes: one or more processors 31 and a memory 32, Fig. 9 A processor 31 is taken as an example.

[0112] The processor 31 and the memory 32 may be connected via a bus or other means. Fig. 9 The example of connecting through bus is taken in the following.

[0113] The memory 32 is a non-volatile computer-readable storage medium that can be used to store non-volatile software programs, non-volatile computer executable programs and modules, such as program instructions / modules corresponding to the writing input effect detection method of the touch device in the embodiment of the present application. The processor 31 executes various functional applications and data processing of the electronic device by running the non-volatile software programs, instructions and modules stored in the memory 32, that is, the writing input effect detection method of the touch device in the above method embodiment is realized.

[0114] The memory 32 may include a program storage area and a data storage area, wherein the program storage area may store an operating system and applications required by at least one function; the data storage area may store data created according to the use of the writing input effect detection device of the touch device, etc. In addition, the memory 32 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, or other non-volatile solid-state storage device. In some embodiments, the memory 32 may optionally include a memory remotely arranged relative to the processor 31, and these remote memories may be connected to the writing input effect detection device of the touch device via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.

[0115] The one or more modules are stored in the memory 32, and when executed by the one or more processors 31, the writing input effect detection method of the touch device in any of the above method embodiments is executed, for example, the writing input effect detection method described above is executed. Figure 2, Figure 4 , Figure 5 , Figure 6 Steps to achieve Figure 8 The functions of the modules in .

[0116] The above-mentioned product can execute the method provided in the embodiment of the present application, and has the functional modules and beneficial effects corresponding to the execution method. For technical details not fully described in this embodiment, please refer to the method provided in the embodiment of the present application.

[0117] The electronic devices of the embodiments of the present application exist in various forms, including but not limited to: mobile communication devices, ultra-mobile personal computer devices, servers, and other electronic devices with data interaction functions.

[0118] The embodiment of the present application provides a non-volatile computer-readable storage medium, wherein the non-volatile computer-readable storage medium stores computer-executable instructions, and the computer-executable instructions are executed by one or more processors, such as Fig. 9 A processor 31 in the embodiment may enable the one or more processors to execute the writing input effect detection method of the touch device in any of the above method embodiments, for example, to execute the above described Figure 2 , Figure 4 , Figure 5 , Figure 6 Steps to achieve Figure 8 The functions of the modules in .

[0119] The present application provides a computer program product, wherein the computer program product includes a computer program stored on a non-volatile computer-readable storage medium, wherein the computer program includes program instructions, and when the program instructions are executed by the electronic device, the electronic device is enabled to execute the writing input effect detection method of the touch device in any of the above method embodiments, for example, executing the above described Figure 2 , Figure 4 , Figure 5 , Figure 6 Steps to achieve Figure 8 The functions of the modules in .

[0120] The device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place, or may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0121] Through the description of the above implementation methods, ordinary technicians in this field can clearly understand that each implementation method can be implemented by means of software plus a general hardware platform, and of course, it can also be implemented by hardware. Ordinary technicians in this field can understand that all or part of the processes in the above-mentioned embodiment method can be completed by instructing related hardware through a computer program, and the program can be stored in a computer-readable storage medium. When the program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, the storage medium can be a disk, an optical disk, a read-only memory (ROM) or a random access memory (RAM), etc.

[0122] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them. Under the concept of the present application, the technical features in the above embodiments or different embodiments can also be combined, the steps can be implemented in any order, and there are many other changes in different aspects of the present application as described above, which are not provided in detail for the sake of simplicity. Although the present application has been described in detail with reference to the aforementioned embodiments, a person of ordinary skill in the art should understand that the technical solutions described in the aforementioned embodiments can still be modified, or some of the technical features can be replaced by equivalents. These modifications or replacements do not deviate the essence of the corresponding technical solutions from the scope of the technical solutions of the embodiments of the present application.

Claims

1. A method for detecting writing input effect of a touch device, characterized in that: include: Get the preset writing track; Acquire a test track corresponding to the preset writing track, wherein the test track is generated when the writing device writes on the touch device according to the preset writing track; Calculating the difference between the test track and the preset writing track; The writing input effect of the touch device is detected according to the difference.

2. The method according to claim 1, characterized in that The test track includes a plurality of test points, the plurality of test points form a test point sequence, and the calculating the difference between the test track and the preset writing track includes: Obtaining a mapping ratio coefficient according to the preset writing trajectory and the test trajectory; Obtaining a mapping point sequence according to the mapping scale coefficient and the test point sequence; Based on the test point sequence and the mapping point sequence, respectively calculating a metric value between each test point and its corresponding mapping point; The mean of all the measurement values ​​is calculated, and the mean is used to measure the difference between the test track and the preset writing track.

3. The method according to claim 2, characterized in that The obtaining of a mapping ratio coefficient according to the preset writing trajectory and the test trajectory includes: Calculating a first track length of each stroke in the preset writing track; Calculating the second trajectory length of each stroke in the test trajectory; A first track length and a second track length corresponding to the same stroke are selected, and a ratio of the first track length to the second track length is calculated, where the ratio is a mapping proportional coefficient corresponding to the same stroke.

4. The method according to claim 2, characterized in that: The obtaining of a mapping point sequence according to the mapping scale coefficient and the test point sequence comprises: Get the preprocessed test point sequence; Taking the starting point of the preset writing trajectory as the starting point of the mapping point sequence; Based on the preprocessed test point sequence, calculating the distance between the current test point and the previous test point; Calculate a mapping distance corresponding to the distance according to the distance and a mapping ratio coefficient of the stroke corresponding to the current test point; intercepting a line segment of the mapping distance on a preset writing trajectory corresponding to the stroke, and determining an end point of the line segment as a mapping point of the current test point on the preset writing trajectory; Repeat the above steps of calculating the distance between the current test point and the previous test point, calculating the mapping distance according to the distance and the mapping ratio coefficient, and obtaining the mapping point according to the mapping distance, until all the test points in the preprocessed test point sequence obtain corresponding mapping points, wherein all the mapping points constitute the mapping point sequence.

5. The method according to claim 2, characterized in that: The calculating, based on the test point sequence and the mapping point sequence, respectively the metric value between each test point and its corresponding mapping point comprises: Based on the test point sequence and the mapping point sequence, the distance or the square of the distance between each test point and its corresponding mapping point is calculated respectively.

6. The method according to any one of claims 1 to 5, characterized in that: The obtaining of a test track corresponding to the preset writing track includes: Generating instructions executable by the writing device according to the preset writing trajectory; Sending the instruction to the writing device so that the writing device performs a writing operation according to the instruction; A test track generated when the writing device writes on the touch device according to the instruction is obtained.

7. The method according to claim 6, characterized in that The method further comprises: The coordinate information of the test point corresponding to the test track on the touch screen of the touch device is obtained; wherein, when the writing device writes on the touch device according to the instruction, the touch device records the coordinate information of the test point generated during the writing process.

8. The method according to claim 1, characterized in that The detecting the writing input effect of the touch device according to the difference includes: Obtaining the difference between each stroke corresponding to the test trajectory and the preset writing trajectory; Calculate the mean of the differences of all strokes to obtain the total difference; The total difference is compared with a preset threshold to determine the writing input effect of the touch device.

9. A writing input effect detection device for a touch device, characterized in that: include: A preset writing trajectory acquisition module, used to acquire a preset writing trajectory; A test track acquisition module, used to acquire a test track corresponding to the preset writing track, wherein the test track is generated when the writing device writes on the touch device according to the preset writing track; A trajectory difference calculation module, used to calculate the difference between the test trajectory and the preset writing trajectory; The writing input effect detection module is used to detect the writing input effect of the touch device according to the difference.

10. An electronic device, characterized in that: include: at least one processor; as well as, a memory communicatively connected to the at least one processor; wherein, The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform the method according to any one of claims 1 to 8.