Communication device, control method thereof, and program

JP2023035838A5Active Publication Date: 2025-06-27CANON KK
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
JP2022101446
Authority / Receiving Office
JP · JP
Patent Type
Applications
Current Assignee / Owner
Priority Date
2021-08-31
Filing Date
2022-06-23
Publication Date
2025-06-27
Estimated Expiration
2042-06-23

AI Technical Summary

Technical Problem

Existing communication devices face challenges in conveniently connecting to access points while ensuring security and efficient network setup operations.

Method used

A communication device that supports multiple protocols, including Wi-Fi Easy Connect (WEC) and Device Provisioning Protocol (DPP), allowing for secure and convenient network setup by transmitting connection information and managing states to ensure seamless communication with access points.

Benefits of technology

Enables highly convenient and secure network setting operations by ensuring secure communication and efficient network setup across different protocols.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 00000000_0000_ABST
    Figure 00000000_0000_ABST
Patent Text Reader

Abstract

To improve the convenience of a function for connecting a communication device and an access point.SOLUTION: A communication device includes: first control means for executing first control so as to acquire connection information for the communication device to connect to an access point from an information processing device via communication with the information processing device according to a first protocol; second control means for executing second control so as to invalidate a second state in which communication with the information processing device can be executed according to a second protocol different from the first protocol, based on establishment of connection between the communication device and the access point using the connection information acquired by the first control means; and third control means for executing third control so as to continue, without invalidating, the second state in which communication with the information processing device can be executed according to the second protocol, based on no establishment of connection between the communication device and the access point using the connection information acquired by the first control means.SELECTED DRAWING: Figure 7
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to a communication device, a control method thereof, and a program.

Background Art

[0002] A technique is known in which an information processing device such as a PC (personal computer) transmits information regarding an access point to a communication device such as a printer and connects the communication device and the external device.

Prior Art Documents

Patent Documents

[0003]

Patent Document 1

Summary of the Invention

Problems to be Solved by the Invention

[0004] By the way, as the function of transmitting connection information for connecting to an access point to a communication device and connecting the communication device and the access point becomes widespread, it is required to improve the convenience of the function.

[0005] The present invention has been made in view of the above problems, and an object thereof is to improve the convenience of the function of connecting a communication device and an access point.

Means for Solving the Problems

[0006] To solve the problems described above, the communication device according to the present disclosure is a communication device that communicates with an information processing device, and is characterized by comprising: a first control means that executes a first control to obtain connection information for the communication device to connect with an access point from the information processing device via communication with the information processing device using a first protocol; a second control means that executes a second control to disable a second state in which communication with the information processing device using a second protocol different from the first protocol is possible, based on the fact that a connection between the communication device and the access point has been established using the connection information obtained by the first control means; and a third control means that executes a third control to continue the second state in which communication with the information processing device using the second protocol is possible without disabling it, based on the fact that a connection between the communication device and the access point has not been established using the connection information obtained by the first control means. [Effects of the Invention]

[0007] According to the present invention, it becomes possible to perform secure and convenient network configuration operations. [Brief explanation of the drawing]

[0008] [Figure 1] This diagram shows the configuration of an information processing device, a communication device, and an access point. [Figure 2] This flowchart shows the processing flow executed by the information processing device during network setup. [Figure 3] This is an example of a screen for scanning QR codes (registered trademark) displayed in the settings app. [Figure 4] This is a sequence diagram showing the processes performed by the information processing device and the communication device. [Figure 5] This is an example of the WEC start screen. [Figure 6] This is a sequence diagram showing the processes performed by the information processing device and the communication device. [Figure 7]This flowchart shows the flow of the first setup process performed by the communication device during the network setup process. [Figure 8] This flowchart shows the flow of the second setup process performed by the communication device during the network setup process. [Figure 9] This is a flowchart illustrating the process for initiating DPP waiting mode. [Figure 10] This is a flowchart illustrating the execution process of WEC. [Modes for carrying out the invention]

[0009] Preferred embodiments of the present invention will be described below with reference to the drawings. However, it should be understood that the present invention also includes modifications and improvements made to the embodiments described below, without departing from the spirit of the invention, based on the ordinary knowledge of those skilled in the art.

[0010] (First Embodiment) This section describes the information processing device and communication device included in the communication system of this embodiment. While a smartphone is used as an example of the information processing device in this embodiment, it is not limited to this. For example, various devices such as mobile terminals, PCs (personal computers), tablet terminals, PDAs (personal digital assistants), and digital cameras can be used as information processing devices. Similarly, while a printer is used as an example of the communication device in this embodiment, it is not limited to this; various devices capable of wireless communication with the information processing device can be used. For example, inkjet printers, full-color laser beam printers, monochrome printers, etc., can be used. Furthermore, it can be applied not only to printers but also to copiers, facsimile machines, mobile terminals, smartphones, notebook PCs, tablet terminals, PDAs, digital cameras, music playback devices, televisions, smart speakers, etc. It can also be applied to multifunction devices equipped with multiple functions such as copying, faxing, and printing.

[0011] Furthermore, in this embodiment, if the information processing device supports a function called Wi-Fi Easy Connect (hereinafter referred to as WEC) (registered trademark), it can perform that function. WEC is a function that performs network setup of other devices using the Device Provisioning Protocol (hereinafter referred to as DPP) established by the Wi-Fi Alliance. Specifically, network setup of other devices is the process of connecting other devices to access points that form a network. In WEC, communication takes place between a device operating in the role of "Configurator" (hereinafter referred to as the Configurator device) and a device operating in the role of "Enrollee" (hereinafter referred to as the Enrollee device). The Configurator device obtains Bootstrapping information from the Enrollee device. Bootstrapping information includes, for example, identification information of the Enrollee device (MAC address, etc.) and public key information used to perform secure communication with the Enrollee device. In this embodiment, Bootstrapping information is described as "WEC-related information." Other information may also be treated as WEC-related information. The Configurator device then performs wireless communication with the Enrollee device using the obtained Bootstrapping information. Specifically, for example, the Configurator device communicates with the Enrollee device using the public key included in the Bootstrapping information. Furthermore, it generates a shared key based on the information obtained from that communication and sends the encrypted information using that shared key to the Enrollee device. The information sent here is specifically, for example, connection information for connecting to an access point. The Enrollee device then establishes a wireless connection with the access point using the connection information received from the Configurator device. In this embodiment, the network setup process using WEC is described as operating as a Configurator device for information processing devices that support WEC, and as operating as an Enrollee device for communication devices that support WEC.

[0012] First, the configuration of the information processing apparatus of the present embodiment and the communication apparatus capable of communicating with the information processing apparatus of the present embodiment will be described with reference to the block diagram of FIG. 1. In the present embodiment, the following configuration will be described as an example, but the present embodiment is applicable to an apparatus capable of communicating with a communication apparatus, and is not particularly limited to the functions as shown in this figure.

[0013] The information processing apparatus 101 is the information processing apparatus of the present embodiment. The information processing apparatus 101 includes an input interface 102, a CPU 103, a ROM 104, a RAM 105, an external storage device 106, an output interface 107, a display unit 108, a communication unit 110, a short-range wireless communication unit 111, and the like. A computer of the information processing apparatus 101 is formed by the CPU 103, the ROM 104, the RAM 105, and the like.

[0014] The input interface 102 is an interface for receiving data input and operation instructions from a user when an operation unit such as a keyboard 109 is operated. Note that the operation unit may be a physical keyboard or physical buttons, or may be a soft keyboard or soft buttons displayed on the display unit 108. That is, the input interface 102 may receive an input from the user via the display unit 108.

[0015] The CPU 103 is a system control unit that controls the entire information processing apparatus 101.

[0016] The ROM 104 stores fixed data such as a control program executed by the CPU 103, a data table, and an embedded operating system (hereinafter referred to as OS) program. In the present embodiment, each control program stored in the ROM 104 performs software execution control such as scheduling, task switching, and interrupt processing under the management of the embedded OS stored in the ROM 104.

[0017] The RAM 105 is composed of an SRAM (Static Random Access Memory) or the like that requires a backup power supply. Since the data in the RAM 105 is retained by a primary battery for data backup (not shown), important data such as program control variables can be stored without being volatile. Also, a memory area for storing the setting information of the information processing device 101, the management data of the information processing device 101, etc. is also provided in the RAM 105. Further, the RAM 105 is also used as the main memory and the work memory of the CPU 103.

[0018] The external storage device 106 stores an application program (hereinafter referred to as the setting app) for executing the network setup of the communication device 151, a print information generation program for generating print information interpretable by the communication device 151, and the like. The setting app is an application program for setting the access point of the connection destination of the communication device 151 using a WEC or the like. Note that the setting app may have other functions in addition to the network setup function. For example, the setting app may have a function to cause the communication device 151 to execute printing, a function to scan the original document set in the communication device 151, a function to check the state of the communication device 151, and the like. The setting app is stored in the external storage device 106 by being installed from an external server via Internet communication through the communication unit 110, for example. Also, the external storage device 106 stores various programs such as an information transmission / reception control program for transmitting and receiving information with the communication device 151 connected via the communication unit 110, and various information used by these programs.

[0019] The output interface 107 is an interface that controls the display unit 108 to display data and notify the state of the information processing device 101.

[0020] The display unit 108 is composed of an LED (light emitting diode), an LCD (liquid crystal display), etc., and displays data and notifies the state of the information processing device 101.

[0021] The communication unit 110 is configured to connect to devices such as the communication device 151 and the access point 131 to perform data communication. For example, the communication unit 110 can connect to an access point (not shown) within the communication device 151. By connecting the communication unit 110 to the access point within the communication device 151, the information processing device 101 and the communication device 151 can communicate with each other. The communication unit 110 may communicate directly with the communication device 151 via wireless communication, or it may communicate via an external device located outside the information processing device 101 and the communication device 151. External devices include external access points (such as access point 131) located outside the information processing device 101 and the communication device 151, as well as devices other than access points that can relay communication. In this embodiment, the wireless communication method used by the communication unit 110 is assumed to be Wi-Fi (WirelessFidelity) (registered trademark), a communication standard compliant with the IEEE 802.11 series. The aforementioned WEC is performed by communication via the communication unit 110. Furthermore, the access point 131 can be, for example, a wireless LAN router or other device. In this embodiment, the method by which the information processing device 101 and the communication device 151 are directly connected without going through an external access point is called the direct connection method, and direct communication is communication via the direct connection. Also, the method by which the information processing device 101 and the communication device 151 are connected via an external access point is called the infrastructure connection method, and infrastructure communication is communication via the infrastructure connection.

