[go: up one dir, main page]

CN115599323B - Printing device control method, apparatus, device and storage medium - Google Patents

Printing device control method, apparatus, device and storage medium Download PDF

Info

Publication number
CN115599323B
CN115599323B CN202211529237.XA CN202211529237A CN115599323B CN 115599323 B CN115599323 B CN 115599323B CN 202211529237 A CN202211529237 A CN 202211529237A CN 115599323 B CN115599323 B CN 115599323B
Authority
CN
China
Prior art keywords
image
printing
printed
sdk
connection
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.)
Active
Application number
CN202211529237.XA
Other languages
Chinese (zh)
Other versions
CN115599323A (en
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.)
ShenZhen NuoYouXue Technology Co.,Ltd.
Original Assignee
Shenzhen Nuoyuoxue Technology 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 Shenzhen Nuoyuoxue Technology Co ltd filed Critical Shenzhen Nuoyuoxue Technology Co ltd
Priority to CN202211529237.XA priority Critical patent/CN115599323B/en
Publication of CN115599323A publication Critical patent/CN115599323A/en
Application granted granted Critical
Publication of CN115599323B publication Critical patent/CN115599323B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR 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/1211Improving printing performance
    • G06F3/1212Improving printing performance achieving reduced delay between job submission and print start
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N1/00Scanning, transmission or reproduction of documents or the like, e.g. facsimile transmission; Details thereof
    • H04N1/00127Connection or combination of a still picture apparatus with another apparatus, e.g. for storage, processing or transmission of still picture signals or of information associated with a still picture
    • H04N1/00132Connection or combination of a still picture apparatus with another apparatus, e.g. for storage, processing or transmission of still picture signals or of information associated with a still picture in a digital photofinishing system, i.e. a system where digital photographic images undergo typical photofinishing processing, e.g. printing ordering
    • H04N1/00185Image output
    • H04N1/00188Printing, e.g. prints or reprints
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N1/00Scanning, transmission or reproduction of documents or the like, e.g. facsimile transmission; Details thereof
    • H04N1/00127Connection or combination of a still picture apparatus with another apparatus, e.g. for storage, processing or transmission of still picture signals or of information associated with a still picture
    • H04N1/00278Connection or combination of a still picture apparatus with another apparatus, e.g. for storage, processing or transmission of still picture signals or of information associated with a still picture with a printing apparatus, e.g. a laser beam printer
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N1/00Scanning, transmission or reproduction of documents or the like, e.g. facsimile transmission; Details thereof
    • H04N1/40Picture signal circuits
    • H04N1/405Halftoning, i.e. converting the picture signal of a continuous-tone original into a corresponding signal showing only two levels
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Theoretical Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Accessory Devices And Overall Control Thereof (AREA)

Abstract

The application provides a printing device control method, a device and a storage medium, wherein the method comprises the following steps: acquiring an operation interface, packaging the operation interface, and generating a printing connection SDK; connecting the printing device through the printing connection SDK; acquiring an original image, and carrying out binarization on the original image to obtain an image to be printed; and transmitting the image to be printed to the printing equipment by taking the image pixel as a unit, and simultaneously controlling the printing equipment to print the image to be printed. By using the content to be printed as the original image, the printing equipment does not need to use more memories on a hardware level to expand the storage space, and the hardware cost of the printing equipment can be reduced. The bytes comprising a plurality of image pixels are transmitted to the printing equipment, so that the transmission efficiency of the image to be printed can be improved, the image to be printed is printed while the image to be printed is transmitted, and the efficiency of printing the image to be printed is improved.

Description

