Media processing apparatus and control method for media processing apparatus

By using hierarchical judgment of the media processing device and JSON-formatted response information, the problem of error judgment when the media processing device receives multiple setting information is solved, thereby improving the reliability of the device and the user's error handling capability.

CN117141121BActive Publication Date: 2025-11-14SEIKO EPSON CORP
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202310605818.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Priority Date
2022-05-31
Filing Date
2023-05-26
Publication Date
2025-11-14
Estimated Expiration
2043-05-26

AI Technical Summary

Technical Problem

In the prior art, when a media processing device receives multiple setting information, it is difficult to accurately determine the incorrect setting information and its cause.

Method used

The media processing device receives a general setting command through the communication unit, performs hierarchical judgment on the setting information using the control unit, and generates response information when an error is detected, including the setting item and reason for the error, and transmits it in JSON format.

Benefits of technology

It enables accurate error detection and cause analysis of the set information, improving the reliability of the media processing device and the user's error handling capability.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117141121B_ABST
    Figure CN117141121B_ABST
Patent Text Reader

Abstract

This invention provides a media processing apparatus and a control method for the media processing apparatus. The media processing apparatus includes: a communication unit capable of communicating with an external device; and a control unit that, upon receiving a first instruction containing multiple sets of setting information via the communication unit, determines whether the setting information is erroneous, wherein the setting information includes setting items related to the setting and setting values ​​corresponding to the setting items. If the control unit determines that an error exists in the setting information, upon receiving a second instruction via the communication unit, it sends response information via the communication unit, wherein the response information includes the first information related to the setting item for which the error is determined to exist and the second information related to the error.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This disclosure relates to a media processing apparatus and a control method for the media processing apparatus. Background Technology

[0002] Previously, as in Patent Document 1, there was a known device that would send multiple settings information when receiving an instruction requesting multiple settings information from an external device such as a computer.

[0003] However, in the device described in Patent Document 1, when an external device that receives multiple setting information has an error in the setting information, it is difficult to determine which setting information is wrong and what the error is.

[0004] Patent Document 1: Japanese Patent Application Publication No. 2016-128215 Summary of the Invention

[0005] A media processing apparatus includes: a communication unit capable of communicating with an external device; and a control unit that, upon receiving a first instruction containing multiple sets of setting information via the communication unit, determines whether the setting information is incorrect, wherein the setting information includes setting items related to the setting and setting values ​​corresponding to the setting items; and, if the control unit determines that an error exists in the setting information, upon receiving a second instruction via the communication unit, sends response information via the communication unit, wherein the response information includes first information related to the setting item for which the error is determined to exist and second information related to the error.

[0006] A control method for a media processing device is provided, comprising a communication unit capable of communicating with an external device. In this method, when a first instruction containing multiple sets of setting information is received via the communication unit, an error is determined in the setting information. The setting information includes setting items related to the setting and setting values ​​corresponding to the setting items. If an error is determined to exist in the setting information, when a second instruction is received via the communication unit, a response message is sent via the communication unit. The response message includes first information related to the setting item for which the error is determined to exist and second information related to the error. Attached Figure Description

[0007] Figure 1 This is a block diagram illustrating the structure of a media processing device.

[0008] Figure 2 An example representing the first instruction.

[0009] Figure 3 This is a flowchart illustrating the control method of a media processing device.

[0010] Figure 4 A table showing examples of response information sent by a media processing device.

[0011] Figure 5 An example of a response message.

[0012] Figure 6 An example of a response message.

[0013] Figure 7 An example of a response message.

[0014] Figure 8 An example of a response message.

[0015] Figure 9 An example of a response message. Detailed Implementation

[0016] 1. The media processing apparatus according to the first embodiment

[0017] 1-1. Structure of the Media Processing Device

[0018] Figure 1 The media processing device 1 shown is, for example, a line thermal printer for printing receipts, etc. Figure 1 As shown, the media processing device 1 is configured to include a control unit 10, a storage unit 20, a head 30, a roller 40, and a communication unit 50.

[0019] The control unit 10 is configured to include a CPU (Central Processing Unit) for unified control of all parts of the media processing device 1, a UART (Universal Asynchronous Receiver Transmitter) for input / output management, an FPGA (Field Programmable Gate Array) as logic circuitry, a PLD (Programmable Logic Device), etc. The CPU is also simply referred to as a processor. The storage unit 20 is configured to include flash memory (Read-Only Memory) or HDD (Hard Disk Drive) as rewritable non-volatile memory, or RAM (Random Access Memory) as volatile memory, etc.

[0020] The CPU of the control unit 10 reads the firmware and other programs stored in the non-volatile memory of the storage unit 20, and uses the RAM of the storage unit 20 as a working area to execute the program.

[0021] The communication unit 50 is configured to include circuitry for implementing communication. The communication unit 50 can be wired with a connector such as USB (Universal Serial Bus) or wireless with an antenna such as Wi-Fi. The communication unit 50 can receive printed data or instructions from the external device 2, and can also send response information (described later) to the external device 2.

[0022] In addition, external device 2 is, for example, a computer, tablet, or smartphone.

