[go: up one dir, main page]

CN113885816A - Method, system, device and storage medium for printing by virtual printing device - Google Patents

Method, system, device and storage medium for printing by virtual printing device Download PDF

Info

Publication number
CN113885816A
CN113885816A CN202111152857.1A CN202111152857A CN113885816A CN 113885816 A CN113885816 A CN 113885816A CN 202111152857 A CN202111152857 A CN 202111152857A CN 113885816 A CN113885816 A CN 113885816A
Authority
CN
China
Prior art keywords
usb
printing
virtual
printer
equipment
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202111152857.1A
Other languages
Chinese (zh)
Inventor
梁嘉津
林海新
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Guangdong Telepower Communication Co ltd
Original Assignee
Guangdong Telepower Communication Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Guangdong Telepower Communication Co ltd filed Critical Guangdong Telepower Communication Co ltd
Priority to CN202111152857.1A priority Critical patent/CN113885816A/en
Publication of CN113885816A publication Critical patent/CN113885816A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/12Digital output to print unit, e.g. line printer, chain printer
    • G06F3/1201Dedicated interfaces to print systems
    • G06F3/1202Dedicated interfaces to print systems specifically adapted to achieve a particular effect
    • G06F3/1203Improving or facilitating administration, e.g. print management
    • G06F3/1209Improving or facilitating administration, e.g. print management resulting in adapted or bridged legacy communication protocols, e.g. emulation, protocol extension
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/12Digital output to print unit, e.g. line printer, chain printer
    • G06F3/1201Dedicated interfaces to print systems
    • G06F3/1223Dedicated interfaces to print systems specifically adapted to use a particular technique
    • G06F3/1224Client or server resources management
    • G06F3/1228Printing driverless or using generic drivers
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/12Digital output to print unit, e.g. line printer, chain printer
    • G06F3/1201Dedicated interfaces to print systems
    • G06F3/1223Dedicated interfaces to print systems specifically adapted to use a particular technique
    • G06F3/1236Connection management
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/12Digital output to print unit, e.g. line printer, chain printer
    • G06F3/1201Dedicated interfaces to print systems
    • G06F3/1278Dedicated interfaces to print systems specifically adapted to adopt a particular infrastructure
    • G06F3/1279Controller construction, e.g. aspects of the interface hardware
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • H04L69/08Protocols for interworking; Protocol conversion
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • H04L69/18Multiprotocol handlers, e.g. single devices capable of handling multiple protocols

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Security & Cryptography (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Accessory Devices And Overall Control Thereof (AREA)

Abstract

The invention belongs to the technical field of computers, and particularly relates to a method, a system, equipment and a storage medium for printing by virtual printing equipment. The method comprises the following steps: starting up and loading a virtual USB printer module, and constructing non-USB printing equipment into a virtual USB printer; acquiring a USB printer device detection request; responding to the USB printer equipment detection request, and feeding back the virtual USB printer information to the USB printer application; establishing connection with a USB printer application and transmitting data; and receiving the printing data sent by the USB printer application, and printing by the non-USB printing equipment. According to the invention, the printing equipment which does not support the USB communication protocol can realize printing through the USB printer application developed based on the Android system, when the printing equipment is switched to the printer schemes of different protocols, the application does not need to be modified, the development time of a client is saved, the communication of the upper layer application to the printing driver is realized under the condition that the hardware and the printing driver protocol are not modified, and the hardware switching and the driver development cost are greatly reduced.

Description

Method, system, device and storage medium for printing by virtual printing device
Technical Field
The invention belongs to the technical field of computers, and particularly relates to a method, a system, equipment and a storage medium for printing by virtual printing equipment.
Background
The application of the intelligent terminal is more and more extensive, and currently, open source operating systems mainly used include Android and Ubuntu. The Android system is widely applied in the civil mobile field, has rich interfaces and massive application, and becomes a dominant system in the current market.
Because the Android system supports various communication protocols, printers of different schemes can communicate with the Android system through the communication protocols, and the application calls the corresponding standard Android communication interface to send the printing data to the printer to realize printing. The printing driving module generally realizes printing based on an ESC/POS protocol, so that the application of printers developed based on Android systems in the market is mainly different in the communication protocols of the printing driving module, such as USB printing, Bluetooth printing or TCP/IP printing.
In the prior art, a terminal application (application layer) calls a USB communication interface from an Android system, and sends print data to a printer supporting a USB protocol through the USB interface for printing (printer driver); namely, the USB printing application is only suitable for Android terminal printers supporting the USB protocol. If communication between the USB print application and the non-USB printer is to be achieved, only by changing the print application, or changing the driver of the USB printer.
In other words, the USB printer application developed based on the Android system is only applicable to Android terminal printers that support the USB protocol. Therefore, for a printer which does not support the USB communication protocol, how to implement printing by using a USB printer application developed based on the Android system becomes one of the problems that need to be solved at present.
Disclosure of Invention
In order to solve the problems that a USB printer application developed based on an Android system is only suitable for an Android terminal printer supporting a USB protocol in the prior art, and the communication between the USB printing application and a non-USB printer is realized only by changing the printing application or changing the drive of the USB printer, the invention provides a method, a system, equipment and a storage medium for printing by virtual printing equipment.
The invention is realized by adopting the following technical scheme:
a method for printing by virtual printing equipment is applied to printers which do not support a USB communication protocol, namely non-USB printing equipment, and realizes that the printing equipment which does not support the USB communication protocol can realize printing by USB printer application developed based on an Android system, and the method for printing by the virtual printing equipment comprises the following steps:
starting up and loading a virtual USB printer module, and constructing non-USB printing equipment into a virtual USB printer;
acquiring a USB printer device detection request;
responding the USB printer equipment detection request, and feeding back the virtual USB printer information to a USB printer application;
establishing connection with the USB printer application and transmitting data;
and receiving the printing data sent by the USB printer application, and printing by the non-USB printing equipment.
As a further scheme of the invention, the virtual USB printer module consists of a custom service and a custom USB device class, is used for initializing the USB service in the starting process, and instantiates the custom USB device class according to the process of adding new devices to the USB service when the USB service is in a normal running state, so as to realize the virtual USB printer and construct the non-USB printing device into the virtual USB printer.
Further, the process of adding new devices to the USB service is a process of adding different attribute values of different types of USB devices to a device list, where the attribute value of the custom USB device class is an attribute value carried by a USB printing device filled in the reference USB printer model.
Further, the attribute value of the custom USB device class includes a device descriptor, an endpoint descriptor, a vendor ID, or a device version number.
As a further scheme of the present invention, the USB printer application calls an Android standard USB communication interface to interact with a USB service module to send a request for acquiring USB printer devices, so as to acquire the number of USB devices on the Android device.
Further, after the non-USB printing device loaded with the virtual USB printer module is constructed as a virtual USB printer in response to the USB printer device detection request, the USB printer application acquires a default USB printer when acquiring the virtual USB printer device.
Further, the virtual USB printer is matched to the USB printer application via a USB communication protocol.
Further, the receiving of the print data sent by the USB printer application, when the non-USB printing device prints, further includes:
sending handshake data when the virtual USB printer equipment is connected with a printing module of the non-USB printer equipment for the first time;
distinguishing the communication protocol type of the current printing module through the difference of handshake of different communication protocols;
and converting the USB protocol into a communication protocol which can be identified by the current non-USB printing equipment, and sending the printing data to the non-USB printing equipment for printing.
The invention also comprises a system for printing by the virtual printing equipment, wherein the system for printing by the virtual printing equipment adopts the method for printing by the virtual printing equipment to realize that the printing equipment which does not support the USB communication protocol can realize printing by the USB printer application developed based on the Android system; the system for printing by the virtual printing equipment comprises a virtual USB printer module, a USB service module, a conversion communication module and a printing drive module.
The virtual USB printer module is used for loading when the non-USB printing equipment is started up, and the non-USB printing equipment is constructed into a virtual USB printer. The USB service module is used for interacting with a USB printer through an android standard USB communication interface so as to send a request of the USB printer application for acquiring USB printer equipment, feeding information back to the USB printer application when a virtual USB printer is detected, and transmitting data of the USB printer application to the virtual USB printer module.
The conversion communication module is used for converting the USB protocol into a communication protocol which can be identified by the current non-USB printing equipment and transmitting data to the printing drive module. And the printing driving module is used for receiving the data transmitted by the conversion communication module and driving the non-USB printing equipment to print.
The invention also includes a computer device comprising a memory and a processor, the memory storing a computer program, the processor implementing the steps of the method for printing by a virtual printing device when executing the computer program.
The invention also includes a storage medium storing a computer program which, when executed by a processor, implements the steps of a method for printing by a virtual printing apparatus.
The technical scheme provided by the invention has the following beneficial effects:
the invention can construct a virtual USB printer on the printing equipment which does not support the USB communication protocol by loading the virtual USB printer module, the system detects the USB printer by default, the upper layer application can be connected with the virtual USB printer through a standard interface for communication, the communication protocol driven by the bottom layer can be stripped by utilizing the conversion communication module, the USB printer application does not need to care about the printing driving protocol, and the USB printer application is completely processed by the conversion communication module for printing. On the basis that a client develops the application of a standard android USB printer, the application does not need to be modified when the printer scheme of different protocols is switched, and the development time of the client is saved; the communication protocol supported by the printing module is closely related to hardware, and the communication of upper-layer application to the printing driver is realized by the invention under the condition of not modifying the hardware and the printing driver protocol, so that the hardware switching and the driver development cost are greatly reduced; the invention accords with the code design switching principle, does not need to modify the designed application layer and the designed drive layer, and the system is completed by the extended function module.
Drawings
The accompanying drawings, which are included to provide a further understanding of the invention and are incorporated in and constitute a part of this specification, illustrate embodiments of the invention and together with the description serve to explain the principles of the invention and not to limit the invention. In the drawings:
fig. 1 is a flowchart of a method for printing by a virtual printing apparatus according to an embodiment of the present invention.
FIG. 2 is a system block diagram of a printing system performed by the virtual printing apparatus in one embodiment of the present invention.
FIG. 3 is a flow chart of a printing process performed by the virtual printing apparatus in the printing system according to an embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, the present invention is described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
Aiming at the problem that a USB printer application developed based on an Android system is only suitable for an Android terminal printer supporting a USB protocol, the USB printing application is communicated with a non-USB printer, and only by changing the printing application or changing the drive of the USB printer, the non-USB printer is loaded with a virtual USB printer module 11 through the research and development of a system of an intelligent terminal, so that a product can realize printing through the USB printer application developed based on the Android system under the condition that an upper layer application and a printer drive of the product are not modified.
In an embodiment of the present invention, a system for printing by using a virtual printing device is provided, where the system is applied to a printer that does not support a USB communication protocol, that is, a non-USB printing device, and the printing device that does not support the USB communication protocol can print by using a USB printer application developed based on an Android system. Referring to fig. 2 and 3, the system for printing by the virtual printing device includes a virtual USB printer module 11, a USB service module 12, a conversion communication module 13, and a print driver module 14.
The virtual USB printer module 11 is used for loading when the non-USB printing device is powered on, and constructs the non-USB printing device as a virtual USB printer.
The USB service module 12 is used for interacting with a USB printer application through an android standard USB communication interface to send a request of the USB printer application for acquiring USB printer equipment, feeding information back to the USB printer application when a virtual USB printer is detected, and transmitting data of the USB printer application to the virtual USB printer module 11.
The conversion communication module 13 is configured to convert the USB protocol into a communication protocol recognizable by the current non-USB printing device, and transmit data to the print driver module 14.
The print driving module 14 is configured to receive the data transmitted by the conversion communication module 13, and drive the non-USB printing device to print.
When the system is used for printing operation, the virtual USB printer module 11 is loaded when the non-USB printing equipment is started to form a virtual USB printer; after the USB printer application interacts with the USB service module 12, when the USB printer device is acquired through the USB service module 12, the USB service module 12 detects a virtual USB printer and returns the virtual USB printer device to the USB printer application, the USB printer application successfully acquires the virtual USB printer device and allows the virtual USB printer device to send print data to the virtual USB printer, the virtual USB printer module 11 receives the print data, the conversion communication module 13 is started, the USB protocol is converted into a communication protocol which can be identified by the current intelligent terminal printer, the print data is sent to the print driving module 14, and the print driving module 14 processes the data to realize printing.
The system for printing by the virtual printing equipment realizes a virtual USB printer module 11, detects a USB printer by default, upper-layer application can be connected with the virtual USB printer through a standard interface for communication, and also realizes a conversion communication module 13 for stripping a communication protocol driven by a bottom layer, and the USB printer application does not need to care about a printing driving protocol and is completely processed by the conversion communication module 13.
Referring to fig. 1, in an embodiment of the present invention, a method for printing by a virtual printing device is further provided, where the method is applied to a printer that does not support a USB communication protocol, that is, a non-USB printing device, and the printing device that does not support the USB communication protocol can print by using a USB printer application developed based on an Android system, and the method for printing by the virtual printing device includes:
and S1, starting up and loading the virtual USB printer module 11, and constructing the non-USB printing device into a virtual USB printer.
In this embodiment, the non-USB printing device forms a virtual USB printer after loading the virtual USB printer module 11 when it is powered on. Can be recognized by the USB printer application in order to establish communication. The virtual USB printer module 11 is composed of a custom service and a custom USB device class, and is used for initializing the USB service in the starting process, and instantiating the custom USB device class according to the process of adding new devices to the USB service when the USB service is in a normal running state, so that a virtual USB printer is realized, and non-USB printing devices are constructed into the virtual USB printer.
In this embodiment, the USB service add-new-device procedure is a procedure of adding different attribute values of different types of USB devices to a device list, where the attribute value of the custom USB device class is an attribute value carried by a USB printing device filled in the reference USB printer model. The attribute value of the custom USB device class comprises a device descriptor, an endpoint descriptor, a vendor ID or a device version number.
Specifically, the virtual USB printer module 11 is composed of a custom service and a custom USB device class. The method comprises the steps that USB service is initialized in the starting process of the android system, a service for monitoring the USB service is designed, when the USB service is monitored to be in a normal running state, a user-defined USB device class is instantiated according to a new device adding process of the USB service, and therefore a virtual USB printer is achieved. The USB service adds new equipment flow, actually adds attribute value to equipment list, for a USB equipment is U disk or keyboard, USB organization has already a set of standard protocol specification, different types of USB equipment have different attribute value, self-defining USB equipment type refers to USB printer model and fills an attribute value carried by USB printing equipment, for example, equipment descriptor fills printer attribute, end point descriptor sets transmission packet length, manufacturer ID, equipment version number and other attribute values
The USB printer application acquires the number of USB devices on the android device through the USB service module 12, and after the virtual USB printer module 11 is loaded, the USB printer application acquires the USB devices by default to acquire one USB printer. The first step of the USB printing application is often to acquire and connect a USB printer, which is a necessary step, and the starting point of this embodiment is to enable a product whose printing module is not a USB printer to print on the USB printing application, and the function of virtualizing a USB printer is to provide a USB printer for connecting with the USB printing application and performing data transmission. If the virtual USB printer module 11 is not loaded, the USB printing application cannot be used because the USB printer device is not available on the product.
S2, acquiring the USB printer device detection request.
In this embodiment, the detection request is that the USB printer application calls the android standard USB communication interface to interact with the USB service module 12, so as to obtain the USB printer device. In this embodiment, the USB printer device detection request is made by the USB printer application calling an Android standard USB communication interface to interact with the USB service module 12, so as to send a request for acquiring USB printer devices, where the request is used to acquire the number of USB devices on the Android device.
And S3, responding to the USB printer device detection request, and feeding back the virtual USB printer information to the USB printer application.
In this embodiment, after the non-USB printing device loaded with the virtual USB printer module 11 is constructed as a virtual USB printer in response to the USB printer device detection request, the USB printer application acquires a USB printer by default when acquiring the virtual USB printer device.
When the USB service module 12 detects a virtual USB printer, it returns the virtual USB printer device to the USB printer application.
And S4, establishing connection with the USB printer application and carrying out data transmission.
In this embodiment, the virtual USB printer is matched to the USB printer application via a USB communication protocol. The USB printer application successfully obtains the virtual USB printer device and allows the print data to be sent to the virtual USB printer.
And S5, receiving the printing data sent by the USB printer application, and printing by the non-USB printing equipment.
In this embodiment, when the receiving the print data sent by the USB printer application and printing by the non-USB printing device, the method further includes: sending handshake data when the virtual USB printer equipment is connected with a printing module of the non-USB printer equipment for the first time; distinguishing the communication protocol type of the current printing module through the difference of handshake of different communication protocols; and converting the USB protocol into a communication protocol which can be identified by the current non-USB printing equipment, and sending the printing data to the non-USB printing equipment for printing.
When printing, virtual USB printer module 11 receives the print data, start conversion communication module 13, design an intermediate level promptly, convert the USB protocol into the communication protocol that current intelligent terminal printer can discern, the communication protocol that known print module used is half duplex mode at least, two-way communication promptly, no matter be the serial ports, bluetooth or network port agreement, equipment can send the data of shaking hands when first connecting with print module, the difference of shaking hands of accessible different communication protocols distinguishes which kind of communication protocol that current print module used, so convert USB data into the data of corresponding agreement, and send data to print drive module 14, print drive module 14 processing data, realize printing.
The invention can construct a virtual USB printer on the printing equipment which does not support the USB communication protocol by loading the virtual USB printer module 11, the system detects the USB printer by default, the upper layer application can be connected with the virtual USB printer through a standard interface for communication, the communication protocol driven by the bottom layer can be stripped by utilizing the conversion communication module 13, the USB printer application does not need to care about the printing driving protocol, and the USB printer application is completely processed by the conversion communication module 13 for printing. On the basis that a client develops the application of a standard android USB printer, the application does not need to be modified when the printer scheme of different protocols is switched, and the development time of the client is saved; the communication protocol supported by the printing module is closely related to hardware, and the communication of upper-layer application to the printing driver is realized by the invention under the condition of not modifying the hardware and the printing driver protocol, so that the hardware switching and the driver development cost are greatly reduced; the invention accords with the code design switching principle, does not need to modify the designed application layer and the designed drive layer, and the system is completed by the extended function module.
In an embodiment of the present invention, there is further provided a computer device, including a memory and a processor, where the memory stores a computer program, and the processor implements the steps in the above method embodiments when executing the computer program:
starting up and loading a virtual USB printer module 11, and constructing non-USB printing equipment into a virtual USB printer;
acquiring a USB printer device detection request;
responding the USB printer equipment detection request, and feeding back the virtual USB printer information to a USB printer application;
establishing connection with the USB printer application and transmitting data;
and receiving the printing data sent by the USB printer application, and printing by the non-USB printing equipment.
In an embodiment of the present invention, there is further provided a storage medium having a computer program stored thereon, which when executed by a processor, implements the steps in the above-described method embodiments:
starting up and loading a virtual USB printer module 11, and constructing non-USB printing equipment into a virtual USB printer;
acquiring a USB printer device detection request;
responding the USB printer equipment detection request, and feeding back the virtual USB printer information to a USB printer application;
establishing connection with the USB printer application and transmitting data;
and receiving the printing data sent by the USB printer application, and printing by the non-USB printing equipment.
It will be understood by those skilled in the art that all or part of the processes of the methods of the embodiments described above can be implemented by hardware instructions of a computer program, which can be stored in a non-volatile computer-readable storage medium, and when executed, can include the processes of the embodiments of the methods described above. Any reference to memory, storage, database or other medium used in the embodiments provided herein can include at least one of non-volatile and volatile memory.
The above description is only for the purpose of illustrating the preferred embodiments of the present invention and is not to be construed as limiting the invention, and any modifications, equivalents and improvements made within the spirit and principle of the present invention are intended to be included within the scope of the present invention.

Claims (10)

1. A method for printing by virtual printing equipment is applied to printers which do not support a USB communication protocol, namely non-USB printing equipment, and realizes that the printing equipment which does not support the USB communication protocol can realize printing by using a USB printer developed based on an Android system; the method for printing by the virtual printing equipment is characterized by comprising the following steps:
acquiring a USB printer device detection request;
responding the USB printer equipment detection request, and feeding back the virtual USB printer information to a USB printer application;
establishing connection with the USB printer application and transmitting data;
and receiving the printing data sent by the USB printer application, and printing by the non-USB printing equipment.
2. The method of printing by the virtual printing device of claim 1, wherein: the virtual USB printer module is composed of a custom service and a custom USB device class, is used for initializing the USB service in the starting process, instantiates the custom USB device class according to the process of adding new devices to the USB service when the USB service is in a normal running state, realizes a virtual USB printer, and constructs non-USB printing devices into the virtual USB printer.
3. The method of printing by the virtual printing device of claim 2, wherein: the new device adding process of the USB service is a process of adding different attribute values of different types of USB devices into a device list, wherein the attribute value of the user-defined USB device class is an attribute value carried by filling one USB printing device with a reference USB printer model.
4. A method of printing by a virtual printing device as claimed in claim 3, wherein: the attribute values of the custom USB device class include a device descriptor, an endpoint descriptor, a vendor ID, or a device version number.
5. The method of printing by the virtual printing device of claim 4, wherein: and the USB printer equipment detection request calls an Android standard USB communication interface to interact with a USB service module by the USB printer application so as to send a request for acquiring the USB printer equipment, and the request is used for acquiring the number of the USB equipment on the Android equipment.
6. The method of printing by the virtual printing device of claim 5, wherein: and after responding to the USB printer equipment detection request and constructing a virtual USB printer for the non-USB printing equipment loaded with the virtual USB printer module, the USB printer application acquires a USB printer by default when acquiring the virtual USB printer equipment.
7. The method of printing by the virtual printing device of claim 6, wherein: the receiving of the print data sent by the USB printer application, when the printing is performed by the non-USB printing device, further includes:
sending handshake data when the virtual USB printer equipment is connected with a printing module of the non-USB printer equipment for the first time;
distinguishing the communication protocol type of the current printing module through the difference of handshake of different communication protocols;
and converting the USB protocol into a communication protocol which can be identified by the current non-USB printing equipment, and sending the printing data to the non-USB printing equipment for printing.
8. A system for printing by a virtual printing device, characterized by: the system for printing by the virtual printing equipment adopts the method for printing by the virtual printing equipment in any one of claims 1 to 7 to realize that the printing equipment which does not support the USB communication protocol can realize printing by the USB printer application developed based on the Android system; the system for printing by the virtual printing device comprises:
the virtual USB printer module is used for loading when the non-USB printing equipment is started up and constructing the non-USB printing equipment into a virtual USB printer;
the USB service module is used for interacting with a USB printer application through an android standard USB communication interface so as to send a request of the USB printer application for acquiring USB printer equipment, feeding information back to the USB printer application when a virtual USB printer is detected, and transmitting data of the USB printer application to the virtual USB printer module;
the conversion communication module is used for converting the USB protocol into a communication protocol which can be identified by the current non-USB printing equipment and transmitting data to the printing drive module; and
and the printing driving module is used for receiving the data transmitted by the conversion communication module and driving the non-USB printing equipment to print.
9. A computer device comprising a memory and a processor, the memory storing a computer program, characterized in that the processor, when executing the computer program, implements the steps of the method of any of claims 1 to 5.
10. A storage medium storing a computer program, characterized in that the computer program, when being executed by a processor, realizes the steps of the method of any one of claims 1 to 5.
CN202111152857.1A 2021-09-29 2021-09-29 Method, system, device and storage medium for printing by virtual printing device Pending CN113885816A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111152857.1A CN113885816A (en) 2021-09-29 2021-09-29 Method, system, device and storage medium for printing by virtual printing device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111152857.1A CN113885816A (en) 2021-09-29 2021-09-29 Method, system, device and storage medium for printing by virtual printing device

Publications (1)

Publication Number Publication Date
CN113885816A true CN113885816A (en) 2022-01-04

Family

ID=79008185

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111152857.1A Pending CN113885816A (en) 2021-09-29 2021-09-29 Method, system, device and storage medium for printing by virtual printing device

Country Status (1)

Country Link
CN (1) CN113885816A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114756181A (en) * 2022-04-27 2022-07-15 深圳前海百递网络有限公司 Cloud printing method, device, equipment and storage medium

Citations (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2005033295A (en) * 2003-07-08 2005-02-03 Oki Telecommunication Systems Co Ltd Protocol conversion apparatus, protocol conversion method, and protocol conversion program
JP2007323120A (en) * 2006-05-30 2007-12-13 Silex Technology Inc Printer connection device and network printing system
CN101675422A (en) * 2007-04-30 2010-03-17 惠普发展公司,有限责任合伙企业 systems and methods for sharing a printer
CN103475561A (en) * 2013-09-26 2013-12-25 山东神思电子技术股份有限公司 Virtual communication link dynamic switching-on and switching-off method and device
CN103970582A (en) * 2013-01-28 2014-08-06 联想(北京)有限公司 USB device simulation method
US20140268229A1 (en) * 2013-03-12 2014-09-18 Midnight Mosaic, Llc Methods and apparatus for usb tunneling through usb printer device class
CN104898611A (en) * 2015-04-16 2015-09-09 段亮 Remote control system compatible with different types of 3D printers
CN106970767A (en) * 2017-03-03 2017-07-21 华中科技大学 It is a kind of to realize the method and system that local printer accesses cloud print platform
CN112015356A (en) * 2019-05-30 2020-12-01 佳能株式会社 Virtual device, operating system, virtual device service, information processing device and control method thereof
CN112035074A (en) * 2019-06-04 2020-12-04 中兴通讯股份有限公司 Printing implementation method, device and system and storage medium
CN112764694A (en) * 2021-01-13 2021-05-07 统信软件技术有限公司 Printing system, printing method and computing device
CN113190187A (en) * 2021-04-28 2021-07-30 杭州和利时自动化有限公司 Printing method, printing device, electronic equipment and computer readable storage medium

Patent Citations (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2005033295A (en) * 2003-07-08 2005-02-03 Oki Telecommunication Systems Co Ltd Protocol conversion apparatus, protocol conversion method, and protocol conversion program
JP2007323120A (en) * 2006-05-30 2007-12-13 Silex Technology Inc Printer connection device and network printing system
CN101675422A (en) * 2007-04-30 2010-03-17 惠普发展公司,有限责任合伙企业 systems and methods for sharing a printer
CN103970582A (en) * 2013-01-28 2014-08-06 联想(北京)有限公司 USB device simulation method
US20140268229A1 (en) * 2013-03-12 2014-09-18 Midnight Mosaic, Llc Methods and apparatus for usb tunneling through usb printer device class
CN103475561A (en) * 2013-09-26 2013-12-25 山东神思电子技术股份有限公司 Virtual communication link dynamic switching-on and switching-off method and device
CN104898611A (en) * 2015-04-16 2015-09-09 段亮 Remote control system compatible with different types of 3D printers
CN106970767A (en) * 2017-03-03 2017-07-21 华中科技大学 It is a kind of to realize the method and system that local printer accesses cloud print platform
CN112015356A (en) * 2019-05-30 2020-12-01 佳能株式会社 Virtual device, operating system, virtual device service, information processing device and control method thereof
CN112035074A (en) * 2019-06-04 2020-12-04 中兴通讯股份有限公司 Printing implementation method, device and system and storage medium
CN112764694A (en) * 2021-01-13 2021-05-07 统信软件技术有限公司 Printing system, printing method and computing device
CN113190187A (en) * 2021-04-28 2021-07-30 杭州和利时自动化有限公司 Printing method, printing device, electronic equipment and computer readable storage medium

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114756181A (en) * 2022-04-27 2022-07-15 深圳前海百递网络有限公司 Cloud printing method, device, equipment and storage medium

Similar Documents

Publication Publication Date Title
US20050209842A1 (en) Remote USB port system and method
WO2023284699A1 (en) Protocol stack data transmission method based on linux system, and computer device and storage medium
US9537927B2 (en) Communication device
CN107493266B (en) Communication system, method and device of embedded self-service terminal
EP2922267B1 (en) Method for achieving communication based on mbim interface and device therefor
CN107425943A (en) Message data transmission method and device, electronic equipment and computer storage medium
CN102170366B (en) Method, device and system for communicating with single board
CN103092648B (en) A kind of image upgrade method, system and subscriber equipment and personal computer
US10499311B2 (en) Method and apparatus for implementing network sharing
CN104753746B (en) The method and control server of a kind of access device
EP2670107B1 (en) Communication method for wireless terminal and host device, and wireless terminal and host device
CN113885816A (en) Method, system, device and storage medium for printing by virtual printing device
CN116032968B (en) Internet of things equipment communication method and Internet of things equipment
US9525757B2 (en) Information processing apparatus that controls connection of devices, method of controlling the apparatus, and device control system
EP2015190B1 (en) Technique of controlling communication of installed apparatus with outside by means of proxy server
US8051191B2 (en) Ethernet extensibility
KR100501856B1 (en) Communication control apparatus and method
US12452675B2 (en) Bluetooth connection
WO2016179944A1 (en) Function multiplexing method and apparatus for communication interface
CN115567619B (en) Communication method, device and message queue telemetry transport protocol client
CN107277163A (en) A kind of long-range mapping method of equipment and device
CN118316573A (en) Communication baud rate adaptation method, module, device and readable storage medium
US20070155422A1 (en) Method for controlling mobile data connection through USB Ethernet management of mobile station
CN213342280U (en) Communication system
US9009328B2 (en) System and method for dynamic negotiation of device name with wildcard character

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20220104