Printing device control method, apparatus, device and storage medium
Technical Field
The present application relates to the field of print control technology, and for example, to a printing apparatus control method, apparatus, device, and storage medium.
Background
Printing equipment such as a printer is widely applied to the fields of work, certificate handling and the like, and the existing printing equipment can be connected with a tablet personal computer and is controlled to print images and/or characters through the tablet personal computer. When the content to be printed contains characters, the existing method for controlling the printing equipment is that the tablet computer directly transmits the character content to be printed to the printing equipment and controls the printing equipment to print the character content. Tablet computer systems such as the android system support characters in multiple languages, but the printing device needs to use more memories on the hardware level to expand the storage space to store word libraries in multiple languages, resulting in higher hardware cost. Another existing printing device control method is that a tablet computer sends printed text content to a printing device in an image mode for printing, but the data volume of an image is large, and the image to be printed cannot be printed while the image to be printed is transmitted.
Disclosure of Invention
The application provides a printing equipment control method, a printing equipment control device, printing equipment and a storage medium, and aims to solve the problems that hardware cost is high due to direct printing of text content, and the image to be printed cannot be printed while the image to be printed is transmitted.
In order to solve the problems, the following technical scheme is adopted in the application:
provided herein is a printing apparatus control method including:
acquiring an operation interface, packaging the operation interface, and generating a printing connection SDK;
connecting the printing device through the printing connection SDK;
acquiring an original image, and carrying out binarization on the original image to obtain an image to be printed;
and transmitting the image to be printed to the printing equipment by taking image pixels as transmission units, and simultaneously controlling the printing equipment to print the image to be printed.
Preferably, the binarizing the original image to obtain an image to be printed includes:
setting a pixel value threshold;
taking each pixel point of which the pixel value is greater than or equal to the pixel value threshold value in the original image as a target pixel point;
taking each pixel point in the original image, of which the pixel value is smaller than the pixel value threshold value, as a non-target pixel point;
setting the pixel value of each target pixel point to be 1, and setting the pixel value of each non-target pixel point to be 0, so as to obtain the image to be printed.
Preferably, the transmitting the image to be printed to the printing apparatus in units of image pixels includes:
taking a preset number of image pixels as image bytes in rows or columns;
sequencing all the image bytes to obtain a transmission sequence;
transmitting all of the image bytes to the printing device according to the transmission order.
Preferably, the connecting the printing device through the printing connection SDK includes:
acquiring a connection function;
running the connection function to select the printing connection SDK;
connecting the printing device using the printing connection SDK.
Preferably, the encapsulating the operation interface and generating the printing connection SDK includes:
packaging the operation interface to obtain a packaged interface, wherein the operation interface is a USB interface;
and generating the printing connection SDK according to the packaging interface.
Preferably, the controlling the printing apparatus to print the image to be printed includes:
detecting whether a fault prompt is received, wherein the fault prompt comprises a paper jam prompt and/or a paper shortage prompt;
and if the fault prompt is received, stopping transmitting the image to be printed to the printing equipment.
Preferably, after the simultaneously controlling the printing apparatus to print the image to be printed, the method further includes:
obtaining a closing function;
disconnecting the printing device according to the shutdown function.
The present application also provides a printing apparatus control device, including:
the printing connection SDK generating module is used for acquiring an operation interface, packaging the operation interface and generating a printing connection SDK;
the printing equipment connecting module is used for connecting the printing equipment through the printing connection SDK;
the original image binarization module is used for acquiring an original image, and binarizing the original image to obtain an image to be printed;
and the image to be printed printing module is used for transmitting the image to be printed to the printing equipment by taking image pixels as units and controlling the printing equipment to print the image to be printed.
The present application also provides a computer device comprising a memory and a processor, wherein the memory stores a computer program, and the processor implements the steps of the printing device control method according to any one of the above when executing the computer program.
The present application also provides a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, implements the steps of the printing apparatus control method of any of the above.
The printing equipment control method comprises the steps of obtaining an operation interface, packaging the operation interface and generating a printing connection SDK; connecting the printing device through the printing connection SDK; acquiring an original image, and carrying out binarization on the original image to obtain an image to be printed; and transmitting the image to be printed to the printing equipment by taking the image pixel as a unit, and simultaneously controlling the printing equipment to print the image to be printed. By using the content to be printed as the original image, the printing equipment does not need to use more memories on a hardware level to expand the storage space, and the hardware cost of the printing equipment can be reduced. The original image is binarized and then transmitted by taking the image pixels as transmission units, wherein the transmission units are bits, one byte comprises a plurality of bits, namely one byte comprises a plurality of image pixels. The bytes comprising a plurality of image pixels are transmitted to the printing equipment, so that the transmission efficiency of the image to be printed can be improved, the image to be printed is printed while the image to be printed is transmitted, and the efficiency of printing the image to be printed is improved.
Drawings
FIG. 1 is a flowchart illustrating a printing apparatus control method according to an embodiment;
FIG. 2 is a schematic diagram of a process for connecting a printing device via a printing connection SDK according to an embodiment;
FIG. 3 is a schematic flowchart illustrating an exemplary process of binarizing an original image;
FIG. 4 is a schematic flow diagram of a disconnected printing device of an embodiment;
FIG. 5 is a block diagram schematically showing the configuration of a printing apparatus control device according to an embodiment;
FIG. 6 is a block diagram illustrating the structure of a computer device according to an embodiment.
The implementation of the objectives, functional features, and advantages of the present application will be further described with reference to the accompanying drawings.
Detailed Description
In order to make the objects, technical solutions and advantages of the present application more apparent, the present application 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 present application and are not intended to limit the present application.
As used herein, the singular forms "a", "an", "the" and "the" include plural referents unless the content clearly dictates otherwise. It will be further understood that the terms "comprises" and/or "comprising," when used in this specification, specify the presence of stated features, integers, steps, operations, elements, units, and/or components, but do not preclude the presence or addition of one or more other features, integers, steps, operations, elements, units, components, and/or groups thereof. It will be understood that when an element is referred to as being "connected" or "coupled" to another element, it can be directly connected or coupled to the other element or intervening elements may also be present. Further, "connected" or "coupled" as used herein may include wirelessly connected or wirelessly coupled. As used herein, the term "and/or" includes all or any element and all combinations of one or more of the associated listed items.
It will be understood by those within the art that, unless otherwise defined, all terms (including technical and scientific terms) used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs. It will be further understood that terms, such as those defined in commonly used dictionaries, should be interpreted as having a meaning that is consistent with their meaning in the context of the prior art and will not be interpreted in an idealized or overly formal sense unless expressly so defined herein.
Referring to fig. 1, a schematic flow chart of a printing apparatus control method according to the present application includes:
s1: and acquiring an operation interface, packaging the operation interface, and generating a printing connection SDK.
Packaging the operation interface to obtain a packaged interface, wherein the operation interface is a USB interface;
and generating the printing connection SDK (Software Development Kit) according to the packaging interface.
The tablet computer obtains an operation interface corresponding to the USB developer mode provided by the android system framework, and the operation interface is packaged into a printing connection SDK.
Through the packaging operation interface, the printing device can be directly connected by using the printing connection SDK.
Preferably, the reconnecting software or the reconnecting code is packaged inside the printing connection SDK, so that when the printing device stops working on a physical level, for example, when the printing device stops working due to power failure, the printing connection SDK releases relevant resources on a software level, and when the printing device restarts working, the tablet computer automatically reconnects the printing device through the printing connection SDK.
S2: and connecting the printing device through the printing connection SDK.
Referring to fig. 2, the step S2 of connecting the printing apparatus through the print connection SDK includes the following steps S21 to S23:
s21: acquiring a connection function;
s22: running the connection function to select the printing connection SDK;
s23: connecting the printing device using the printing connection SDK.
Optionally, the connection function is an Open-type function. The printing device is connected through the printing connection SDK, codes for enumerating the printing device and connecting the printing device do not need to be written, and the efficiency of connecting the printing device is improved.
On the hardware level, the tablet computer is wirelessly connected or wired with the printing device.
S3: and acquiring an original image, and carrying out binarization on the original image to obtain an image to be printed.
Referring to fig. 3, the step S3 of binarizing the original image to obtain an image to be printed includes the following steps S31 to S34:
s31: setting a pixel value threshold;
s32: taking each pixel point of which the pixel value is greater than or equal to the pixel value threshold value in the original image as a target pixel point;
s33: taking each pixel point in the original image, of which the pixel value is smaller than the pixel value threshold value, as a non-target pixel point;
s34: and setting the pixel value of each target pixel point to be 1, and setting the pixel value of each non-target pixel point to be 0 to obtain the image to be printed.
The original image may be a black and white image or a grayscale image. If the original image is a black-and-white image, the pixel value of the pixel point in the black area in the original image is 0, and the pixel value of the pixel point in the white area in the original image is 255.
Preferably, the pixel value threshold is set to 160.
Setting the pixel value threshold value to 1 for the pixel points which are greater than or equal to the pixel value threshold value in the original image, and setting the pixel value of the pixel points which are less than the pixel value threshold value in the original image to 0. Preferably, one image byte includes 8 bits, and 1 bit in the image byte can be used to represent the pixel value of one pixel point in the image to be printed.
If the original image is a black-and-white image, the pixel value of the pixel point of the original image is 0 or 255, and if the original image is a gray image, the pixel value of the pixel point of the original image ranges from 0 to 255, and only one image byte can be used for representing one pixel point of the original image. Compared with the method that one image byte is used for representing one pixel point of an original image, the binaryzation is carried out on the original image to obtain the image to be printed, and one image byte can represent 8 pixel points of the image to be printed, so that the data volume needing to be transmitted can be reduced, and the data transmission efficiency is improved.
S4: and transmitting the image to be printed to the printing equipment by taking the image pixel as a transmission unit, and controlling the printing equipment to print the image to be printed.
The transmitting the image to be printed to the printing apparatus in units of image pixels includes: taking a preset number of image pixels as image bytes in rows or columns;
sequencing all the image bytes to obtain a transmission sequence;
transmitting all of the image bytes to the printing device according to the transmission order.
Preferably, the preset number is set to 8, the selection is made by rows starting from the first row of the image to be printed, and the consecutive 8 image pixels selected each time are taken as one image byte.
And determining the position of the first image pixel in each image byte in the image to be printed, wherein the smaller the row number and the column number of the image pixel is, the earlier the image byte corresponding to the image pixel is in the transmission sequence.
All image bytes are transmitted to the printing device in the transmission order so that the printing device can print out the image to be printed.
The controlling the printing device to print the image to be printed includes:
detecting whether a fault prompt is received, wherein the fault prompt comprises a paper jam prompt and/or a paper shortage prompt;
and if the fault prompt is received, stopping transmitting the image to be printed to the printing equipment.
When the printing equipment receives an instruction for printing an image to be printed, if a fault exists, the printing equipment sends a fault prompt to the tablet computer, and the tablet computer stops transmitting the image to be printed to the printing equipment; when the printing equipment receives an instruction of printing an image to be printed, if no fault exists, the printing equipment does not send a response signal to the tablet computer. Compared with a data transmission mode of one response, the method has the advantages that the printing equipment sends the fault prompt to the tablet personal computer only under the condition that the fault exists, and the data transmission efficiency can be improved.
The printing equipment control method comprises the steps of obtaining an operation interface, packaging the operation interface, and generating a printing connection SDK; connecting the printing device through the printing connection SDK; acquiring an original image, and carrying out binarization on the original image to obtain an image to be printed; and transmitting the image to be printed to the printing equipment by taking the image pixel as a unit, and simultaneously controlling the printing equipment to print the image to be printed. By using the content to be printed as the original image, the printing equipment does not need to use more memories on a hardware level to expand the storage space, and the hardware cost of the printing equipment can be reduced. The original image is binarized and then transmitted by taking the image pixels as transmission units, wherein the transmission units are bits, and one byte comprises a plurality of bits, namely one byte comprises a plurality of image pixels. The bytes comprising a plurality of image pixels are transmitted to the printing equipment, so that the transmission efficiency of the image to be printed can be improved, the image to be printed is printed while the image to be printed is transmitted, and the efficiency of printing the image to be printed is improved.
In one embodiment, referring to fig. 4, after the step S4 of simultaneously controlling the printing apparatus to print the image to be printed, the method further includes the following steps S51-S52:
s51: a shutdown function is obtained.
Optionally, the Close function is a Close-like function.
The shutdown function includes the address of the printing device and/or the name of the printing device.
S52: disconnecting the printing device according to the shutdown function.
After printing is finished, the printing equipment detects whether an image to be printed is received, if not, the printing equipment continues to wait, and when the waiting time exceeds a waiting time threshold value, the connection between the tablet personal computer and the printing equipment is disconnected through a closing function, and the printing equipment is enabled to be in a standby state.
The connection between the tablet personal computer and the printing equipment is automatically disconnected, the printing equipment is in a standby state, energy consumption can be reduced, and error printing of the printing equipment under the condition that a printing instruction of the tablet personal computer is not received can be prevented.
As described above, after controlling the printing device to print the image to be printed, the method further includes obtaining a closing function, and disconnecting the printing device according to the closing function. The connection between the tablet personal computer and the printing equipment is automatically disconnected, the printing equipment is in a standby state, energy consumption can be reduced, and error printing of the printing equipment under the condition that a printing instruction of the tablet personal computer is not received can be prevented.
Referring to fig. 5, it is a block diagram schematically illustrating the structure of a printing device control apparatus according to the present application, the apparatus comprising:
a printing connection SDK generation module 10, configured to obtain an operation interface, package the operation interface, and generate a printing connection SDK;
a printing device connection module 20, configured to connect to a printing device through the printing connection SDK;
an original image binarization module 30, configured to obtain an original image, and binarize the original image to obtain an image to be printed;
and the to-be-printed image printing module 40 is configured to transmit the to-be-printed image to the printing device in units of image pixels, and control the printing device to print the to-be-printed image.
In one embodiment, the raw image binarization module 30 further comprises:
a pixel value threshold setting unit for setting a pixel value threshold;
a target pixel point definition unit, configured to use, as a target pixel point, each pixel point in the original image whose pixel value is greater than or equal to the pixel value threshold;
a non-target pixel point definition unit, configured to use each pixel point in the original image, where the pixel value is smaller than the pixel value threshold, as a non-target pixel point;
and the pixel value setting unit is used for setting the pixel value of each target pixel point to be 1 and setting the pixel value of each non-target pixel point to be 0 to obtain the image to be printed.
In one embodiment, the image to be printed printing module 40 further includes:
the image byte definition unit is used for taking the image pixels with preset number as image bytes according to rows or columns;
the image byte sequencing unit is used for sequencing all the image bytes to obtain a transmission sequence;
an image byte transmission unit configured to transmit all the image bytes to the printing apparatus according to the transmission order.
In one embodiment, the printing device connection module 20 further includes:
a connection function acquisition unit for acquiring a connection function;
a printing connection SDK selecting unit for operating the connection function to select the printing connection SDK;
a printing device connecting unit configured to connect the printing device using the printing connection SDK.
In one embodiment, the printing connection SDK generating module 10 further includes:
the operation interface packaging unit is used for packaging the operation interface to obtain a packaged interface, and the operation interface is a USB interface;
and the printing connection SDK generating unit is used for generating the printing connection SDK according to the packaging interface.
In one embodiment, the image to be printed printing module 40 further includes:
the fault prompt detection unit is used for detecting whether a fault prompt is received or not, wherein the fault prompt comprises a paper jam prompt and/or a paper shortage prompt;
and the transmission stopping unit is used for stopping transmitting the image to be printed to the printing equipment if the fault prompt is received.
In one embodiment, the printing device control apparatus further includes:
a closing function obtaining module for obtaining a closing function;
and the disconnection module is used for disconnecting the printing equipment according to the closing function.
Referring to fig. 6, an embodiment of the present application further provides a computer device, where the computer device may be a server, and an internal structure of the computer device may be as shown in fig. 6. The computer device includes a processor, a memory, a network interface, and a database connected by a system bus. The computer designed processor is used to provide computational and control capabilities. The memory of the computer device comprises a nonvolatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program, and a database. The internal memory provides an environment for the operation of an operating system and computer programs in the non-volatile storage medium. The database of the computer device is used to store images to be printed, etc. The network interface of the computer device is used for communicating with an external terminal through a network connection. Further, the computer device may be further provided with an input device, a display screen, and the like. The computer program is executed by a processor to implement a printing apparatus control method.
The processor executes the printing apparatus control method, including:
acquiring an operation interface, packaging the operation interface, and generating a printing connection SDK;
connecting the printing device through the printing connection SDK;
acquiring an original image, and carrying out binarization on the original image to obtain an image to be printed;
and transmitting the image to be printed to the printing equipment by taking image pixels as transmission units, and simultaneously controlling the printing equipment to print the image to be printed.
Those skilled in the art will appreciate that the architecture shown in fig. 6 is merely a block diagram of some of the structures associated with the present teachings and is not intended to limit the scope of the present teachings as applied to computer devices.
An embodiment of the present application also provides a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, implements a printing apparatus control method. It is to be understood that the computer-readable storage medium in the present embodiment may be a volatile-readable storage medium or a non-volatile-readable storage medium.
The printing apparatus control method includes:
acquiring an operation interface, packaging the operation interface, and generating a printing connection SDK;
connecting a printing device through the printing connection SDK;
acquiring an original image, and carrying out binarization on the original image to obtain an image to be printed;
and transmitting the image to be printed to the printing equipment by taking image pixels as transmission units, and simultaneously controlling the printing equipment to print the image to be printed.
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 provided herein and used in the embodiments may include non-volatile and/or volatile memory. Non-volatile memory can include read-only memory (ROM), programmable ROM (PROM), electrically Programmable ROM (EPROM), electrically Erasable Programmable ROM (EEPROM), or flash memory. Volatile memory can include Random Access Memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in a variety of forms such as Static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (SSRDRAM), enhanced SDRAM (ESDRAM), synchronous Link (Synchlink) DRAM (SLDRAM), rambus (Rambus) direct RAM (RDRAM), direct bused dynamic RAM (DRDRAM), and bused dynamic RAM (RDRAM).
It should be noted that, in this document, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, apparatus, article, or method that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, apparatus, article, or method. Without further limitation, an element defined by the phrases "comprising a," "8230," "8230," or "comprising" does not exclude the presence of another identical element in a process, apparatus, article, or method comprising the element.
The above description is only a preferred embodiment of the present application, and not intended to limit the scope of the present application, and all modifications of equivalent structures and equivalent processes, which are made by the contents of the specification and the drawings of the present application, or which are directly or indirectly applied to other related technical fields, are also included in the scope of the present application.