[0023] The head 30 is, for example, a thermal head. The recording paper, as the medium, is, for example, thermal paper in a long strip shape. The recording paper is held by the head 30 and the roller 40, and is conveyed by the roller 40.

[0024] The control unit 10 energizes the head 30 for the entire predetermined energizing time based on the printing data received from the external device 2, thereby heating it up and performing processes such as printing by applying the recording paper to the forming point.

[0025] In this way, the control unit 10 performs printing through the head 30 while feeding the recording paper through the roller 40.

[0026] The recording paper printed through the head 30 is cut by a shear (not shown) with a moving cutting blade and discharged from the media handling device 1.

[0027] 1-2. Instructions

[0028] Here, an example of instructions received and executed by the media processing device 1 from the external device 2 will be described in detail.

[0029] The instructions are configured according to the control system of the firmware of the media processing device 1. The instructions are configured to include information added to them. Furthermore, in this embodiment, text codes are also included in the instructions.

[0030] A. First instruction

[0031] The first instruction is a so-called general setting instruction that contains multiple setting information. The structure of a general setting instruction can be represented, for example, as "ESC+A+setting information". "ESC" indicates the instruction information containing the following series of information, and "A" indicates the instruction information for performing the general setting.

[0032] The following "setting information" consists of the setting items involved in the setting of the media processing device 1, and the combination of the setting values ​​corresponding to the setting items. In addition, there can be multiple setting items, and multiple setting items can be hierarchically arranged.

[0033] Figure 2 This shows an example of the "Settings Information" included in the summary setting command, excluding "ESC+A". Here, an example containing two sets of settings information is shown. For example... Figure 2 As shown, the setting information is structured hierarchically using "{" and "}" (curly braces), and the correspondence between setting items and setting values ​​is indicated using ":" (colon). Furthermore, as will be described later, Figure 2 There are two sets of settings shown, separated by a comma.

[0034] In addition, like Figure 2 and the response information described below. Figures 5-9 The format used to represent data using "{", "}", and ":" is called JSON (JavaScript Object Notation). JSON is supported by a wide variety of programming languages, enabling easy data exchange between them.

[0035] The control unit 10 can use "{", "}", and ":" to extract setting items and setting values ​​from the "setting information".

[0036] In addition, the "Setting" item, which is the highest-level setting item, is also called "object," and other setting items and setting values ​​are also called "string." Furthermore, setting items are also called "keywords," and setting values ​​are also called "values."

[0037] exist Figure 2 In this context, "0.0.0.0" and "Level20," which serve as the settings for various configuration information, are designated as "value." Furthermore, the configuration items located between "object" and "value" are designated as "key."

[0038] Figure 2 The first setting information is specifically structured as follows. First, the setting items are explained.

[0039] The first layer, the topmost layer, contains settings related to the configuration, namely "Setting". The second layer contains settings related to the TCP / IP structure of the network, namely "TcpIpCfg". The third layer contains settings related to Internet Protocol version 4, namely "Ipv4". The fourth layer, the bottommost layer, contains settings related to IP addresses, namely "Ip" as a communication setting.

[0040] Finally, a setting value corresponding to these level settings is configured, namely "0.0.0.0". "0.0.0.0" is the IP address value set in the media processing device 1, and is a communication item value.

[0041] also, Figure 2 The second setting information is specifically structured as follows. First, the setting items are explained.

[0042] The first level, the topmost level, contains settings related to the settings, namely "Setting". The second level contains settings related to printing, namely "Print". The third level, the bottommost level, contains settings related to printing speed, namely "Speed".

[0043] Finally, a setting value corresponding to these levels is configured, namely "Level 20". "Level 20" is the printing speed value set in the media processing device 1, and it is represented in a stage-by-stage manner as a level of printing speed value.

[0044] When the control unit 10 receives a general setting command from the communication unit 50, it determines that "ESC" in the general setting command is a command containing a series of subsequent information, and "A" is a command to perform general settings. Then, the control unit 10 determines the subsequent "setting information".

[0045] Specifically, in the general setting command, the control unit 10 determines the first setting information in the following manner.

[0046] The control unit 10 determines, in order from the upper layer to the lower layer, that "Setting" is a setting item related to the setting, "TcpIpCfg" is a setting item related to the TCP / IP structure of the network, "IpV4" is a setting item related to Internet Protocol version 4, and "Ip" is a setting item related to the IP address, and determines that "0.0.0.0" is a setting value corresponding to these hierarchical setting items and is an IP address value.

[0047] The control unit 10 determines the communication item included in the setting items of the setting information as, for example, "Ip". Furthermore, the control unit 10 determines the communication item value corresponding to "Ip" as, for example, "0.0.0.0". Additionally, as described later, "Ip" can be included in the first information.

[0048] In this way, the overall setting information of the setting command can include "Ip", which is both a setting item and a communication item, and can include "0.0.0.0", which is both a setting value corresponding to "Ip" and a communication item value.

[0049] The control unit 10 can determine "0.0.0.0" corresponding to "Ip" as the IP address value that the external device 2 wants to set for the media processing device 1, and set it in the communication unit 50.

