Remote printing method and system

By searching for available devices around the printer and using them to control printers that do not support remote printing, the high cost of remote printing in existing technologies is solved, achieving low-cost and efficient remote printing results.

CN120491912BActive Publication Date: 2026-07-14HONOR DEVICE CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
HONOR DEVICE CO LTD
Filing Date
2024-02-08
Publication Date
2026-07-14

Smart Images

  • Figure CN120491912B_ABST
    Figure CN120491912B_ABST
Patent Text Reader

Abstract

The application provides a remote printing method and system, relates to the technical field of long-distance communication, and can realize low-cost remote printing. The method comprises the following steps: a first device receives a first operation of a user on a first document. In response to the first operation, a printer displays a first interface. The first interface comprises the identification of one or more first printers and the identification of one or more second printers. The current distance between the second printer and the first device is greater than a preset distance threshold, the second printer has been used by the first device, and the second printer does not support remote printing. The second printer can be searched by a cloud server, and there is an available device within a preset distance threshold range around the second printer. The first device receives a selection operation of a user on a first identification in the first interface, and in response to the selection operation on the first identification, requests a second device to control a third printer to print the first document. The second device is an available device within a preset distance threshold range around the third printer.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of long-distance communication technology, and in particular to a remote printing method and system. Background Technology

[0002] With the rise of remote work and distance education, the demand for remote printing is increasing. However, some printers on the market do not have remote printing capabilities. Currently, remote printing can be enabled by installing new remote print templates on printers that do not support it. However, purchasing new remote print templates is costly.

[0003] Currently, there is an urgent need for a method that can achieve low-cost remote printing. Summary of the Invention

[0004] This application provides a remote printing method and system for achieving low-cost remote printing.

[0005] To achieve the above objectives, the embodiments of this application adopt the following technical solutions:

[0006] In a first aspect, a remote printing method is provided, applied to a first device, the remote printing method comprising:

[0007] The first device receives a first operation from a user on a first document and, in response to the first operation, searches for printers and displays a first interface, wherein the first operation instructs the first device to print the first document, and the first interface includes identifiers of one or more first printers and identifiers of one or more second printers; the first device receives a selection operation from a user on a first identifier in the first interface and, in response to the selection operation on the first identifier, requests a second device to control a third printer to print the first document, wherein the first identifier is the identifier of the third printer among one or more second printers.

[0008] The current distance between the first printer and the first device is less than a preset distance threshold, and / or the first printer supports remote printing. The current distance between the second printer and the first device is greater than the preset distance threshold, the second printer has been used by the first device, and the second printer does not support remote printing. The second printer is a printer that the first device searched for from the cloud server, and there are available devices within the preset distance threshold range around the second printer. The second device is an available device within the preset distance threshold range around the third printer. The preset distance threshold is a distance threshold for short-range wireless communication, which includes Bluetooth and / or Wi-Fi.

[0009] In the remote printing method provided in this application, the first device, in response to a first operation, can search for printers and find a printer (i.e., a second device) that, although not supporting remote printing, is available within a preset distance threshold range. Thus, although the second printer does not support remote printing and the first device cannot directly control it to print documents, the second device has the capability to control it, allowing the first device to remotely control the second printer. Furthermore, using the remote printing method provided in this application, remote printing can be achieved without installing a remote printing module on the second printer that does not support it. In summary, the remote printing method provided in this application enables low-cost remote printing.

[0010] In one possible implementation of the first aspect, the first device, in response to the first operation, searches for a printer, including: the first device, in response to the first operation, searches for a first printer and obtains an identifier of the first printer; sends a first connection request to a cloud server; wherein the first connection request includes the identifier of the first device, and the first connection request is used to request a second printer from the cloud server; and receives a first connection response from the cloud server; wherein the first connection response includes the identifier of the second printer and the identifier of an available device within a preset distance threshold range around the second printer.

[0011] In this implementation, the first device can search for the first printer and obtain its identifier. It can also receive the identifiers of the second printer and available devices from the cloud server. In other words, the first device can search for printers within a preset distance threshold range, or it can search for printers within the preset distance threshold range plus one available device within the preset distance threshold range surrounding the second printer. This allows users to select a printer based on their needs, improving the user experience during the printing process.

[0012] In one possible implementation of the first aspect, the first connection response further includes a first authorization code corresponding to an available device within a preset distance threshold range around the second printer. The first device, in response to a selection operation on the first identifier, requests the second device to control the third printer to print the first document, including: the first device, in response to the selection operation on the first identifier, sending a print request to the second device. The print request includes the first document and the first authorization code corresponding to the second device; the print request is used to request the second device to verify the first authorization code and, upon successful verification, control the third printer to print the first document.

[0013] Specifically, the second device has a built-in authorization code. The second device can compare the first authorization code with its built-in authorization code. If they match, it means the second device has successfully verified the first authorization code; otherwise, if they do not match, it means the second device has failed to verify the first authorization code.

[0014] In this implementation, the second device can use the first authorization code to ensure that the first device sending the first document has passed the verification before controlling the third printer to print the first document, rather than the first document sent by other devices. In other words, the second device can use the first authorization code to verify whether the received document is the first document sent by the first device that is remotely connected to it, thus achieving the effect of monitoring the first document.

[0015] In one possible implementation of the first aspect, the remote printing method further includes encrypting the first document using a preset encryption algorithm before sending the print request to the second device. The print request includes the encrypted first document.

[0016] In this implementation, an encryption algorithm is used to encrypt the first document. Even if the first document is leaked, the security of its content can be guaranteed, thus ensuring the security of the first document.

[0017] In one possible implementation of the first aspect, the first connection response further includes a first connection time between an available device and the second printer within a preset distance threshold range around the second printer. After the first connection time, the available device disconnects from the second printer.

[0018] In this implementation, the first connection response from the cloud server also includes the first connection time between the available device and the second printer. In other words, the cloud server can monitor the connection status between the available device and the second printer so that it can detect in a timely manner if the connection between the available device and the second printer is lost for any reason.

[0019] In one possible implementation of the first aspect, the first interface further includes a first connection time for reminding the user that after the first connection time, the available device can disconnect from the second printer.

[0020] In this implementation, the first connection time is displayed on the first interface, indicating the available time for the second printer. This facilitates time management for the user, allowing them to use the second printer within the specified available time. This improves the user experience during remote printing.

[0021] In one possible implementation of the first aspect, the cloud server records the identifiers of multiple printers and the usage records of each printer; the usage records of each printer include the identifier of the device that used the printer.

[0022] In this implementation, once the cloud server establishes a connection with the first device, it can determine the printers used by the first device based on the printer's usage records and the device's identifier. This allows it to subsequently send the identifier of the second printer, as well as the identifier of an available device within a preset distance threshold around the second printer, to the first device. This implementation effectively improves the efficiency of remote printing.

[0023] In one possible implementation of the first aspect, the usage record for each printer also includes the user account of the device that used the printer. The cloud server maintains multiple user accounts, each corresponding to the identifier of one or more devices.

[0024] Among them, an available device within a preset distance threshold range around the second printer is: a device that meets the preset conditions within the preset distance threshold range around the second printer.

[0025] The preset conditions include: the user account is logged into on the cloud server with the first device, and the second printer is already connected; or,

[0026] The preset conditions include: being in the same home group as the first device and having connected to the second printer; wherein, the cloud server maintains multiple home group home IDs and multiple user accounts in each home group; and each home group has a different home ID.

[0027] In this implementation, the available devices can be those connected to the second printer within a preset distance threshold around the second printer and logged into the cloud server using the same user account as the first device; or devices connected to the second printer within the preset distance threshold around the second printer and in the same homegroup as the first device. Generally, electronic devices logged into the same user account as the first device or in the same homegroup as the first device are usually the electronic devices of people trusted by the owner of the first device (such as family members). Based on this, the security of data transmission can be guaranteed, and user privacy can be protected.

[0028] In one possible implementation of the first aspect, the usage record for each printer also includes the printing connection protocol between the device and the printer.

[0029] In this implementation, the print connection protocol is used to ensure a normal connection between the device and the printer.

[0030] In one possible implementation of the first aspect, the remote printing method further includes: the first device connecting to the fourth printer via short-range wireless communication, controlling the fourth printer to print the second document, and then sending a print record to a cloud server. The print record includes the identifier of the first device, the identifier of the fourth printer, and the user account of the first device.

[0031] In this implementation, the first device sends the print record to the cloud server, which can then record the print record.

[0032] Secondly, a remote printing method is provided, applied to a cloud server. This remote printing method includes: the cloud server receiving a first connection request from a first device. The first connection request includes an identifier of the first device and is used to request a printer from the cloud server. Based on the identifier of the first device, the cloud server queries a second printer previously used by the first device. The second printer is located within a preset distance threshold range, and an available device exists in its vicinity. The second printer does not support remote printing, and the current distance between the second printer and the first device is greater than or equal to the preset distance threshold. The preset distance threshold is a distance threshold for short-range communication (SMR), including Bluetooth and / or Wi-Fi. A first connection response is sent to the first device. The first connection response includes an identifier of the second printer and an identifier of an available device within the preset distance threshold range of the second printer.

[0033] In the remote printing method provided in this application, the cloud server can query the second printer used by the first device based on the identifier of the first device and send a first connection response to the first device. Although the second printer does not support remote printing, and the first device cannot directly control the second printer to print documents, the aforementioned available devices have the capability to control the second printer, and the first device can control the second printer to print documents through these available devices. Thus, the first device can achieve remote control of the second printer. Furthermore, using the remote printing method provided in this application, it is not necessary to install a remote printing module on the second printer that does not support remote printing to achieve remote printing. In summary, the remote printing method provided in this application can achieve low-cost remote printing.

[0034] Since the first connection response includes the identifier of the second printer and the identifier of an available device within a preset distance threshold range around the second printer, even if the second printer does not support remote printing, the first device can remotely control the second printer to print via the available device. Based on this, the second printer can achieve low-cost remote printing without installing a new remote printing template.