Claims (7)

1. A printing apparatus control method characterized by comprising:
acquiring an operation interface, packaging the operation interface, and generating a printing connection SDK;
connecting the printing device through the printing connection SDK;
acquiring an original image, and carrying out binarization on the original image to obtain an image to be printed;
transmitting the image to be printed to the printing equipment by taking image pixels as transmission units, and simultaneously controlling the printing equipment to print the image to be printed; obtaining a closing function; disconnecting the printing device according to the shutdown function;
the controlling the printing device to print the image to be printed includes: detecting whether a fault prompt is received, wherein the fault prompt comprises a paper jam prompt and/or a paper shortage prompt; if the fault prompt is received, stopping transmitting the image to be printed to the printing equipment;
the transmitting the image to be printed to the printing apparatus with image pixels as a transmission unit includes:
taking a preset number of image pixels as image bytes in rows or columns;
determining the position of a first image pixel in each image byte in the image to be printed, wherein the smaller the row number and the column number of the image pixel are, the more front the image byte corresponding to the image pixel is in the transmission sequence; sequencing all the image bytes to obtain the transmission sequence;
transmitting all of the image bytes to the printing device according to the transmission order.
2. The printing apparatus control method according to claim 1, wherein the binarizing the original image to obtain an image to be printed comprises:
setting a pixel value threshold;
taking each pixel point of which the pixel value is greater than or equal to the pixel value threshold value in the original image as a target pixel point;
taking each pixel point in the original image, of which the pixel value is smaller than the pixel value threshold value, as a non-target pixel point;
setting the pixel value of each target pixel point to be 1, and setting the pixel value of each non-target pixel point to be 0, so as to obtain the image to be printed.
3. The printing apparatus control method according to claim 1, wherein said connecting a printing apparatus through said print connection SDK includes:
acquiring a connection function;
running the connection function to select the printing connection SDK;
connecting the printing device using the printing connection SDK.
4. The printing device control method according to claim 1, wherein the encapsulating the operation interface and generating a printing connection SDK includes:
packaging the operation interface to obtain a packaged interface, wherein the operation interface is a USB interface;
and generating the printing connection SDK according to the packaging interface.
5. A printing apparatus control device, characterized by comprising:
the printing connection SDK generating module is used for acquiring an operation interface, packaging the operation interface and generating a printing connection SDK;
the printing equipment connecting module is used for connecting the printing equipment through the printing connection SDK;
the original image binarization module is used for acquiring an original image and binarizing the original image to obtain an image to be printed;
the printing module of the image to be printed is used for transmitting the image to be printed to the printing equipment by taking image pixels as transmission units and controlling the printing equipment to print the image to be printed; obtaining a closing function; disconnecting the printing device according to the shutdown function;
the controlling the printing device to print the image to be printed includes: detecting whether a fault prompt is received, wherein the fault prompt comprises a paper jam prompt and/or a paper shortage prompt; if the fault prompt is received, stopping transmitting the image to be printed to the printing equipment;
the transmitting the image to be printed to the printing apparatus with image pixels as a transmission unit includes:
taking a preset number of image pixels as image bytes in rows or columns;
determining the position of a first image pixel in each image byte in the image to be printed, wherein the smaller the row number and the column number of the image pixel are, the more front the image byte corresponding to the image pixel is in the transmission sequence; sequencing all the image bytes to obtain the transmission sequence;
transmitting all of the image bytes to the printing device according to the transmission order.
6. A computer device comprising a memory and a processor, the memory having stored therein a computer program, characterized in that the processor, when executing the computer program, implements the steps of the printing device control method according to any one of claims 1 to 4.
7. A computer-readable storage medium, on which a computer program is stored, which, when being executed by a processor, carries out the steps of the printing apparatus control method according to any one of claims 1 to 4.
CN202211529237.XA 2022-12-01 2022-12-01 Printing device control method, apparatus, device and storage medium Active CN115599323B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202211529237.XA CN115599323B (en) 2022-12-01 2022-12-01 Printing device control method, apparatus, device and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211529237.XA CN115599323B (en) 2022-12-01 2022-12-01 Printing device control method, apparatus, device and storage medium

