Paper size detection method and device, electronic equipment and storage medium

CN116719490BActive Publication Date: 2026-10-30ZHUHAI PANTUM ELECTRONICS CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202310688659.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-06-09
Publication Date
2026-10-30
Estimated Expiration
2043-06-09

AI Technical Summary

Technical Problem

[0004]本申请实施例提供了一种纸张尺寸检测方法、装置、电子设备及存储介质,用以解决现有技术中在装载了与待打印页面不匹配纸型纸张的图像形成设备无法进行画像质量较好的图像形成的问题

Benefits of technology

[0049]通过上述方法,在不设置纸型检测传感器,降低图像形成设备成本的同时还满足用户在不匹配的纸型上的打印需求。同时避免了将待打印页面的画像打印在不合适的纸张上所造成耗材的浪费。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116719490B_ABST
    Figure CN116719490B_ABST
Patent Text Reader

Abstract

The application relates to the image forming field, in particular to a paper size detection method and device, an electronic device and a storage medium. The paper size detection method comprises the following steps: acquiring a first length representing a to-be-printed page and a second length representing a size set by a paper tray; determining whether a preset paper and a required size of the to-be-printed page match according to the first length and the second length, wherein the size of the preset paper corresponds to the size set by the paper tray; determining whether printing needs to be performed according to a matching result of the preset paper and the to-be-printed page; when it is determined that printing needs to be performed, determining whether the actual paper and the preset paper match according to the second length and a fourth length of the actual paper in the paper tray; and performing printing according to a matching result of the preset paper and the actual paper. The application can meet the printing demand of a user on a non-matching paper type, and avoid wasting consumables caused by printing the image of the to-be-printed page on an unsuitable paper.
Need to check novelty before this filing date? Find Prior Art

Description

[Technical Field]

[0001] This application relates to the field of image forming, and more particularly to a paper size detection method, apparatus, electronic device, and storage medium. [Background Technology]

[0002] Current image forming equipment can print on paper of different sizes depending on the page to be printed. During actual printing, to ensure the paper matches the printed page, a paper size detection sensor on the image forming equipment, combined with the mechanical structure of the paper tray, is used to sense the paper size.

[0003] However, in some image forming apparatuses, to facilitate simplified and miniaturized design, the paper size detection sensor located inside the paper tray is omitted. If the paper placed in the input tray by the user does not match the required size of the page to be printed, the user will not receive error feedback, resulting in misprints, missing images, and other issues. Therefore, printing the page on unsuitable paper not only degrades the user experience but also wastes consumables. [Summary of the Invention]

[0004] This application provides a paper size detection method, apparatus, electronic device, and storage medium to solve the problem in the prior art that image forming equipment loaded with paper of a mismatch with the page to be printed cannot form images with good image quality.

[0005] In a first aspect, embodiments of this application provide a paper size detection method, the method comprising:

[0006] Obtain the first length representing the page to be printed, and the second length representing the size set in the paper tray, respectively;

[0007] Based on the first length and the second length, it is determined whether the preset paper size matches the required size of the page to be printed, and the size of the preset paper size corresponds to the size of the paper feed tray.

[0008] Whether printing needs to be performed is determined based on the matching result between the preset paper and the page to be printed;

[0009] When it is determined that printing needs to be performed, the actual paper is determined to match the preset paper based on the second length and the fourth length representing the actual paper in the paper tray.

[0010] Printing is performed based on the matching result between the preset paper and the actual paper.

[0011] Optionally, determining whether printing needs to be performed based on the matching result between the preset paper and the page to be printed includes:

[0012] When the first length is the same as the second length, it is determined that printing will be performed in normal printing mode;

[0013] When the first length and the second length are inconsistent, a prompt message is displayed;

[0014] In response to the user's confirmation print command based on the prompt information, it is determined to execute printing through forced print mode.

[0015] Optionally, performing printing based on the matching result between the preset paper and the actual paper includes:

[0016] In normal printing mode, when it is determined that the second length is consistent with the fourth length, all jobs are printed until printing is completed;

[0017] When it is determined that the second length is inconsistent with the fourth length, the remaining printing job is cancelled and a paper jam is reported.

[0018] Optionally, after determining that the second length and the fourth length are inconsistent, the method further includes:

[0019] The third length is used to determine whether the actual paper exceeds the maximum size that the image forming device supports for printing, and the fourth length is the length that characterizes the maximum size of paper that the image forming device supports for printing.

[0020] When the fourth length is greater than the third length, the remaining printing job is cancelled and a paper jam is reported.

[0021] When the fourth length is less than or equal to the third length, the actual paper is ejected and the remaining printing job is canceled.