[0022] The short-range wireless communication unit 111 is configured to wirelessly connect to devices such as the communication device 151 at short range and perform data communication, and communicates using a different communication method than the communication unit 110. The short-range wireless communication unit 111 can connect to, for example, the short-range wireless communication unit 157 within the communication device 151. Examples of communication methods include Near Field Communication (NFC), Bluetooth® Classic, Bluetooth Low Energy (BLE), and Wi-Fi Aware.

[0023] In this embodiment, the information processing device 101 executes WEC using its OS based on an instruction to execute network setup processing by the configuration application.

[0024] The communication device 151 is the communication device of this embodiment. The communication device 151 includes a ROM 152, RAM 153, CPU 154, print engine 155, communication unit 156, short-range wireless communication unit 157, etc. The computer of the communication device 151 is formed by the ROM 152, RAM 153, CPU 154, etc.

[0025] The communication unit 156 has an access point within the communication device 151 for connecting to devices such as the information processing device 101. This access point can be connected to the communication unit 110 of the information processing device 101. When the communication unit 156 activates this access point, the communication device 151 operates as an access point. The communication unit 156 may connect wirelessly to the information processing device 101 directly, or it may connect wirelessly via the access point 131. In this embodiment, the wireless communication method used by the communication unit 156 is a communication standard compliant with the IEEE 802.11 series. In the following description, Wi-Fi (WirelessFidelity) (registered trademark) refers to a communication standard compliant with the IEEE 802.11 series. If the communication device 151 supports WEC, the aforementioned WEC will be executed by communication via the communication unit 156. The communication unit 156 may have hardware that functions as an access point, or it may operate as an access point through software that enables it to function as an access point.

[0026] The communication device 151 of this embodiment can operate in infrastructure mode and P2P (Peer to Peer) mode as modes for performing communication using the communication unit 156.

[0027] Infrastructure mode is a configuration in which the communication device 151 communicates with other devices such as the information processing device 101 via external devices that form a network (for example, the access point 131). The connection with the external access point established by the communication device 151 operating in infrastructure mode is called an infrastructure connection (hereinafter referred to as an infrastructure connection). In this embodiment, in an infrastructure connection, the communication device 151 operates as a slave station, and the external access point operates as a master station. In this embodiment, the master station is a device that determines the communication channel used in the network to which the master station belongs, and the slave station is a device that does not determine the communication channel used in the network to which the slave station belongs, but uses the communication channel determined by the master station.

[0028] P2P mode is a configuration in which the communication device 151 communicates directly with other devices such as the information processing device 101 without going through external devices that form a network. In this embodiment, P2P mode includes AP mode in which the communication device 151 operates as an access point. The access point connection information (SSID and password) enabled within the communication device 151 in AP mode can be arbitrarily set by the user. P2P mode may also include, for example, a WFD mode for the communication device 151 to communicate using Wi-Fi Direct (WFD). Which of the multiple WFD-compatible devices will operate as the master station is determined according to a sequence such as Group Owner Negotiation. The master station may be determined without performing Group Owner Negotiation. A device that is WFD-compatible and also acts as the master station is specifically called the Group Owner. A direct connection with other devices established by the communication device 151 operating in P2P mode is called a direct connection. In this embodiment, in a direct connection, the communication device 151 operates as the master station, and the other devices operate as slave stations.

[0029] Furthermore, in this embodiment, the communication device 151 can operate in network setup mode, which is a mode for performing network setup of the communication device 151 (another device) by receiving a predetermined operation from the user. Network setup of another device refers to the process of connecting the other device to an access point that forms a network. Specifically, the information processing device 101 transmits access point connection information to the communication device 151 via a Wi-Fi connection between the communication device 151, which is operating in network setup mode, and the information processing device 101. The communication device 151 then connects to the access point by using the received access point connection information to connect to the access point, thereby connecting to the network formed by the access point. The communication method used for the network setup process is Wi-Fi communication, but is not limited to this. For example, network setup may be performed using a communication method other than Wi-Fi, such as BLE.

[0030] When the communication device 151 operates in network setup mode, it operates as a setup access point that is active during network setup mode by using the communication unit 156. This setup access point is different from the access point that is enabled in AP mode as described above. The SSID of this setup access point shall contain a predetermined string that can be recognized by the configuration application of the information processing device 101. Furthermore, this setup access point shall not require a password for connection. In addition, the communication device 151 operating in network setup mode shall use a predetermined communication protocol (setup communication protocol) for communication with the information processing device 101 connected to the setup access point. Specifically, the setup communication protocol is, for example, SNMP (Simple Network Management Protocol). After a predetermined time has elapsed since the communication device 151 started operating in network setup mode, it stops operating in network setup mode and disables the setup access point. This is because, as described above, the setup access point is an access point that does not require a password, and if it is enabled for a long time, the possibility of connection requests from inappropriate devices increases. The setup access point may be one that requires a password. In that case, the password used to connect to the setup access point should be a fixed (user-unchangeable) password that the settings application has known in advance.

[0031] Furthermore, in this embodiment, the communication device 151 can also operate in a mode to perform network setup using a communication protocol different from the setup communication protocol, upon receiving a predetermined operation from the user. In this embodiment, the communication protocol different from the setup communication protocol is assumed to be the DPP described above, and this mode is referred to as the DPP waiting mode. When the communication device 151 is operating in the DPP waiting mode and receives a DPP network setup request from the information processing device 101, it performs DPP network setup as described later. Therefore, the DPP waiting mode is, in other words, a mode that waits for a DPP network setup request. The DPP waiting mode will be described later in Figure 9.

[0032] In this embodiment, it is possible to operate the network setup mode and the DPP waiting mode simultaneously (in parallel). Simultaneous operation refers to the simultaneous operation of the network setup mode and the DPP waiting mode. Furthermore, in this embodiment, the network interfaces used for communication in network setup mode and communication in DPP waiting mode are different interfaces. The interface used for communication in network setup mode is a direct communication interface, while the interface used for communication in DPP waiting mode is an infrastructure communication interface.

[0033] In this embodiment, the communication device 151 is equipped with only one wireless chip for Wi-Fi communication, and the operation of both the direct communication interface and the infrastructure communication interface is realized by this single wireless chip. In other words, the wireless chip for Wi-Fi communication switches between a network setup mode and a DPP standby mode in a time-division manner. When the interface being used is switched, the channel used for communication on the interface being used is also switched. However, the communication device 151 may be equipped with multiple wireless chips. In this case, the operation of the direct communication interface and the infrastructure communication interface may be realized by separate wireless chips (for example, a first wireless chip and a second wireless chip). Furthermore, in this case, the first wireless chip may operate in network setup mode and the second wireless chip may operate in DPP standby mode in parallel.

[0034] The short-range wireless communication unit 157 is configured to wirelessly connect to devices such as the information processing device 101 at short range, and can, for example, connect to the short-range wireless communication unit 111 within the information processing device 101. Examples of communication methods include NFC, Bluetooth Classic, BLE, and Wi-Fi Aware.

[0035] RAM 153 is composed of SRAM and other components that require a backup power supply. Since RAM 153's data is maintained by a primary battery (not shown) for data backup, important data such as program control variables can be stored without being lost. RAM 153 also includes a memory area for storing setting information and management data for the communication device 151. Furthermore, RAM 153 is used as the main memory and work memory for the CPU 154, storing a receive buffer for temporarily saving print information received from the information processing device 101, and various other information.

[0036] ROM152 stores fixed data such as control programs, data tables, and OS programs executed by the CPU154. In this embodiment, each control program stored in ROM152 performs software execution control such as scheduling, task switching, and interrupt handling under the management of the embedded OS also stored in ROM152.

[0037] The CPU 154 is the system control unit and controls the entire communication device 151.

[0038] The print engine 155 forms an image on a recording medium such as paper by adding a recording agent such as ink to the recording medium based on the information stored in the RAM 153 and the print job received from the information processing device 101, etc., and outputs the print result. Generally, the amount of data for print jobs transmitted from the information processing device 101, etc. is large, so it is necessary to use a communication method that enables high-speed communication for the communication of print jobs. For this reason, the communication device 151 receives print jobs via the communication unit 156, which is capable of high-speed communication than the short-range wireless communication unit 157.

[0039] Furthermore, the communication device 151 may be equipped with an external HDD or SD card as an optional memory device, and the information stored in the communication device 151 may be stored in such memory.

[0040] Figure 2 is a flowchart showing the processing flow executed by the information processing device 101 in the network setup process of this embodiment. The flowchart shown in Figure 2 is realized, for example, when the CPU 103 reads a setting application stored in the ROM 104 or external storage device 106 into the RAM 105 and executes it. The flowchart shown in Figure 2 is also started when a predetermined operation for network setup (hereinafter referred to as the setting operation) is performed on the screen displayed by the setting application.

[0041] First, in S200, the CPU 103 acquires information about the access point (hereinafter referred to as "connected AP") to which the information processing device 101 was wirelessly connected via Wi-Fi at least when the configuration operation was performed. In this embodiment, since the information processing device 101 has not switched the connected access point after the configuration operation, this access point is also the access point to which the information processing device 101 is currently connected in S200. This information includes information for connecting to the access point to which the information processing device 101 is wirelessly connected via Wi-Fi (SSID, information indicating the encryption method, etc.). The acquired information is stored in a predetermined storage area of ​​the memory of the information processing device 101. If the information processing device 101 is not connected to any access point via Wi-Fi when the configuration operation is performed, this process is omitted.