[0035] In one possible implementation of the second aspect, the cloud server records the identifiers of multiple printers and the usage records of each printer; the usage records of each printer include the identifier of the device that used the printer.

[0036] In this implementation, once the cloud server establishes a connection with the first device, it can determine the second printer that the first device has used based on the printer's usage record and the first device's identifier. This allows the cloud server to subsequently send the identifier of the second printer, as well as the identifier of an available device within a preset distance threshold around the second printer, to the first device. This implementation effectively improves the efficiency of remote printing.

[0037] In one possible implementation of the second aspect, the cloud server queries a second printer used by the first device based on the identifier of the first device, including: the cloud server queries at least one fifth printer used by the first device from the usage records of multiple printers based on the identifier of the first device; obtains the identifier of at least one third device corresponding to each fifth printer from the usage record of each fifth printer; wherein at least one third device has used the fifth printer, and at least one third device is different from the first device; instructs at least one third device corresponding to each fifth printer to connect to the fifth printer via short-range wireless communication, and determines the second printer from the at least one fifth printer based on the connection result; wherein the second printer is the printer among the at least one fifth printer that has successfully connected to the corresponding third device via short-range wireless communication.

[0038] In this implementation, the cloud server first queries at least one fifth printer used by the first device, and obtains the identifier of the third device based on the usage record of the fifth printer. This identifier is used to instruct the third device to connect to the fifth printer. The printer that successfully connects to the corresponding third device via short-range wireless communication among the at least one fifth printer is designated as the second printer. Through this method, the cloud server can determine the second and third printers based on the identifier of the first device, effectively ensuring printing efficiency.

[0039] In one possible implementation of the second aspect, the cloud server instructs at least one third device corresponding to each fifth printer to connect to the fifth printer via the short-range wireless communication, comprising: the cloud server sending a connection instruction to each third device; wherein the connection instruction includes an identifier of the fifth printer corresponding to the third device, and the connection instruction is used to instruct the third device to connect to the fifth printer based on the identifier of the fifth printer; receiving a connection result from the third device; wherein the connection result is sent after the third device successfully connects to the fifth printer, and the connection result includes the identifier of the third device and the identifier of the fifth printer.

[0040] In this implementation, the cloud server can send a connection command to each third device to determine if a printer among the fifth printers has successfully connected to a third device, and designate the printer successfully connected to the third device as the second printer. Thus, when using the second printer for remote printing, since the third device is already connected to the second printer, the time required for connecting the third device to the second printer is saved during the remote printing process, effectively ensuring the efficiency of remote printing.

[0041] In one possible implementation of the second aspect, the connection result also includes: the connection time of the third device connecting to the fifth printer, and the first connection time between the third device and the fifth printer, wherein the first connection time is the planned time for the third device and the fifth printer to maintain a connection.

[0042] In this implementation, the first connection time reflects the available time of the second printer, facilitating time management for the user and ensuring the second printer is used within the specified available time. This improves the user experience during remote printing.

[0043] In one possible implementation of the second aspect, the usage record for each printer also includes the user account of the device that used the printer. The cloud server maintains multiple user accounts, each corresponding to the identifier of one or more devices.

[0044] Specifically, the identifier of at least one third device corresponding to each fifth printer is obtained from the usage record of each fifth printer, including:

[0045] From the usage records of each fifth printer, obtain the identifier of at least one third device that logged into the same user account on the cloud server as the first device. Alternatively,

[0046] From the usage records of each fifth printer, obtain the identifier of at least one third device that is in the same home group as the first device; wherein, the cloud server maintains multiple home group home IDs and multiple user accounts in each home group; each home group has a different home ID.

[0047] In this implementation, the cloud server associates printer usage records with user accounts to determine the user account corresponding to the device using the printer. This allows the cloud server to identify and manage devices based on user accounts. Furthermore, it restricts third-party devices from logging into the same user account or being in the same homegroup as the first device. Generally, electronic devices logged into the same user account or in the same homegroup as the first device belong to someone trusted by the first device's owner (such as a family member). This ensures data transmission security and protects user privacy.

[0048] In one possible implementation of the second aspect, after the cloud server determines the second printer from at least one fifth printer based on the connection result, and before the cloud server sends the first connection response to the first device, the method further includes: the cloud server designating the first third device that has successfully connected to the fifth printer via short-range wireless communication as an available device within a preset distance threshold range around the second printer.

[0049] Alternatively, the usage record for each printer may also include the last connection time between the device that used the printer and the printer; after determining the second printer from at least one fifth printer based on the connection result, and before sending the first connection response to the first device, the method may further include: identifying the third device with the latest last connection time to the fifth printer among the first third devices that successfully connected to the fifth printer via short-range wireless communication as an available device within a preset distance threshold range around the second printer.

[0050] In this implementation, after the cloud server identifies the second printer, it can select available devices around the second printer in two different ways. For example, it can choose the third device that has successfully connected to the fifth printer the fastest via short-range wireless communication, or the third device that last connected to the fifth printer the latest among the first three devices that successfully connected via short-range wireless communication. This approach is beneficial for improving printing efficiency.

[0051] In one possible implementation of the second aspect, the method further includes: after a third device successfully connects to the fifth printer via short-range wireless communication, it sends a pause command to other third devices corresponding to the fifth printer; wherein the pause command is used to instruct the other third devices to stop connecting to the fifth printer via short-range wireless communication.

[0052] In this implementation, the first device only needs one available device (the fifth printer) to assist in remote printing, and the cloud server only needs to select one available device. After a third device successfully connects to the fifth printer via short-range wireless communication, the cloud server can send a pause command to other third devices connected to the fifth printer. This prevents other third devices from responding to connection commands to connect to the fifth printer, effectively ensuring that only one third device communicates with the fifth printer at a time and avoiding communication conflicts.

[0053] In one possible implementation of the second aspect, the remote printing method further includes: a cloud server receiving a printing record from a first device; wherein the printing record is sent by the first device after it connects to a fourth printer via short-range wireless communication and controls the fourth printer to print a second document; the printing record includes the identifier of the first device and the identifier of the fourth printer; and the usage record of the fourth printer is updated based on the printing record.

[0054] In this implementation, the cloud server can track and record the printing activities between the first device and the fourth printer by receiving the printing records sent by the first device. By updating the usage records of the fourth printer, the real-time nature of the usage records of the fourth printer in the cloud server can be guaranteed, thereby reducing the probability that the fourth printer will be unable to connect to the device that has used the fourth printer in the future, and ensuring the efficiency of remote printing.

[0055] In one possible implementation of the second aspect, the print record also includes the user account of the first device; or, the print record also includes the user account of the first device and the family ID of the family group to which the user account belongs.

[0056] In this implementation, the cloud server can manage devices logged into the same user account as the first device through the user account of the first device; and can manage devices within the family group through the family ID of the family group to which the user account belongs.

[0057] Thirdly, a remote printing system is provided, which includes: a first device, one or more first printers, one or more second printers, a cloud server, and a second device.

[0058] The current distance between the first printer and the first device is less than a preset distance threshold, and / or the first printer supports remote printing; the current distance between the second printer and the first device is greater than a preset distance threshold, the second printer has been used by the first device, and the second printer does not support remote printing.

[0059] The first device is used to perform the method of any one of the first aspects above;

[0060] The cloud server is used to execute any of the methods in the second aspect above;

[0061] The second device is used to control a third printer among one or more second printers to print a first document in response to a request from the first device; wherein the second device is an available device within a preset distance threshold range around the third printer.

[0062] In the remote printing system provided in this application, the first device, in response to a first operation, can search for printers and find a printer (i.e., the second printer) that, although not supporting remote printing, is available within a preset distance threshold. Thus, although the second printer does not support remote printing and the first device cannot directly control it to print documents, the second device has the capability to control it, allowing the first device to remotely control the second printer. Furthermore, using the remote printing method provided in this application, remote printing can be achieved without installing a remote printing module on the second printer that does not support it. In summary, the remote printing system provided in this application enables low-cost remote printing.

[0063] Fourthly, an electronic device is provided, comprising: a display screen, a communication module, a memory, and one or more processors, wherein the display screen, the communication module, the memory, and the processors are coupled; the communication module is used to communicate with other devices; the memory is used to store computer program code; the computer program code includes computer instructions, which, when executed by the processor, cause the electronic device to perform the method as described in any of the first aspects above.

[0064] Fifthly, a cloud server is provided, comprising: a communication module, a memory, and one or more processors; the communication module, the memory, and the processors are coupled; the communication module is used to communicate with other devices; the memory is used to store computer program code; the computer program code includes computer instructions, which, when executed by the processor, cause the cloud server to perform any of the remote printing methods described in the second aspect above.

[0065] In a sixth aspect, a computer-readable storage medium is provided, the computer-readable storage medium including computer instructions that, when executed on an electronic device, cause the electronic device to perform a remote printing method as described in the first aspect or any one of the first aspects.

[0066] In a seventh aspect, a computer-readable storage medium is provided, the computer-readable storage medium including computer instructions that, when executed on a cloud server, cause the cloud server to perform the remote printing method as described in the second aspect or any of the methods in the second aspect.

[0067] Eighthly, a computer program product is provided, comprising a computer program / instructions that, when executed by a processor in a computer, enable the computer to implement the steps of any one of the remote printing methods described in the first and second aspects.

[0068] A ninth aspect provides a chip system including a processor for supporting an electronic device in performing the functions described in the first aspect above. In one possible design, the device further includes a memory for storing program instructions and data necessary for the electronic device. When the device is a chip system, it can be composed of chips or may include chips and other discrete devices.

[0069] The technical effects of any of the design methods in aspects four through eight can be found in the technical effects of different design methods in aspect one, and will not be repeated here. Attached Figure Description

[0070] Figure 1A This is a schematic diagram of the architecture scenario of the remote printing system for time period 1 provided in the embodiments of this application;