[0022] Optionally, the method of performing printing based on the matching result of the preset paper and the actual paper further includes:

[0023] In forced printing mode, when it is determined that the second length is consistent with the fourth length, it is determined whether the actual paper size matches the required size of the page to be printed based on the fourth length and the first length;

[0024] When it is determined that the second length is inconsistent with the fourth length, the actual paper size is determined to match the required size of the page to be printed based on the fourth length, the first length, and the third length, wherein the third length is the length that the image forming device supports for printing the largest size paper.

[0025] Optionally, determining whether the actual paper size matches the required size of the page to be printed based on the fourth length and the first length includes:

[0026] When the fourth length is less than the first length, the actual paper is ejected, and the remaining printing job is canceled;

[0027] When the fourth length is greater than or equal to the first length, print all jobs until printing is complete.

[0028] Optionally, determining whether the actual paper size matches the required size of the page to be printed based on the fourth length, the first length, and the third length includes:

[0029] Determine whether the actual paper exceeds the maximum size supported for printing by the image forming device based on the third length and the fourth length;

[0030] When the fourth length is greater than the third length, the remaining printing job is cancelled and a paper jam is reported.

[0031] When the fourth length is less than or equal to the third length, the remaining print jobs are cancelled or all jobs are printed until printing is completed, depending on the fourth length and the first length.

[0032] Optionally, printing all jobs until printing is complete includes:

[0033] The subsequent actual paper transfer is performed via the fourth length.

[0034] Optionally, after determining that printing needs to be performed, the method further includes: determining a fourth length representing the actual paper length within the paper tray, including:

[0035] The time it takes for the actual paper to pass through the paper tip detection sensor is determined by the time difference between the actual paper tip triggering the paper tip detection sensor and the actual paper tail leaving the paper tip detection sensor.

[0036] Determine the linear velocity of the calibration roller;

[0037] The fourth length, representing the actual paper, is determined based on the time it takes for the actual paper to pass through the paper tip detection sensor and the linear velocity of the correction roller.

[0038] Secondly, embodiments of this application provide a paper size detection device, the device comprising:

[0039] The acquisition module acquires a first length representing the page to be printed and a second length representing the size set in the paper tray, respectively.

[0040] The first matching module determines whether the preset paper size matches the required size of the page to be printed based on the first length and the second length, wherein the size of the preset paper size corresponds to the size of the paper tray setting.

[0041] The determination module determines whether printing needs to be performed based on the matching result between the preset paper and the page to be printed;

[0042] The second matching module, when it is determined that printing needs to be performed, determines whether the actual paper matches the preset paper based on the second length and the fourth length representing the actual paper in the paper tray.

[0043] The printing module performs printing based on the matching result between the preset paper and the actual paper.

[0044] Thirdly, embodiments of this application provide an electronic device, including:

[0045] At least one processor; and

[0046] At least one memory communicatively connected to the processor, wherein:

[0047] The memory stores program instructions that can be executed by the processor, which can invoke the program instructions to perform the method as described in any of the first aspects.

[0048] Fourthly, embodiments of this application provide a storage medium including a stored program, wherein, when the program is executed, it controls the device where the storage medium is located to perform the method described in any of the first aspects.

[0049] By employing the above method, the cost of image forming equipment is reduced by eliminating the need for a paper size detection sensor, while still meeting users' printing needs on incompatible paper sizes. This also avoids the waste of consumables caused by printing the image of the page to be printed on unsuitable paper. [Attached Image Description]

[0050] To more clearly illustrate the technical solutions of the embodiments of this application, the drawings used in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0051] Figure 1 A flowchart of a paper size detection method provided in an embodiment of this application;

[0052] Figure 2 This is a schematic diagram of the structure of a paper size detection device provided in an embodiment of this application;

[0053] Figure 3 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application.

Detailed Implementation Methods

[0054] To better understand the technical solution of this application, the embodiments of this application will be described in detail below with reference to the accompanying drawings.

[0055] It should be understood that the described embodiments are merely some, not all, of the embodiments in this application. All other embodiments obtained by those skilled in the art based on the embodiments in this application without inventive effort are within the scope of protection of this application.

[0056] Current image forming equipment can print on paper of different sizes depending on the page to be printed. To ensure that the paper matches the printed page, a paper size detection sensor on the image forming equipment, combined with the mechanical structure of the paper tray, is used to sense the size of the paper.

[0057] Specifically, the image forming device obtains the actual size of the paper through a paper size detection sensor, and then combines it with the page information of the page to be printed set in the image forming device driver. Through internal logic, it determines whether there is a paper size difference and provides feedback to the user before actual printing, prompting the user to change the paper.