[0042] Next, in S201, the CPU 103 instructs the OS of the information processing device 101 to search for access points around the information processing device 101, and the search results are obtained by the setting application.

[0043] Next, in S202, the CPU 103 determines whether or not there is an access point in the search results obtained in S201 that is enabled by the communication device 151 operating in network setup mode. As described above, in this embodiment, the SSID of an access point that is enabled by the communication device 151 operating in network setup mode contains a predetermined string that is recognized in advance by the configuration application. Specifically, in this determination, the CPU 103 determines whether or not there is an access point in the search results obtained in S201 that has an SSID containing the predetermined string. If the result is YES, the CPU 103 proceeds to S203, and if it is NO, it proceeds to S219.

[0044] In S203, the CPU 103 attempts to establish a Wi-Fi connection between the information processing device 101 and an access point that has a communication device 151 operating in network setup mode, which was included in the search results. This Wi-Fi connection corresponds to the Wi-Fi connection between the communication device 151 operating in network setup mode and the information processing device 101.

[0045] Next, in S204, the CPU 103 determines whether the Wi-Fi connection was successfully established by S203. If the CPU 103 determines it is YES, it proceeds to S205; otherwise, it proceeds to S219.

[0046] In S205, the CPU 103 obtains capability information for the information processing device 101 from the OS. In this embodiment, the capability information includes information indicating whether or not the information processing device 101 supports WEC. The content of the capability information varies depending on the model and type number of the information processing device 101.

[0047] Next, in S206, the CPU 103 determines whether the information processing device 101 was connected to the access point via Wi-Fi when the configuration operation was performed, and whether the information processing device 101 supports WEC. For example, if the information processing device 101 was not connected to the access point via Wi-Fi when the configuration operation was performed, the result is NO. Also, for example, if the information processing device 101 was connected to the access point via Wi-Fi when the configuration operation was performed, but the information processing device 101 does not support WEC, the result is NO. Whether the information processing device 101 was connected to the access point via Wi-Fi when the configuration operation was performed is determined based on whether information about connected APs is stored in the predetermined memory area mentioned above. Furthermore, whether the information processing device 101 supports WEC is determined based on the content of the capability information obtained in S205. If the CPU 103 determines YES, it proceeds to S207; if it determines NO, it proceeds to S224.

[0048] In S207, the CPU 103 attempts to obtain various information from the communication device 151 via a Wi-Fi connection between the access point and the information processing device 101, where the communication device 151 is enabled and operating in network setup mode. As mentioned above, the setup communication protocol is used for communication via the Wi-Fi connection between the access point and the information processing device 101 where the communication device 151 is enabled and operating in network setup mode. The information obtained through this includes, for example, the WEC-related information mentioned above and information indicating whether the communication device 151 supports WEC. The information indicating whether or not it supports WEC indicates whether or not the communication device 151 supports DPP and is operating in the DPP waiting mode described later. If the communication device 151 does not support WEC, information indicating that the communication device 151 does not support WEC is obtained, and WEC-related information is not obtained. Also, if the communication device 151 does not support WEC, both WEC-related information and information indicating whether or not the communication device 151 supports WEC may not be obtained. Generally, WEC-related information can be acquired by having the communication device 151 display a QR code corresponding to the WEC-related information on its display unit, and then having the information processing device 101 read that QR code with a camera unit or the like. However, in this embodiment, the WEC-related information is acquired via a Wi-Fi connection between the access point enabled by the communication device 151, which is operating in network setup mode, and the information processing device 101. This configuration allows the information processing device 101 to acquire WEC-related information even if the communication device 151 does not have a display unit for displaying QR codes, or if the information processing device 101 does not have a camera unit for reading QR codes.

[0049] Next, in S208, the CPU 103 determines whether the communication device 151 supports WEC based on the information obtained in S207. WEC support for the communication device 151 means that it supports DPP as described above and is operating in DPP waiting mode. If information indicating that the communication device 151 supports WEC is obtained, the determination is YES; if no such information is obtained, the determination is NO. If the determination is YES, the CPU 103 proceeds to S209; otherwise, it proceeds to S224. If information could not be obtained in S207, the result of this determination is NO.

[0050] Next, in S209, the CPU 103 determines whether or not it was able to obtain WEC-related information from the communication device 151 in S207. If the CPU 103 determines it is YES, it proceeds to S210; otherwise, it proceeds to S222. A case where the CPU 103 determines it is NO is, for example, when information indicating that the communication device 151 supports WEC was obtained, but WEC-related information was not obtained due to a communication error or the like.

[0051] In S210, the CPU 103 obtains capability information of the communication device 151 via a Wi-Fi connection between the access point enabled by the communication device 151, which is operating in network setup mode, and the information processing device 101. In this embodiment, the capability information of the communication device 151 includes information indicating the encryption methods supported by the communication device 151 and information indicating the frequency bands supported by the communication device 151. Examples of encryption methods supported by the communication device 151 are WPA (Wi-Fi Protected Access), WPA2, and WPA3. The information indicating the frequency bands supported by the communication device 151 may also be information indicating the communication channel corresponding to the frequency band supported by the communication device 151 (channel information). Note that this process may be omitted in forms where the determination regarding the encryption methods supported by the communication device 151 and the determination regarding the frequency bands supported by the communication device 151, as described later, are not performed. Note that capability information may be included in the settings application beforehand. In other words, the CPU 103 may identify the capability information corresponding to the communication device 151 from among the multiple capability information provided for each type and model number of communication device that is pre-installed in the settings application, and obtain the identified capability information from the settings application.

[0052] Next, in S211, the CPU 103 determines, based on the capability information obtained in S210, whether the encryption method used to connect with the connected AP is an encryption method supported by the communication device 151. In this embodiment, the encryption methods supported by the communication device 151 are WPA, WPA2, and WPA3, and the encryption method not supported by the communication device 151 is WEP (Wired Equivalent Privacy). If the CPU 103 determines YES, it proceeds to S212; otherwise, it proceeds to S224. This determination may be performed at other times. Specifically, for example, this determination may be performed after S204-YES, and if the determination is YES, it proceeds to S205; otherwise, it proceeds to S224.

[0053] Next, in S212, the CPU 103 determines whether the encryption method used to connect with the connected AP is a WEC-compatible (DPP-compatible) encryption method. WEC-compatible encryption methods include, for example, WPA2 and WPA3, while non-WEC-compatible encryption methods include, for example, WPA and WEP. The CPU 103 may determine which encryption method is WEC-compatible based on information pre-stored by the configuration application, or based on information obtained from the communication device 151. If the CPU 103 determines YES, it proceeds to S213; otherwise, it proceeds to S224.

[0054] Next, in S213, the CPU 103 determines, based on the capability information obtained in S210, whether the frequency band used for connecting with the connected AP is a frequency band supported by the communication device 151. In this embodiment, it is assumed that there are two types of communication devices 151: one that supports both the 2.4GHz and 5GHz frequency bands, and another that supports the 2.4GHz frequency band but not the 5GHz frequency band. The communication device 151 cannot connect to an access point if it does not support a particular frequency band. For example, if the frequency band used for connecting with the connected AP is the 5GHz frequency band, and the communication device 151 does not support the 5GHz frequency band, the result of this determination will be NO. If the CPU 103 determines YES, it proceeds to S214; otherwise, it proceeds to S224.

[0055] In S214, the CPU 103 disconnects the Wi-Fi connection between the access point and the information processing device 101, which is enabled by the communication device 151 operating in network setup mode.

[0056] Next, in S215, the CPU 103 re-establishes the connection between the information processing device 101 and the access point to which the information processing device 101 was connected via Wi-Fi when the configuration operation was performed. Note that during WEC execution, information regarding the access point to which the information processing device 101 is connected is transmitted. Therefore, this process is performed in preparation for the execution of WEC in S216.

[0057] Next, in S216, the CPU 103 executes a process to run WEC using the acquired WEC-related information. In this embodiment, the configuration application does not directly run WEC, but rather launches the OS standard WEC application program (hereinafter referred to as the WEC application) as a process to run WEC. The WEC application then executes the WEC API and sends a WEC execution request to the OS, causing the OS to run WEC. Alternatively, the configuration application may execute the WEC API and send a WEC execution request to the OS, and the process to run WEC may be this execution request. Details of this process will be described later.

[0058] In S217, the CPU 103 determines whether the WEC execution was successful in establishing a connection between the access point and the communication device 151. This determination is made based on information regarding whether the WEC execution was canceled and information obtained from the communication device 151 indicating the success or failure of the connection with the access point. If the CPU 103 determines it is YES, it terminates processing; otherwise, it proceeds to S218.

[0059] In S218, the CPU 103 determines whether the reason for the failure to establish a connection between the access point and the communication device 151 is a specific cause, based on the executed WEC. In this embodiment, information regarding the reason for the failure to establish a connection between the access point and the communication device 151 is obtained from the communication device 151 by the executed WEC, and this determination is performed based on that information. In this embodiment, specific causes include, for example, a communication error in the WEC (cause 1), or the encryption method used for the connection between the information processing device 101 and the access point being an encryption method not supported by the communication device 151 (cause 2). Another example is the encryption method used for the connection between the information processing device 101 and the access point being an encryption method not supported by the WEC (cause 3). Note that connection failures due to causes 2 and 3 may occur if the WEC is executed after S221-YES. This is because, unlike when WEC is executed after S215, when WEC is executed after S221-YES, capability information for the communication device 151 has not been acquired, and therefore, judgments like those in S211 and S212 have not been performed. The CPU 103 proceeds to S224 if the judgment is YES, and terminates processing if the judgment is NO.

[0060] Note that the processing in S217 and S218 may be omitted. Specifically, for example, after S216, the process may terminate without executing S217 or S218. Also, in the case of S217-NO, the process may terminate without executing S218.

[0061] Next, we will explain S219, which is executed in the cases of S202-NO and S204-NO. In S219, the CPU 103 determines whether the information processing device 101 was connected to the access point via Wi-Fi when the setting operation was performed. This determination is made based on whether or not information about the access point is stored in the predetermined memory area mentioned above. If the determination is YES, the CPU 103 proceeds to S220, and if the determination is NO, it terminates the process.