[0071] Figure 1B This application provides a schematic diagram of another remote printing system scenario for the remote printing system provided in the embodiment of the present application.

[0072] Figure 1C This is a schematic diagram of a remote printing system architecture provided in an embodiment of this application.

[0073] Figure 2 This is a schematic diagram of the overall hardware structure of the first device provided in the embodiments of this application;

[0074] Figure 3 This application provides a schematic diagram of the system architecture for remote printing using a printing system.

[0075] Figure 4 A flowchart illustrating a remote printing scenario provided in an embodiment of this application;

[0076] Figure 5 A schematic diagram of the display interface of an electronic device provided in an embodiment of this application;

[0077] Figure 6 A schematic diagram of the display interface of an electronic device provided in this application embodiment. Figure 2 ;

[0078] Figure 7 A schematic diagram of the display interface of an electronic device provided in this application embodiment. Figure 3 ;

[0079] Figure 8A schematic diagram of the display interface of an electronic device provided in this application embodiment. Figure 4 ;

[0080] Figure 9 A schematic diagram of the display interface of an electronic device provided in an embodiment of this application;

[0081] Figure 10 A flowchart illustrating a remote printing method provided in this application embodiment is shown below;

[0082] Figure 11 A flowchart illustrating a remote printing method provided in this application embodiment. Figure 2 ;

[0083] Figure 12 A flowchart illustrating a remote printing method provided in this application embodiment. Figure 3 ;

[0084] Figure 13 A schematic diagram of the printing process provided for an embodiment of this application;

[0085] Figure 14 A schematic diagram of the printing process provided for embodiments of this application. Figure 2 . Detailed Implementation

[0086] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. In the description of the embodiments of this application, the terminology used in the following embodiments is for the purpose of describing specific embodiments only and is not intended to limit the application. Furthermore, to facilitate a clear description of the technical solutions of the embodiments of this application, the terms "first," "second," etc., are used in the embodiments of this application to distinguish identical or similar items with substantially the same function and effect. Those skilled in the art will understand that the terms "first," "second," etc., do not limit the quantity or execution order, and that "first," "second," etc., are not necessarily different. Also, in the description of the embodiments of this application, unless otherwise stated, "multiple" means two or more.

[0087] Once connected to a printer, electronic devices (such as laptops, mobile phones, or tablets) can control the printer to print documents. The connection between electronic devices and printers can be divided into wired connections and wireless connections. Wireless printing methods can be further divided into two types: remote printing (also known as far-field printing) and near-field printing.

[0088] Near-field printing refers to a situation where the distance between an electronic device and a printer is less than a preset distance threshold; the electronic device and printer can establish a short-range wireless connection; and the electronic device controls the printer to print documents through this short-range wireless connection. The preset distance threshold is a distance threshold for short-range wireless communication. If the distance between two devices is within the range corresponding to the preset distance threshold, then the two devices can establish a short-range wireless connection to achieve short-range wireless communication. For example, the short-range wireless communication may include at least one of Bluetooth, Wi-Fi, or ZigBee.

[0089] For example, such as Figure 1A As shown, during a time period 1, mobile phone 100 and printer 103 are in the same spatial environment 12, and the distance between mobile phone 100 and printer 103 is less than a preset distance threshold. In this spatial environment 12, mobile phone 100 can establish a short-range wireless connection with printer 103 and control printer 103 to print documents. However, the spatial environment in which mobile phone 100 is located may change as the location of mobile phone 100 changes. For example, in another time period 2, such as... Figure 1B As shown, phone 100 may enter space environment 11. (As indicated...) Figure 1B As shown, the mobile phone 100 and the printer 101 are in the same spatial environment 11, and the distance between the mobile phone 100 and the printer 101 is less than a preset distance threshold. In the aforementioned spatial environment 11, the mobile phone 100 can establish a short-range wireless connection with the printer 101 and control the printer 101 to print documents.

[0090] During the aforementioned time period 2, such as Figure 1B As shown, mobile phone 200, printer 102, and printer 103 are in the same spatial environment 12. The distance between mobile phone 200 and printer 102 is less than a preset distance threshold, and the distance between mobile phone 200 and printer 103 is less than a preset distance threshold. In the aforementioned spatial environment 12, mobile phone 200 can establish a short-range wireless connection with printer 102 and control printer 102 to print documents; mobile phone 200 can also establish a short-range wireless connection with printer 103 and control printer 102 to print documents. The aforementioned spatial environments 11 and 12 can be a user's home, office, or public places such as a library or coffee shop.

[0091] Remote printing refers to a situation where the distance between an electronic device and a printer exceeds a preset distance threshold; the electronic device can remotely connect to the printer and control it to print documents. Printers that support remote printing are equipped with remote print templates. These templates can be standalone hardware devices, plug-ins, or expansion cards, used to enable long-distance communication between the printer and the electronic device via cloud communication.

[0092] For example, during time period 2, although mobile phone 300 and printer 102 are not in the same spatial environment (e.g., mobile phone 300 is in spatial environment 13, and printer 102 is in spatial environment 12), the distance between mobile phone 100 and printer 102 is greater than a preset distance threshold; however, as Figure 1B As shown, printer 102 supports remote printing; therefore, mobile phone 100 can connect to printer 102 and control printer 102 to print documents. Similarly, mobile phone 100 can also connect to printer 102 and control printer 102 to print documents.