[0058] However, in some image forming apparatuses, for the sake of simplified and miniaturized design, the paper size detection sensor is omitted. If the paper placed in the paper tray by the user does not match the required paper size for the page to be printed, the user will not receive error feedback, which may result in missing prints or incomplete images.

[0059] like Figure 1 The image shows a paper size detection method provided in an embodiment of this application. (See also...) Figure 1 The specific steps of this method include:

[0060] S101, respectively obtain a first length representing the page to be printed and a second length representing the size set by the paper tray.

[0061] Specifically, the first length and the second length are determined by the setting information of the image forming apparatus.

[0062] For example, the required paper size and corresponding length of the page to be printed are determined through the image forming device driver settings, i.e., the first length. The dimensions of the paper tray are determined through the image forming device driver settings, thereby determining the length of the paper tray, i.e., the second length; or the dimensions of the paper tray are determined and set according to user instructions received from the control panel of the image forming device, thereby determining the second length.

[0063] The paper feed tray is typically an automatic tray that can be adjusted in size according to user control commands. Users need to place appropriate paper according to the size of the paper feed tray for the image forming equipment to perform the printing task.

[0064] S102, determine whether the preset paper size matches the required size of the page to be printed based on the first length and the second length.

[0065] Specifically, the preset paper size corresponds to the paper tray size; that is, the size set in the paper tray is determined as the preset paper size. The required size of the preset paper size is determined by comparing the size of the paper tray with the size of the page to be printed. The matching of the preset paper size with the required size of the page is further confirmed by determining whether a first length and a second length are equal. The preset paper size is not a physical piece of paper, but rather a constructed virtual concept used to print the page.

[0066] Specifically, when the first length representing the page to be printed is equal to the second length representing the size set by the paper tray, it is determined that the preset paper size matches the required size of the page to be printed.

[0067] S103, determine whether printing needs to be performed based on the matching result of the preset paper and the page to be printed.

[0068] Specifically, printing is determined to be performed when the preset paper size matches the page to be printed, or when they do not match but the user confirms the print order.

[0069] Specifically, when the first length and the second length are the same, that is, when it is determined that the preset paper size matches the required size of the page to be printed, printing is performed in normal printing mode.

[0070] When the first and second lengths are inconsistent, indicating a mismatch between the preset paper size and the required print size, a prompt message is displayed, asking the user whether to force print. Upon receiving a confirmation print command from the user based on the prompt message, printing is executed in forced print mode. Upon receiving a cancellation print command from the user based on the prompt message, or if no such command is received within the specified time limit, the current print job is canceled, and the user is prompted to reset the print job.

[0071] In one specific embodiment, a prompt message is displayed: "Paper type mismatch, force printing?" When it is confirmed that the user has pressed the "Confirm" button according to the prompt message, it is determined that the user has issued a confirmation printing command, and printing is executed through forced printing mode.

[0072] S104, when it is determined that printing needs to be performed, determine whether the actual paper matches the preset paper based on the second length and the fourth length representing the actual paper in the paper tray.

[0073] Specifically, after determining that printing is required, an image is generated based on a first length representing the page to be printed. A sheet of paper is then picked up from the paper tray by a paper feed roller and fed into the image forming device for printing. In normal printing mode, the actual paper is fed at the first length; in forced printing mode, the actual paper is fed at a third length. The third length represents the length corresponding to the largest paper size that the image forming device supports for printing.

[0074] When the preset paper is fed into the image forming device, the size of the actual paper is calculated, that is, the fourth length representing the actual paper is calculated.

[0075] Specifically, a paper tip detection sensor is installed at the correction roller of the image forming equipment to align the paper tip and prevent paper tilting. This application determines a fourth length, representing the actual paper size, by measuring the duration of time the actual paper triggers the paper tip detection sensor. When the actual paper is conveyed inside the image forming equipment and passes through the correction roller for tilt correction, the paper tip detection sensor detects whether the tip of the actual paper has reached the position of the correction roller. Timing begins when the sensor is triggered upon arrival and continues until the sensor is released, confirming that the tail end of the actual paper has left the sensor. The time it takes for the actual paper to pass the sensor and the linear velocity of the correction roller are determined, and the two are multiplied to determine the fourth length.

[0076] The formula for calculating the fourth length is: L4 = VT.

[0077] Where L4 is the actual length of the paper, i.e., the fourth length; V is the linear speed of the correction roller; T is the time it takes for the actual paper to pass through the sensor, i.e., the time difference between the actual paper tip triggering the paper tip detection sensor and the actual paper tail leaving the paper tip detection sensor.

[0078] After determining the fourth length, which represents the actual paper size, the second and fourth lengths are compared in normal printing mode or forced printing mode, depending on the specific printing mode, to determine whether the actual paper matches the preset paper size.