[0050] Furthermore, in the summary setting command, the control unit 10 determines the second setting information in the following manner.

[0051] The control unit 10 determines, in order from the upper level to the lower level, that “Setting” is a setting item related to setting, “Print” is a setting item related to printing, and “Speed” is a setting item related to printing speed, and determines that “Level20” is a setting value corresponding to these hierarchical setting items and is a printing speed value.

[0052] In this way, the setting information of the general setting command can include the printing speed, i.e., "Speed", as a setting item, and the printing speed value corresponding to "Speed", i.e., "Level20", as a setting value. In addition, as described later, "Speed" can be included in the first information.

[0053] The control unit 10 can determine the setting value corresponding to "Speed", namely "Level 20", as the printing speed value and set it in the head 30 and the roller 40 to perform printing.

[0054] In the storage unit 20, hierarchical setting items are stored in an associated manner. When the control unit 10 receives a correct summary setting command, it stores the setting value in the storage unit 20 in a manner that corresponds to the hierarchical setting items, based on the setting information contained in the summary setting command.

[0055] The storage unit 20 has multiple hierarchical settings items, each with its own correct setting value.

[0056] For example, in the case of the first setting information, "Setting", "TcpIpCfg", "IpV4", and "Ip" are stored in the storage unit 20 in an associated manner as hierarchical setting items. Furthermore, the setting value "0.0.0.0" is stored in the storage unit 20 in a manner corresponding to the hierarchical setting item.

[0057] Alternatively, the following method can be adopted: only "Ip" as the lowest level is stored as a setting item, and "0.0.0.0" as the setting value is stored in the storage unit 20 in a manner corresponding to "Ip".

[0058] Furthermore, in the case of the second setting information, "Setting," "Print," and "Speed," which are hierarchical setting items, are stored in the storage unit 20 in an associated manner. Moreover, the setting value "Level 20" is stored in the storage unit 20 in a manner corresponding to the hierarchical setting item.

[0059] Alternatively, the following method can be adopted: only "Speed" as the lowest level is stored as a setting item, and "Level20" as a setting value is stored in the storage unit 20 in a manner corresponding to "Speed".

[0060] The control unit 10 can read the setting values ​​corresponding to the hierarchical setting items from the storage unit 20, thereby executing various settings.

[0061] For example, the control unit 10 traces the levels related to the settings of the communication unit 50 in order from the upper level to the lower level, based on the first setting information and referring to the storage unit 20.

[0062] Specifically, the control unit 10 refers to the storage unit 20 and traces back, in order from the upper layer to the lower layer, the settings related to the settings, including “Setting”, “TcpIpCfg”, “IpV4”, “Ip”, and the settings related to the communication unit 50.

[0063] Furthermore, the control unit 10 can read "0.0.0.0" from the storage unit 20 as the setting value corresponding to these hierarchical setting items.

[0064] The control unit 10 can set the communication unit 50 to "0.0.0.0" as the IP address read from the storage unit 20. As a result, the communication unit 50 can communicate with the external device 2 based on the set IP address "0.0.0.0".

[0065] Additionally, as will be discussed later, although the IP address setting value "0.0.0.0" is incorrect, it will be described as the correct value here.

[0066] Furthermore, for example, the control unit 10 traces the layers related to the printing speed setting in order from the upper layer to the lower layer based on the second setting information and referring to the storage unit 20.

[0067] Specifically, the control unit 10 refers to the storage unit 20 and traces back, in order from the upper layer to the lower layer, the setting item "Setting" related to setting, the setting item "Print" related to printing, the setting item "Speed" related to printing speed, and the layer related to the setting of printing speed.

[0068] Furthermore, the control unit 10 can read "Level 20" from the storage unit 20, which is the setting value corresponding to these hierarchical setting items.

[0069] The control unit 10 can set "Level 20" for the head 30 and the roller 40 as the printing speed value read from the storage unit 20. As a result, the head 30 and the roller 40 can print on the recording paper according to the set printing speed value "Level 20".

[0070] In this way, the control unit 10 can determine and perform multiple settings on the multiple settings information contained in the general setting command.

[0071] Furthermore, as will be explained later, although "Level20" as the setting value for printing speed is incorrect, it will be described as the correct value here.

[0072] B. Second Instruction

[0073] The second instruction is a response information request instruction, which requests response information described later. When the control unit 10 receives the response information request instruction through the communication unit 50, it determines whether there is an error in the overall setting instruction, and sends response information if an error is determined to exist.

[0074] The structure of a response request instruction can be represented, for example, as "ESC+B". "ESC" indicates an instruction containing a series of subsequent information, and "B" indicates an instruction requesting a response.

[0075] When the control unit 10 receives a response information request instruction from the communication unit 50, it determines that "ESC" in the response information request instruction is an instruction containing a series of information that will follow, and determines that "B" is an instruction requesting response information.

[0076] Furthermore, the control unit 10 determines whether there is an error in the overall setting command, and sends a response message if an error is determined to exist.

[0077] C. Third Instruction