[0093] Currently, most printers (such as Figure 1B Printers 101, 102, and 103 shown support near-field printing, and a large number of printers (such as...) Figure 1B Printers 101 and 103 shown do not support remote printing. Therefore, Figure 1B Neither mobile phone 100 nor mobile phone 300 can control printer 103 to remotely print documents, and mobile phone 300 cannot control printer 101 to remotely print documents either. Although remote printing can be achieved by purchasing and configuring a remote printing module for the printer, the cost is high. With the increasing demand for remote printing from users, how to achieve remote printing on existing printers that support near-field printing at a low cost is an urgent problem to be solved.

[0094] Based on this, the embodiments of this application provide a remote printing method that can realize remote printing on existing printers without configuring a remote printing module, thereby achieving low-cost remote printing.

[0095] Specifically, in response to a user's print request, the electronic device (i.e., the first device) can search for printers and find a second printer (i.e., the second device) that is available within a preset distance threshold range, even though it does not support remote printing. Thus, although the second printer does not support remote printing and the first device cannot directly control it to print documents, the second device has the capability to control it, allowing the first device to remotely control the second printer.

[0096] Please refer to Figure 1C This illustration shows a schematic diagram of a remote printing system architecture provided in an embodiment of this application. Combined with... Figure 1A ,like Figure 1C As shown, the remote printing system includes: a first device (such as a mobile phone 100), a second printer (such as a printer 103) that does not support remote printing, a second device (such as a tablet computer 400 or a foldable screen mobile phone 500), and a cloud server 600.

[0097] In this system, mobile phone 100 can locate printer 103 via cloud server 600. Although printer 103 does not support remote printing, there are available devices (i.e., second devices, such as tablet computer 400) within a preset distance threshold around printer 103. Mobile phone 100 can control printer 103 to print documents via tablet computer 400.

[0098] It should be noted that the above description uses a mobile phone as the first device and a tablet computer as the second device to illustrate the implementation principle of this solution. The actual product forms of the first and second devices are not limited to these. For example, the first and second devices mentioned above can be any electronic device that supports wireless communication, such as a mobile phone, tablet computer, laptop computer, personal computer (PC), ultra-mobile personal computer (UMPC), handheld computer, netbook, smart home device (e.g., smart TV, smart screen, large screen, smart speaker, smart air conditioner, etc.), personal digital assistant (PDA), wearable device (e.g., smartwatch, smart bracelet, etc.), in-vehicle device, virtual reality device, etc. This application embodiment does not impose any restrictions on this. The device types of the first and second devices mentioned above can be the same or different.

[0099] This application uses a mobile phone as an example to describe the hardware structure of the first device described above. Figure 2 As shown, it illustrates the overall hardware structure of mobile phone 100.

[0100] Mobile phone 100 may include a processor 110, an external memory interface 120, an internal memory 121, a universal serial bus (USB) interface 130, a charging management module 140, a power management module 141, a battery 142, antenna 1, antenna 2, a mobile communication module 150, a wireless communication module 160, an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, a sensor module 180, buttons 190, a motor 191, an indicator 192, a camera 193, a display screen 194, and a subscriber identification module (SIM) card interface 195, etc. The sensor module 180 may include a pressure sensor 180A, a gyroscope sensor 180B, a barometric pressure sensor 180C, a magnetic sensor 180D, etc.

[0101] It is understood that the structures illustrated in the embodiments of the present invention do not constitute a specific limitation on the mobile phone 100. In other embodiments of this application, the mobile phone 100 may include more or fewer components than illustrated, or combine some components, or split some components, or have different component arrangements. The illustrated components may be implemented in hardware, software, or a combination of software and hardware.

[0102] The processor 110 described above may include one or more processing units, such as an application processor (AP), a modem processor, a graphics processing unit (GPU), an image signal processor (ISP), a controller, memory, a video codec, a digital signal processor (DSP), a baseband processor, and / or a neural network processing unit (NPU). These different processing units may be independent devices or integrated into one or more processors.

[0103] The controller can serve as the central nervous system and command center of the mobile phone 100. Based on the instruction operation code and timing signals, the controller generates operation control signals to control the fetching and execution of instructions.

[0104] The processor 110 may also include a memory for storing instructions and data. In some embodiments, the memory in the processor 110 is a cache memory. This memory can store instructions or data that the processor 110 has just used or that are used repeatedly. If the processor 110 needs to use the instruction or data again, it can retrieve it directly from the memory. This avoids repeated accesses, reduces the waiting time of the processor 110, and thus improves the efficiency of the system.

[0105] In some embodiments, the processor 110 may include one or more interfaces. Interfaces may include an inter-integrated circuit (I2C) interface, an inter-integrated circuit sound (I2S) interface, a pulse code modulation (PCM) interface, a universal asynchronous receiver / transmitter (UART) interface, a mobile industry processor interface (MIPI), a general-purpose input / output (GPIO) interface, a subscriber identity module (SIM) interface, and / or a universal serial bus (USB) interface, etc.

[0106] It is understood that the interface connection relationships between the modules illustrated in the embodiments of the present invention are merely illustrative and do not constitute a structural limitation on the mobile phone 100. In other embodiments of this application, the mobile phone 100 may also adopt different interface connection methods or combinations of multiple interface connection methods as described in the above embodiments.

[0107] The wireless communication function of mobile phone 100 can be realized through antenna 1, antenna 2, mobile communication module 150, wireless communication module 160, modem processor and baseband processor.

[0108] Antenna 1 and antenna 2 are used to transmit and receive electromagnetic wave signals. Each antenna in mobile phone 100 can be used to cover one or more communication frequency bands. Different antennas can also be reused to improve antenna utilization. For example, antenna 1 can be reused as a diversity antenna for a wireless local area network. In some other embodiments, the antennas can be used in conjunction with a tuning switch.

[0109] The mobile communication module 150 can provide wireless communication solutions, including 2G / 3G / 4G / 5G, for use on the mobile phone 100. In this embodiment, the mobile communication module 150 can be used to support communication between the mobile phone 100 and the cloud server 600, and to obtain relevant information about the second device from the cloud server 600. The mobile communication module 150 can also support communication between the mobile phone 100 and the second device, enabling the second device to control the printer 103 to print documents, thus achieving remote printing.

[0110] The wireless communication module 160 can provide solutions for wireless communication applications on the mobile phone 100, including wireless local area networks (WLAN) (such as wireless fidelity (Wi-Fi) networks), Bluetooth (BT), global navigation satellite system (GNSS), frequency modulation (FM), near field communication (NFC), infrared (IR), and satellite communication technologies.

[0111] In this embodiment, the wireless communication module 160 can be used to support the mobile phone 100 to access the wireless local area network, communicate with the cloud server 600, and obtain relevant information about the second device from the cloud server 600. The wireless communication module 160 can also support the mobile phone 100 to access the wireless local area network, communicate with the second device, and control the printer 103 to print documents, thus achieving remote printing.

[0112] In some embodiments, antenna 1 of mobile phone 100 is coupled to mobile communication module 150, and antenna 2 is coupled to wireless communication module 160, enabling mobile phone 100 to communicate with networks and other devices via wireless communication technology. Wireless communication technology may include Global System for Mobile Communications (GSM), General Packet Radio Service (GPRS), Code Division Multiple Access (CDMA), Wideband Code Division Multiple Access (WCDMA), Time-Division Code Division Multiple Access (TD-SCDMA), Long Term Evolution (LTE), BT, GNSS, WLAN, NFC, FM, and / or IR technologies, etc. GNSS can include the Global Positioning System (GPS), the Global Navigation Satellite System (GLONASS), the BeiDou Navigation Satellite System (BDS), the Quasi-Zenith Satellite System (QZSS), and / or satellite-based augmentation systems (SBAS).

[0113] The mobile phone 100 implements display functions through a GPU, a display screen 194, and an application processor. The GPU is a microprocessor for image processing, connected to the display screen 194 and the application processor. The GPU performs mathematical and geometric calculations and is used for graphics rendering. The processor 110 may include one or more GPUs, which execute program instructions to generate or modify display information. The display screen 194 is used to display images, videos, etc. In this embodiment, the display screen 194 can be used to display interfaces related to documents to be printed, interfaces related to searching for printers, and interfaces related to the mobile phone 100 controlling the printer 103 to print documents, etc.

[0114] The external storage interface 120 can be used to connect an external storage card, such as a Micro SD card, to expand the storage capacity of the mobile phone 100. The external storage card communicates with the processor 110 through the external storage interface 120 to perform data storage functions. For example, music, video, and other files can be saved on the external storage card.

[0115] The internal memory 121 can be used to store computer executable program code, which includes instructions. The processor 110 executes various functional applications and data processing of the mobile phone 100 by running the instructions stored in the internal memory 121. The internal memory 121 may include a program storage area and a data storage area. The program storage area may store the operating system, at least one application program required for a function (such as sound playback, image playback, etc.), etc. The data storage area may store data created during the use of the mobile phone 100 (such as audio data, phonebook, etc.). Furthermore, the internal memory 121 may include high-speed random access memory, and may also include non-volatile memory, such as at least one disk storage device, flash memory device, universal flash storage (UFS), etc.

[0116] In this embodiment, the hardware structure of the second device can be referred to Figure 2 The hardware structure of the mobile phone 100 shown will not be described in detail here.

[0117] Combination Figure 1C The remote printing system architecture shown is as follows: Figure 1C As shown, the remote printing system includes: a mobile phone 100 and a printer 101 in spatial environment 11, a printer 102, a printer 103, a mobile phone 200, a mobile phone 500 and a tablet computer 400 in spatial environment 12, and a cloud server 600.

[0118] Printers 101 and 103 do not support remote printing, while printer 102 does. It should be noted that the location of the mobile phone changes with the user, therefore the spatial environment in which the mobile phone is located may differ at different times. In this embodiment, mobile phone 100 and printer 101 are in spatial environment 11, while printers 102 and 103, mobile phone 200, mobile phone 500, and tablet computer 400 are in spatial environment 12, all within time period 2. In this embodiment, the remote printing process occurs within time period 2. Time period 2 is not a specific time period, but rather refers to the time in which each device and printer is located. Figure 1C The spatial environment shown corresponds to the time period.

[0119] This application provides a remote printing method, which allows a mobile phone 100 to control a printer 103 for remote printing. The remote printing method can be divided into two processes: Process One and Process Two. Process One involves a short-range connection between the mobile phone 100 and the printer 103 to achieve near-field printing. In Process One, after the mobile phone 100 controls the printer 103 for near-field printing, a print record is generated and uploaded to a cloud server. Thus, in Process Two, the cloud server can be requested to query the printers used by the mobile phone 100 based on the print record, enabling remote printing.

[0120] Process 1: Near-field printing process where mobile phone 100 and printer 103 are both in spatial environment 12.

[0121] like Figure 1A As shown, during time period 1, mobile phone 100 and printer 103 are both in spatial environment 12, and the distance between them is less than a preset distance threshold. Figure 3 As shown, process one may include S401-S403.

[0122] S401, mobile phone 100 and printer 103 are in the same spatial environment 12. Mobile phone 100 connects to printer 103 through short-range wireless communication and controls printer 103 to print document 1.

[0123] In this embodiment, mobile phone 100 is the first device, and document 1 is the second document. In process one, printer 103 serves as the fourth printer.

[0124] S402, Mobile phone 100 sends the print record 1 between mobile phone 100 and printer 103 to cloud server 600.

[0125] Once the mobile phone 100 controls the printer 103 to print a document in the near field, it can send the corresponding print record to the cloud server 600.

[0126] In some embodiments, the above-mentioned print record 1 may include the identifier of the mobile phone 100 and the identifier of the printer 103.

[0127] In some embodiments, the above-mentioned print record 1 may include not only the identifier of mobile phone 100 and the identifier of printer 103, but also the user account of mobile phone 100 (such as Ross_582).

[0128] In other embodiments, print record 1 may include not only the identifier of mobile phone 100, the identifier of printer 103, and the user account of mobile phone 100 (e.g., Ross_582), but also the homegroup ID (e.g., Home_a) to which user account 1 belongs. The aforementioned user account and homegroup ID are used by cloud server 600 to query available devices around printer 103. See the following description for details.

[0129] S403, cloud server 600 receives print record 1 from mobile phone 100 and updates the usage record of printer 103 according to print record 1.

[0130] It should be understood that the cloud server 600 stores the identifiers of multiple printers, as well as the usage records of each printer. Each printer's usage record includes the identifier of the device that used the printer. These usage records are statistically derived from print records uploaded by electronic devices after using the printer. For example, the cloud server 600 may store the usage records shown in Table 1 before executing S403.

[0131] Table 1

[0132]

[0133]

[0134] In some embodiments, the cloud server 600 maintains multiple user accounts, each user account corresponding to the identifier of one or more devices. A printer usage record may also include the user account of the device that has used the printer. For example, please refer to Table 2, which shows an example of the printer 103 usage record saved by the cloud server 600 before executing S403.

[0135] Table 2

[0136]

[0137] In other embodiments, a printer usage log may include not only the user account of the device that used the printer, but also the home group ID to which the user account belongs. For example, please refer to Table 3, which shows an example of the printer 103 usage log saved by the cloud server 600 before executing S403.

[0138] Table 3

[0139]

[0140] It's important to note that the usage records for each printer stored on the cloud server 600 may not include the user accounts of all devices that have used that printer. Some devices may choose to hide their user accounts. In this case, the cloud server 600 will not receive and save the corresponding device's user account. Similarly, the usage records may not include the HomeGroup IDs of all devices that have used the printer. For example, some devices may not be joined to any HomeGroup and therefore will not send their corresponding HomeGroup IDs to the cloud server 600.

[0141] For example, print record 1 includes the identifier of mobile phone 100, the identifier of printer 103, user account (e.g., Ross_582), and home group ID (e.g., Home_a). Cloud server 600 executes S403, which can update the usage record of printer 103 shown in Table 3, resulting in the updated usage record of printer 103 shown in Table 4.

[0142] Table 4

[0143]

[0144]

[0145] In some embodiments, the above-mentioned print record 1 may also include the time when the mobile phone 100 performs S401 to use the printer 103, such as 2024.1.15-14:00. Correspondingly, the printer usage record stored by the cloud server 600 may also include the time when each device uses the printer, such as the time of the most recent printer use or the time of each printer use. For example, the cloud server 600 may store the printer 103 usage record shown in Table 5.

[0146] Table 5

[0147]

[0148] Process Two: Remote printing process where mobile phone 100 and printer 103 are in different spatial environments. For example... Figure 1C As shown, during time period 2, mobile phone 100 is in spatial environment 11, printer 103 is in spatial environment 12, and the distance between mobile phone 100 and printer 103 is greater than a preset distance threshold.

[0149] In process one above, after mobile phone 100 controls printer 103 for near-field printing, the print record is uploaded to the cloud server. In process two, based on the print record in the cloud server, the printer used by mobile phone 100 (e.g., printer 103) can be queried to achieve far-field printing. Specifically, as follows... Figure 3 or Figure 4 As shown, process two may include S501-S505.

[0150] S501, Mobile phone 100 receives a first operation from the user on the first document. This first operation instructs mobile phone 100 to print document 2.

[0151] For example, mobile phone 100 can receive document 2 from other devices via instant messaging software. For instance, document 2 could be homework assigned by a teacher and sent to parents via instant messaging software. Alternatively, document 2 could be any type of document, such as a work document, a family record document, or an article shared by someone else. Or, document 2 could be a document downloaded from a webpage by the user using mobile phone 100. This application embodiment does not limit the source of document 2.

[0152] In some embodiments, after receiving or downloading document 2, mobile phone 100 can print document 2 in response to user operation (i.e., first operation) without opening document 2.

[0153] For example, the mobile phone 100 displays as follows Figure 5 The instant messaging software chat interface (a) shown in (a) is displayed. Mobile phone 100 receives document 2 (e.g., "Picture Description"). In response to user input... Figure 5 The chat interface shown in (a) of document 2 (such as "Picture Caption") has preset operations (such as double-click or long-press operations), which can be displayed on mobile phone 100. Figure 5 The information box shown in (b) may include a "Print" button. The first operation described above may be a user clicking the "Print" button in the information box.

[0154] For example, after receiving document 2 via instant messaging software, mobile phone 100 may not currently display the chat interface described above. In this case, mobile phone 100 can send a message such as... Figure 6 The notification message shown may include a "Print" button. The first operation described above is the user clicking the "Print" button.

[0155] For example, after mobile phone 100 finishes downloading document 2 from the webpage, it can display a notification message indicating that the download is complete. This notification message may include a "Print" button. The first operation mentioned above is the user clicking the "Print" button.

[0156] In other embodiments, after receiving or downloading document 2, mobile phone 100 can open document 2 in response to a user's action. Then, in response to the user's first action on the opened document, document 2 can be printed.

[0157] For example, after receiving document 2, mobile phone 100 can display... Figure 7 The notification message shown in (a) may include an "Open" button. This is in response to the user's... Figure 7 Clicking the "Open" button in (a) allows mobile phone 100 to open document 2 and display it. Figure 7 The file preview interface is shown in (b) above. Mobile phone 100 responds to user input... Figure 7 Clicking the "..." icon in the upper right corner of the interface shown in (b) displays... Figure 7 The prompt box shown in (c) may include a "Print" icon. The first action described above is the user clicking the "Print" icon.

[0158] For example, mobile phone 100 responds to the user opening Figure 5 The operation shown in (a) of the "Picture Description" document (i.e., document 2) can display... Figure 7 The file preview interface is shown in (b) above. It responds to user input... Figure 7 Clicking the "..." icon in the upper right corner of the interface shown in (b) will allow the phone to display... Figure 7 The prompt box shown in (c) may include a "Print" icon. The first action described above is the user clicking the "Print" icon.

[0159] For example, after receiving document 2, mobile phone 100 can display as follows: Figure 8 The prompt message shown indicates that you should open document 2 and display the following: Figure 7 The file preview interface is shown in (b) above. It responds to user input such as... Figure 7 Clicking the "..." icon in the upper right corner of the interface shown in (b) will display the following on mobile phone 100: Figure 7 The prompt box shown in (c) may include a "Print" icon. The first action described above is the user clicking the "Print" icon.

[0160] For example, after mobile phone 100 finishes downloading document 2 from the webpage, it can display a notification message indicating that the download is complete. After displaying this notification, it can open document 2 and display its open interface. Then, in response to the user's first action on the opened document 2, it can print document 2.

[0161] It should be noted that the above Figure 5 , Figure 6 , Figure 7 as well as Figure 8 The interface shown is for illustrative purposes only and is not intended to limit the scope of the interface displayed in this application. Furthermore, Document 2 is not limited to the document type shown in the illustrations (such as...). It can also be used for other document types (such as...) This application does not limit this.

[0162] S502, in response to the first operation, mobile phone 100 searches for printers and displays a first interface. This first interface includes identifiers for one or more first printers and identifiers for one or more second printers. The second printers are those found by mobile phone 100 from cloud server 600.

[0163] Among them, the current distance between the first printer and the mobile phone 100 is less than a preset distance threshold, and / or the first printer supports remote printing.

[0164] For example, in response to the first operation described above, mobile phone 100 can search for and display printers. Figure 9 The first interface 910 shown includes an identifier 901 for a "nearby-WiFi" printer, an identifier 902 for a "nearby-Bluetooth" printer, and an identifier 903 for a cloud printer.

[0165] like Figure 1C As shown, printer 101 and mobile phone 100 are in the same spatial environment 11 during time period 2, and the current distance between printer 101 and mobile phone 100 is less than a preset distance threshold; therefore, printer 101 is the first printer. Wherein, Figure 9 The labels 901 for "Nearby-WiFi" printers and 902 for "Nearby-Bluetooth" printers shown may be... Figure 1C The printer 101 is shown in the diagram. That is to say, Figure 9 The identifiers 901 for the "Nearby-WiFi" printer and 902 for the "Nearby-Bluetooth" printer shown are identifiers for the first printer.

[0166] like Figure 1C As shown, during time period 2, the current distance between printer 102 and mobile phone 100 is greater than the preset distance threshold, but printer 102 supports remote printing and is the first printer. Figure 9 The cloud printer identifier 903 shown can be... Figure 1C The printer 102 is shown in the diagram. That is to say, Figure 9 The cloud printer identifier 903 shown is the identifier of the first printer.

[0167] The second printer mentioned above is the printer that mobile phone 100 searches for from cloud server 600. The second printer meets the following conditions: the current distance between the second printer and mobile phone 100 is greater than a preset distance threshold, the second printer has been used by mobile phone 100, and the second printer does not support remote printing.

[0168] For example, Figure 9 The first interface 910 shown also includes a remote printer identifier 904. Table 4 shows that printer 103 has been used by mobile phone 100; Figure 1C It is known that printer 103 does not support remote printing, and there are available devices (such as at least one of mobile phone 500, tablet computer 400, and mobile phone 200) within a preset distance threshold around printer 103. Therefore, printer 103 is a second printer. Figure 9 The remote printer identifier 904 shown can be Figure 1CThe printer 103 is shown in the diagram. That is to say, Figure 9 The identifier 904 for the remote printer shown is the identifier for the second printer.

[0169] It should be noted that the first interface may include the identifiers of printer 101, printer 102, and printer 103. However, if the current distance between printer 101 and mobile phone 100 is greater than a preset distance threshold, mobile phone 100 cannot find printer 101. In this case, mobile phone 100 can only search for printers 102 and 103 from cloud server 600. At this time, the first interface may include the identifiers of printer 102 and printer 103.

[0170] Alternatively, any one of printers 101, 103, and 104 may be offline, and mobile phone 100 may not be able to find that printer.

[0171] For example, Figure 9 The first interface 910 shown may include an identifier 901 for a "Nearby-WiFi" printer, an identifier 902 for a "Nearby-Bluetooth" printer, an identifier 903 for a cloud printer, and an identifier 904 for a remote printer. If the current distance between the "Nearby-WiFi" printer and the mobile phone 100 exceeds a preset distance threshold or the connection is lost, the mobile phone 100 cannot find the printer. In this case, the first interface 910 may include an identifier 902 for a "Nearby-Bluetooth" printer, an identifier 903 for a cloud printer, and an identifier 904 for a remote printer. That is, the mobile phone 100 may not be able to find all of the aforementioned printers.

[0172] For printers that cannot be found by the mobile phone 100 or cannot be found by the mobile phone 100 through the cloud server 600, they can be displayed on the first screen and distinguished from the printers that can be found. For example, the information can be displayed in grayscale or marked as an unavailable printer, indicating that it was previously displayed on the mobile phone 100 screen, but the user could not select this printer to print.

[0173] In some embodiments, the first interface described above may further include a first connection time, used to remind the user that after the first connection time, the available device can disconnect from the second printer. For example... Figure 9 As shown, mobile phone 100 can display a first interface 920, which can include the identifier 901 for the "Nearby-WiFi" printer, the identifier 902 for the "Nearby-Bluetooth" printer, and the identifier 903 for the cloud printer, and may also include the identifier 905 for the remote printer. Similar to the identifier 904 for the remote printer, the identifier 905 for the far-field printer is also the identifier for the second printer, such as... Figure 1C The printer 103 is shown as labeled. (And...) Figure 9 Unlike the remote printer identifier 904 shown, the far-field printer identifier 905 also includes a first connection time, such as "Valid connection time 8:35-9:00". This first connection time is used to remind users that the remote printer supports connecting and printing during the period of 8:35-9:00 on the same day.

[0174] In this embodiment, the first connection time of the second printer is displayed on the first interface, which reflects the available time of the second printer for the user. This facilitates time management when using the printer, allowing the user to use the second printer within the available time. This improves the user experience during remote printing.

[0175] S503, mobile phone 100 receives the user's selection operation on the first identifier in the first interface, the first identifier is the identifier of printer 103 (i.e. third printer) in one or more second printers.

[0176] Based on the examples above, we can see that: Figure 9 The identifier 904 or 905 of the remote printer shown is the identifier of the second printer. That is to say, Figure 9 The remote printer shown can be Figure 1C The printer shown is 103 (i.e., the third printer). Figure 9 The identifier 904 or 905 of the remote printer shown can serve as the aforementioned first identifier. For example, mobile phone 100 can receive user input... Figure 9 The first interface 910 shows the selection operation of the remote printer identifier 904, or it can receive user input. Figure 9 The first interface 920 shows the selection operation of the remote printer identifier 905.

[0177] Following S503, in response to the selection operation of the first identifier, mobile phone 100 can request a second device (such as tablet computer 400) to control printer 103 to print document 2. The second device is an available device within a preset distance threshold range around the second printer. Specifically, the available devices within the preset distance threshold range around the second printer are those that meet preset conditions within the preset distance threshold range around the second printer.

[0178] In one implementation, the aforementioned preset conditions include: the user account is logged into on the cloud server with the mobile phone 100 and the second printer is connected.

[0179] For example, based on the examples above, we can see that: Figure 9 The identifier 904 or 905 of the remote printer shown is the identifier of the second printer. Figure 9 The remote printer shown is Figure 1CThe printer 103 is shown. Based on the usage records of printer 103 stored on the cloud server 600, as shown in Table 4 or Table 5, it can be seen that the tablet computer 400 and the mobile phone 100 (the first device) are logged into the same user account (e.g., Ross_582). Therefore, when the tablet computer 400 is connected to the second printer, the tablet computer 400 can be used as a device for printer 103.

[0180] Generally, electronic devices logged into the same user account as mobile phone 100 belong either to the owner of mobile phone 100 or to someone the owner trusts (such as a family member). In this implementation, mobile phone 100 uses devices logged into the same user account as mobile phone 100 as available devices for printer 103, ensuring data transmission security and protecting user privacy.

[0181] Alternatively, in another implementation, the aforementioned preset conditions include: being in the same home group as the first device and having a second printer connected.

[0182] For example, based on the examples above, we can see that: Figure 9 The identifier 904 or 905 of the remote printer shown is the identifier of the second printer. Figure 9 The remote printer shown is Figure 1C The printer 103 is shown. Based on the usage records of printer 103 stored on the cloud server 600, as shown in Table 4 or Table 5, both tablet computer 400 and mobile phone 500 are in the same home group (e.g., Home_a) as mobile phone 100. When tablet computer 400 is connected to a second printer, the tablet computer can be used as a device for printer 103.

[0183] Taking a tablet computer 400 as an example, after S503, the method of this application embodiment may also include S504-S505.

[0184] S504, in response to the selection operation of the first identifier, mobile phone 100 sends a print request to tablet computer 400. The print request includes document 2.

[0185] The relevant information (such as the identifier of the second device) is sent from the cloud server 600 to the mobile phone 100. The mobile phone 100 can send a print request to the second device based on the relevant information of the second device (such as the tablet computer 400).

[0186] The above print request is used to request the tablet computer 400 to control the printer 103 to print document 2.

[0187] The S505 and tablet computer 400 receive a print request and control printer 103 to print document 2.

[0188] In some embodiments, the print request may further include a first authorization code. The print request is used to request the tablet computer 400 to verify the first authorization code and, upon successful verification, to control the printer 103 to print document 2.

[0189] The first authorization code is used to verify the legitimacy of the tablet computer 400 and the mobile phone 100. After the tablet computer 400 connects to the printer 103 in response to the instruction from the cloud server 600, it can obtain a unique authorization code from the cloud server 600. This first authorization code is also assigned to the mobile phone 100 by the cloud server 600. If the authorization code of the tablet computer 400 matches the first authorization code, the verification is successful, and the tablet computer 400 can control the printer 103 to print document 2. If the authorization code of the tablet computer 400 does not match the first authorization code, the verification fails, and the tablet computer 400 will not control the printer 103.

[0190] Based on this, the tablet computer 400 can only control the printer 103 to print document 2 after verifying that the mobile phone 100 sending document 2 has been verified, using the first authorization code. This prevents the printing of document 2 from being sent by other devices. If the authorization code of the second device does not match the first authorization code, it can be determined that the received document is not document 2 sent by the first device. If the second device does not receive document 2 sent by the first device, document 2 may be leaked.

[0191] In summary, the second device can verify whether the received document is document 2 sent by the first device that is remotely connected to it based on the first authorization code, thereby achieving the effect of monitoring document 2.

[0192] In some embodiments, to ensure the security of document 2, before S504, mobile phone 100 can encrypt document 2 using a document encryption algorithm and send the encrypted document 2 to a second device (such as tablet computer 400). The document encryption algorithm can be any algorithm used to encrypt documents, and this application does not limit it. It should be noted that the usable device needs to have a built-in decryption algorithm corresponding to the encryption algorithm, used to decrypt the encrypted document 2 after receiving it and send it to printer 103 for printing. According to the above method, even if document 2 is leaked, the security of its content can be guaranteed.

[0193] This application embodiment describes the specific method in S502 where the mobile phone 100 responds to the first operation by searching for printers and displaying the first interface. For example... Figure 10 As shown, S502 may include S601-S606.

[0194] S601 and mobile phone 100 respond to the first operation, search for the first printer, and obtain the identifier of the first printer.

[0195] In response to the first operation, mobile phone 100 can search for a first printer within a preset distance range using short-range communication and display the identifier of the first printer. The method by which the mobile phone searches for the first printer and obtains its identifier can be found in relevant descriptions of conventional technologies, and will not be elaborated upon here.

[0196] S602, Mobile phone 100 sends a first connection request to cloud server 600. The first connection request includes the identifier of mobile phone 100 and is used to request a second printer from cloud server 600. In some embodiments, the first connection request may also include the user account of mobile phone 100 (e.g., Ross_582). This user account is used by cloud server 600 to find available devices for the second printer requested by mobile phone 100.

[0197] In other embodiments, the first connection request may also include the user account of mobile phone 100 (e.g., Ross_582) and the homegroup ID to which the user account belongs (e.g., Home_a). The user account and homegroup ID are used by cloud server 600 to find available devices for the second printer requested by mobile phone 100.

[0198] The specific method by which the cloud server 600 searches for available devices for the second printer requested by the mobile phone 100 can be found in the detailed description in the following embodiments, and will not be repeated here.

[0199] S603 and cloud server 600 receive the first connection request and, based on the identifier of mobile phone 100, query the second printer used by mobile phone 100.

[0200] The second printer mentioned above is a printer that meets the following conditions: there are available devices within a preset distance threshold range, it does not support remote printing, and its current distance from the mobile phone 100 is greater than or equal to the preset distance threshold.

[0201] In some embodiments, the cloud server 600 can query the usage records of each printer stored on the cloud server 600 based on the identifier of the mobile phone 100, and obtain the second printer used by the mobile phone 100. Specifically, such as... Figure 11 As shown, S603 may include S603a-S603c.

[0202] S603a and cloud server 600, based on the identifier of mobile phone 100, query at least one fifth printer used by mobile phone 100 from the usage records of multiple printers.

[0203] For example, the usage records of printer 103 in Table 4 or Table 5 show that mobile phone 100 has used printer 103. The usage records of other printers in Table 1 show that mobile phone 100 has used printers 101, 102, and b. In other words, mobile phone 100 has used printers 101, 102, b, and 103. Printers 101, 102, 103, and b are all the fifth printers.

[0204] S603b and cloud server 600 obtain the identifier of at least one third device corresponding to each fifth printer from the usage record of each fifth printer. At least one third device has used the fifth printer, and at least one third device is different from mobile phone 100.

[0205] For example, consider a fifth printer (such as printer 103). As shown in Table 4 or Table 5, the usage records of printer 103 show that mobile phone 500, tablet computer 400, mobile phone 200, and mobile phone 100 have all used printer 103. Therefore, except for mobile phone 100, mobile phone 500, tablet computer 400, and mobile phone 200 are all third devices of printer 103. Cloud server 600 can obtain the identifiers of these three third devices of printer 103, such as the identifiers of mobile phone 500, tablet computer 400, and mobile phone 200.

[0206] As described in the above embodiments, the usage record of each printer also includes the user account of the device that has used printer 103. Based on this, in this embodiment, S603b may include: cloud server 600 obtaining from the usage record of each fifth printer the identifier of at least one third device that has logged into the same user account as the first device on the cloud server.

[0207] For example, consider a fifth printer (such as printer 103). As shown in Table 4 or Table 5, the usage records of printer 103 show that both tablet computer 400 and mobile phone 100 have used printer 103, and their user accounts (such as Ross_582) are the same. Therefore, tablet computer 400 is a third device for printer 103. Cloud server 600 can obtain the identifier of a third device for printer 103, such as the identifier of tablet computer 400.

[0208] As described in the above embodiments, the usage record of each printer also includes the user account of the device that has used printer 103, and the home group ID to which each user account belongs may be different. Based on this, in this embodiment, S603b may include: cloud server 600 obtaining the identifier of at least one third device that is in the same home group as the first device from the usage record of each fifth printer; wherein, the cloud server maintains multiple home group IDs and multiple user accounts in each home group; the home group IDs are different for each home group.

[0209] For example, consider a fifth printer (e.g., printer 103). As shown in Table 4 or Table 5, the usage records of printer 103 show that tablet 400, mobile phone 500, and mobile phone 100 have all used printer 103, and their HomeGroup IDs (e.g., Home_a) are the same. Therefore, tablet 400 and mobile phone 500 are third devices for printer 103. Cloud server 600 can obtain the identifiers of these two third devices for printer 103, such as the identifiers of mobile phone 500 and tablet 400.

[0210] S603c and cloud server 600 respectively instruct at least one third device corresponding to each fifth printer to connect to the fifth printer via short-range wireless communication, and determine the second printer from the at least one fifth printer based on the connection result. The second printer is the printer among the at least one fifth printer that has successfully connected to its corresponding third device via short-range communication.

[0211] For example, consider a fifth printer (such as printer 103). Assume that the third devices associated with printer 103 include mobile phone 500 and tablet computer 400. Cloud server 600 can instruct the third devices (such as mobile phone 500 and tablet computer 400) corresponding to printer 103 to respectively print the fifth printer via short-range wireless communication.

[0212] In some embodiments, the cloud server 600 can send the identifier of the fifth printer corresponding to each third device to each third device, instructing the third device to connect to the fifth printer based on the identifier of the fifth printer. For example, taking a fifth printer (such as printer 103) as an example. Assume that the third devices for printer 103 include mobile phone 500 and tablet computer 400. The cloud server 600 can send the identifier of printer 103 to the third devices corresponding to printer 103 (such as mobile phone 500 and tablet computer 400), instructing mobile phone 500 and tablet computer 400 to connect to printer 103 via short-range wireless communication based on the identifier of printer 103.

[0213] For example, S603c may specifically include: the cloud server 600 sending a connection instruction to each third device corresponding to each fifth printer; and receiving a connection result from the third device. The connection instruction includes the identifier of the fifth printer corresponding to the third device, and this connection instruction instructs the third device to connect to the fifth printer based on the identifier of the fifth printer. The connection result is sent after the third device successfully connects to the fifth printer, and the connection result includes the identifier of the third device and the identifier of the fifth printer.

[0214] For example, consider a fifth printer (such as printer 103). Assume the third devices connected to printer 103 include mobile phone 500 and tablet computer 400. Cloud server 600 can send connection instructions to the corresponding third devices (such as mobile phone 500 and tablet computer 400) respectively. These connection instructions include the identifier of printer 103, instructing the third device (such as mobile phone 500 or tablet computer 400) to connect to printer 103. After tablet computer 400 connects to printer 103 via short-range wireless communication, it can send connection result 1 to cloud server 600. Connection result 1 includes the identifiers of tablet computer 400 and printer 103. After mobile phone 100 connects to printer 103 via short-range wireless communication, it can send connection result 2 to cloud server 600. Connection result 2 includes the identifiers of mobile phone 100 and printer 103.

[0215] It should be noted that the printer connection protocol is a protocol between the printer and the device controlling the printer, used to define the rules and message formats for communication. The printer connection protocol can be Bluetooth Low Energy (BLE) or Constrained Application Protocol (CoAP).

[0216] After the cloud server 600 determines the second printer by executing S603, the cloud server 600 can use either of the following two methods to designate one of the at least one third device corresponding to the second printer as an available device within a preset distance threshold range around the second printer.

[0217] Method (1): The cloud server 600 will use the first third device that successfully connects to the fifth printer via short-range wireless communication as an available device within a preset distance threshold range around the second printer.

[0218] For example, in conjunction with the above example, suppose that the tablet computer 400 successfully establishes a connection with the printer 103 via short-range wireless communication before the mobile phone 500, and sends connection result 1 to the cloud server 600; then the cloud server 600 can regard the tablet computer 400 as an available device (i.e., a second device) within a preset distance threshold range around the printer 103.

[0219] Method (2): The usage record of each printer in the cloud server 600 also includes the last connection time between the device that used the printer and the printer. After determining the second printer from at least one fifth printer based on the connection result, before sending the first connection response to the first device, the method of this application embodiment may further include: the cloud server 600 designates the third device with the latest last connection time with the fifth printer among the first third devices that successfully connected to the fifth printer via short-range wireless communication as an available device within a preset distance threshold range around the second printer.

[0220] For example, consider a fifth printer (such as printer 103). Assume that the third devices connected to printer 103 include mobile phone 500 and tablet computer 400. After cloud server 600 instructs mobile phone 500 and tablet computer 400 to connect to printer 103 respectively, both mobile phone 500 and tablet computer 400 successfully establish a connection with printer 103 via short-range wireless communication.

[0221] As shown in Table 5, the last time tablet computer 400 used printer 103 was at 10:35 AM on January 13, 2024, while the last time mobile phone 500 used printer 103 was at 9:45 AM on December 3, 2023. Since 10:35 AM on January 13, 2024 is after 9:45 AM on December 3, 2023, the last time tablet computer 400 used printer 103 was later than the last time mobile phone 500 used printer 103. Cloud server 600 can treat tablet computer 400 as an available device (i.e., a second device) within a preset distance threshold around printer 103.

[0222] Considering that mobile phone 100 only needs one available device, printer 103, to assist in remote printing, cloud server 600 only needs to select one available device (i.e., the second device). In some embodiments, after a third device successfully connects to the fifth printer via short-range wireless communication, cloud server 600 can send a pause command to other third devices corresponding to the fifth printer. The pause command instructs the other third devices to stop connecting to the fifth printer via short-range wireless communication. Thus, other third devices will no longer respond to connection commands to connect to printer 103.

[0223] For example, in conjunction with the above example, suppose that tablet computer 400 successfully establishes a connection with printer 103 via short-range wireless communication before mobile phone 500, and sends connection result 1 to cloud server 600; then cloud server 600 can send a pause command to mobile phone 500, instructing mobile phone 500 to stop connecting to printer 103 via short-range wireless communication.

[0224] In other embodiments, the connection time between the third device and the fifth printer is the first connection time between the third device and the fifth printer, which is the planned duration for the third device and the fifth printer to maintain a connection. This first connection time can be carried in the first connection response of S604 and sent by the cloud server 600 to the mobile phone 100, which can then display the first connection time on the aforementioned first interface.

[0225] S604, cloud server 600 sends a first connection response to mobile phone 100. The first connection response includes the identifier of the second printer (e.g., printer 103) and the identifier of an available device (e.g., tablet computer 400) within a preset distance threshold range around the identifier of the second printer (e.g., printer 103).

[0226] S605, mobile phone 100 receives the first connection response from the cloud server.

[0227] The S606 and mobile phone 100 display a first interface. This first interface includes the identifiers of one or more first printers and one or more second printers.

[0228] In this embodiment, the mobile phone 100 can search the cloud server 600 for printers 103 (i.e., the second printer) that are available within a preset distance threshold range from printers connected to the mobile phone 100. The cloud server 600 provides the mobile phone 100 with the identifier of the printer 103 and the identifier of the available device (such as a tablet computer 400) for the printer 103. Thus, the mobile phone 100 can display the identifier of the second printer on the first interface for the user to select for remote printing.

[0229] After S604 above, if the available device is offline for some reason, in this case, the available device cannot receive the print request sent by the mobile phone 100, and the connection between the mobile phone 100 and the available device is interrupted, causing the available device to be unable to receive document 2, resulting in the interruption of the printing process.

[0230] In the above situation, to ensure that Document 2 can be printed correctly when it is online on available devices, as follows: Figure 12As shown, mobile phone 100 can send a print request to cloud server 600. Cloud server 600 can receive the print request and upload it to the resource server. After the available device comes online, it can retrieve the print request from the resource server, download document 2, and send document 2 to the fifth printer to ensure that the interrupted printing process can proceed normally. In summary, in conjunction with the embodiments of this application, as... Figure 13 and Figure 14 As shown, printing can include, but is not limited to, the following three printing methods:

[0231] Printing method (1): Near-field printing.

[0232] Printing method (2): Low-cost remote printing in this application embodiment.

[0233] Printing method (3): Remote printing is achieved by a printer that supports remote printing.

[0234] For the above printing method (1), the printer is within the preset distance threshold range of the mobile phone 100. The mobile phone 100 can search for the printer to be online and establish a connection with the printer through the printing connection protocol. After the connection is established, the mobile phone 100 can send a printing request to the printer so that the printer can print the document 2 in the printing request.

[0235] For remote printing using the above printing methods (2) and (3), the distance between the mobile phone 100 and the printer is relatively far, and the mobile phone 100 needs the assistance of other devices to achieve remote printing through the printer. Therefore, the printing process is prone to interruption due to device reasons (such as disconnection or unstable communication connection), and document 2 may be lost. To solve the above problem, document 2 can be sent to the resource server before the mobile phone 100 sends the print request. In this way, when the printing process is interrupted, document 2 can be stored in the resource server and can be called when the printing process is normal in the future to achieve normal printing.

[0236] Specifically, such as Figure 13 and Figure 14As shown, for the above printing method (2), in conjunction with the above embodiments, it can be seen that the available device can search for printers within a preset distance threshold range that are online through the printing connection protocol and connect to the cloud server 600. The cloud server 600 receives the printer's online status sent by the available device and notifies the mobile phone 100. The mobile phone 100 can send document 2 to the resource server and receive the Uniform Resource Locator (URL) returned by the resource server, where the Uniform Resource Locator is used to locate the address of document 2 in the resource server. After that, the mobile phone 100 sends a print request to the cloud server 600. The cloud server 600 forwards the print request to the available device, and the available device can obtain document 2 through the print request, or through other means such as... Figure 13 The resource server downloads document 2 and sends document 2 to the printer for printing.

[0237] For the printing method (3) described above, the printer can communicate with the cloud server 600. Therefore, the mobile phone can communicate with the printer through the cloud server 600 to achieve remote printing. Specifically, the printer can connect to the cloud server 600 via WiFi. The mobile phone 100 can obtain the printer's online status message through the cloud server 600, send document 2 to the resource server, and receive the Uniform Resource Locator (URL) returned by the resource server. Afterward, the mobile phone 100 sends a print request to the cloud server 600. The cloud server 600 forwards the print request to the printer. The printer can obtain document 2 through the print request, or it can obtain it through other means such as... Figure 13 The resource server downloads document 2 and sends document 2 to the printer for printing.

[0238] This application also provides an electronic device, including: a display screen, a communication module, a memory, and one or more processors. The display screen, communication module, memory, and processors are coupled together. The communication module is used to communicate with other devices. The memory is used to store computer program code. The computer program code includes computer instructions, which, when executed by the processor, cause the electronic device to perform the remote printing method.

[0239] This application also provides a computer storage medium that includes computer instructions. When the computer instructions are executed on an electronic device, the electronic device performs the various functions or steps described in the above method embodiments.

[0240] This application also provides a computer program product, including a computer program / instructions, which, when executed by a processor, implement the various functions or steps in the above method embodiments.

[0241] Through the above description of the embodiments, those skilled in the art can clearly understand that, for the sake of convenience and brevity, only the division of the above functional modules is used as an example. In actual applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above.

[0242] In the several embodiments provided in this application, it should be understood that the disclosed apparatus and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of modules or 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 apparatus, or some features may be ignored or not executed. Furthermore, the mutual 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.

[0243] The units described as separate components may or may not be physically separate. A component shown as a unit can be one or more physical units; that is, it can be located in one place or distributed in multiple different locations. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.

[0244] Furthermore, the functional units in the various embodiments of this application 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 as a software functional unit.

[0245] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a readable storage medium. Based on this understanding, the technical solutions of the embodiments of this application, in essence, or the parts that contribute to the prior art, or all or part of the technical solutions, can be embodied in the form of a software product. This software product is stored in a storage medium and includes several instructions to cause a device (which may be a microcontroller, chip, etc.) or processor to execute all or part of the steps of the methods of the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0246] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any changes or substitutions within the technical scope disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.