[0079] S105, Printing is performed based on the matching result between the preset paper and the actual paper.

[0080] Specifically, in normal printing mode, once the second length and the fourth length are confirmed to be the same, it can be determined that the actual paper size matches the size set in the paper tray. That is, the preset paper size matches the actual paper size, the user places the paper correctly, and all jobs can be printed normally until the printing is finished.

[0081] In normal printing mode, if the second length and the fourth length are determined to be inconsistent, it means that the actual paper size is inconsistent with the paper tray size, the preset paper size does not match the actual paper size, and the user has placed the wrong paper. This will cause the printer to jam, stop the printer, cancel the remaining print jobs, and report the paper jam fault.

[0082] In forced printing mode, when the second and fourth lengths are determined to be the same (i.e., the preset paper size matches the actual paper size), since the preset paper size cannot match the page to be printed, it is necessary to further determine whether the actual paper size meets the requirements of the page to be printed by comparing the relationship between the fourth and first lengths. When the fourth length is greater than or equal to the first length, all jobs are printed normally until printing is completed; when the fourth length is less than the first length, the actual paper in the current image forming device is ejected, the remaining print jobs are canceled, and a prompt message is displayed, prompting the user to reset the print job.

[0083] Specifically, when the first length is greater than or equal to the fourth length, it can be determined that the actual paper size is larger than the required paper size for the page to be printed. Therefore, the entire content of the page to be printed can be printed on the actual paper, and printing can proceed normally. When the first length is less than the fourth length, it can be determined that the actual paper size is smaller than the required paper size for the page to be printed. During printing, the size issue may prevent some content from being printed onto the actual paper, resulting in missing content. Therefore, printing will not be performed using the actual paper. Furthermore, because the actual paper size is smaller, it will not cause paper jams within the image forming device, and thus the actual paper can be ejected.

[0084] In forced printing mode, when it is determined that the second length and the fourth length are inconsistent, that is, the preset paper does not match the actual paper and the user has placed the paper incorrectly, since the size of the actual paper cannot be determined, before comparing the relationship between the fourth length and the first length to determine whether the actual paper can complete the entire content of the page to be printed, it is also necessary to compare the fourth length and the third length to determine whether the image forming device supports printing the actual paper, that is, whether the size of the actual paper exceeds the maximum printing size of the image forming device.

[0085] When the fourth length is greater than the third length, it is determined that the actual paper size exceeds the maximum print size supported by the image forming device, the printing job is stopped, and a paper jam fault is reported.

[0086] When the fourth length is less than or equal to the third length, it is determined that the actual paper size is within the maximum print size supported by the image forming device, and printing can proceed. Then, by comparing the fourth length with the first length, it is determined whether to cancel the remaining print jobs or print all jobs normally.

[0087] The method for comparing the fourth length with the first length is the same as the method for comparing the fourth length with the first length in the forced printing mode. When the fourth length is greater than or equal to the first length, printing is performed normally. When the fourth length is less than the first length, printing is canceled and the actual paper is ejected.

[0088] In both normal and forced printing modes, since the size of the paper tray cannot exceed the maximum paper size supported by the image forming device, once the actual paper size is determined to be consistent with the paper tray size by the second and fourth lengths, i.e., the user has placed the paper correctly, there is no need to compare the fourth and third lengths to determine whether the actual paper exceeds the maximum printing range of the image forming device.

[0089] This application's embodiments determine whether the actual paper meets the printing requirements and execute printing by comparing the size of the page to be printed with the size of the paper tray, and by comparing the size of the paper tray with the size of the actual paper. This eliminates the need for a paper size detection sensor, reducing the cost of the image forming equipment while still meeting the user's printing needs on mismatched paper types. It also avoids wasting consumables by printing the image of the page to be printed on unsuitable paper. Furthermore, even after determining a paper type mismatch, this application still prints a page for the user to confirm the print effect, improving the user experience and ensuring the final execution of the printing job.

[0090] Optionally, in some embodiments, when performing step S105, printing is performed based on the matching result of the preset paper and the actual paper, if it is determined in normal mode that the second length and the fourth length are inconsistent, that is, if it is determined in normal mode that the user has actually placed the paper incorrectly, in addition to directly stopping the machine, canceling the remaining printing job and reporting the paper jam fault, the fourth length, which represents the actual paper size, can be further compared with the third length, which represents the maximum paper size that the image forming device can print, in order to refine the printing process.