Publications (2)

Publication Number Publication Date
CN115599323A CN115599323A (en) 2023-01-13
CN115599323B true CN115599323B (en) 2023-03-21

Family

ID=84853213

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211529237.XA Active CN115599323B (en) 2022-12-01 2022-12-01 Printing device control method, apparatus, device and storage medium

Country Status (1)

Country Link
CN (1) CN115599323B (en)

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108628557A (en) * 2018-04-19 2018-10-09 深圳鼎智通讯股份有限公司 A kind of efficient printer technology based on picture compression

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106569755B (en) * 2016-10-26 2020-06-05 深圳盒子信息科技有限公司 Printing method and printing device for mobile payment terminal
JP6809567B2 (en) * 2019-06-21 2021-01-06 大日本印刷株式会社 Judgment device, control method of judgment device, judgment system, control method of judgment system, and program
CN111813350B (en) * 2020-05-29 2022-12-13 厦门汉印电子技术有限公司 Method, device and equipment for sending print data and storage medium
CN113190187A (en) * 2021-04-28 2021-07-30 杭州和利时自动化有限公司 Printing method, printing device, electronic equipment and computer readable storage medium

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108628557A (en) * 2018-04-19 2018-10-09 深圳鼎智通讯股份有限公司 A kind of efficient printer technology based on picture compression