Claims

1. A remote printing method, characterized in that, Applied to a first device, the method includes: Receive a first operation from the user on the first document, wherein the first operation instructs the first device to print the first document; In response to the first operation, a first printer is searched for, and a first connection request is sent to the cloud server; wherein the current distance between the first printer and the first device is less than a preset distance threshold, and / or the first printer supports remote printing; the first connection request is used to request a printer from the cloud server; The system receives a first connection response from the cloud server. The first connection response includes an identifier for the second printer and an identifier for an available device. The second printer is a printer that the cloud server has queried from the usage records of multiple printers and that has been used by the first device. The current distance between the second printer and the first device is greater than a preset distance threshold, and the second printer does not support remote printing. The available device is a device within the preset distance threshold range surrounding the second printer. The available device is a device that the cloud server has queried from the usage records of the second printer and that has used the second printer and has successfully connected to it. The preset distance threshold is a distance threshold for short-range wireless communication, including Bluetooth and / or Wi-Fi. Display a first interface; wherein the first interface includes one or more identifiers of the first printer and one or more identifiers of the second printer; The system receives a user's selection of a first identifier in the first interface, where the first identifier is the identifier of a third printer among the one or more second printers. In response to the selection operation of the first identifier, a second device is requested to control the third printer to print the first document; wherein the second device is an available device within the preset distance threshold range around the third printer.