[0091] Specifically, the fourth length is compared with the third length. When the fourth length is greater than the third length, it is determined that the actual paper size exceeds the maximum paper size supported by the image forming device, indicating a paper jam and reporting a paper jam fault. When the fourth length is less than the third length, since it has been determined that the actual paper size is inconsistent with the paper size required for the page to be printed, and the actual paper size will not cause a paper jam, the actual paper is ejected, the remaining print job is canceled, and a prompt message is displayed to remind the user to reset the print job.

[0092] When executing S104, if it is determined that printing needs to be performed, and the actual paper matches the preset paper based on the second length and the fourth length representing the actual paper size in the paper tray, the paper in the paper tray needs to be transported as the actual paper into the image forming device to determine the fourth length.

[0093] In normal printing mode, since the second length of the paper tray is known to be the same as the first length representing the page to be printed, and it is assumed that the user has placed the paper correctly in the paper tray, the first length, which is more in line with the size of the page to be printed, is selected to transport the paper. In forced printing mode, since the second length of the paper tray is known to be different from the first length representing the page to be printed, the actual size of the paper cannot be determined. Therefore, in order to avoid paper jams during transport, the third length, which represents the maximum paper size supported by the image forming device, should be selected to transport the paper.

[0094] Optionally, in some embodiments, the user's misconfiguration of the paper tray size is not due to operational error causing the set paper tray size to be inconsistent with the paper size required for the page to be printed, resulting in a discrepancy between the first and second lengths. Rather, it may be due to special circumstances, such as the lack of suitable paper, leading the user to actively select a larger sheet for printing and thus intentionally setting an incorrect paper tray size. Therefore, in forced printing mode, the image forming device can transport the paper using the second length, which represents the paper tray size, instead of using the third length, thereby improving paper feeding accuracy.

[0095] In one specific embodiment, the required paper size for the page to be printed is A4, but the user does not have A4 paper on hand, only A3 paper. Therefore, the user chooses to print using A3 paper and sets the paper tray to the size of A3 paper. After determining the size of the paper tray, the image forming device moves the paper in the paper tray according to the second length of the paper tray, that is, the length of A3 paper.

[0096] Optionally, in some embodiments, in forced printing mode, once the actual paper size is determined to be sufficient for the page to be printed by comparing the fourth length with the first and third lengths, the printing job is executed normally. Since the size of the paper in the paper tray (i.e., the fourth length) has been determined by the first sheet of paper retrieved from the tray, subsequent printing jobs can proceed by using the fourth length, which represents the actual paper size, instead of the third or second length, thus improving paper handling accuracy.

[0097] In one specific embodiment, the required paper size for the page to be printed is B5. The user sets the paper tray size to A4, but actually stores A3-sized paper in the paper tray, and prints using A3-sized paper. After printing begins, the image forming apparatus moves the first sheet of actual paper in the paper tray according to the second length of the paper tray size A4. Once the actual paper size is determined by the first sheet of actual paper, and it is determined that the actual paper can be printed, the remaining actual paper in the paper tray is moved according to the fourth length of the actual paper size A3 for printing, until printing is complete.

[0098] In some embodiments, when performing S105 and printing according to the matching result of the preset paper and the actual paper, the image forming device may jam due to some actual paper sizes exceeding the maximum size supported by the image forming device, i.e., the fourth length is greater than the third length, or due to some special circumstances such as paper sticking.

[0099] Optionally, when the image forming equipment experiences a paper jam, the jammed paper can be automatically ejected via the paper jam ejection function without manual intervention, thereby improving the user experience.

[0100] Specifically, when the image forming equipment detects a paper jam, it activates the forced paper ejection function. This involves independently controlling the conveying structure of the image forming unit to perform two consecutive forced paper ejections, expelling the paper from the unit. If the paper is still not ejected, the forced paper ejection stops, a paper jam fault is reported, and the user is prompted to manually eject the paper.

[0101] In this embodiment, the conveying structures include, but are not limited to, a paper feed roller, a correction roller, a transfer roller, a fixing roller, and a discharge roller. The forced paper jam control can be configured to control multiple conveying structures to alternately rotate forward and backward at certain angles multiple times. For example, three sensors are correspondingly installed on three conveying structures along the paper path, in the order of conveying structure 1, conveying structure 2, and conveying structure 3. If the paper jam occurs at conveying structure 2, all conveying structures are first reversed. When the end of the paper is conveyed to conveying structure 1, the corresponding sensor 1 on conveying structure 1 is triggered, and then all conveying structures are controlled to rotate forward. This can be calculated based on the path and paper length. If conveying structure 1 cannot be triggered within a certain time, manual paper discharge is required. Of course, the scheme for controlling forced paper jam control is not limited to the above scheme. Those skilled in the art, without creative effort, can also implement forward and reverse control of multiple conveying mechanisms based on this application to achieve the same inventive purpose, all of which fall within the scope of protection of this application.