[0078] The third instruction is a setting mode conversion instruction requesting a switch to the setting mode. When the control unit 10 receives the setting mode conversion instruction via the communication unit 50, it switches from the normal mode to the setting mode. The normal mode is a mode in which settings based on the general setting instruction are disabled, while the setting mode is a mode in which settings can be made via the general setting instruction.

[0079] The structure of a setting mode switching command can be represented as "ESC+C+1". "ESC" indicates a command containing a series of consecutive information, "C" indicates a command to switch modes, and "1" indicates a request to switch from normal mode to setting mode.

[0080] When the control unit 10 receives a setting mode switching command from the communication unit 50, it determines that "ESC" in the setting mode switching command is a command containing a series of subsequent information, "C" is a command to switch modes, and "1" is a request to switch from the normal mode to the setting mode. Then, the control unit 10 switches from the normal mode to the setting mode.

[0081] In this manner, when the control unit 10 receives a setting mode conversion command via the communication unit 50, it switches to the setting mode and receives a summary setting command, thereby enabling settings based on the setting information. However, in the setting mode, the control unit 10 prohibits the printing of print data. Even if the control unit 10 receives print data via the communication unit 50, it will discard the data and will not perform printing.

[0082] In addition, a normal mode conversion command is also prepared to request a switch from setting mode to normal mode. The structure of the normal mode conversion command can be represented, for example, as "ESC+C+0". The explanation will focus on the differences from the setting mode conversion command. The final "0" in the normal mode conversion command indicates a switch from setting mode to normal mode. When the control unit 10 receives a normal mode conversion request command, it determines that "0" is a request to switch from setting mode to normal mode, and thus switches from setting mode to normal mode.

[0083] In normal mode, even if the control unit 10 receives a general setting command through the communication unit 50, it will discard the command and will not perform any settings. On the other hand, when the control unit 10 receives printing data through the communication unit 50, it will perform printing.

[0084] 1-3. Control method of the media processing apparatus according to the first embodiment

[0085] In reference Figure 3 Simultaneously, the control method for the media processing device 1 will be described. The control unit 10 is configured as a control unit in normal mode. As described above, in normal mode, even if the control unit 10 receives a general setting command through the communication unit 50, it will discard the command and will not perform any setting.

[0086] When the control unit 10 receives a setting mode conversion command as a third command via the communication unit 50, it switches from the normal mode to the setting mode (S100). The control unit 10 receives a summary setting command, thereby enabling it to perform settings based on setting information.

[0087] Alternatively, the control unit 10 can be switched between normal mode and setting mode by user operation of any combination of panel switches or sensors, power switches, etc. (not shown) of the media processing device 1, either together with a third instruction or without a third instruction.

[0088] The control unit 10 receives a general setting instruction (S101) as the first instruction via the communication unit 50.

[0089] When the control unit 10 receives a response information request instruction as a second instruction through the communication unit 50 (S102), it determines whether there is an error in the general setting instruction (S103), and if an error is determined to exist (S103: yes), it sends a response information (S104).

[0090] In addition, if the general setting command contains multiple setting information and the control unit 10 determines that at least one of the setting information contains an error, a response message is sent.

[0091] On the other hand, if the control unit 10 determines that there is no error (S103: No), it will not send a response message.

[0092] In this case, the control unit 10, based on the multiple setting information included in the overall setting command, refers to the storage unit 20 and stores each setting value in the storage unit 20 in a manner corresponding to the respective hierarchical setting items. Then, the control unit 10 reads the setting value corresponding to the setting item from the storage unit 20 and performs the setting.

[0093] In addition, when the control unit 10 receives the overall setting instruction, it can also pre-determine whether there is an error in the overall setting instruction before receiving the response information request instruction.

[0094] If the control unit 10 determines in advance that there is an error in the overall setting command, it can immediately send a response information when it receives a response information request command.

[0095] 1-4. Response Information

[0096] The response information sent by the control unit 10 when it determines that there is an error in the general setting command is explained in detail.

[0097] The response information includes first information and second information. The first information includes information related to the setting items in the overall setting instruction that the control unit 10 determined to have an error. Furthermore, the second information includes information related to the error.

[0098] Furthermore, the first information may also include information related to the setting values ​​of the summary setting command that the control unit 10 determines to be erroneous. Moreover, the first information may also include information displaying the error reason as a string that can be determined by the user.

[0099] The response information is recorded in JSON format and is structured from the higher level down to the lower level, including "object", "key", and "value". However, depending on the structure of the response information, there may be cases where "object" exists but "key" is not.

[0100] Figure 4 This diagram is a hierarchical representation of the response information, listed in JSON format, from No. 1 to No. 5. In these examples, "object" is named "ValueError," and "key" is named in multiple levels from the top to the bottom, such as "KeyName1," "KeyName2," "KeyName3," "KeyName4," "SetValue," and "Details." "Value" is named "ErrorCode."

[0101] Additionally, for the received summary setting command, "ValueError" indicates that there is an error in the setting value; "KeyName1", "KeyName2", "KeyName3", and "KeyName4" refer to the received setting items as "keys"; "SetValue" refers to the received setting value; "Details" refers to the error reason displayed as a string that the user can also determine; and "ErrorCode" refers to the error code.