[0062] In S220, an attempt is made to acquire WEC-related information using a different method than that used in S207. Specifically, for example, an attempt is made to acquire WEC-related information by reading a QR code, as described above. Figure 3 is an example of a screen for capturing a QR code displayed by the settings application. The screen 300 for capturing a QR code displays a frame 301, and the screen 300 also displays an image captured by the camera unit of the information processing device 101. The user operates the information processing device 101 so that the QR code captured by the camera unit and displayed by the communication device 151 fits within the frame 301. When it is detected that the QR code fits within the frame 301, the CPU 103 analyzes the QR code and acquires WEC-related information. Note that the acquisition of WEC-related information is not limited to this form; for example, WEC-related information may also be acquired from the communication device 151 via NFC or BLE. Note that if the communication device 151 does not support WEC, it cannot display a QR code or transmit WEC-related information via NFC or BLE. In that case, CPU 103 terminates the process by accepting a cancellation operation from the user via the settings app. Note that the screen 700 for scanning the QR code may be displayed by an application program other than the settings app (for example, the WEC app or another scanning application program).

[0063] Next, in S221, it is determined whether or not WEC-related information was obtained in S220. If the CPU 103 determines it is YES, it proceeds to S216; otherwise, it terminates processing. For example, if the QR code read in S220 is not a QR code for obtaining WEC-related information, or if the QR code reading fails, it will be determined to be NO. In the case of a NO determination, the CPU 103 may proceed to S224 without terminating processing. Also, if S221 is YES, the CPU 103 may determine whether or not the encryption method used to connect with the connected AP is an encryption method that supports WEC (supports DPP). If the CPU 103 determines it is YES, it proceeds to S216; otherwise, it may terminate processing or proceed to S224. In this case, it is assumed that the CPU 103 knows which encryption method supports WEC based on information previously held by the configuration application.

[0064] Next, we will describe S222, which is executed in the case of S209-NO. In S222, the CPU 103 disconnects the Wi-Fi connection between the access point enabled by the communication device 151, which is operating in network setup mode, and the information processing device 101.

[0065] Next, in S223, the CPU 103 re-establishes the connection between the information processing device 101 and the access point to which the information processing device 101 was connected via Wi-Fi when the configuration operation was performed. After that, the CPU 103 proceeds to S220 as described above.

[0066] In this embodiment, if WEC-related information cannot be obtained through the Wi-Fi connection between the communication device 151 and the information processing device 101 operating in network setup mode, an attempt is made to obtain the WEC-related information by other means. Specifically, for example, an attempt is made to obtain the WEC-related information by reading a QR code. This ensures that WEC can be executed even if WEC-related information cannot be obtained through the Wi-Fi connection between the communication device 151 and the information processing device 101 operating in network setup mode.

[0067] Next, we will explain S224, which is executed in the cases of S206-NO, S208-NO, S211-213-NO, and S218-YES. In S224, the CPU 103 performs network setup of the communication device 151 in a way different from that of WEC. In this embodiment, the method different from that of WEC is to perform network setup of the communication device 151 using a setup communication protocol, which is a different protocol from the protocol used for WEC (DPP). Details of this process will be described later. After that, the process ends.

[0068] The processing described in the flowchart above is not limited to what is described above. For example, if the CPU 103 cannot obtain WEC-related information via the Wi-Fi connection between the communication device 151 operating in network setup mode and the information processing device 101, it may terminate the process without attempting to obtain the WEC-related information by other means. Specifically, cases where WEC-related information cannot be obtained via the Wi-Fi connection between the communication device 151 operating in network setup mode and the information processing device 101 include, for example, S202-NO, S204-NO, and S209-NO. In other words, in the cases of S202-NO, S204-NO, and S209-NO, the process may terminate without executing the subsequent processing (S219-S223).

[0069] Furthermore, as mentioned above, two decisions, S208 and S209, were made after S207, but the process is not limited to this form. For example, after S207, instead of the two decisions in S208 and S209, a decision may be made to determine whether or not WEC-related information has been acquired. Then, if the result of the decision is YES, the process proceeds to S210, and if the result is NO, it proceeds to S224, and the processing of S220 to S223 may not be executed.

[0070] In this embodiment, the encryption method supported by the communication device 151 includes an encryption method that supports WEC. Therefore, the determination in S211 may not be performed. Specifically, for example, after S210, the determination in S211 may not be performed, and the determination in S212 may be performed instead.

[0071] Furthermore, for example, the encryption method supported by the communication device 151 may be WPA3 only, while the encryption methods supported by WEC are WPA2 and WPA3. In such cases, the encryption method supported by WEC may be included in the encryption methods supported by WEC. In this case, the determination in S212 may not be performed. Specifically, for example, after S211-YES, the determination in S212 may not be performed, and the determination in S213 may be performed instead.

[0072] Using Figure 4, the processing performed by the information processing device 101 and the communication device 151 in S216 will be explained. The sequence shown in Figure 4 is realized, for example, by the CPU of each device reading programs stored in the ROM or external storage device of each device into the RAM of each device and executing them.

[0073] First, in S400, the information processing unit 101 starts WEC using DPP through the functions of the OS. Specifically, the information processing unit 101 starts the WEC application by instructing the OS to start the WEC application from the configuration application. As a result, the WEC application runs in the foreground and the configuration application runs in the background. For example, the execution of this instruction corresponds to the instruction to start WEC. As a result, the information processing unit 101 displays the WEC start screen by the WEC application. The WEC application is a program that is pre-installed on the information processing unit 101 and is provided by the OS vendor of the information processing unit 101. When the WEC application is started, WEC-related information acquired by the configuration application is provided to the WEC application. Figure 5 is an example of the WEC start screen displayed by the WEC application. The WEC start screen 300 displays areas 501, 502, and 503. Area 501 is an area for changing the access point that is set as the target of WEC configuration. Before area 501 is operated, the access point set as the target for WEC configuration is the access point to which the information processing device 101 is currently connected. When area 501 is selected, the information processing device 101 displays a list of access points and newly sets the access point selected by the user from the list as the target for WEC configuration. The list of access points includes, for example, access points discovered by the information processing device 101 through AP search and access points to which the information processing device 101 has previously connected. Area 502 is for canceling the execution of WEC, and area 503 is for instructing the execution of WEC. When area 502 is operated, the information processing device 101 terminates the processing in this sequence diagram and proceeds to S217. In this case, WEC is considered to have failed. Also, when area 503 is pressed, the information processing device 101 proceeds to S401.

[0074] In S401, the WEC application executes a WEC API using WEC-related information and information about access points configured as targets for WEC configuration, thereby instructing the OS to execute WEC. Then, the OS performs a process called DPP Authentication between the information processing device 101 and the communication device 151. In DPP Authentication, authentication information and information used for information encryption are communicated between the information processing device 101 and the communication device 151 to authenticate communication between the devices. In DPP Authentication, various information transmitted from the information processing device 101 is encrypted based on the WEC-related information acquired by the information processing device 101 in the process shown in Figure 2. Specifically, in DPP Authentication, the information processing device 101 first sends an Authentication Request as a DPP network setup request. Next, the communication device 151, which is operating in DPP waiting mode, receives the Request sent from the information processing device 101 because it is operating in DPP waiting mode, which is a mode that waits for the Authentication Request. Upon receiving an Authentication Request, the communication device 151 attempts to decrypt the received Request using the decryption key it currently possesses. If the decryption is successful, the communication device 151 sends an Authentication response to the information processing device 101, thereby authenticating communication with the information processing device 101. However, if the information processing device 101 has not been able to obtain accurate WEC-related information and has not been able to encrypt the information accurately, the decryption by the communication device 151 will fail, authentication will fail, and no Authentication response will be sent. DPP Authentication is completed when the information processing device 101 receives the Authentication response. Furthermore, DPP is used to execute communication during DPP Authentication.

[0075] Next, in S402, the OS performs a process called DPP Configuration between the information processing device 101 and the communication device 151. In DPP Configuration, the information processing device 101 sends connection information to the communication device 151 via WEC to connect to the access point that has been configured as a target for WEC configuration. The connection information includes the SSID, password, and encryption method of the access point that has been configured as a target for WEC configuration. The password sent at this time is information entered by the user on the screen displayed by the OS-compatible application when the connection between the information processing device 101 and the access point is established. It is also information that the OS has retained when the connection between the information processing device 101 and the access point is established. Furthermore, the password is not information that the configuration application retains. Moreover, since the password sent at this time is information that the OS already retains, and DPP Configuration is a process executed by the OS, it does not need to be newly entered by the user on the screen displayed by the configuration application. As in this embodiment, by transmitting connection information via WEC, the password can be sent to the communication device 151 via secure communication without requiring the user to enter a password again on the screen displayed by the configuration application. In DPP Configuration, DPP is also used for communication.

[0076] In S403, the communication device 151 exits network setup mode and transitions to infrastructure mode. The communication device 151 then attempts to connect to the access point corresponding to the connection information obtained by WEC. If the connection is successful, the communication device 151 can then perform communication via the network formed by the connected access point. Communication via the network formed by the connected access point is performed using a protocol different from DPP (specifically, for example, Port9100, SNMP, or a vendor-specific protocol of the communication device 151). The communication device 151 may also send information to the information processing device 101 indicating whether the connection to the access point corresponding to the connection information obtained by WEC was successful or not. Furthermore, if the connection to the access point corresponding to the connection information obtained by WEC fails, the communication device 151 may also send information indicating the cause of the failure to the information processing device 101. These information transmissions may be performed using DPP. The reasons why the connection to the access point corresponding to the connection information obtained by WEC fails include communication errors in WEC, the access point not being found, or the WEC-related information obtained from the communication device 151 not being appropriate. For example, the encryption method used for connecting to the access point set as a target for WEC configuration may be an encryption method not supported by the communication device 151. For example, the encryption method used for connecting to the access point set as a target for WEC configuration may be an encryption method not supported by WEC. The information processing device 101 may also display information on the display unit 108 indicating whether the connection to the access point corresponding to the connection information obtained by WEC was successful or not. Furthermore, if the connection to the access point corresponding to the connection information obtained by WEC fails, the display unit 108 may also display information indicating the reason for the failure.