[0102] Optionally, if a power outage occurs during printing, causing the paper to remain inside the image forming device, and the image forming device restarts, a paper jam is also detected, and the paper jam ejection function is activated to eject the paper from the image forming device.

[0103] When the jammed page is ejected, the image forming device needs to reprint the contents of the jammed page before re-executing the printing task.

[0104] Corresponding to the above-described paper size detection method, this application also provides a paper size detection device. The paper size detection device can be implemented as an image forming device. See also... Figure 2 The above is a schematic diagram of the structure of a paper size detection device provided in an embodiment of this application. The paper size detection device may include: an acquisition module 201, a first matching module 202, a determination module 203, a second matching module 204, and a printing module 205.

[0105] The acquisition module 201 acquires a first length representing the page to be printed and a second length representing the size set in the paper tray, respectively.

[0106] The first matching module 202 determines whether the preset paper size matches the required size of the page to be printed based on the first length and the second length. The size of the preset paper size corresponds to the size set in the paper tray.

[0107] The determination module 203 determines whether printing needs to be performed based on the matching result between the preset paper and the page to be printed;

[0108] The second matching module 204 determines whether the actual paper matches the preset paper based on the second length and the fourth length representing the actual paper in the paper tray when it is determined that printing needs to be performed.

[0109] The printing module 205 performs printing based on the matching result between the preset paper and the actual paper.

[0110] Figure 3 This is a schematic diagram illustrating the structure of one embodiment of the electronic device described in this specification. The electronic device can be implemented as the image forming apparatus described above or a cloud server. Figure 3 As shown, the above-mentioned electronic device may include at least one processor; and at least one memory communicatively connected to the processing unit, wherein: the memory stores program instructions that can be executed by the processing unit, and the processor can execute the paper size detection method provided in this embodiment by calling the program instructions.

[0111] The aforementioned electronic device can be a device capable of intelligent dialogue with the user, such as a cloud server. This specification does not limit the specific form of the electronic device in the embodiments. It is understood that the electronic device here refers to the machine mentioned in the method embodiments.

[0112] Figure 3 A block diagram is shown that is suitable for implementing embodiments of this specification in an exemplary electronic device. Figure 3 The electronic device shown is merely an example and should not be construed as limiting the functionality and scope of use of the embodiments described in this specification.

[0113] like Figure 3 As shown, the electronic device is represented in the form of a general-purpose computing device. The components of the electronic device may include, but are not limited to: one or more processors 310, communication interface 320, memory 330, and communication bus 340 connecting different system components (including memory 330, communication interface 320 and processor 310).

[0114] Communication bus 340 represents one or more of several bus architectures, including a memory bus or memory controller, a peripheral bus, a graphics acceleration port, a processor, or a local bus using any of the various bus architectures. For example, these architectures include, but are not limited to, Industry Standard Architecture (ISA) buses, Micro Channel Architecture (MAC) buses, Enhanced ISA buses, Video Electronics Standards Association (VESA) local buses, and Peripheral Component Interconnect (PCI) buses.

[0115] Electronic devices typically include a variety of computer-readable media. These media can be any available media that can be accessed by the electronic device, including volatile and non-volatile media, and removable and non-removable media.

[0116] Memory 330 may include computer system readable media in the form of volatile memory, such as random access memory (RAM) and / or cache memory. The electronic device may further include other removable / non-removable, volatile / non-volatile computer system storage media. Memory 330 may include at least one program product having a set (e.g., at least one) of program modules configured to perform the functions of the embodiments described herein.

[0117] A program / utility having a set (at least one) of program modules can be stored in memory 330. Such program modules include—but are not limited to—an operating system, one or more application programs, other program modules, and program data. Each or some combination of these examples may include an implementation of a network environment. The program modules typically perform the functions and / or methods described in the embodiments of this specification.

[0118] The processor 310 executes various functional applications and data processing by running programs stored in the memory 330, such as implementing the paper size detection method provided in the embodiments shown in this specification.

[0119] This specification provides a non-transitory computer-readable storage medium that stores computer instructions that cause the computer to execute the paper size detection method provided in the embodiments shown in this specification.

[0120] The aforementioned non-transitory computer-readable storage medium may be any combination of one or more computer-readable media. A computer-readable medium may be a computer-readable signal medium or a computer-readable storage medium. A computer-readable storage medium may be, for example—but not limited to—an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. More specific examples of computer-readable storage media (a non-exhaustive list) include: an electrical connection having one or more wires, a portable computer disk, a hard disk, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM), or flash memory, optical fiber, portable compact disk read-only memory (CD-ROM), optical storage device, magnetic storage device, or any suitable combination thereof. In this document, a computer-readable storage medium may be any tangible medium containing or storing a program that may be used by or in connection with an instruction execution system, apparatus, or device.