2. The method according to claim 1, characterized in that, The first connection request includes the identifier of the first device, which is used to query the printers used by the first device from the usage records of multiple printers.

3. The method according to claim 1, characterized in that, The first connection response also includes a first authorization code corresponding to an available device within the preset distance threshold range around the second printer; The step of requesting the second device to control the third printer to print the first document in response to the selection operation of the first identifier includes: In response to the selection operation of the first identifier, a print request is sent to the second device; wherein, the print request includes the first document and a first authorization code corresponding to the second device; the print request is used to request the second device to verify the first authorization code and, after successful verification, control the third printer to print the first document.

4. The method according to claim 1, characterized in that, The first connection response also includes a first connection time between an available device and the second printer within the preset distance threshold range around the second printer; wherein, after the first connection time, the available device disconnects from the second printer.

5. The method according to claim 4, characterized in that, The first interface also includes the first connection time, used to remind the user that after the first connection time, the available device will disconnect from the second printer.

6. The method according to any one of claims 2-5, characterized in that, The cloud server records the identifiers of multiple printers and the usage records of each printer; the usage records of each printer include the identifier of the device that used the printer.

7. The method according to claim 6, characterized in that, Each printer's usage record also includes the user account of the device that used the printer; wherein, the cloud server maintains multiple user accounts, and each user account corresponds to the identifier of one or more devices; Wherein, an available device within the preset distance threshold range around the second printer is: a device within the preset distance threshold range around the second printer that meets the preset conditions; The preset conditions include: the user account logged into the cloud server with the first device is the same as the user account logged in with the first device, and the second printer is already connected; or... The preset conditions include: being in the same home group as the first device and being connected to the second printer; wherein, the cloud server maintains multiple home group home IDs and multiple user accounts in each home group; each home group has a different home ID.