[0077] In S404, the information processing unit 101 switches the application running in the foreground from the WEC application to the configuration application based on the completion of WEC execution. The information processing unit 101 then searches for the communication device 151 on the network to which it belongs. This process is carried out by the configuration application, which has received notification from the OS that WEC execution has finished. When the information processing unit 101 finds the communication device 151, it requests capability information from the communication device 151, and the communication device 151 sends the capability information to the information processing unit 101. As a result, the information of the communication device 151 is registered in the configuration application, and thereafter, the configuration application can perform communication with the communication device 151. Specifically, for example, the configuration application can send print jobs to the communication device 151. At this time, if the information processing unit 101 belongs to the network formed by the access point to which the communication device 151 is connected via WEC, communication with the communication device 151 can be performed via that access point. Furthermore, if communication between the information processing device 101 and the communication device 151 is not possible, for example, if the access point to which the communication device 151 is connected is not the same access point to which the information processing device 101 is connected, the request and acquisition of capability information are omitted. Note that the communication in S404 is performed using a communication protocol different from both DPP and the setup communication protocol (specifically, for example, CHMP). After that, the information processing device 101 completes the processing in this sequence diagram and proceeds to S217.

[0078] The above description assumes that a WEC application displays the WEC start screen and instructs the OS to run WEC by executing a WEC API. However, the system is not limited to this configuration. For example, a configuration application may display the WEC start screen. Alternatively, a configuration application may execute a WEC API to instruct the OS to run WEC.

[0079] Next, using Figure 6, the processing performed by the information processing device 101 and the communication device 151 in S224 will be explained. The sequence shown in Figure 6 is realized, for example, by the CPU of each device reading programs stored in the ROM or external storage device of each device into the RAM of each device and executing them. As mentioned above, a setup communication protocol is used for communication between the communication device 151 and the information processing device 101 via a Wi-Fi connection, when the communication device is operating in network setup mode.

[0080] In the S600, the information processing device 101 requests a list of access points from the communication device 151 via a Wi-Fi connection between the information processing device 101 and the communication device 151, which is operating in network setup mode, using a configuration application.

[0081] Next, in S601, the communication device 151 transmits a list of access points to the information processing device 101 via a Wi-Fi connection between the communication device 151, which is operating in network setup mode, and the information processing device 101. The list transmitted here is a list of one or more access points that the communication device 151 can connect to, which were discovered by the communication device 151 performing an AP search.

[0082] Next, in S602, the information processing device 101 transmits connection information for one of the access points included in the received list to the communication device 151 via a Wi-Fi connection between the information processing device 101 and the communication device 151, which is operating in network setup mode. This process is realized by the settings application controlling the information processing device 101 to transmit connection information for one of the access points included in the received list. Specifically in this process, if the received list includes a connected AP, the information processing device 101 transmits the connection information for the connected AP. In this embodiment, since the list only includes access points that the communication device 151 can connect to, if the received list includes a connected AP, that is, if the communication device 151 can connect to the connected AP. If the received list does not include a connected AP, the information processing device 101 displays the received list and accepts the user's selection of an access point from the list. The information processing device 101 then transmits the connection information for the selected access point. In this embodiment, the list only includes access points that the communication device 151 can connect to. Therefore, if a connected AP is not included in the received list, it means that the communication device 151 cannot connect to the connected AP. In addition, access points that can be connected using encryption methods not supported by the communication device 151 are not included in the list because the communication device 151 cannot connect to them. Similarly, access points that can be connected using frequency bands not supported by the communication device 151 are not included in the list because the communication device 151 cannot connect to them. As a result, in the case of S211-NO and S224 executed in the case of S213-NO, connection information for an access point different from the connected AP will be transmitted. In the case of S212-NO, it is possible that the connected AP and the communication device 151 can connect to each other, so it is possible that connection information for the connected AP or connection information for an access point different from the connected AP will be transmitted. This embodiment is not limited to this form, and the list may always be displayed and the user may be asked to select an access point each time.Before the connection information is transmitted, the information processing device 101 accepts a password for connecting to the access point from the user on a screen displayed by the setup application. The received password is then included in the connection information, and the connection information is transmitted.

[0083] In S603, the communication device 151 notifies the information processing device 101 that it has received connection information via a Wi-Fi connection between the communication device 151, which is operating in network setup mode, and the information processing device 101.

[0084] In S604, the communication device 151 exits network setup mode and switches to infrastructure mode. The communication device 151 then attempts to connect to the access point corresponding to the connection information obtained in S602. If the connection is successful, the communication device 151 can then perform communication via the network formed by the connected access point.

[0085] In S605, the information processing device 101 uses the connection information stored by the setting application to reconnect with the access point to which the information processing device 101 was connected when the setting operation was performed. However, it is not limited to this configuration. For example, if the information processing device 101 has sent connection information for a different access point to the communication device 151 at the time the setting operation was performed, it may connect to that other access point.

[0086] In S606, the information processing device 101 searches for the communication device 151 on the network to which it belongs using a configuration application. When the information processing device 101 finds the communication device 151, it requests capability information from the communication device 151, and the communication device 151 sends the capability information to the information processing device 101. This registers the information of the communication device 151 in the configuration application, and thereafter, the configuration application can perform communication with the communication device 151. Specifically, for example, the configuration application can send print jobs to the communication device 151. At this time, if the information processing device 101 belongs to a network formed by the access point to which the communication device 151 is connected via network setup, communication with the communication device 151 can be performed via that access point. However, if the access point to which the communication device 151 is connected is not the same access point to which the information processing device 101 is connected, or if communication between the information processing device 101 and the communication device 151 cannot be performed, the request and acquisition of capability information are omitted. Note that the communication in S606 is performed using a communication protocol different from both DPP and the setup communication protocol (specifically, CHMP, for example). After that, the information processing device 101 terminates the processing in this sequence diagram.

[0087] The processing described in the sequence diagram above is not limited to what is described above. For example, if the received list does not include the access point to which the information processing device 101 was connected via Wi-Fi when the configuration operation was performed, the communication device 151 does not need to send the access point connection information and does not need to attempt to establish a connection between the communication device 151 and the access point. Instead, the communication device 151 may receive the access point connection information that will be enabled within the communication device 151 in AP mode and attempt to establish a connection between the communication device 151, which is operating in AP mode, and the information processing device 101. In that configuration, the communication device 151 sends the access point connection information that will be enabled within the communication device 151 in AP mode, then exits network setup mode and transitions to AP mode.

[0088] Figures 7 and 8 are flowcharts showing the processing flow performed by the communication device 151 during the network setup process of this embodiment. In this embodiment, the conditions for the communication device 151 to start operating in setup mode include a first condition and a second condition. The first condition is that "a power-on operation is performed on the communication device 151, which is in a state where initial setup is not yet complete, and power is supplied to the communication device 151." The second condition is that "a predetermined operation for network setup is performed on the communication device 151, which is in a power-on state." The setup mode processing started based on the first condition and the setup mode processing started based on the second condition will be explained using Figures 7 and 8, respectively.

[0089] First, let's explain the processing in setup mode, which is initiated based on the first condition. The communication device 151 performs initial setup based on the fact that the user has performed the power-on operation for the first time in the factory default state (arrival state) (i.e., the first condition). The factory default state corresponds to, for example, a state in which the communication device 151 has not completed initial setup. For example, the communication device 151 is shipped from the factory without ink tanks, print heads, etc. installed. Therefore, as initial setup, the communication device 151 performs processes to make the communication device 151 usable, such as prompting the user to install the included ink tanks, print heads, etc. into the communication device 151, register adjustment, and print head cleaning. Whether or not the communication device 151 is in the factory default state is controlled using a flag (initial startup flag) stored in RAM 153 or memory. The communication device 151 changes the state of the initial startup flag according to the completion of initial setup, and is configured so that initial setup is not started even if the power of the communication device 151 is turned on after the completion of initial setup. In order to use the communication device 151, it is preferable that the network setup of the communication device 151 be performed. Therefore, in this embodiment, the network setup process is performed during the initial setup.

[0090] Figure 7 is a flowchart showing the processes executed by the communication device 151 when a power-on operation is performed on the communication device 151. The flowchart shown in Figure 7 is realized, for example, by the CPU 154 reading a setting application stored in ROM 152 or memory into RAM 153 and executing it. Furthermore, the flowchart shown in Figure 7 is started based on the power-on operation described above.

[0091] In S700, the CPU 154 refers to the initial startup flag stored in RAM 153 or memory, etc., and determines whether the communication device 151 is in the initial startup state. For example, the initial startup flag is set to a specific value that indicates the communication device 151 is in the initial startup state when it is shipped from the factory. If the CPU 154 determines NO in S700, it proceeds to S701; if the CPU 154 determines YES in S700, it proceeds to S703. The case where the CPU 154 determines NO in S700 is when the initial setup of the communication device 151 has already been completed and the power to the communication device 151 has been turned ON.

[0092] In S701, the CPU 154 executes processing according to the configured connection mode stored in RAM 153 or memory. For example, if the communication device 151 is wirelessly connected to an access point via Wi-Fi when the user turns off the power, and the infrastructure connection mode is set, the CPU 154 will connect to the access point.

[0093] In S702, CPU154 displays the standby screen (home screen) and terminates the processing of this flowchart.

[0094] In S703, the CPU 154 initiates (enables) network setup mode operation in the communication device 151. Specifically, the CPU 154 enables the setup access point. Furthermore, the CPU 154 starts a network setup mode timeout timer and counts the elapsed time since the start of operation in network setup mode, in order to terminate network setup mode after a predetermined time has elapsed.