[0121] Computer-readable signal media may include data signals propagated in baseband or as part of a carrier wave, carrying computer-readable program code. Such propagated data signals may take various forms, including—but not limited to—electromagnetic signals, optical signals, or any suitable combination thereof. Computer-readable signal media may also be any computer-readable medium other than computer-readable storage media, capable of transmitting, propagating, or transmitting programs for use by or in connection with an instruction execution system, apparatus, or device.

[0122] The program code contained on a computer-readable medium may be transmitted using any suitable medium, including—but not limited to—wireless, wire, optical fiber, RF, etc., or any suitable combination thereof.

[0123] Computer program code for performing the operations described herein can be written in one or more programming languages ​​or a combination thereof, including object-oriented programming languages ​​such as Java, Smalltalk, and C++, as well as conventional procedural programming languages ​​such as C or similar languages. The program code can be executed entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving remote computers, the remote computer can be connected to the user's computer via any type of network—including a Local Area Network (LAN) or a Wide Area Network (WAN), or it can be connected to an external computer (e.g., via the Internet using an Internet service provider).

[0124] The foregoing has described specific embodiments of this specification. Other embodiments are within the scope of the appended claims. In some cases, the actions or steps recited in the claims may be performed in a different order than that shown in the embodiments and may still achieve the desired result. Furthermore, the processes depicted in the drawings do not necessarily require the specific or sequential order shown to achieve the desired result. In some embodiments, multitasking and parallel processing are possible or may be advantageous.

[0125] Furthermore, the terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include at least one of that feature. In the description of this specification, "a plurality of" means at least two, such as two, three, etc., unless otherwise explicitly specified.

[0126] Any process or method described in the flowchart or otherwise herein can be understood as representing a module, segment, or portion of code comprising one or more executable instructions for implementing custom logic functions or processes, and the scope of the preferred embodiments of this specification includes additional implementations in which functions may be performed not in the order shown or discussed, including substantially simultaneously or in reverse order depending on the functions involved, as will be understood by those skilled in the art to which the embodiments of this specification pertain.

[0127] Depending on the context, the word "if" as used here can be interpreted as "when," "when," "in response to determination," or "in response to detection." Similarly, depending on the context, the phrase "if determination" or "if detection (of the stated condition or event)" can be interpreted as "when determination," "in response to determination," "when detection (of the stated condition or event)," or "in response to detection (of the stated condition or event)."

[0128] It should be noted that the terminals involved in the embodiments of this specification may include, but are not limited to, personal computers (hereinafter referred to as PCs), personal digital assistants (hereinafter referred to as PDAs), wireless handheld devices, tablet computers, mobile phones, MP3 players, MP4 players, etc.

[0129] In the embodiments provided in this specification, it should be understood that the disclosed systems, apparatuses, and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between apparatuses or units may be electrical, mechanical, or other forms.

[0130] Furthermore, the functional units in the various embodiments of this specification can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or in a combination of hardware and software functional units.

[0131] The integrated units implemented as software functional units described above can be stored in a computer-readable storage medium. These software functional units, stored in a storage medium, include several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) or processor to execute some steps of the methods described in the various embodiments of this specification.

[0132] The above description is merely a preferred embodiment of this specification and is not intended to limit this specification. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this specification should be included within the scope of protection of this specification.

Claims

1. A method for detecting paper size, characterized in that, The method includes: Obtain the first length representing the page to be printed, and the second length representing the size set in the paper tray, respectively; Based on the first length and the second length, it is determined whether the preset paper size matches the required size of the page to be printed, and the size of the preset paper size corresponds to the size of the paper feed tray. Whether printing needs to be performed is determined based on the matching result between the preset paper and the page to be printed; When it is determined that printing needs to be performed, the actual paper is determined to match the preset paper based on the second length and the fourth length representing the actual paper in the paper tray. Printing is performed based on the matching result between the preset paper and the actual paper; The method of performing printing based on the matching result between the preset paper and the actual paper further includes: In forced printing mode, when it is determined that the second length is consistent with the fourth length, it is determined whether the actual paper size matches the required size of the page to be printed based on the fourth length and the first length; When it is determined that the second length is inconsistent with the fourth length, the actual paper size is determined to match the required size of the page to be printed based on the fourth length, the first length, and the third length, wherein the third length is the length that characterizes the maximum paper size that the image forming device supports for printing. The step of determining whether the actual paper size matches the required size of the page to be printed based on the fourth length, the first length, and the third length includes: Determine whether the actual paper exceeds the maximum size supported for printing by the image forming device based on the third length and the fourth length; When the fourth length is greater than the third length, the remaining printing job is cancelled and a paper jam is reported. When the fourth length is less than or equal to the third length, the remaining print jobs are cancelled or all jobs are printed until printing is finished, depending on the fourth length and the first length. The entire printing job, from start to finish, includes: The subsequent actual paper transfer is performed via the fourth length.