[0102] Specifically, the first information in the response message is included Figure 4 The "key" shown. Furthermore, the "KeyName1", "KeyName2", "KeyName3", and "KeyName4" contained in the "key" correspond to the hierarchical setting items contained in the setting information of the received summary setting command. Additionally, the "key" may also contain a "SetValue" corresponding to the setting value contained in the setting information of the received summary setting command. Furthermore, in addition to the external device 2, the "key" may also contain "Details" displayed as an error reason in a string that can be determined by the user. The "Details" are generated based on the error determined by the control unit 10.

[0103] "ErrorCode" is an error code indicating the cause of the error, and is generated based on the error determined by the control unit 10. "ErrorCode" is second information related to the error determined by the control unit 10, and is error information specific to a set value. Alternatively, "Details" can be included in the second information. Furthermore, either "ErrorCode" or "Details" can be set as the second information.

[0104] Figures 5-9 This example illustrates the specific response information sent via the communication unit 50 when the control unit 10 determines that an error exists in the overall setting command. Additionally, Figures 5-9 response information and Figure 4 Correspondingly, it is described in JSON format, which includes the first information and the second information.

[0105] Figure 4 Examples of "No.1" in the text and Figure 5 Correspondingly, the example of "No.2" is the same as Figure 6 Correspondingly, the example of "No.3" is the same as Figure 7 Correspondingly, the example of "No.4" is the same as Figure 8 Correspondingly, the example of "No.5" is... Figure 9 Correspondingly.

[0106] Figure 5 Reference Figure 2 An example of the response information corresponding to the first setting information contained in the above-mentioned summary setting command is shown.

[0107] The "Setting", "TcpIpCfg", "IpV4", and "Ip" included in the first setting information, as setting items, correspond to "KeyName1", "KeyName2", "KeyName3", and "KeyName4" respectively in the response information. The "0.0.0.0" included in the first setting information, as the setting value corresponding to the setting item, corresponds to "SetValue" as a "key" in the response information.

[0108] When the control unit 10 receives the summary setting command, it determines that "Setting", "TcpIpCfg", "IpV4", and "Ip" included in the first setting information are setting items related to communication that include communication items. In addition, the control unit 10 determines that "0.0.0.0" is an IP address value set in the media processing device 1 and is a communication item value corresponding to the communication item.

[0109] On the other hand, the storage unit 20 stores values ​​used to determine if an error exists in the setting information. For example, the storage unit 20 stores a range of communication item values ​​corresponding to the communication items involved in the communication. Specifically, the storage unit 20 stores a range of IP address values ​​corresponding to "Ip" representing an IP address, for example, from "0.0.0.1" to "255.255.255.255". The control unit 10 compares the received IP address value "0.0.0.0" with the range of IP address values ​​read from the storage unit 20. The control unit 10 can determine that "0.0.0.0" is outside the range from "0.0.0.1" to "255.255.255.255" and is therefore an incorrect value, thus determining that an error exists.

[0110] When the control unit 10 receives a response information request instruction, it determines whether there is an error in the received general setting instruction. If an error is determined to exist, the control unit 10 sends a response message through the communication unit 50. In this example, the control unit 10 determines that the received IP address value "0.0.0.0" is incorrect.

[0111] The control unit 10 generates and sends response information in the following manner: "ValueError" is included as "object", "Setting" is included as "KeyName1", "TcpIpCfg" is included as "KeyName2", "IpV4" is included as "KeyName3", "Ip" is included as "KeyName4", "0.0.0.0" is included as "SetValue", "OutOfRange" is included as "Details", and "100" is included as "ErrorCode".

[0112] In this way, the information from "Setting" to "Ip" contained in "key" is included in the first information and corresponds to the setting items that the control unit 10 determines to have incorrect setting information.

[0113] Furthermore, the "OutOfRange" information contained in the "key" can also be included in the first information. "OutOfRange" is displayed as a string that the user can also determine, thereby enabling the determination of cases where "0.0.0.0" is outside the range.

[0114] Furthermore, the information "100" contained in "value" is included in the second information related to the error determined by the control unit 10. "100" is an error code indicating that "0.0.0.0" is outside the range of IP address values ​​involved in the communication, and the external device 2 can process it.

[0115] Alternatively, it can be configured to include "OutOfRange" in the second information. Furthermore, either "100" or "OutOfRange" can be set as the second information.

[0116] Alternatively, the response information may include, as first information, at least one of the following: "Ip" corresponding to the IP address of the communication item; as second information, an error message "100" corresponding to the communication item value ("0.0.0.0"); and "OutOfRange". The external device 2 receiving the response information can determine that the error is related to the IP address based on "Ip", and can determine the primary cause of the error as the IP address value being outside the range based on "100" or "OutOfRange".

[0117] The external device 2 that receives the response information can determine whether there is an error in the overall setting instruction and what the main cause of the error is.