8. The method according to claim 7, characterized in that, The method further includes: The first device connects to the fourth printer via the short-range wireless communication and controls the fourth printer to print the second document, then sends a print record to the cloud server; wherein the print record includes the identifier of the first device, the identifier of the fourth printer, and the user account of the first device.

9. A remote printing method, characterized in that, Applied to cloud servers Receive a first connection request from a first device; wherein the first connection request includes the identifier of the first device, and the first connection request is used to request a printer from the cloud server; Based on the identifier of the first device, a second printer used by the first device is queried from the usage records of multiple printers; wherein, there are available devices within a preset distance threshold range around the second printer, and the available devices are obtained from the usage records of the second printer; the second printer does not support remote printing, and the current distance between the second printer and the first device is greater than or equal to the preset distance threshold; the preset distance threshold is a distance threshold for short-range wireless communication, and the short-range wireless communication includes Bluetooth and / or Wi-Fi; Send a first connection response to the first device; wherein the first connection response includes the identifier of the second printer and the identifier of an available device within the preset distance threshold range around the second printer.

10. The method according to claim 9, characterized in that, The cloud server records the identifiers of multiple printers and the usage records of each printer; the usage records of each printer include the identifier of the device that used the printer.

11. The method according to claim 10, characterized in that, The step of querying the usage records of multiple printers based on the identifier of the first device to find the second printer that the first device has used includes: Based on the identifier of the first device, query at least one fifth printer that the first device has used from the usage records of the plurality of printers; From the usage records of each fifth printer, obtain the identifier of at least one third device corresponding to the fifth printer; wherein the at least one third device has used the fifth printer, and the at least one third device is different from the first device; Each fifth printer is instructed to connect to the fifth printer via the short-range wireless communication, and the second printer is determined from the at least one fifth printer based on the connection result; wherein the second printer is the printer among the at least one fifth printer that has successfully connected to the corresponding third device via the short-range wireless communication.