2. The method according to claim 1, characterized in that, The step of determining whether printing needs to be performed based on the matching result between the preset paper and the page to be printed includes: When the first length is the same as the second length, it is determined that printing will be performed in normal printing mode; When the first length and the second length are inconsistent, a prompt message is displayed; In response to the user's confirmation print command based on the prompt information, it is determined to execute printing through forced print mode.

3. The method according to claim 1, characterized in that, The step of printing based on the matching result between the preset paper and the actual paper includes: In normal printing mode, when it is determined that the second length is consistent with the fourth length, all jobs are printed until printing is completed; When it is determined that the second length is inconsistent with the fourth length, the remaining printing job is cancelled and a paper jam is reported.

4. The method according to claim 3, characterized in that, After determining that the second length and the fourth length are inconsistent, the method further includes: The image forming device determines whether the actual paper exceeds the maximum size that it can support printing based on the fourth length and the third length, wherein the third length is the length that characterizes the maximum size of paper that the image forming device can support printing. When the fourth length is greater than the third length, the remaining printing job is cancelled and a paper jam is reported. When the fourth length is less than or equal to the third length, the actual paper is ejected and the remaining printing job is canceled.

5. The method according to claim 1, characterized in that, The step of determining whether the actual paper size matches the required size of the page to be printed based on the fourth length and the first length includes: When the fourth length is less than the first length, the actual paper is ejected, and the remaining printing job is canceled; When the fourth length is greater than or equal to the first length, print all jobs until printing is complete; The entire printing job, from start to finish, includes: The subsequent actual paper transfer is performed via the fourth length.

6. The method according to any one of claims 1-5, characterized in that, After determining that printing needs to be performed, the method further includes: determining a fourth length representing the actual paper length within the paper tray, including: The time it takes for the actual paper to pass through the paper tip detection sensor is determined by the time difference between the actual paper tip triggering the paper tip detection sensor and the actual paper tail leaving the paper tip detection sensor. Determine the linear velocity of the calibration roller; The fourth length, representing the actual paper, is determined based on the time it takes for the actual paper to pass through the paper tip detection sensor and the linear velocity of the correction roller.

7. A paper size detection device, characterized in that, The device includes: The acquisition module acquires a first length representing the page to be printed and a second length representing the size set in the paper tray, respectively. The first matching module determines whether the preset paper size matches the required size of the page to be printed based on the first length and the second length, wherein the size of the preset paper size corresponds to the size of the paper tray setting. The determination module determines whether printing needs to be performed based on the matching result between the preset paper and the page to be printed; The second matching module, when it is determined that printing needs to be performed, determines whether the actual paper matches the preset paper based on the second length and the fourth length representing the actual paper in the paper tray. The printing module performs printing based on the matching result between the preset paper and the actual paper; The step of performing printing based on the matching result between the preset paper and the actual paper further includes: In forced printing mode, when it is determined that the second length is consistent with the fourth length, it is determined whether the actual paper size matches the required size of the page to be printed based on the fourth length and the first length; When it is determined that the second length is inconsistent with the fourth length, the actual paper size is determined to match the required size of the page to be printed based on the fourth length, the first length, and the third length, wherein the third length is the length that characterizes the maximum paper size that the image forming device supports for printing. The step of determining whether the actual paper size matches the required size of the page to be printed based on the fourth length, the first length, and the third length includes: Determine whether the actual paper exceeds the maximum size supported for printing by the image forming device based on the third length and the fourth length; When the fourth length is greater than the third length, the remaining printing job is cancelled and a paper jam is reported. When the fourth length is less than or equal to the third length, the remaining print jobs are cancelled or all jobs are printed until printing is finished, depending on the fourth length and the first length. The entire printing job, from start to finish, includes: The subsequent actual paper transfer is performed via the fourth length.

8. An electronic device, characterized in that, include: At least one processor; as well as At least one memory communicatively connected to the processor, wherein: The memory stores program instructions that can be executed by the processor, and the processor can execute the method as described in any one of claims 1 to 6 by calling the program instructions.

9. A storage medium, characterized in that, The storage medium includes a stored program, wherein, when the program is executed, it controls the device on which the storage medium is located to perform the method according to any one of claims 1 to 6.

Citation Information

Patent Citations

  • Prompt method for image formation processing and image formation device

    CN107943435A

  • Image forming device

    JP2005194012A