[0118] exist Figure 5In the example, the user can also determine that "0.0.0.0" included in the general setting command is outside the range based on "OutOfRange". Furthermore, external device 2 can determine that "0.0.0.0" is outside the range of IP address values ​​involved in the communication based on "100". External device 2 can resolve the main cause of the error as an IP address value being outside the range based on the setting value "100" which represents an error code. Then, external device 2 can generate a general setting command containing the correct IP address value and send it to media processing device 1 to set the IP address value.

[0119] Alternatively, if the control unit 10 determines that there is no error in the overall setting command, it may send "Null" as a response. Or, the control unit 10 may send "Details" and "ErrorCode" as a response. The external device 2, upon receiving "Null," can determine that there is no error in the overall setting command.

[0120] exist Figure 6 The reference is shown in the middle. Figure 2 An example of the response information corresponding to the second setting information included in the above-mentioned general setting instruction.

[0121] The "Setting", "Print", and "Speed" items included in the second setting information are respectively used as "keys" in the response information, corresponding to "KeyName1", "KeyName2", and "KeyName3". The "Level20" setting value corresponding to the setting item included in the second setting information is also used as a "key" in the response information, corresponding to "SetValue".

[0122] On the other hand, the storage unit 20 stores a range of setting values, namely printing speed values, corresponding to "Speed," which represents the printing speed as a setting item. Specifically, the range of printing speed values ​​stored in the storage unit 20 is, for example, from "Level 5" to "Level 15."

[0123] The control unit 10 compares the received printing speed value, "Level 20", with the range of printing speed values ​​read from the storage unit 20. The control unit 10 can determine that "Level 20" is outside the range from "Level 5" to "Level 15" and is therefore an incorrect value, thus determining that it is erroneous.

[0124] In this example, the control unit 10 determines that the received "Level20" is incorrect, and generates and sends a response message in the following manner: "ValueError" is included as "object", "Setting" is included as "KeyName1", "Print" is included as "KeyName2", "Speed" is included as "KeyName3", "Level20" is included as "SetValue", "OutOfRange" is included as "Details", and "000" is included as "ErrorCode".

[0125] In this way, the information from “Setting” to “Speed” contained in “key” is included in the first information and corresponds to the setting items that the control unit 10 determines to have incorrect setting information.

[0126] Furthermore, the "OutOfRange" information contained in the "key" can also be included in the first information. "OutOfRange" is displayed as a string that the user can also determine, thereby enabling the determination of cases where "Level20" is outside the range.

[0127] Furthermore, the "000" information contained in the "value" is included in the second information related to the error determined by the control unit 10. "000" is an error code indicating that "Level 20" is outside the range of printing speed values ​​related to printing speed, and the external device 2 can process it.

[0128] Alternatively, it can be configured to include "OutOfRange" in the second information. Furthermore, either "000" or "OutOfRange" can be set as the second information.

[0129] Alternatively, the response information may include, as a first piece of information, at least one of "Speed" corresponding to the printing speed specified in the setting, and as a second piece of information, an error message "000" corresponding to the printing speed value (Level 20), or "OutOfRange". The external device 2 receiving the response information can determine, based on "Speed", that the error is related to the printing speed, and can determine, based on "000" or "OutOfRange", that the primary cause of the error is that the printing speed value is outside the range.

[0130] The external device 2 that receives the response information can determine whether there is an error in the overall setting instruction and what the main cause of the error is.

[0131] exist Figure 6 In the example, the user can also determine that "Level 20" included in the general setting instruction is outside the range based on "OutOfRange". Furthermore, external device 2 can determine that "Level 20" is outside the range of printing speed values ​​related to printing speed based on "000". External device 2 can analyze the main cause of the error as the printing speed value being outside the range based on the setting value "000" which represents an error code. Then, external device 2 can generate a general setting instruction containing the correct printing speed value and send it to media processing device 1 to set the printing speed value.

[0132] In addition, the control unit 10 can refer to Figure 2 If it is determined that there is an error in the first setting information or the second setting information contained in the above-mentioned general setting instruction, a response information containing the respective first and second information is generated and sent.

[0133] Specifically, the control unit 10 generates "ValueError" as a common "object". Next, the control unit 10 generates and adds the first and second information as the first information in the form of "Setting" as "KeyName1" included in the "key", "TcpIpCfg" as "KeyName2", "IpV4" as "KeyName3", "Ip" as "KeyName4", "0.0.0.0" as "SetValue", "OutOfRange" as "Details", and "100" as "ErrorCode" included in the "value".

[0134] Next, the control unit 10 can generate and add "Setting" as "KeyName1" included in "key", "Print" as "KeyName2", "Speed" as "KeyName3", "Level20" as "SetValue", "OutOfRange" as "Details", and "000" as "ErrorCode" included in "value", and send it as a response message.

[0135] In this way, the external device 2 that receives a response message can determine where the error exists and what the main cause of the error is based on the first and second information contained in the response message, even when there are multiple setting messages contained in the overall setting command.

[0136] Although Figure 7 The related general setting command is not shown, but an example of a response message sent by the control unit 10 when it determines that there is an error in the setting information related to the network password among the multiple setting information included in the general setting command.