Also Published As

Publication number Publication date
CN115599323A (en) 2023-01-13

Similar Documents

Publication Publication Date Title
US9177238B2 (en) Techniques for generating customized two-dimensional barcodes
CN111782505B (en) Train system simulation test method, device, computer equipment and storage medium
CN108335199B (en) Loan request processing method, loan request processing device, computer equipment and storage medium
CN105120109A (en) file display method and system
CN111399732B (en) Webpage screenshot method and device, computer equipment and storage medium
CN110597714B (en) Test method and device of kafka message, computer equipment and storage medium
CN112631908A (en) Browser page testing method and device, computer equipment and storage medium
CN109669646A (en) Method of printing, device, computer equipment and storage medium
KR980003992A (en) How to process print data
CN115599323B (en) Printing device control method, apparatus, device and storage medium
CN112765057B (en) Data transmission method, PCIE system, equipment and storage medium
CN113900762A (en) Page display method and device, computer equipment and storage medium
JP3039152B2 (en) Printer with automatic emulation switching function
CN108566301B (en) Switch offline configuration method, device, system and computer equipment
CN108984319B (en) Method, device, computer equipment and storage medium for solving operation instruction conflict
CN110990747A (en) Image generation method, device, equipment and storage medium
CN112286821A (en) HTML5 page compatibility testing method, device, equipment and storage medium
CN110865943A (en) Interface testing method and device, computer equipment and storage medium
CN111459564B (en) boot stage initialization compatible implementation method, system and computer equipment
US20130131842A1 (en) Programmable controller
CN112463791A (en) Nuclear power station document data acquisition method and device, computer equipment and storage medium
EP3514731B1 (en) System for producing information code and method of processing information
CN111652787A (en) Processing method and device for adding watermark characters into picture and computer equipment
CN112035157A (en) Method, equipment and storage medium for communication between android and front-end page
KR960700473A (en) DELIVERING AND FETCHING FONT INFORMATION

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
GR01 Patent grant
GR01 Patent grant
CP01 Change in the name or title of a patent holder

Address after: 518000, 702A, 702B, Building C, Chuangwei Innovation Valley, Tangtou No.1 Road, Tangtou Community, Shiyan Street, Bao'an District, Shenzhen City, Guangdong Province

Patentee after: ShenZhen NuoYouXue Technology Co.,Ltd.

Address before: 518000, 702A, 702B, Building C, Chuangwei Innovation Valley, Tangtou No.1 Road, Tangtou Community, Shiyan Street, Bao'an District, Shenzhen City, Guangdong Province

Patentee before: Shenzhen nuoyuoxue Technology Co.,Ltd.

CP01 Change in the name or title of a patent holder