Edge printing method and device based on visual calibration and electronic equipment
Through the edge printing method based on visual calibration, the position and edge profile of the display module are identified and calibrated, and the problems of size differences and position errors in printing technology are solved, which improves the protection effect of the middle frame and reduces production costs.
Patent Information
- Application Number
- CN202411670991.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-21
- Publication Date
- 2025-03-14
- Estimated Expiration
- 2044-11-21
AI Technical Summary
When printing the edge profile of the product using printing technology, there are dimensional differences and position errors caused by production errors, which affect the waterproof, dustproof and support protection effects of the middle frame. Display modules of different sizes require different middle frame molds, which increases production costs.
The edge printing method based on visual calibration is adopted, by obtaining the product image of the product to be printed, identifying the actual and theoretical position coordinates of the feature points, calculating the position offset information, adjusting the mobile stage and the printing path, and realizing the error calibration of the edge profile.
The calibration of the overall position offset error and edge profile error of the printed product is realized, the tight fit between the middle frame and the display module is improved, the waterproof, dustproof and support protection effects are enhanced, and the production cost is reduced.
Smart Images

Figure CN119620967A_ABST
Abstract
Description
Technical Field
[0001] Multiple embodiments of the present specification relate to the field of printing technology, and specifically to an edge printing method and device based on visual calibration, and an electronic device. Background Art
[0002] As a device that can provide image display function, the display module is widely used in various display devices. The display module includes glass cover, display panel, flexible circuit board and other components. It is relatively fragile and can be easily damaged by external impact. Therefore, it is necessary to set a middle frame at the outer edge contour of the display module to protect the display module.
[0003] The current mainstream solution is to use mold injection molding to achieve this. First, the middle frame is injection molded through a mold, and then the middle frame is clamped to the display module. The actual size of the middle frame produced in this way may deviate from the size of the display module, so that the middle frame cannot fit tightly with the display module, which leads to poor waterproof, dustproof and supporting protection effects of the middle frame. In addition, different sizes of display modules require different middle frame molds, which makes the production cost of the middle frame high.
[0004] At present, there is also a method of making the middle frame through printing technology. In this method, you only need to preset the corresponding printing route according to the screen size, and print according to the preset printing route, which can adapt to display modules of different sizes. In order to improve the efficiency of middle frame production, the display module is usually fixed on the carrier, and printed according to the preset printing route through the printing system, and display modules of the same design size are printed using the same preset printing route. However, even display modules of the same design size have certain production errors in the production process. Therefore, the edge contours of display modules of the same design size also have certain differences, and the position of the middle frame needs to maintain a preset distance from the edge contour of the display module to ensure the product quality of the display module. In addition, the display module is fixed on the carrier, and there may be certain errors in the fixed position of the display module.
[0005] The above problems exist in the production of all products that need to be printed with edge contours. Therefore, there is an urgent need for a method for calibrating errors when printing edge contours of products using printing technology. Summary of the invention
[0006] The embodiments of this specification provide an edge printing method and device based on visual calibration, and an electronic device, which can perform error calibration when edge printing of a product is performed using printing technology.
[0007] The technical solution is as follows:
[0008] In a first aspect, an embodiment of the present specification provides an edge printing method based on visual calibration, comprising:
[0009] Acquire a product image of a product to be printed fixed on the mobile stage;
[0010] Identify the actual position coordinates of at least two feature points on the product to be printed in the product image, and obtain position offset information of the product to be printed based on the actual position coordinates and theoretical position coordinates of at least two feature points on the product to be printed in the product image;
[0011] Controlling the moving stage to move based on the position offset information of the product to be printed;
[0012] Identify the edge contour of the product to be printed in the product image, and obtain the printing path information of the product to be printed based on the preset edge printing distance requirement information, the position offset information and the identified edge contour of the product to be printed in the product image;
[0013] The printing system is controlled to print on the edge of the product to be printed based on the printing path information of the product to be printed.
[0014] As a preferred scheme, the execution time of the step of controlling the movement of the mobile stage based on the position offset information of the product to be printed and the execution time of the step of identifying the edge contour of the product to be printed in the product image, and obtaining the printing path information of the product to be printed based on the preset edge printing distance requirement information, the position offset information and the identified edge contour of the product to be printed in the product image, at least partially overlap.
[0015] As a preferred solution, the identifying the actual position coordinates of at least two feature points on the product to be printed in the product image, and obtaining the position offset information of the product to be printed based on the actual position coordinates and theoretical position coordinates of at least two feature points on the product to be printed in the product image, includes:
[0016] Identify the actual position coordinates of the first feature point and the second feature point on the product to be printed in the product image;
[0017] Acquire a first actual vector based on actual position coordinates of the first feature point and the second feature point in the product image, and acquire a first theoretical vector based on theoretical position coordinates of the first feature point and the second feature point in the product image;
[0018] Based on the actual position coordinates of the first feature point in the product image, the theoretical position coordinates of the first feature point in the product image, the first actual vector, and the first theoretical vector, position offset information of the product to be printed is acquired.
[0019] As a preferred solution, the method of obtaining the position offset information of the product to be printed based on the actual position coordinates of the first feature point in the product image, the theoretical position coordinates of the first feature point in the product image, the first actual vector, and the first theoretical vector includes:
[0020] Based on the actual position coordinates of the first feature point in the product image and the theoretical position coordinates of the first feature point in the product image, obtaining the offset distance information in the X-axis direction and the offset distance information in the Y-axis direction;
[0021] Based on the first actual vector and the first theoretical vector, overall angle offset information is acquired.
[0022] As a preferred solution, the identifying the edge contour of the product to be printed in the product image, and obtaining the printing path information of the product to be printed based on the preset edge printing distance requirement information, the position offset information and the identified edge contour of the product to be printed in the product image, includes:
[0023] Identify the edge contour of the product to be printed in the product image;
[0024] Based on the overall angle offset information, the X-axis offset distance information, and the Y-axis offset distance information, the edge contour position of the product to be printed in the product image is adjusted to obtain an adjusted edge contour of the product to be printed in the product image;
[0025] Based on the preset edge printing distance requirement information and the adjusted edge contour of the product to be printed in the product image, the printing path information of the product to be printed is obtained.
[0026] As a preferred solution, the edge contour position of the product to be printed in the product image is adjusted based on the overall angle offset information, the X-axis offset distance information, and the Y-axis offset distance information to obtain the adjusted edge contour of the product to be printed in the product image, including:
[0027] Taking the first feature point as the rotation center, and adjusting the angle of the edge contour position of the to-be-printed product in the product image based on the overall angle offset information;
[0028] Based on the X-axis direction offset distance information and the Y-axis direction offset distance information, the edge contour position of the product to be printed after the angle adjustment in the product image is adjusted in translation;
[0029] The position of the edge contour of the product to be printed in the product image after the translation adjustment is used as the adjusted edge contour of the product to be printed in the product image.
[0030] As a preferred solution, after identifying the actual position coordinates of the first feature point and the second feature point on the product to be printed in the product image, the method further includes:
[0031] Identify the actual position coordinates of the third feature point on the product to be printed in the product image;
[0032] Acquire a second actual vector based on the actual position coordinates of the first feature point and the third feature point in the product image, and acquire a second theoretical vector based on the theoretical position coordinates of the first feature point and the third feature point in the product image;
[0033] The step of acquiring the position offset information of the product to be printed based on the actual position coordinates of the first feature point in the product image, the theoretical position coordinates of the first feature point in the product image, the first actual vector, and the first theoretical vector includes:
[0034] Based on the actual position coordinates of the first feature point in the product image, the theoretical position coordinates of the first feature point in the product image, the first actual vector, the first theoretical vector, the second actual vector, and the second theoretical vector, obtaining position offset information of the product to be printed;
[0035] Furthermore, the method of obtaining the position offset information of the product to be printed based on the actual position coordinates of the first feature point in the product image, the theoretical position coordinates of the first feature point in the product image, the first actual vector, the first theoretical vector, the second actual vector, and the second theoretical vector includes:
[0036] Based on the actual position coordinates of the first feature point in the product image and the theoretical position coordinates of the first feature point in the product image, obtaining the offset distance information in the X-axis direction and the offset distance information in the Y-axis direction;
[0037] Based on the first actual vector, the first theoretical vector, the second actual vector, and the second theoretical vector, overall angle offset information is acquired.
[0038] As a preferred solution, the step of obtaining the overall angle offset information based on the first actual vector, the first theoretical vector, the second actual vector, and the second theoretical vector includes:
[0039] Acquire first angle offset information based on the first actual vector and the first theoretical vector;
[0040] Acquire second angle offset information based on the second actual vector and the second theoretical vector;
[0041] Based on the first angle offset information and the second angle offset information, overall angle offset information is acquired.
[0042] In a second aspect, an embodiment of the present specification provides an edge printing device based on visual calibration, including a mobile stage, a visual calibration system, and a printing system;
[0043] The visual calibration system includes a visual recognition module, an image processing module, and a control module;
[0044] The visual recognition module acquires a product image of a product to be printed fixed on the mobile stage;
[0045] The image processing module identifies actual position coordinates of at least two feature points on the product to be printed in the product image, and acquires position offset information of the product to be printed based on the actual position coordinates and theoretical position coordinates of at least two feature points on the product to be printed in the product image;
[0046] The image processing module further identifies the edge contour of the product to be printed in the product image, and acquires printing path information of the product to be printed based on the preset edge printing distance requirement information, the position offset information and the identified edge contour of the product to be printed in the product image;
[0047] The control module controls the movable stage to move based on the position offset information of the product to be printed;
[0048] The control module further controls the printing system to print on the edge of the product to be printed based on the printing path information of the product to be printed.
[0049] In a third aspect, an embodiment of this specification provides an electronic device, comprising a processor and a memory; the processor is connected to the memory; the memory is used to store executable program code; the processor runs a program corresponding to the executable program code by reading the executable program code stored in the memory, so as to execute the steps described in the first aspect of the above embodiment.
[0050] In a fourth aspect, an embodiment of this specification provides a computer storage medium, wherein the computer storage medium stores a plurality of instructions, wherein the instructions are suitable for being loaded by a processor and executing the steps described in the first aspect of the above embodiment.
[0051] The beneficial effects brought by the technical solutions provided by some embodiments of this specification include at least:
[0052] Based on the actual position coordinates and theoretical position coordinates of at least two feature points on the product to be printed in the product image, the position offset information of the product to be printed is obtained, and the mobile stage is controlled to move based on the position offset information of the product to be printed, thereby realizing the calibration of the overall position offset error of the product to be printed. The edge contour of the product to be printed in the product image is identified, and based on the preset edge printing distance requirement information, the position offset information and the identified edge contour of the product to be printed in the product image, the printing path information of the product to be printed is obtained, thereby realizing the calibration of the edge contour error of the product to be printed. That is, through the overall position offset error calibration and the edge contour error calibration, error calibration is realized when edge printing of the product is performed using printing technology.
[0053] Since the printing path information of the product to be printed is obtained based on the preset edge printing distance requirement information, position offset information and the edge contour of the product to be printed in the product image obtained by recognition, rather than by re-recognizing the product image after the moving stage has moved, it is not necessary to perform image recognition twice when calibrating the edge contour error, and the algorithm processing speed of the background is faster than the image recognition speed, thereby speeding up the product production speed.
[0054] Since the printing path information of the product to be printed is obtained based on the preset edge printing distance requirement information, position offset information and the edge contour of the product to be printed in the product image obtained by identification, rather than being obtained by re-identifying the product image after the moving stage has moved, the execution time of the step of controlling the movement of the moving stage based on the position offset information of the product to be printed and the execution time of the step of identifying the edge contour of the product to be printed in the product image and obtaining the printing path information of the product to be printed based on the preset edge printing distance requirement information, position offset information and the edge contour of the product to be printed in the product image obtained by identification can at least partially overlap, that is, the execution of the two steps can be carried out simultaneously, further speeding up the speed of product production. BRIEF DESCRIPTION OF THE DRAWINGS
[0055] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0056] Figure 1 It is a flowchart of an edge printing method based on visual calibration provided in an embodiment of this specification.
[0057] Figure 2It is a schematic diagram of a product image in an edge printing method based on visual calibration provided in an embodiment of this specification.
[0058] Figure 3 It is a structural schematic diagram of an edge printing device based on visual calibration provided in an embodiment of this specification.
[0059] Figure 4 It is a structural schematic diagram of an electronic device provided in an embodiment of this specification.
[0060] In the figure: 21, product image; 22, product to be printed; 31, mobile carrier; 32, printing system; 33, main control system; 34, visual recognition module. DETAILED DESCRIPTION
[0061] The technical solutions in the embodiments of this specification will be described clearly and completely below in conjunction with the drawings in the embodiments of this specification.
[0062] The terms "first", "second", "third", etc. in the description and claims of this specification and the above-mentioned drawings are used to distinguish different objects, rather than to describe a specific order. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions. For example, a process, method, system, product or device that includes a series of steps or units is not limited to the listed steps or units, but optionally includes steps or units that are not listed, or optionally includes other steps or units inherent to these processes, methods, products or devices.
[0063] The following description provides examples and does not limit the scope, applicability or examples set forth in the claims. Changes may be made to the functions and arrangements of the elements described without departing from the scope of the present specification. Various processes or components may be appropriately omitted, substituted or added to each example. For example, the described method may be performed in an order different from the order described, and various steps may be added, omitted or combined. In addition, features described with respect to some examples may be combined in other examples.
[0064] Reference Figure 1 , Figure 2 , Figure 3 As shown, Figure 1 A flowchart of an edge printing method based on visual calibration provided in an embodiment of this specification may include at least the following steps:
[0065] Step 102, obtaining a product image 21 of a product to be printed 22 fixed on the movable stage 31;
[0066] Step 104, identifying the actual position coordinates of at least two feature points on the product to be printed 22 in the product image 21, and obtaining the position offset information of the product to be printed 22 based on the actual position coordinates and theoretical position coordinates of at least two feature points on the product to be printed 22 in the product image 21 (note: the actual position coordinates represent the position coordinates of the feature points actually presented in the product image, and the theoretical position coordinates represent the position coordinates of the feature points that should be presented when there is no error in the position of the product to be printed, and the theoretical position coordinates need to be obtained in advance);
[0067] Step 106: Control the movable stage 31 to move based on the position offset information of the product 22 to be printed;
[0068] Step 108: Identify the edge contour of the product to be printed 22 in the product image 21, and obtain printing path information of the product to be printed 22 based on preset edge printing distance requirement information (note: it can be understood that the edge contour of the product to be printed 22 needs to be moved inward by a preset edge printing distance for printing), position offset information, and the identified edge contour of the product to be printed 22 in the product image 21;
[0069] Step 110 : Control the printing system 32 to print on the edge of the product 22 to be printed based on the printing path information of the product 22 to be printed.
[0070] In a method for edge printing based on visual calibration provided in multiple embodiments of the present specification, the position offset information of the product 22 to be printed is obtained based on the actual position coordinates and theoretical position coordinates of at least two feature points on the product 22 to be printed in the product image 21, and the moving stage 31 is controlled to move based on the position offset information of the product 22 to be printed, thereby realizing the calibration of the overall position offset error of the product 22 to be printed. The edge contour of the product 22 to be printed in the product image 21 is identified, and the printing path information of the product 22 to be printed is obtained based on the preset edge printing distance requirement information, the position offset information and the identified edge contour of the product 22 to be printed in the product image 21, thereby realizing the calibration of the edge contour error of the product 22 to be printed. That is, through the overall position offset error calibration and the edge contour error calibration, error calibration is realized when edge printing of a product is performed using printing technology.
[0071] Since the printing path information of the product to be printed 22 is obtained based on the preset edge printing distance requirement information, position offset information and the recognized edge contour of the product to be printed 22 in the product image 21, rather than being obtained by recognizing the product image again after the moving stage 31 has moved, it is not necessary to perform image recognition twice when calibrating the edge contour error, and the algorithm processing speed of the background is faster than the image recognition speed, thereby speeding up the product production speed.
[0072] In multiple embodiments of the present specification, the execution time of the step of controlling the movement of the mobile stage 31 based on the position offset information of the product to be printed 22 and the execution time of the step of identifying the edge contour of the product to be printed 22 in the product image 21, and obtaining the printing path information of the product to be printed 22 based on the preset edge printing distance requirement information, the position offset information and the identified edge contour of the product to be printed 22 in the product image 21, at least partially overlap.
[0073] In a method for edge printing based on visual calibration provided in multiple embodiments of the present specification, the printing path information of the product 22 to be printed is obtained based on the preset edge printing distance requirement information, position offset information and the edge contour of the product 22 to be printed in the product image 21 obtained by recognition, rather than being obtained by re-recognizing the product image after the moving stage 31 has moved. Therefore, the execution time of the step of controlling the movement of the moving stage 31 based on the position offset information of the product 22 to be printed and the execution time of the step of recognizing the edge contour of the product 22 to be printed in the product image 21 and obtaining the printing path information of the product 22 to be printed based on the preset edge printing distance requirement information, position offset information and the edge contour of the product 22 to be printed in the product image 21 obtained by recognition, may at least partially overlap, that is, the execution of the two steps may be performed simultaneously, further speeding up the production of products.
[0074] Reference Figure 2 As shown, in multiple embodiments of the present specification, the identifying the actual position coordinates of at least two feature points on the product to be printed 22 in the product image 21, and obtaining the position offset information of the product to be printed 22 based on the actual position coordinates and theoretical position coordinates of at least two feature points on the product to be printed 22 in the product image 21, includes:
[0075] Step 1042: Identify the actual position coordinates of the first feature point and the second feature point on the to-be-printed product 22 in the product image 21 (Note: the positions actually identified in the product image 21 are respectively Figure 2 The actual position coordinates A' of the first feature point in the product image 21 and the actual position coordinates B' of the second feature point in the product image 21);
[0076] Step 1044: Obtain a first actual vector based on the actual position coordinates of the first feature point and the second feature point in the product image 21, and obtain a first actual vector based on the theoretical position coordinates of the first feature point and the second feature point in the product image 21 (Note: respectively Figure 2The first theoretical vector is obtained by using the theoretical position coordinates A of the first feature point in the product image 21 and the theoretical position coordinates B of the second feature point in the product image 21;
[0077] Step 1046 : Acquire position offset information of the to-be-printed product 22 based on the actual position coordinates of the first feature point in the product image 21 , the theoretical position coordinates of the first feature point in the product image 21 , the first actual vector, and the first theoretical vector.
[0078] In multiple embodiments of the present specification, the step of obtaining the position offset information of the product to be printed 22 based on the actual position coordinates of the first feature point in the product image 21, the theoretical position coordinates of the first feature point in the product image 21, the first actual vector, and the first theoretical vector includes:
[0079] Step 10462: Based on the actual position coordinates of the first feature point in the product image 21 and the theoretical position coordinates of the first feature point in the product image 21, obtain the offset distance information in the X-axis direction and the offset distance information in the Y-axis direction;
[0080] Assuming that the actual position coordinate A' of the first feature point in the product image 21 is (x, y), and the theoretical position coordinate A of the first feature point in the product image 21 is (x', y'), then the offset distance information in the X-axis direction is x-x', and the offset distance information in the Y-axis direction is y-y'.
[0081] Step 10464: Based on the first actual vector and the first theoretical vector, obtain the overall angle offset information.
[0082] Assuming that the actual position coordinate B' of the second feature point in the product image 21 is (w, e), and the theoretical position coordinate B of the second feature point in the product image 21 is (w', e'), then:
[0083] The first actual vector is (wx,ey);
[0084] The first theoretical vector is (w'-x', e'-y');
[0085] The angle between the first actual vector and the first theoretical vector can be calculated based on the following formula:
[0086]
[0087] Wherein, θ represents the angle between the first actual vector and the first theoretical vector, and the overall angle offset information can be further obtained based on θ.
[0088] It should be noted that the characteristic point position may be a corner point of the product 21 to be printed (ie Figure 2 ), or may be additional marking points set at other positions on the to-be-printed product 21, without limitation.
[0089] Further, in step 106, controlling the movable stage 31 to move based on the position offset information of the product 22 to be printed includes:
[0090] The position of the movable stage 31 is adjusted based on the X-axis direction offset distance information, the Y-axis direction offset distance information, and the overall angle offset information.
[0091] The mobile stage 31 can be first adjusted in translation based on the offset distance information in the X-axis direction and the offset distance information in the Y-axis direction, and then the angle of the mobile stage 31 can be adjusted based on the overall angle offset information; or the angle of the mobile stage 31 can be first adjusted based on the overall angle offset information, and then the mobile stage 31 can be adjusted in translation based on the offset distance information in the X-axis direction and the offset distance information in the Y-axis direction.
[0092] However, it should be noted that when the angle of the movable stage 31 is adjusted based on the overall angle offset information, the actual position coordinate A′ of the first feature point in the product image 21 needs to be used as the rotation center.
[0093] In multiple embodiments of the present specification, the identifying the edge contour of the product to be printed 22 in the product image 21, and obtaining the printing path information of the product to be printed 22 based on the preset edge printing distance requirement information, the position offset information and the identified edge contour of the product to be printed in the product image 21, includes:
[0094] Step 1082: Identify the edge contour of the product to be printed 22 in the product image 21 (Note: that is, Figure 2 The actual edge contour of the product to be printed 22, the method for identifying the edge contour will not be described in detail here, which is the prior art);
[0095] Step 1084: Based on the overall angle offset information, the X-axis offset distance information, and the Y-axis offset distance information, the edge contour position of the product to be printed 22 in the product image 21 is adjusted to obtain an adjusted edge contour of the product to be printed 22 in the product image 21;
[0096] Step 1086 : Based on the preset edge printing distance requirement information and the adjusted edge contour of the product 22 to be printed in the product image 21 , the printing path information of the product 22 to be printed is obtained.
[0097] The step of adjusting the edge contour position of the product to be printed 22 in the product image 21 based on the overall angle offset information, the X-axis offset distance information, and the Y-axis offset distance information to obtain the adjusted edge contour of the product to be printed 22 in the product image 21 includes:
[0098] Step 10842: Taking the first feature point as the rotation center, and based on the overall angle offset information, the edge contour position of the to-be-printed product 22 in the product image 21 is adjusted in angle (i.e., taking A' as the rotation center, the edge contour of the to-be-printed product 22 in the product image 21 is rotated);
[0099] Step 10844: Based on the offset distance information in the X-axis direction and the offset distance information in the Y-axis direction, the edge contour position of the product 22 to be printed after the angle adjustment in the product image 21 is adjusted in translation;
[0100] Step 10846: The edge contour position of the to-be-printed product 22 in the product image 21 after the translation adjustment is used as the adjusted edge contour of the to-be-printed product 22 in the product image 21 .
[0101] That is, through the background image data processing, it is possible to obtain the edge contour that the product to be printed 22 should present in the product image 21 after the movable stage 31 is moved based on the position offset information of the product to be printed 22 .
[0102] In multiple embodiments of the present specification, after identifying the actual position coordinates of the first feature point and the second feature point on the to-be-printed product 22 in the product image 21, the method further includes:
[0103] Identify the actual position coordinates C′ of the third feature point on the to-be-printed product 22 in the product image 21 ;
[0104] The second actual vector is obtained based on the actual position coordinates of the first feature point and the third feature point in the product image 21, and the second theoretical vector is obtained based on the theoretical position coordinates of the first feature point and the third feature point in the product image 21 (Note: The theoretical position coordinates of the third feature point in the product image 21 are Figure 2 C in
[0105] The step of acquiring the position offset information of the product to be printed 22 based on the actual position coordinates of the first feature point in the product image 21, the theoretical position coordinates of the first feature point in the product image 21, the first actual vector, and the first theoretical vector includes:
[0106] Based on the actual position coordinates of the first feature point in the product image 21, the theoretical position coordinates of the first feature point in the product image 21, the first actual vector, the first theoretical vector, the second actual vector, and the second theoretical vector, the position offset information of the product to be printed 22 is obtained;
[0107] Furthermore, the method of obtaining the position offset information of the product to be printed 22 based on the actual position coordinates of the first feature point in the product image 21, the theoretical position coordinates of the first feature point in the product image 21, the first actual vector, the first theoretical vector, the second actual vector, and the second theoretical vector includes:
[0108] Based on the actual position coordinates of the first feature point in the product image 21 and the theoretical position coordinates of the first feature point in the product image 21, obtaining the offset distance information in the X-axis direction and the offset distance information in the Y-axis direction;
[0109] Based on the first actual vector, the first theoretical vector, the second actual vector, and the second theoretical vector, overall angle offset information is acquired.
[0110] In multiple embodiments of this specification, the step of acquiring overall angle offset information based on the first actual vector, the first theoretical vector, the second actual vector, and the second theoretical vector includes:
[0111] Acquire first angle offset information based on the first actual vector and the first theoretical vector;
[0112] Acquire second angle offset information based on the second actual vector and the second theoretical vector;
[0113] Based on the first angle offset information and the second angle offset information, overall angle offset information is acquired.
[0114] It is understandable that there are occasional errors in obtaining the overall angle offset information through only two feature points, so an additional feature point is added, namely the third feature point. Then, the second actual vector is obtained based on the actual position coordinates of the first feature point and the third feature point in the product image 21, and the second theoretical vector is obtained based on the theoretical position coordinates of the first feature point and the third feature point in the product image 21. Further, the second angle offset information can be obtained based on the second actual vector and the second theoretical vector (Note: the method for obtaining the second angle offset information can refer to the method for obtaining θ mentioned above, and no further details will be given here).
[0115] Then, based on the first angle offset information and the second angle offset information, the overall angle offset information can be obtained (note: it can be obtained by using an angle averaging operation).
[0116] It should be noted that there is an image coordinate system in the product image 21, and each pixel in the image has its own corresponding coordinates. The coordinate acquisition of the first feature point, the second feature point, and the third feature point, as well as the translation adjustment and rotation adjustment are all performed based on the image coordinate system.
[0117] The above is a description of a specific embodiment of the specification. Other embodiments are within the scope of the appended claims. In some cases, the actions or steps recorded in the claims can be performed in an order different from that in the embodiments and still achieve the desired results. In addition, the processes depicted in the drawings do not necessarily require the specific order or continuous order shown to achieve the desired results. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.
[0118] See next Figure 3 , Figure 3 A schematic structural diagram of an edge printing device based on visual calibration provided in an embodiment of this specification is shown.
[0119] The edge printing device may include at least a moving stage 31, a visual calibration system, and a printing system 32;
[0120] The visual calibration system includes a visual recognition module 34 (Note: for the convenience of demonstration, Figure 3 The visual recognition module 34 is not arranged directly above the mobile stage 31. In actual application, the visual recognition module 34 can be arranged directly above the mobile stage 31 to simplify the data processing of the product image at the back end), the image processing module (arranged in the main control system 33), and the control module (arranged in the main control system 33);
[0121] The visual recognition module 34 acquires a product image 21 of a product to be printed 22 fixed on the mobile stage 31;
[0122] The image processing module identifies actual position coordinates of at least two feature points on the product to be printed 22 in the product image 21, and obtains position offset information of the product to be printed 22 based on the actual position coordinates and theoretical position coordinates of at least two feature points on the product to be printed 22 in the product image 21;
[0123] The image processing module further identifies the edge contour of the product to be printed 22 in the product image 21, and acquires printing path information of the product to be printed 22 based on the preset edge printing distance requirement information, the position offset information and the identified edge contour of the product to be printed 22 in the product image 21;
[0124] The control module controls the moving stage 31 to move based on the position offset information of the product 22 to be printed;
[0125] The control module further controls the printing system 32 to print on the edge of the product 22 to be printed based on the printing path information of the product 22 to be printed.
[0126] Each embodiment in this specification is described in a progressive manner, and the same or similar parts between the embodiments can be referred to each other, and each embodiment focuses on the differences from other embodiments. In particular, for the edge printing device embodiment, since it is basically similar to the edge printing method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the edge printing method embodiment.
[0127] See also Figure 4 A schematic diagram of the structure of an electronic device provided in an embodiment of this specification is shown.
[0128] like Figure 4 As shown, the electronic device 400 may include: at least one processor 401 , at least one network interface 404 , a user interface 403 , a memory 405 , and at least one communication bus 402 .
[0129] The communication bus 402 may be used to realize the connection and communication among the above-mentioned components.
[0130] The user interface 403 may include buttons, and the optional user interface may also include a standard wired interface or a wireless interface.
[0131] The network interface 404 may include, but is not limited to, a Bluetooth module, an NFC module, a Wi-Fi module, etc.
[0132] Among them, the processor 401 may include one or more processing cores. The processor 401 uses various interfaces and lines to connect the various parts of the entire electronic device 400, and executes various functions and processes data of the electronic device 400 by running or executing instructions, programs, code sets or instruction sets stored in the memory 405, and calling data stored in the memory 405. Optionally, the processor 401 can be implemented in at least one hardware form of DSP, FPGA, and PLC. The processor 401 can integrate one or a combination of CPU, GPU, modem, etc. Among them, the CPU mainly processes the operating system, user interface, and application programs; the GPU is responsible for rendering and drawing the content to be displayed on the display screen; the modem is used to process wireless communications. It can be understood that the above-mentioned modem may not be integrated into the processor 401, and it can be implemented separately through a chip.
[0133] Among them, the memory 405 may include RAM or ROM. Optionally, the memory 405 includes a non-transitory computer-readable medium. The memory 405 can be used to store instructions, programs, codes, code sets or instruction sets. The memory 405 may include a program storage area and a data storage area, wherein the program storage area may store instructions for implementing an operating system, instructions for at least one function (such as a touch function, a sound playback function, an image playback function, etc.), instructions for implementing the above-mentioned various method embodiments, etc.; the data storage area may store data involved in the above-mentioned various method embodiments, etc. The memory 405 may also be at least one storage device located away from the aforementioned processor 401. The memory 405 as a computer storage medium may include an operating system, a network communication module, a user interface module and an edge printing application. The processor 401 may be used to call the edge printing application stored in the memory 405 and execute the steps of the edge printing method mentioned in the above-mentioned embodiment.
[0134] The embodiment of this specification also provides a computer-readable storage medium, which stores instructions, and when the instructions are executed on a computer or a processor, the computer or the processor executes one or more steps in the above-mentioned edge printing method embodiment. If the component modules of the above-mentioned electronic device are implemented in the form of software functional units and sold or used as independent products, they can be stored in the computer-readable storage medium.
[0135] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented using software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the process or function described in the embodiment of this specification is generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium or transmitted through the computer-readable storage medium. The computer instructions can be transmitted from a website site, computer, server or data center to another website site, computer, server or data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line (Digital Subscriber Line, DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) mode. The computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server, data center, etc. that contains one or more available media integrated. The available medium may be a magnetic medium (eg, a floppy disk, a hard disk, a magnetic tape), an optical medium (eg, a digital versatile disc (DVD)), or a semiconductor medium (eg, a solid state disk (SSD)).
[0136] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiments can be implemented by instructing the relevant 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. The aforementioned storage medium includes: ROM, RAM, magnetic disk or optical disk and other media that can store program codes. In the absence of conflict, the technical features in this embodiment and the implementation scheme can be combined arbitrarily.
[0137] The embodiments described above are merely preferred embodiments of this specification and are not intended to limit the scope of this specification. Without departing from the design spirit of this specification, various modifications and improvements made to the technical solutions of this specification by ordinary technicians in this field should fall within the scope of protection determined by the claims of this specification.
Claims
1. A method for edge printing based on visual calibration, applied to product edge printing scenarios, characterized in that: include: Acquire a product image of a product to be printed fixed on the mobile stage; Identify the actual position coordinates of at least two feature points on the product to be printed in the product image, and obtain position offset information of the product to be printed based on the actual position coordinates and theoretical position coordinates of at least two feature points on the product to be printed in the product image; Controlling the moving stage to move based on the position offset information of the product to be printed; Identify the edge contour of the product to be printed in the product image, and obtain the printing path information of the product to be printed based on the preset edge printing distance requirement information, the position offset information and the identified edge contour of the product to be printed in the product image; The printing system is controlled to print on the edge of the product to be printed based on the printing path information of the product to be printed.
2. The edge printing method based on visual calibration according to claim 1, characterized in that: The execution time of the step of controlling the movement of the mobile stage based on the position offset information of the product to be printed and the execution time of the step of identifying the edge contour of the product to be printed in the product image, and obtaining the printing path information of the product to be printed based on the preset edge printing distance requirement information, the position offset information and the identified edge contour of the product to be printed in the product image, at least partially overlap.
3. The edge printing method based on visual calibration according to claim 1, characterized in that: The identifying the actual position coordinates of at least two feature points on the product to be printed in the product image, and acquiring the position offset information of the product to be printed based on the actual position coordinates and theoretical position coordinates of at least two feature points on the product to be printed in the product image, includes: Identify the actual position coordinates of the first feature point and the second feature point on the product to be printed in the product image; Acquire a first actual vector based on actual position coordinates of the first feature point and the second feature point in the product image, and acquire a first theoretical vector based on theoretical position coordinates of the first feature point and the second feature point in the product image; Based on the actual position coordinates of the first feature point in the product image, the theoretical position coordinates of the first feature point in the product image, the first actual vector, and the first theoretical vector, position offset information of the product to be printed is acquired.
4. The edge printing method based on visual calibration according to claim 3, characterized in that: The step of acquiring the position offset information of the product to be printed based on the actual position coordinates of the first feature point in the product image, the theoretical position coordinates of the first feature point in the product image, the first actual vector, and the first theoretical vector includes: Based on the actual position coordinates of the first feature point in the product image and the theoretical position coordinates of the first feature point in the product image, obtaining the offset distance information in the X-axis direction and the offset distance information in the Y-axis direction; Based on the first actual vector and the first theoretical vector, overall angle offset information is acquired.
5. The edge printing method based on visual calibration according to claim 4, characterized in that: The identifying the edge contour of the product to be printed in the product image, and obtaining the printing path information of the product to be printed based on the preset edge printing distance requirement information, the position offset information and the identified edge contour of the product to be printed in the product image, includes: Identify the edge contour of the product to be printed in the product image; Based on the overall angle offset information, the X-axis offset distance information, and the Y-axis offset distance information, the edge contour position of the product to be printed in the product image is adjusted to obtain an adjusted edge contour of the product to be printed in the product image; Based on the preset edge printing distance requirement information and the adjusted edge contour of the product to be printed in the product image, the printing path information of the product to be printed is obtained.
6. The edge printing method based on visual calibration according to claim 5, characterized in that: The step of adjusting the edge contour position of the product to be printed in the product image based on the overall angle offset information, the X-axis offset distance information, and the Y-axis offset distance information to obtain an adjusted edge contour of the product to be printed in the product image includes: Taking the first feature point as the rotation center, and adjusting the angle of the edge contour position of the to-be-printed product in the product image based on the overall angle offset information; Based on the X-axis direction offset distance information and the Y-axis direction offset distance information, the edge contour position of the product to be printed after the angle adjustment in the product image is adjusted in translation; The position of the edge contour of the product to be printed in the product image after the translation adjustment is used as the adjusted edge contour of the product to be printed in the product image.
7. The edge printing method based on visual calibration according to claim 4, characterized in that: After identifying the actual position coordinates of the first feature point and the second feature point on the product to be printed in the product image, the method further includes: Identify the actual position coordinates of the third feature point on the product to be printed in the product image; Acquire a second actual vector based on the actual position coordinates of the first feature point and the third feature point in the product image, and acquire a second theoretical vector based on the theoretical position coordinates of the first feature point and the third feature point in the product image; The step of acquiring the position offset information of the product to be printed based on the actual position coordinates of the first feature point in the product image, the theoretical position coordinates of the first feature point in the product image, the first actual vector, and the first theoretical vector includes: Based on the actual position coordinates of the first feature point in the product image, the theoretical position coordinates of the first feature point in the product image, the first actual vector, the first theoretical vector, the second actual vector, and the second theoretical vector, obtaining position offset information of the product to be printed; Furthermore, the method of obtaining the position offset information of the product to be printed based on the actual position coordinates of the first feature point in the product image, the theoretical position coordinates of the first feature point in the product image, the first actual vector, the first theoretical vector, the second actual vector, and the second theoretical vector includes: Based on the actual position coordinates of the first feature point in the product image and the theoretical position coordinates of the first feature point in the product image, obtaining the offset distance information in the X-axis direction and the offset distance information in the Y-axis direction; Based on the first actual vector, the first theoretical vector, the second actual vector, and the second theoretical vector, overall angle offset information is acquired.
8. The edge printing method based on visual calibration according to claim 7, characterized in that: The obtaining of the overall angle offset information based on the first actual vector, the first theoretical vector, the second actual vector, and the second theoretical vector includes: Acquire first angle offset information based on the first actual vector and the first theoretical vector; Acquire second angle offset information based on the second actual vector and the second theoretical vector; Based on the first angle offset information and the second angle offset information, overall angle offset information is acquired.
9. An edge printing device based on visual calibration, applied to product edge printing scenarios, characterized in that: Including mobile stage, visual calibration system, and printing system; The visual calibration system includes a visual recognition module, an image processing module, and a control module; The visual recognition module acquires a product image of a product to be printed fixed on the mobile stage; The image processing module identifies actual position coordinates of at least two feature points on the product to be printed in the product image, and acquires position offset information of the product to be printed based on the actual position coordinates and theoretical position coordinates of at least two feature points on the product to be printed in the product image; The image processing module further identifies the edge contour of the product to be printed in the product image, and acquires printing path information of the product to be printed based on the preset edge printing distance requirement information, the position offset information and the identified edge contour of the product to be printed in the product image; The control module controls the movable stage to move based on the position offset information of the product to be printed; The control module further controls the printing system to print on the edge of the product to be printed based on the printing path information of the product to be printed.
10. An electronic device, characterized in that: including a processor and a memory; The processor is connected to the memory; The memory is used to store executable program code; The processor runs a program corresponding to the executable program code by reading the executable program code stored in the memory, so as to execute the method according to any one of claims 1 to 8.
Citation Information
Patent Citations
Printing calibration method for self-help type form-filling machine
CN105365416A
PCB positioning error calibration method, device and equipment and storage medium
CN109685784A
Printing method, printing device, terminal and storage medium
CN110126480A
Ink-jet printing system based on stepping motors and printing method of ink-jet printing system
CN110816056A
Printing control method, controller, 3D printing system and storage medium
CN111452365A
Cited By
Grabbing deviation correction method and system based on visual inspection technology
CN121132642A