[0137] The settings items “Setting,” “NwCSAuth,” and “Password,” which are part of the network password settings included in the overall setting command, are respectively assigned as “keys” to “KeyName1,” “KeyName2,” and “KeyName3” in the response information. The password value “XXXXX,” which is part of the network password settings and corresponds to the settings item (password), is assigned as a “key” to “SetValue” in the response information.

[0138] On the other hand, the storage unit 20 stores "YYYYY", which is the password value corresponding to "Password". "Password" is a setting related to the network password, and "YYYYY" is the setting value corresponding to the password "Password". The control unit 10 compares the received password value "XXXXX" with the password value "YYYYY" read from the storage unit 20. Since "XXXXX" and "YYYYY" are different, the control unit 10 can determine that the password value is incorrect, and thus determine that it is wrong.

[0139] In this example, the control unit 10 determines that the received “XXXXX” is incorrect, and generates and sends a response message in the following manner: “ValueError” is included as “object”, “Setting” is included as “KeyName1”, “NwCSAuth” is included as “KeyName2”, “Password” is included as “KeyName3”, “XXXXX” is included as “SetValue”, “WrongPassword” is included as “Details”, and “198” is included as “ErrorCode”.

[0140] In this way, the information from "Setting" to "Password" contained in the "key" is included in the first information and corresponds to the setting item that the control unit 10 determines has incorrect setting information. Furthermore, the "WrongPassword" information contained in the "key" can also be included in the first information. In addition to the external device 2, the "WrongPassword" can also be displayed using a string that the user can also determine, and "XXXXX" can determine if the password value involved in the password is incorrect.

[0141] Furthermore, the information "198" contained in "value" is included in the second information related to the error determined by the control unit 10. "198" is an error code indicating that the password value involved in the password is incorrect, and the external device 2 can process it.

[0142] Alternatively, it can be configured to include "WrongPassword" in the second information. Furthermore, either "198" or "WrongPassword" can be set as the second information.

[0143] Alternatively, the response information may include at least one of the following as the first piece of information: "Password", "198" (corresponding to the password value), and "WrongPassword".

[0144] The external device 2 that receives the response information can determine whether there is an error in the overall setting instruction and what the main cause of the error is.

[0145] exist Figure 7 In the example, external device 2 can determine that the object of the error is related to the password based on "Password", and can determine the main cause of the error as an incorrect password value based on "198" or "WrongPassword".

[0146] External device 2 can generate a general setting instruction containing "YYYYY" as the correct password value and send it to media processing device 1 to set the password value.

[0147] In this way, the external device 2 that receives the response information can determine where the error exists and what the cause of the error is, even when there are multiple setting information contained in the overall setting command, based on the first and second information contained in the response information.

[0148] Although Figure 8While the related general setting command is not shown, an example of a response message sent by the control unit 10 after determining that an error exists in the network password setting information among the multiple setting information included in the general setting command. Specifically, Figure 8 An example of the response information is shown when the overall setting command received by the control unit 10 does not include setting information related to the network password.

[0149] If the control unit 10 does not include the setting information related to the network password in the received general setting command, it can determine that there is an error related to the network password.

[0150] In this example, the control unit 10 determines that the error does not include the setting information related to the network password, and generates and sends a response message with "ValueError" as the "object," "NoPassword" as the "Details," and "197" as the "ErrorCode." In this case, since the setting information related to the network password is not included in the overall setting command, the response message does not contain a "key" or similar information corresponding to the setting information.

[0151] Therefore, the control unit 10 generates the information of "ValueError" and "NoPassword" as the first information, and generates the information of "197" contained in "value" as the second information related to the error, and sends it.

[0152] The "NoPassword" message is displayed using a string that the user can also determine, thus enabling the determination of cases where no password-related settings are available. Furthermore, the "197" message is an error code indicating that no password-related settings are available, and this can be processed by the external device 2.

[0153] Alternatively, it can be configured to include "NoPassword" in the second information. Furthermore, either "197" or "NoPassword" can be set as the second information.

[0154] Alternatively, the response information may include at least "NoPassword" as the first piece of information, and at least one of "197" and "NoPassword" as the second piece of information.

[0155] The external device 2 that receives the response information can determine whether there is an error in the overall setting instruction and what the main cause of the error is.

[0156] exist Figure 8 In the example, external device 2 can determine the main cause of the error as the lack of network password settings based on "197" or "NoPassword".

[0157] External device 2 can generate a summary setting command containing setting information related to the correct network password and send it to media processing device 1 to set up the network.

[0158] In this way, the external device 2 that receives the response information can determine where the error exists and what the main cause of the error is, even when there are multiple setting information contained in the overall setting command, based on the first and second information contained in the response information.

[0159] Although Figure 9 The related summary setting command is not shown, but an example of a response message sent by the control unit 10 when it determines that there is an error in the format of the summary setting command containing multiple setting information is present.

[0160] The storage unit 20 stores the format of the summary setting command. The control unit 10 processes the received summary setting command according to the format of the summary setting command read from the storage unit 20.

[0161] The control unit 10 can determine that the received general setting command is incorrect if it does not conform to the format read from the storage unit 20.