[0095] In S704, the CPU 154 initiates the communication device 151 into the DPP waiting mode described above. The DPP waiting mode will be described later in Figure 9. It also starts a timeout timer for the DPP waiting mode and counts the elapsed time since the start of operation in DPP waiting mode.

[0096] In S705, the CPU 154 receives a connection request to the setup access point from the information processing device 101.

[0097] In S706, the CPU 154 attempts to establish a Wi-Fi connection. This Wi-Fi connection corresponds to the Wi-Fi connection between the communication device 151 and the information processing device 101, which are operating in network setup mode.

[0098] In S707, the CPU 154 receives requests for various WEC-related information from the information processing device 101 via the Wi-Fi connection established in S706. As mentioned above, the network setup communication protocol is used for communication between the access point, which is enabled by the communication device 151 operating in network setup mode, and the information processing device 101 via the Wi-Fi connection.

[0099] In S708, the CPU 154 transmits various information regarding WEC of the communication device 151 to the information processing device 101. For example, the various information regarding WEC of the communication device 151 includes the WEC-related information mentioned above and information indicating whether or not the communication device 151 supports WEC. The information indicating whether or not WEC is supported indicates whether or not the communication device 151 supports DPP and is operating in the DPP waiting mode described later. If the communication device 151 does not support WEC, information indicating that the communication device 151 does not support WEC is transmitted, and WEC-related information is not transmitted. In addition, if the communication device 151 does not support WEC, both the WEC-related information and the information indicating whether or not the communication device 151 supports WEC may not be transmitted.

[0100] In S709, CPU 154 determines whether it has received a request to execute network setup using the network setup protocol. Specifically, CPU 154 determines whether it has received a request for a list of access points from the information processing device. If CPU 154 determines YES in S709, it proceeds to S710; if it determines NO in S709, it proceeds to S712.

[0101] In S710, CPU 154 performs network setup using the network setup protocol. Specifically, it executes the process described in Figure 6 as the process performed by the communication device 151, and then terminates this flowchart. Note that in S604 of Figure 6, CPU 154 terminates (disables) operation in network setup mode and disables the setup access point.

[0102] In S711, CPU 154 terminates the DPP waiting mode and exits this flowchart. Note that the termination of operation in network setup mode and the termination of DPP waiting mode may occur in any order, as long as the network setup has been completed. In other words, CPU 154 may terminate the operation in network setup mode after terminating the DPP waiting mode. Alternatively, the termination of operation in network setup mode and the termination of DPP waiting mode may occur simultaneously.

[0103] In S712, which is executed when S709-NO, the CPU 154 determines whether it has received a request to execute a network setup (WEC) using DPP. Specifically, the CPU 154 determines from the information processing device 101 whether it has received a request to execute a network setup request (WEC) using DPP in the DPP Authentication process described above. If the CPU 154 determines YES in S712, it proceeds to S713; if the CPU 154 determines NO in S712, it proceeds to S721. The CPU 154 may also start a timer for waiting for a network setup request using DPP as a timeout. In this case, if the count value of the timer for waiting for a WEC execution request exceeds a threshold, the CPU 154 may change the channel used for DPP communication. Furthermore, if the CPU 154 has changed the channel used for DPP communication more than a predetermined number of times but has not received a WEC execution request, it may proceed to S718, terminate the DPP waiting mode, and wait for a request to execute the network setup mode.

[0104] In S713, CPU 154 performs network setup using DPP. Specifically, it performs the process described in Figure 4 as the process to be performed by communication device 151, and then terminates this flowchart. Network setup using DPP (WEC) will be described later using Figure 10.

[0105] In S714, the CPU 154 determines whether the WEC executed successfully established a connection between the access point to which the information processing device 101 is connected and the communication device 151. This determination is considered successful if the connection between the communication device 151 and the information processing device 101 is successful, that is, if the communication device 151 connects to the access point to which the information processing device 101 is connected. Furthermore, in S713, if the determination in each of the determinations in Figure 10 is NO, and the information processing device 101 does not connect to the access point to which it is connected, it is considered a failure. In addition, even if the communication device 151 connects to an access point in S1308, it is considered a failure if the connected access point is a different access point from the one to which the information processing device 101 is connected. However, if the communication device 151 is connected to an access point, it may be considered a success even if that access point is not the one to which the information processing device 101 is connected. If CPU 154 determines that S714 is YES, it proceeds to S715; if S714 is NO, it proceeds to S716. CPU 154 may determine that WEC was successful if it determines that each of the conditions in Figure 10 in S713 is YES, and may then terminate the DPP waiting mode before connecting to the access point; the order of processing does not matter.

[0106] In S715, CPU154 terminates its operation in network setup mode and DPP waiting mode, and then terminates this flowchart. Note that the termination of network setup mode and DPP waiting mode may occur in either order or simultaneously. Furthermore, the order of the termination process for network setup mode or DPP waiting mode and the connection process with the access point does not matter.

[0107] In S716, the CPU 154 determines whether the WEC execution has failed to establish a connection between the access point and the communication device 151 more than twice. The number of determinations is not limited; it is sufficient to determine whether the failures have occurred more than a predetermined number of times. If the CPU 154 determines YES in S716, it proceeds to S718; if the WEC execution is NO, it proceeds to S717. The CPU 154 may also determine whether the WEC execution has failed to establish a connection between the access point and the communication device 151 more than twice for the same reason. That is, it may determine whether the same determination process as the previous one was determined to be NO in each determination process shown in Figure 10, which will be described later. Furthermore, if the CPU 154 determines NO in S716, i.e., if the number of failures is less than a predetermined number, it may reset the DPP waiting mode timeout timer, which will be described later, and restart it in order to execute the WEC again.

[0108] In S717, the CPU 154 does not terminate the DPP listening mode and network setup mode, but updates the public key and listening channel included in the WEC-related information in order to wait for a request to run WEC again. Information other than the public key and listening channel included in the WEC-related information may also be updated. The CPU 154 may also update the WEC-related information only if the cause of the failure is information included in the WEC-related information, or it may update only the information regarding the cause of the failure included in the WEC-related information. The information processing device 101 may store the WEC-related information obtained from the communication device 151 in the previous (first) communication with the communication device 151 in memory such as RAM 105 or external storage device 106. However, when the information processing device 101 runs WEC again, it runs WEC using the updated WEC-related information obtained from the communication device 151 in the second communication with the communication device 151. This reduces the chance of unintended network setup being performed. Furthermore, the CPU 154 returns to S705 to establish a connection with the information processing device 101 again.

[0109] In S718, the CPU 154 continues in network setup mode without terminating and terminates the DPP waiting mode. Then, in S720, after establishing a connection with the information processing device 101, the CPU 154 proceeds to S724 if it determines in S723 that it has received a request to execute network setup using the network setup protocol. Then, it executes network setup using the network setup protocol. In other words, if the WEC executed fails to establish a connection between the access point and the communication device 151 two or more times, network setup using the network setup protocol is executed. This makes it possible to more reliably establish a connection between the access point and the communication device 151. For this reason, the CPU 154 does not terminate network setup mode. Note that in S712, the CPU 154 may terminate network setup mode if it determines that it has received a request to execute WEC. However, in this configuration, if the WEC executed in S713 fails to establish a connection between the access point and the communication device 151, it is necessary to start network setup mode again.

[0110] The processes in S719 and S720 are the same as those in S705 and S706, respectively, so their explanation will be omitted.

[0111] In S721, CPU 154 determines whether the DPP waiting mode timeout timer has exceeded a threshold value and whether the DPP waiting mode has timed out. If CPU 154 determines YES in S721, it proceeds to S722; if it determines NO in S721, it returns to S709.

[0112] In S722, CPU154 exits DPP waiting mode and proceeds to S723.

[0113] S723 and S724 perform the same processing as S709 and S710 respectively, so their explanations are omitted. CPU 154 proceeds to S724 if the result of S723 is YES, and to S725 if the result of S723 is NO.

[0114] In S725, CPU154 determines whether the network setup mode has timed out because the value counted by the network setup mode timeout timer has exceeded the threshold. If CPU154 determines YES in S725, it proceeds to S726; if NO in S725, it returns to S723.

[0115] In S726, CPU154 terminates operation in network setup mode and disables the setup access point. This is because, as mentioned above, the setup access point does not require a password, and if it is enabled for a long time, the likelihood of unauthorized devices requesting a connection increases. The setup access point may be an access point that requires a password. In that case, the password used to connect to the setup access point shall be a fixed (user-unchangeable) password that the configuration application has known in advance. Then CPU154 terminates this flowchart.

[0116] After the initial setup is complete, the CPU 154 changes the value of the initial startup flag stored in RAM 153 or memory from a value indicating the initial startup state to a value indicating the non-initial startup state. The non-initial startup state corresponds to the state in which the initial setup is complete. As a result, once the initial setup is complete, the flowchart in Figure 7 will not be executed when the communication device 151 is powered on by the user in the future.

[0117] Next, we will describe the setup process in the setup mode operation that is initiated based on the second condition.

[0118] Figure 8 is a flowchart showing the setup process performed by the communication device 151. The flowchart shown in Figure 8 is realized, for example, when the CPU 154 reads a setting application stored in ROM 152 or memory into RAM 153 and executes it. The flowchart in Figure 8 is executed based on the fact that the second condition described above is met.

[0119] In S800, the communication device 151 determines whether a connection mode is set for the communication device 151 when the setting operation is performed. If the result in S800 is YES, the communication device 151 proceeds to S801; if the result in S800 is NO, it proceeds to S802.

[0120] In S801, the communication device 151 disables the connection mode that was set when the configuration operation was performed. For example, if the infrastructure connection mode was set for the communication device 151 when the configuration operation was performed, and the communication device 151 was wirelessly connected to an access point via Wi-Fi, the infrastructure connection mode is disabled and the connection to the access point is disconnected. The communication device 151 also obtains information about the connection mode that was set for the communication device 151 when the configuration operation was performed and saves it in RAM 153 or memory. This is because this information is necessary when reconnecting to the connection mode that was set for the communication device 151 when the configuration operation was performed, as described later in S818. For example, the communication device 151 obtains information about the access point that was wirelessly connected to via Wi-Fi when the configuration operation was performed and saves it in RAM 153 or memory. This information includes information necessary for the communication device 151 to connect to the access point that is wirelessly connected via Wi-Fi (SSID, encryption method information, etc.). If no connection mode is set when the configuration operation is performed, the acquisition of information about the connection mode is omitted.