12. The method according to claim 11, characterized in that, The instruction that at least one third device corresponding to each fifth printer connects to the fifth printer via the short-range wireless communication includes: A connection instruction is sent to each third device; wherein the connection instruction includes the identifier of the fifth printer corresponding to the third device, and the connection instruction is used to instruct the third device to connect to the fifth printer based on the identifier of the fifth printer; Receive a connection result from the third device; wherein the connection result is sent by the third device after successfully connecting to the fifth printer, and the connection result includes the identifier of the third device and the identifier of the fifth printer.

13. The method according to claim 12, characterized in that, The connection result also includes: the connection time of the third device to the fifth printer, and the first connection time between the third device and the fifth printer, wherein the first connection time is the planned connection time between the third device and the fifth printer.

14. The method according to any one of claims 11-13, characterized in that, Each printer's usage record also includes the user account of the device that used the printer; wherein, the cloud server maintains multiple user accounts, and each user account corresponds to the identifier of one or more devices; The step of obtaining the identifier of at least one third device corresponding to each fifth printer from the usage record of each fifth printer includes: From the usage records of each fifth printer, obtain the identifier of at least one third device that logged into the same user account as the first device on the cloud server; or... From the usage records of each fifth printer, obtain the identifier of at least one third device that is in the same home group as the first device; wherein, the cloud server maintains multiple home group home IDs and multiple user accounts in each home group; each home group has a different home ID.

15. The method according to any one of claims 11-13, characterized in that, After determining the second printer from the at least one fifth printer based on the connection result and before sending the first connection response to the first device, the method further includes: The first third device that successfully connects to the fifth printer via the short-range wireless communication is considered a usable device within the preset distance threshold range around the second printer. Alternatively, the usage record for each printer may also include the last connection time between the device that used the printer and the printer; after the second printer is determined from the at least one fifth printer based on the connection result and before the first connection response is sent to the first device, the method further includes: The third device that was last connected to the fifth printer most recently among the first third devices that successfully connected to the fifth printer via the short-range wireless communication will be considered as an available device within the preset distance threshold range around the second printer.

16. The method according to claim 15, characterized in that, The method further includes: After a third device successfully connects to the fifth printer via the short-range wireless communication, it sends a pause command to other third devices corresponding to the fifth printer; wherein, the pause command is used to instruct the other third devices to stop connecting to the fifth printer via the short-range wireless communication.

17. The method according to any one of claims 10-13, characterized in that, The method further includes: Receive a print record from the first device; wherein the print record is sent by the first device after it connects to the fourth printer via the short-range wireless communication and controls the fourth printer to print a second document; the print record includes the identifier of the first device and the identifier of the fourth printer; Update the usage record of the fourth printer based on the printed records.

18. A remote printing system, characterized in that, include: A first device, one or more first printers, one or more second printers, a cloud server, and a second device; The current distance between the first printer and the first device is less than a preset distance threshold, and / or the first printer supports remote printing; the current distance between the second printer and the first device is greater than the preset distance threshold, the second printer has been used by the first device, and the second printer does not support remote printing. The first device is used to perform the method as described in any one of claims 1-8; The cloud server is used to perform the method as described in any one of claims 9-17; The second device is used to control a third printer among the one or more second printers to print a first document in response to a request from the first device; wherein the second device is an available device within the preset distance threshold range around the third printer.

19. An electronic device, characterized in that, include: The device includes a display screen, a communication module, a memory, and one or more processors, wherein the display screen, the communication module, the memory, and the processors are coupled together. The communication module is used to communicate with other devices; the memory is used to store computer program code; the computer program code includes computer instructions, which, when executed by the processor, cause the electronic device to perform the method as described in any one of claims 1-8.

20. A computer-readable storage medium, characterized in that, The computer-readable storage medium includes computer instructions that, when executed on an electronic device, cause the electronic device to perform the method as described in any one of claims 1-8 or 9-17.