[0162] In this example, the control unit 10 determines that there is an error in the format of the general setting instruction, and generates and sends response information in the manner of generating "FormatError" as "object" and "ErrorCode" as "ErrorCode". Additionally, in Figure 4 In this context, the quotation marks in "ErrorCode" are displayed as blank. Additionally, the quotation marks can also be "Null".

[0163] In this case, because the error is in the format of the overall setting instruction, the response information does not contain a "key" or similar information corresponding to the setting information.

[0164] Therefore, the control unit 10 generates the "FormatError" information as the first information and generates the information containing "" in "value" as the second information related to the error, and sends it.

[0165] The "FormatError" message is displayed using a string that the user can also determine, thus enabling the identification of errors in the format of the general setting instruction. Furthermore, the "" message indicates an error code indicating a formatting error in the general setting instruction, which can be processed by external device 2.

[0166] Alternatively, you can configure it to include "FormatError" in the second message. Furthermore, you can set either "" or "FormatError" as the second message.

[0167] Alternatively, the response information may include at least one of "FormatError" as the first piece of information, and at least one of "" and "FormatError" as the second piece of information.

[0168] The external device 2 that receives the response information can determine whether there is an error in the overall setting instruction and what the main cause of the error is.

[0169] exist Figure 9 In the example, external device 2 can determine the main cause of the error as an error in the format of the general setting instruction based on "" or "FormatError".

[0170] External device 2 generates a summary setting command in the correct format and sends it to media processing device 1, thereby enabling the setting.

[0171] In this way, the external device 2 that receives the response information can determine where the error is and what the main cause of the error is, even when there are multiple setting information contained in the overall setting command, based on the first and second information contained in the response information.

[0172] According to the media processing apparatus 1 and the control method of the media processing apparatus 1 described above in the first embodiment, when the control unit 10 receives a response information request instruction through the communication unit 50, it determines whether there is an error in the received summary setting instruction, and if an error is determined, it sends a response information through the communication unit 50.

[0173] The general setting command contains multiple setting information items, which include setting items related to the setting of the media processing device 1 and setting values ​​corresponding to the setting items. When the control unit 10 determines that there is an error in the setting information, the response information includes the setting items as the first information and the error information regarding the setting item values ​​as the second information.

[0174] Upon receiving the response information, the external device 2, based on the first and second information contained in the response information, can determine where the error in the setting information exists and what the main cause of the error is, even when there are multiple setting information contained in the overall setting command. Furthermore, the external device 2 can correct the setting information of the overall setting command to the correct value and send it to the media processing device 1 to perform the setting.

[0175] Although these embodiments have been described in detail above with reference to the accompanying drawings, the specific structure is not limited to these embodiments. As long as it does not depart from the spirit of this disclosure, changes, replacements, deletions, etc., can be made.

[0176] For example, although a thermal printhead has been used as an example for the head of media processing device 1, the printing method is not limited. An inkjet printhead can also be used. In this case, the recording paper becomes plain paper. The media can also be checks, forms, etc.

Claims

1. A media processing apparatus, comprising: The communications unit is capable of communicating with external devices; The control unit, upon receiving a first instruction containing multiple setting information via the communication unit, determines whether the setting information is incorrect. The setting information includes setting items related to the setting of the media processing device, and setting values ​​corresponding to the setting items. When the control unit determines that an error exists in the setting information, it sends a response message through the communication unit when it receives a second instruction through the communication unit. The response message includes first information related to the setting item for which the error is determined to exist, and second information related to the error.

2. The media processing apparatus as described in claim 1, wherein, The first and second information in the response information are information recorded in JSON format.

3. The media processing apparatus as described in claim 1, wherein, When the control unit receives a third instruction through the communication unit, it switches to the setting mode and receives the first instruction, thereby enabling it to perform settings based on the setting information.

4. The media processing apparatus as claimed in claim 1, wherein, In the setting information of the first instruction, a password is included as a setting item, and a password value corresponding to the password is included as a setting value. The response information includes the password as the first information and error information about the password value as the second information.

5. The media processing apparatus as claimed in claim 1, wherein, The setting information in the first instruction includes printing speed as a setting item and a printing speed value corresponding to the printing speed as a setting value. The response information includes the printing speed as the first information and error information regarding the printing speed value as the second information.

6. The media processing apparatus as claimed in claim 1, wherein, In the setting information of the first instruction, communication items are included as setting items, and communication item values ​​corresponding to the communication items are included as setting values. The response information includes the communication item as the first information and error information regarding the value of the communication item as the second information.

7. A control method for a media processing apparatus, comprising a communication unit capable of communicating with an external device, wherein, When a first instruction containing multiple setting information is received via the communication unit, errors in the setting information are determined, wherein... The setting information includes setting items related to the setting of the media processing device, and setting values ​​corresponding to the setting items. If it is determined that an error exists in the setting information, when a second instruction is received through the communication unit, a response message is sent through the communication unit, wherein the response message includes first information related to the setting item for which the error is determined to exist, and second information related to the error.

Citation Information

Patent Citations

  • Printer and control method of the same

    JP2016128215A

  • Failure prediction device, failure prediction method and failure prediction program

    JP2005309733A