[0121] Since steps S802 to S825 are the same as steps S703 to S726, their explanation will be omitted.

[0122] In S826, the communication device 151 reconnects to the connection mode that was set when the configuration operation was performed, based on the information obtained in S801 regarding the connection mode that the communication device 151 was set to at the time the configuration operation was performed. For example, the communication device 151 reconnects to the access point to which it was wirelessly connected via Wi-Fi when the configuration operation was performed. The communication device 151 also reconnects to the connection mode that was set when the configuration operation was performed, even if it exits DPP waiting mode or network setup mode in S810 or S814.

[0123] Here, the processes in S704 in Figure 7 and S803 in Figure 8 will be explained using Figure 9.

[0124] Figure 9 is a flowchart showing the process for starting the DPP waiting mode. The flowchart shown in Figure 9 is implemented, for example, by the CPU 154 reading a configuration application stored in ROM 152 or memory into RAM 153 and executing it. Furthermore, the flowchart in Figure 9 is started, for example, when the communication device 151 starts network setup mode. As mentioned above, network setup mode is started when the first and second conditions are met, so this flowchart can also be considered to be started, for example, when the first and second conditions are met.

[0125] In S1001, the CPU 154 determines the listening channel for DPP communication. The listening channel for DPP communication is the channel that listens for network setup requests via DPP transmitted from the information processing device 101. The same channel is also used for DPP configuration processing. Note that the channel used for DPP communication listening may be set by the user, for example, from the operation screen of the communication device 151.

[0126] In S1002, the CPU 154 generates public key information used to perform secure communication with the information processing device 101 as described above.

[0127] In S1003, the CPU 154 generates the Bootstrapping information described above. The Bootstrapping information includes, for example, the identification information of the communication device 151 (such as its MAC address), information about the listening channel for DPP communication, and the public key information generated in S1002.

[0128] In S1004, the CPU 154 starts DPP waiting mode. Once DPP waiting mode is started, communication for DPP Authentication becomes possible between the communication device 151 and the information processing device 101.

[0129] In S1005, CPU 154 starts the DPP waiting mode timeout timer. After a predetermined time has elapsed since starting operation in DPP waiting mode, CPU 154 stops operation in DPP waiting mode. This is because stopping operation in DPP waiting mode allows the system to transition to network setup processing using the network setup protocol. Specifically, in S721 or S820, if the value counted by the DPP waiting mode timeout timer exceeds a threshold and a network setup mode timeout occurs, CPU 154 terminates DPP waiting mode.

[0130] Then, CPU 154 proceeds to process S705 in Figure 7 or S804 in Figure 8.

[0131] Here, the processes in S713 in Figure 7 and S812 in Figure 8 will be explained using Figure 10.

[0132] Figure 10 is a flowchart showing the execution process of network setup (WEC) using DPP, and corresponds to the operation of the communication device 151 in the sequence in Figure 4. The flowchart shown in Figure 10 is realized, for example, when the CPU 154 reads a configuration application stored in ROM 152 or memory into RAM 153 and executes it. Furthermore, the flowchart in Figure 10 is started based on the communication device 151 receiving a WEC execution request in the DPP Authentication process from the information processing device 101.

[0133] In S1301, the CPU 154 executes DPP Authentication processing. As described above, in DPP Authentication processing, authentication information and information used for information encryption are communicated between the information processing device 101 and the communication device 151, thereby authenticating communication between the devices. In DPP Authentication, DPP is used to perform the communication.

[0134] In S1302, the CPU 154 determines whether the DPP Authentication process with the information processing device 101 was successful. As described above, the various information transmitted from the information processing device 101 during DPP Authentication communication is encrypted based on the WEC-related information acquired by the information processing device 101 in the process shown in Figure 2. If the CPU 154 successfully decrypts the information received from the information processing device 101 using a pre-held decryption key, it authenticates the communication with the information processing device 101. If the information processing device 101 has not acquired accurate WEC-related information and has not accurately encrypted the information, decryption in the communication device 151 will fail, and authentication will fail. Therefore, if the authentication of communication with the information processing device 101 is successful, the CPU 154 determines that the DPP Authentication process was successful, and if it fails, it determines that the DPP Authentication process was failed. If the CPU 154 determines NO in S1302, it terminates this flowchart. On the other hand, if the CPU 154 determines YES in S1302, it proceeds to S1303.

[0135] In S1303, CPU 154 performs DPP Configuration processing. During DPP Configuration processing, CPU 154 receives connection information via WEC from the information processing device 101 to connect to the access point configured as a WEC target. The connection information includes the SSID, password, and encryption method of the access point configured as a WEC target.

[0136] In S1304, the CPU 154 determines whether the DPP Configuration process with the information processing device 101 was successful. Specifically, the CPU 154 determines that the process was successful if it receives connection information via WEC from the information processing device 101 to connect to the access point that has been configured as a target for WEC configuration, and that it failed if it does not receive the information. If the CPU 154 determines NO in S1304, it terminates this flowchart. On the other hand, if the CPU 154 determines YES in S1304, it proceeds to S1305. If the DPP Configuration process is successful, the CPU 154 obtains the access point's SSID, encryption method, and password.

[0137] In S1305, the CPU 154 determines whether the SSID is included in the access point information received from the information processing device 101 that is configured by WEC. If the CPU 154 determines NO in S1305, it terminates this flowchart. On the other hand, if the CPU 154 determines YES in S1305, it proceeds to S1306.

[0138] In S1306, the CPU 154 determines whether the access point information received from the information processing device 101, which is set as a target for WEC configuration, includes an encryption method. If the CPU 154 determines NO in S1306, it terminates this flowchart. On the other hand, if the CPU 154 determines YES in S1306, it proceeds to S1307.

[0139] In S1307, the CPU 154 determines whether the access point information received from the information processing device 101, which is set as a target for WEC configuration, contains a password. Note that if the CPU 154 connects to the access point using DPP communication, it may determine whether public key information is included instead of a password. If the CPU 154 determines NO in S1307, it terminates this flowchart. On the other hand, if the CPU 154 determines YES in S1307, it proceeds to S715 in Figure 7 or S814 in Figure 8 and terminates the DPP waiting mode. Once the CPU 154 terminates the DPP waiting mode, it cannot respond to requests for DPP Authentication processing from the information processing device 101.

[0140] In S1308, the CPU 154 connects to the access point based on the various information (SSID, password, encryption method) of the access point that has been set as a target for WEC configuration, received from the information processing device 101. Then the CPU 154 terminates this flowchart.

[0141] As described above, in this embodiment, the communication device 151 does not terminate the network setup mode and the DPP waiting mode if the execution of WEC fails. This makes it possible to perform network setup again in response to a request to execute network setup or WEC from the information processing device.

[0142] In this embodiment, when the communication device 151 receives either a network setup execution request or a WEC execution request, it also enables the mode for the other execution request. In other words, even when a network setup execution request is received, the DPP waiting mode is enabled. However, when the communication device 151 receives either a network setup execution request or a WEC execution request, it may disable the mode for the other execution request. For example, when a WEC execution request is received, the network setup mode may be terminated, but if the WEC execution fails, the network setup mode is restarted based on the failure of the WEC execution. This makes it possible to execute the network setup again in response to a network setup execution request or a WEC execution request from the information processing device. Furthermore, by disabling the mode for the other execution request when either a network setup execution request or a WEC execution request is received, it is possible to reduce the likelihood of unintended network setup execution. Also, in this embodiment, the DPP waiting mode is started after the network setup mode is started on the communication device 151. This allows the information processing device 101 to automatically acquire various information related to the communication device 151's WEC at the time it wants to execute WEC. Furthermore, the timing at which the network setup mode is started is the timing at which the user wants to perform network setup of the communication device. Therefore, by starting the network setup mode and the DPP waiting mode at the same time, the user can perform network setup of the communication device in either mode of their choice. This improves the convenience of the network setup function. Alternatively, the information processing device 101 may execute a request to the communication device 151 to start DPP waiting mode, causing the communication device 151 to start DPP waiting mode. This allows the information processing device 101 to execute WEC at the time it wants to execute WEC.Furthermore, by having the information processing device 101 initiate DPP waiting mode only when it wants to execute WEC, the execution of unintended network setups by the user can be reduced.

[0143] In this embodiment, the network setup mode is started after the DPP waiting mode is started when the first and second conditions are met, but the system is not limited to this configuration. For example, the network setup mode may be started after the DPP waiting mode is started when the first and second conditions are met. That is, if the start conditions for the network setup mode and the DPP waiting mode are the same, the start order does not matter, and both modes may be started simultaneously. Furthermore, the other mode may be started on the condition that one of the two modes, the network setup mode or the DPP waiting mode, has been started. For example, the information processing device 101 requests only the information regarding whether the communication device 151 supports WEC from the communication device 151 via a Wi-Fi connection with the communication device 151. Then, if the communication device 151 supports WEC, the information processing device 101 requests the communication device 151 to start the DPP waiting mode, and the communication device 151 starts the DPP waiting mode based on receiving the request. Furthermore, the information processing device 101 may request WEC-related information from the communication device 151 after requesting the start of DPP waiting mode.

[0144] In addition, in this embodiment, if the communication device 151 can connect to the predetermined access point to be configured, the information processing device 101 is controlled to transmit connection information for the predetermined access point to the communication device 151 via WEC. If the communication device 151 cannot connect to the predetermined access point to be configured, the information processing device 101 is controlled to transmit connection information for an access point different from the predetermined access point to the communication device 151 via network setup. The case in which the communication device 151 can connect to the predetermined access point is, for example, when the communication device 151 supports the encryption method used for connecting to the predetermined access point, or when the communication device 151 supports the frequency band used for connecting to the predetermined access point. The case in which the communication device 151 cannot connect to the predetermined access point is, for example, when the communication device 151 does not support the encryption method used for connecting to the predetermined access point, or when the communication device 151 does not support the frequency band used for connecting to the predetermined access point. In this embodiment, even if the communication device 151 can be connected to a predetermined access point, if WEC does not support the encryption method used for connecting to the predetermined access point, the information processing device 101 is controlled by network setup to send connection information for an access point different from the predetermined access point to the communication device 151.

[0145] This configuration allows for a simple setup process that eliminates the need for users to enter passwords, etc., by performing the setup using WEC when the connection between the designated access point and the communication device 151 can be established by WEC. Furthermore, if the connection between the designated access point and the communication device 151 cannot be established by WEC, the connection between the access point and the communication device 151 can be more reliably established by performing the setup using a different function than WEC.

[0146] (Other embodiments) In the above embodiment, WEC transmits connection information for connected APs, and various determinations such as S211 to S213 are performed on connected APs, but the system is not limited to this configuration. Connection information for APs other than connected APs may be transmitted, or determinations may be made on APs other than connected APs. Specifically, an AP other than a connected AP may be, for example, an access point to which the information processing device 101 was not connected at the time the configuration operation was performed, but which the information processing device 101 had connected to at some point before the configuration operation was performed. Alternatively, it may be an access point selected by the user from a list of access points to which the information processing device 101 has connected. This is because any connection information for an access point to which the information processing device 101 has connected at some point, and which is stored in the OS, can be transmitted by WEC.

[0147] In the above-described embodiment, setup can be performed using WEC, thereby enabling a simple setup that omits the user's password input. However, setup may also be performed using functions other than WEC. For example, setup may be performed using a function that utilizes the Hyper Text Transfer Protocol. In this case, similar to WEC, a simple setup that omits the user's password input can be achieved. Furthermore, in the above-described embodiment, setup was performed using a setup communication protocol (for example, SNMP (Simple Network Management Protocol)). However, setup may also be performed using functions other than setup communication protocols. For example, setup may be performed using a function that utilizes the Hyper Text Transfer Protocol.

[0148] Furthermore, in the above-described embodiment, the network setup in S224 was described in a form in which connection information is transmitted via a Wi-Fi connection between the information processing device 101 and the communication device 151, but the embodiment is not limited to this form. For example, the network setup may also involve transmitting connection information via a connection between the information processing device 101 and the communication device 151 using a communication method other than Wi-Fi, such as BLE. In this form, the information processing device 101 can connect with the communication device 151 via BLE while maintaining a Wi-Fi connection with the connected AP. That is, it can transmit the connection information of the currently connected access point as connection information for the connected AP. In this form as well, a communication protocol different from DPP is used.

[0149] Furthermore, in the above-described embodiment, S207 described a configuration in which various information is acquired via a Wi-Fi connection between the access point, which is enabled by the communication device 151 operating in network setup mode, and the information processing device 101. However, the embodiment is not limited to this configuration. The information may also be acquired by reading a QR code as in S220, or via communication using other communication methods such as NFC or BLE.

[0150] In addition, the above-described embodiments can also be realized by performing the following process: sharing software (programs) that realize the functions of the above-described embodiments with a system or device via a network or various storage media, and having the computer (CPU, MPU, etc.) of that system or device read and execute the program. The program may be executed on a single computer or by having multiple computers work together. Furthermore, it is not necessary to implement all of the above-described processes in software; some or all of the processes may be implemented in hardware such as an ASIC. Also, the CPU is not limited to a single CPU that performs all the processing; multiple CPUs may work together as appropriate to perform the processing. [Explanation of Symbols]

[0151] 101 Information Processing Device 103 CPU 151 Communication equipment

Claims

A communication device that is communicable with an information processing device and operable in a first state capable of performing first communication with the information processing device according to a first protocol and a second state capable of performing second communication with the information processing device according to a second protocol different from the first protocol, a first acquisition means for acquiring, from the information processing device via the first communication, connection information for the communication device to connect to an access point when the communication device is operating in the first state; a second acquisition means for acquiring, from the information processing device via the second communication, connection information for the communication device to connect to an access point when the communication device is operating in the second state; an establishment means for establishing a connection between the communication device and the access point using the connection information; a first stop means for stopping both the first state and the second state based on the acquisition of the connection information via the first communication in a state where the communication device is operating in the first state and the second state in parallel; A communication device, characterized by comprising the above. Based on the acquisition of the connection information via the first communication and the establishment of a connection between the communication device and the access point using the connection information in a state where the communication device is operating in the first state and the second state in parallel, both the first state and the second state are stopped, The communication device according to claim 1, characterized by the above. a control means for controlling to continue without stopping the second state based on the acquisition of the connection information via the first communication but the failure to establish a connection between the communication device and the access point using the connection information in a state where the communication device is operating in the first state and the second state in parallel; The communication device according to claim 1, further characterized by comprising the above. a second stop means for stopping the first state based on the acquisition of the connection information via the first communication but the failure to establish a connection between the communication device and the access point using the connection information in a state where the communication device is operating in the first state and the second state in parallel; The communication device according to claim 3, further characterized by comprising the above.

5. The communication device operates in parallel in the first state and the second state. When the connection information is obtained via the first communication, if the establishment of the connection between the communication device and the access point based on the connection information obtained via the first communication fails a predetermined number of times or more, the first state is stopped. The communication device according to claim 4, characterized in that.

6. The communication device operates in parallel in the first state and the second state. Based on the fact that the connection information is obtained via the second communication, there is a second stopping means for stopping the first state and the second state. The communication device according to claim 1, further comprising.

7. The communication device operates in parallel in the first state and the second state. Based on the fact that the connection information is obtained via the second communication, the communication device according to claim 1 further comprises a third stopping means for stopping both the first state and the second state.

8. Based on the fact that the connection between the communication device and the access point using the connection information obtained via the first communication is not established, there is an updating means for updating the channel information included in the information used for communication with the information processing device according to the first protocol, and an executing means for executing the connection between the communication device and the access point using the connection information again. The communication device according to claim 1, further comprising.

7. The communication device according to claim 1, further comprising.

8. The communication device according to claim 1, further comprising a fourth stopping means for stopping the first state based on the fact that a predetermined time has elapsed since the operation in the first state was started.

9. The communication device according to claim 1, further comprising a fifth stopping means for stopping the second state based on the fact that a predetermined time has elapsed since the operation in the second state was started.

10. The communication device according to claim 1, further comprising a printing means for executing printing based on a print job received from the information processing device via the access point to which the communication device is connected.

12. The communication device according to claim 1, wherein the first interface used in the first communication and the second interface used in the second communication are different interfaces.

13. One wireless chip is mounted on the communication device, The communication device according to claim 12, wherein the first communication by the first interface and the second communication by the second interface are realized by one wireless chip.

14. The communication device according to claim 13, wherein the one wireless chip switches between a state of communicating via the first interface and a state of communicating via the second interface in a time-division manner when the communication device is operating in both the first state and the second state.

15. A plurality of wireless chips are mounted on the communication device, The communication device according to claim 12, wherein the first communication by the first interface is realized by a first wireless chip among the plurality of wireless chips, and the second communication by the second interface is realized by a second wireless chip different from the first wireless chip among the plurality of wireless chips.

16. The communication device according to claim 15, wherein a state in which the first wireless chip communicates via the first interface and a state in which the second wireless chip communicates via the second interface operate in parallel.

17. The communication device according to claim 1, wherein the connection information is information including at least one of the SSID of the access point, the encryption method, and the password or public key information.

18. When the communication device can execute communication with the information processing device according to the second protocol, the connection information for connecting to the access point is transmitted to the communication device via communication with the information processing device according to the second protocol, The communication device according to claim 1, wherein based on the fact that the communication device cannot execute communication with the information processing device according to the second protocol, the connection information for connecting to the access point is transmitted to the communication device via communication with the information processing device according to the first protocol.

19. The communication device according to claim 1, further comprising generation means for generating information used for communication with the communication device according to the first protocol based on the start of the first state.

20. The communication device according to claim 19, wherein the information used for communication with the communication device according to the first protocol includes at least one of identification information of the communication device, public key information, and channel information used for communication between the information processing device and the communication device according to the first protocol.

21. The communication device according to claim 19, further comprising transmission means for transmitting the information used for communication with the communication device according to the first protocol via communication between the information processing device and the communication device according to the second protocol.

22. The communication device according to claim 19, further comprising display means for displaying a QR code (registered trademark) for causing the information processing device to acquire the information used for communication with the communication device according to the first protocol.

23. The communication device according to claim 1, wherein the first protocol is a Device Provisioning Protocol.

24. The communication device according to claim 1, wherein the first protocol is a Hyper Text Transfer Protocol.

25. The communication device according to claim 1, wherein the second protocol is a Simple Network Management Protocol.

26. The communication device according to claim 1, wherein the second protocol is a Hyper Text Transfer Protocol.

27. The communication device according to claim 1, wherein the communication between the information processing device and the communication device according to the first protocol and the communication between the information processing device and the communication device according to the second protocol are communications based on IEEE802.

11.

28. A control method for a communication device that is capable of communicating with an information processing device and is operable in a first state in which a first communication with the information processing device according to a first protocol can be executed and a second state in which a second communication with the information processing device according to a second protocol different from the first protocol can be executed, comprising: When the communication device is operating in the first state, a first acquisition step of acquiring connection information for the communication device to connect to an access point from the information processing device via the first communication; When the communication device is operating in the second state, a second acquisition step of acquiring connection information for the communication device to connect to an access point from the information processing device via the second communication; An establishment step of establishing a connection between the communication device and the access point using the connection information; A first stop step of stopping both the first state and the second state based on the acquisition of the connection information via the first communication in a state where the communication device is operating in the first state and the second state in parallel; A control method characterized by comprising the steps.

29. A program characterized by storing a program for causing a computer to function as each means of the communication device according to claim 1.