Electronic device and recovery method

CN122946211APending Publication Date: 2026-10-20SCHNEIDER ELECTRIC JAPAN HLDG LTD
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202610424114.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Priority Date
2025-04-14
Filing Date
2026-04-01
Publication Date
2026-10-20

AI Technical Summary

Technical Problem

因此,若USB器件控制器出现了问题,则存在无法消除USB通信错误的问题

Benefits of technology

根据本发明一个方面,即使在器件控制器发生了问题的情况下,也能够恢复主机控制器与器件控制器之间的USB通信。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure FT_1
    Figure FT_1
  • Figure FT_2
    Figure FT_2
  • Figure FT_3
    Figure FT_3
Patent Text Reader

Abstract

The challenge is to restore USB communication between the host controller and the device controller even if the device controller malfunctions. The solution is that in the electronic device (1), the USB device controller (10) outputs a link signal indicating the established state of USB communication between itself and the USB host controller (40). If the reset circuit (20) determines that USB communication is disconnected based on the link signal, it outputs a request signal to restart the USB device controller (10). The USB device controller (10) restarts upon detecting the request signal.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to electronic devices and recovery methods. Background Technology

[0002] In manufacturing environments such as factories, computer equipment establishes communication with various electronic devices to play a crucial role in the system. In recent years, computer equipment has sometimes incorporated USB host controllers, enabling USB communication with electronic devices equipped with USB device controllers via USB cables. However, USB communication errors frequently occur between computer and electronic devices.

[0003] For example, Patent Document 1 discloses a technique for eliminating such USB communication error states. Specifically, in the technique disclosed in Patent Document 1, USB communication occurs between a host device equipped with a USB host controller and an electronic device equipped with a USB device controller. If an error occurs in the USB communication between the host device and the electronic device, the electronic device causes the host device to perform a USB communication bus reset to eliminate the USB communication error.

[0004] Existing technical documents Patent Document 1: Japanese Patent Application Publication No. 2019-061402 Summary of the Invention (The problem that the invention aims to solve) However, the technology disclosed in Patent Document 1 is based on the premise that the USB device controller is functioning normally. Therefore, if the USB device controller malfunctions, there is a problem that USB communication errors cannot be eliminated. Furthermore, if a USB device is not properly recognized during system startup, data packet transmission from the USB host controller to the USB device controller will not occur. Therefore, the USB communication error cannot be recognized, resulting in the inability to detect USB communication interruptions and the inability to self-recover the USB communication connection.

[0005] One aspect of the present invention is to achieve the restoration of USB communication between the host controller and the device controller even if a problem occurs with the device controller.

[0006] (Technical means used to solve the problem) To achieve the above objectives, an electronic device according to one aspect of the present invention includes: a device controller that establishes USB communication with a host controller; and a reset circuit that outputs a request signal requesting the device controller to restart, wherein the device controller outputs a connection signal indicating the establishment state of the USB communication, the reset circuit outputs the request signal when it determines that the USB communication is in a disconnected state based on the connection signal, and the device controller restarts upon detecting the request signal.

[0007] Additionally, one aspect of the present invention is a recovery method for restoring USB communication between a host controller and a device controller, comprising: a link signal output step, wherein the device controller outputs a link signal indicating the establishment state of the USB communication; a determination step, determining whether the USB communication is in a disconnected state based on the link signal; a request signal output step, wherein if the determination step determines that the USB communication is in a disconnected state, a request signal requesting the device controller to restart is output; and a restart step, wherein the device controller restarts upon detecting the request signal.

[0008] (Invention effect) According to one aspect of the invention, USB communication between the host controller and the device controller can be restored even in the event of a problem with the device controller. Attached Figure Description

[0009] Figure 1 This is a block diagram of an example of an electronic device and PC according to Embodiment 1 of the present invention.

[0010] Figure 2 yes Figure 1 The circuit diagram shows an example of a reset circuit in the electronic device shown.

[0011] Figure 3 yes Figure 1 A flowchart illustrating an example of the processing performed by the reset circuit of the electronic device shown.

[0012] Figure 4 yes Figure 3 The flowchart shows an example of step S4.

[0013] Figure 5 This is a block diagram of an example of an electronic device and PC according to Embodiment 2 of the present invention. Detailed Implementation

[0014] [Implementation Method 1] (The structure of electronic device 1) Figure 1This is a block diagram of an example of an electronic device 1 and a PC (Personal Computer) 2 according to Embodiment 1 of the present invention. Figure 2 yes Figure 1 The circuit diagram shows an example of a reset circuit 20 provided by the electronic device 1. Hereinafter, the electronic device 1 and PC2 will be described primarily, but these descriptions also serve as an explanation of a method for restoring USB communication between the USB (Universal Serial Bus) device controller 10 and the USB host controller 40.

[0015] Electronic device 1 is, for example, an audio output device that outputs audio, an IC card reader, or a USB device (device device) such as a USB memory, but it is not limited to these and can also be other types of USB devices. Figure 1 As shown, the electronic device 1 includes a USB device controller 10, a reset circuit 20, and a USB device interface 30.

[0016] The USB device controller 10 is an example of a device controller, which has a control unit 11. The control unit 11 is, for example, a processor such as a CPU (Central Processing Unit). The control unit 11 controls the electronic device 1 and includes an output unit 12. The control unit 11 uses the USB device interface 30 to establish USB communication with the USB host controller 40 of the PC2. In this embodiment, USB communication refers to communication between the USB device controller 10 and the USB host controller 40 based on the USB standard.

[0017] Output unit 12 outputs a link signal indicating the establishment state of USB communication to reset circuit 20 (link signal output step). Here, the establishment state of USB communication refers to either the established or terminated state of USB communication. In this case, output unit 12 continuously outputs a link signal indicating that USB communication has been established while USB communication is in the established state. Additionally, output unit 12 continuously outputs a link signal indicating that USB communication has been terminated while USB communication is in the terminated state.

[0018] Output unit 12 is a control block of control unit 11. The function of output unit 12 can also be implemented by control unit 11 executing a program stored in a memory (not shown) or similar storage unit of the USB device controller 10. Here, the function of output unit 12 can also be implemented by logic circuitry. In this case, control unit 11 can also be a corresponding logic circuit.

[0019] The reset circuit 20 is a circuit that outputs a reset signal to request the USB device controller 10 to restart. The reset signal is an example of a request signal. Alternatively, the reset circuit 20 may be a circuit with, for example, a WDT (Watch Dog Timer) function, such as a reset IC.

[0020] Here, the reset circuit 20 only needs to have a timer function and a reset function when the voltage is lost; for example, it can be a voltage monitor or voltage monitoring circuit with these functions. Figure 2 As shown, the reset circuit 20 has a VDD terminal, a timer start input terminal, a timeout duration setting input terminal, a reset output terminal, a timeout output terminal, and a GND terminal.

[0021] A 5V voltage is applied from PC2 to the VDD terminal via USB device interface 30. Here, USB device interface 30 is connected to USB host interface 50 via VBUS, the power line used to supply power from PC2 to electronic device 1.

[0022] Whether USB communication is connected or disconnected, power is continuously supplied from PC2 to the VDD terminal. Here, electronic device 1 may also have a power supply different from that of PC2, and may also supply 5V voltage to the VDD terminal from the USB device controller 10. Alternatively, electronic device 1 may have its own power supply to power PC2. The reset circuit 20 may also activate its WDT function after a third predetermined time elapsed since the point when voltage is applied to the VDD terminal.

[0023] The link signal output from the output section 12 of the USB device controller 10 is output to the timer start input terminal. The timeout duration setting input terminal is grounded via capacitor C1. The reset output terminal and the timeout output terminal are connected to the USB device controller 10, for example, via an AND circuit (not shown) (if the reset output terminal and the timeout output terminal are open-drain / open-collector output terminals, they can be a wired AND circuit connected with pull-up resistors (not shown). The GND terminal is grounded.

[0024] The reset output terminal and timeout output terminal are each connected to one of the two input terminals of the aforementioned AND circuit. The output terminal of the AND circuit is connected to the USB device controller 10. The signal output from the reset output terminal is low when the voltage at the VDD terminal is less than the reference value, and high when the voltage at the VDD terminal is greater than the reference value. The signal output from the timeout output terminal is either low or high.

[0025] If the signal output from the timeout output terminal changes from a high level to a low level, a low-level signal is output from the timeout output terminal to the AND circuit. At this time, the low-level signal is output from the AND circuit to the USB device controller 10, and this signal becomes a reset signal. The AND circuit can also be included in the reset circuit 20.

[0026] USB device interface 30 is a USB interface used for communication between USB device controller 10 and USB host controller 40. USB device interface 30 is connected to USB host interface 50, for example, via a USB cable (not shown). Thus, USB device interface 30 and USB host interface 50 are connected through multiple signal lines (communication lines) including VBUS, D+, D-, and GND.

[0027] (The composition of PC2) PC2 is an example of a computer device. PC2 can be any computer device equipped with a USB host controller 40. Alternatively, electronic device 1 may not be connected to PC2, but to a computer device such as an HMI (Human Machine Interface) device, a smartphone, or a tablet computer.

[0028] PC2 includes a USB host controller 40 and a USB host interface 50. The USB host controller 40 is an example of a host controller and includes a control unit 41. The control unit 41 is, for example, a processor such as a CPU, used to control PC2. PC2 may also have a host controller instead of the USB host controller 40. In this case, the host controller is not limited to USB communication and can be used for other purposes.

[0029] The control unit 41 uses the USB host interface 50 to establish USB communication with the USB device controller 10 of the electronic device 1. Specifically, in order to establish USB communication between the USB host controller 40 and the USB device controller 10, the USB host controller 40 sends a request (e.g., a data packet) to the USB device controller 10. Then, the USB device controller 10 responds to the request (e.g., sends back a data packet), thereby establishing USB communication. The USB host interface 50 is a USB interface, which is the communication interface for communication between the USB host controller 40 and the USB device controller 10.

[0030] (Processing of electronic device 1) Figure 3 yes Figure 1The flowchart illustrates an example of a process performed by the reset circuit 20 of the electronic device 1. Here, we envision a scenario where PC2 is started up after the electronic device 1 and PC2 have been connected, and a scenario where the electronic device 1 is connected to the operating PC2. In this scenario, power is supplied from PC2 to the electronic device 1, and thus... Figure 3 As shown, the reset circuit 20 activates its WDT function (S1). After activating the WDT function, the reset circuit 20 determines whether the link signal output from the output unit 12 indicates that USB communication has been established (S2).

[0031] If the reset circuit 20 determines that the link signal indicates a disconnection of USB communication ("No" in S2), then the reset circuit 20 determines whether the WDT has timed out (S5). Specifically, the reset circuit 20 determines whether a specified period has elapsed since the point at which it determined that the link signal indicated a disconnection of USB communication.

[0032] The specified period refers to the timeout duration set in the WDT function of the reset circuit 20. The timeout duration can be adjusted by the capacitance of capacitor C1 connected to the timeout duration setting input terminal. In addition, the timeout duration is set to be longer than the time constant of the reset circuit 20 (the duration from when the condition is met until the reset signal is output).

[0033] Here, we envision a scenario where the voltage at the VDD terminal is lower than the reference value, causing the signal output from the reset output terminal to change from a high level to a low level. In this case, the time constant of the reset circuit 20 refers to the duration from the point when the voltage at the VDD terminal becomes higher than the reference value until the signal output from the reset output terminal changes from a low level to a high level.

[0034] If the reset circuit 20 determines that the WDT has timed out (yes in S5), the reset circuit 20 outputs a reset signal (S6: request signal output step). Specifically, if the reset circuit 20 determines that a specified period has elapsed since the point in time when it determined that the link signal indicated the disconnection of USB communication, it determines that "USB communication is in a disconnected state".

[0035] Then, the reset circuit 20 outputs a reset signal to the USB device controller 10. Thus, the reset circuit 20 outputs a reset signal when it determines that USB communication is interrupted based on the connection signal. After the reset circuit 20 outputs the reset signal, its processing proceeds to step S2. The USB device controller 10 restarts upon detecting the reset signal output from the reset circuit 20 (restart step).

[0036] On the other hand, if the reset circuit 20 determines that the WDT has not timed out ("No" in S5), the processing of the reset circuit 20 jumps to step S2. Specifically, if the reset circuit 20 determines that no predetermined period has elapsed since the point at which it determined that the link signal indicated the interruption of USB communication, the processing of the reset circuit 20 jumps to step S2.

[0037] If the reset circuit 20 determines that the link signal indicates that USB communication has been established ("Yes" in S2), then the reset circuit 20 stops its WDT function (S3). At this time, the reset circuit 20 determines that USB communication is in an established state. After stopping the WDT function, the reset circuit 20 executes... Figure 4 The process shown is the process after communication between PC2 and electronic device 1 is established (S4).

[0038] (Processing after communication between PC2 and electronic device 1 is established) Figure 4 yes Figure 3 The flowchart shows an example of step S4. Figure 4 As shown, the reset circuit 20 determines whether the link signal output from the output unit 12 indicates that USB communication has been cut off (S21). If the reset circuit 20 determines that the link signal U indicates that USB communication has been established (in S21, it is "No"), the reset circuit 20 continues the processing of step S21.

[0039] If the reset circuit 20 determines that the connection signal indicates a disconnection of USB communication ("Yes" in S21), then the reset circuit 20 restarts the WDT function (S22). After restarting the WDT function, the reset circuit 20 determines whether the WDT has timed out, similar to step S5 (S23).

[0040] If the reset circuit 20 determines that the WDT has timed out ("Yes" in S23), it outputs a reset signal to the USB device controller 10 in the same manner as in step S6 (S26: Request signal output step). At this time, the reset circuit 20 determines that USB communication is in a disconnected state. After the reset circuit 20 outputs the reset signal, the processing of the reset circuit 20 jumps to step S21. The USB device controller 10 restarts upon detecting the reset signal output from the reset circuit 20 (restart step).

[0041] On the other hand, if the reset circuit 20 determines that the WDT has not timed out ("No" in S23), it determines whether the link signal output from the output unit 12 indicates that USB communication has been established (S24). If the reset circuit 20 determines that the link signal indicates that USB communication has been cut off ("No" in S24), the processing of the reset circuit 20 jumps to the processing of step S23.

[0042] If the reset circuit 20 determines that the link signal indicates that USB communication has been established ("Yes" in S24), then the reset circuit 20 stops its WDT function (S25). At this time, the reset circuit 20 determines that USB communication is in an established state. After the reset circuit 20 stops its WDT function, the processing of the reset circuit 20 jumps to the processing in step S21.

[0043] Reset circuit 20 executes repeatedly Figure 4 The series of processes shown will continue unless power supply from PC2 is stopped. If power supply from PC2 is stopped, reset circuit 20 will terminate. Figure 4 The processing is shown.

[0044] pass Figure 3 As shown in the process, if the link signal is not considered established within the timeout period, that is, if USB communication fails to be established within the timeout period due to identification problems, the reset circuit 20 outputs a reset signal to the USB device controller 10. Therefore, when power is supplied from PC2 to electronic device 1, the reset circuit 20 repeatedly outputs a reset signal whenever a timeout occurs, thus reliably establishing USB communication.

[0045] In addition, through Figure 4 The processing shown enables the WDT function of the reset circuit 20 to be restarted if USB communication is established and then interrupted. Thus, similar to the case where power is supplied from PC2 to electronic device 1, the reset circuit 20 repeatedly outputs a reset signal whenever a timeout occurs, thereby reliably restoring USB communication.

[0046] Through steps S2, S5, and S6, the reset circuit 20 outputs a reset signal when the connection signal indicates a disconnection of USB communication. Through steps S21, S22, S23, and S26, the reset circuit 20 outputs a reset signal when the connection signal indicates a disconnection of USB communication.

[0047] Additionally, through steps S2 and S5, the reset circuit 20 determines whether USB communication is in a disconnected state based on the connection signal (determination step). Through steps S21, S23, and S24, the reset circuit 20 determines whether USB communication is in a disconnected state based on the connection signal (determination step).

[0048] According to the above scheme, if the reset circuit 20 determines that USB communication is in a disconnected state based on the connection signal indicating the establishment state of USB communication, it outputs a reset signal to request the USB device controller 10 to restart. Then, the USB device controller 10 restarts upon detecting the reset signal. Thus, even if a problem occurs with the USB device controller 10, USB communication can be restored.

[0049] In addition, since the USB device controller 10 is restartable, USB communication can be restored in a way that does not affect other electronic devices, even if other electronic devices are connected to the USB host controller 40.

[0050] Furthermore, most USB device controllers 10 have means for detecting the USB communication establishment status with the USB host controller 40. If such a USB device controller 10 is used, its connection signal can be utilized, so there is no need to construct a separate means for determining whether the USB device controller 10 needs to be restarted. Therefore, a mechanism for restoring USB communication can be introduced without significantly increasing costs.

[0051] Here, if electronic device 1 is connected to USB host interface 50 and power is supplied to electronic device 1 from PC2, then USB host controller 40 detects changes in the state of the signal lines. For example, USB host controller 40 detects changes in the state of signal lines D+ and D-.

[0052] When the USB host controller 40 detects a change in the state of a signal line, it sends a data packet to the USB device controller 10. However, if, for example, the control unit 11 of the electronic device 1 is in an abnormal operating state, or if the USB device controller 10 is in the process of starting up, the response of the USB device controller 10 to the data packet will disappear. Therefore, the USB host controller 40 will no longer send data packets to the USB device controller 10.

[0053] This results in a state that is neither a CRC (Cyclic Redundancy Check) error, nor a PID (Packet Identifier) ​​error, nor a bit inversion error—all USB communication errors. Therefore, the PC2 side does not recognize the USB communication error and thus does not recognize the interruption of USB communication, preventing the USB communication from automatically reconnecting.

[0054] Even under such circumstances, the states of signal lines D+ and D- change due to the restart of the USB device controller 10, thus enabling the USB host controller 40 to recognize the electronic device 1. The USB host controller 40 executes the processing performed when the USB device controller 10 restarts, thereby restoring USB communication.

[0055] Furthermore, there is no need to include a circuit in PC2 to control the 5V voltage of VBUS on / off. Also, there is no need in electronic device 1 to use pull-up switches on / off signal lines D+ and D- to make PC2 re-recognize electronic device 1.

[0056] Furthermore, as described above with the USB device controller 10 and reset circuit 20, the functions of electronic device 1 can be implemented using inexpensive hardware. Therefore, no software is required, and no special functions need to be implanted in the operating system (OS) on the PC2 side, the driver software on the PC2 side, or the firmware on the electronic device 1 side. Thus, it is possible to construct a system that utilizes standard software, provides universal compatibility between electronic device 1 and PC2, and enables the restoration of USB communication.

[0057] (Variation Example 1) The USB communication establishment state indicated by the link signal can also be the USB communication established state. In Modification 1, the establishment state indicated by the link signal output from the output unit 12 is the USB communication established state. In this case, during the period when the USB communication is in the establishment state, the output unit 12 outputs the link signal to the reset circuit 20 for each second predetermined duration. Furthermore, during the period when the USB communication is in the disconnected state, the output unit 12 does not output the link signal. Here, for the WDT function of the reset circuit 20, as the timeout duration, a duration greater than the second predetermined duration, i.e., a fourth predetermined duration, needs to be set. That is, the predetermined period involved in steps S5 and S23 is the fourth predetermined duration.

[0058] In variation 1, the reset circuit 20 does not perform... Figure 3Instead of the process shown in step S2, the process determines whether a link signal has been received from the USB device controller 10. If the reset circuit 20 determines that a link signal has been received from the USB device controller 10, then the process in step S3 is executed.

[0059] On the other hand, if the reset circuit 20 determines that it has not received a link signal from the USB device controller 10, it executes step S5. In this case, through steps S5 and S6, the reset circuit 20 outputs a reset signal if it has not received a link signal from the USB device controller 10 within a specified period.

[0060] Furthermore, in variant example 1, the reset circuit 20 does not perform... Figure 4 Instead of the processing in step S21, the process determines whether a link signal has not been received from the USB device controller 10. If the reset circuit 20 determines that a link signal has been received from the USB device controller 10, it continues to determine whether a link signal has not been received. On the other hand, if the reset circuit 20 determines that a link signal has not been received from the USB device controller 10, it executes the processing in step S22.

[0061] Furthermore, in Modified Example 1, the reset circuit 20 does not perform... Figure 4 Instead of the processing in step S24, the process determines whether a link signal has been received from the USB device controller 10. If the reset circuit 20 determines that a link signal has been received from the USB device controller 10, then the process in step S25 is executed.

[0062] On the other hand, if the reset circuit 20 determines that it has not received a link signal from the USB device controller 10, the processing of the reset circuit 20 jumps to step S23. The above processing can be performed by a microcomputer; therefore, in Modification 1, the reset circuit 20 can also be a microcomputer with WDT functionality. Thus, a cheaper reset circuit 20 can be used.

[0063] (Variation Example 2) When USB communication is interrupted, the USB device controller 10 performs a process to restore USB communication. Specifically, as part of the process to restore USB communication, the USB device controller 10 performs: a retry process, adding a first predetermined duration as a standby time, and retrying the USB communication connection.

[0064] Therefore, the USB device controller 10 can perform the process of restoring USB communication before restarting. Thus, if the USB device controller 10 successfully restores USB communication by performing this process, USB communication can be quickly restored. This will be explained in detail below.

[0065] After sending a data packet to the USB device controller 10, the USB host controller 40 will continue to send data packets to the USB device controller 10 a predetermined number of times, even if the response from the USB device controller 10 to the data packet disappears. If the USB host controller 40 still does not receive a response from the USB device controller 10 after sending the predetermined number of data packets, it will stop sending data packets.

[0066] If the USB device controller 10 successfully responds to the data packet sent from the USB host controller 40 by performing the process of restoring USB communication, USB communication can be quickly restored.

[0067] In step S6 or S26, the reset circuit 20 may also output a reset signal after a first predetermined time has elapsed since the point at which the USB communication was determined to be in a disconnected state based on the link signal. Specifically, the reset circuit 20 may, for example, have a delay circuit (not shown) disposed between the aforementioned AND circuit and the timeout output terminal of the reset circuit 20.

[0068] The delay circuit outputs a low-level signal to the AND circuit after a predetermined time elapses following the receipt of the low-level signal from the timeout output terminal. The AND circuit then outputs the low-level signal as a reset signal to the USB device controller 10.

[0069] Furthermore, from the moment the self-delay circuit receives a low-level signal from the timeout output terminal until the first predetermined time has elapsed, the reset circuit 20 determines whether the link signal output from the output unit 12 indicates that USB communication has been established. If the reset circuit 20 determines that the link signal indicates that USB communication has been established within the first predetermined time, the processing of the reset circuit 20 jumps from step S5 to step S2, or from step S23 to step S21. That is, the reset circuit 20 does not output a reset signal.

[0070] On the other hand, if the reset circuit 20 determines that the connection signal indicates the disconnection of USB communication, the processing of the reset circuit 20 proceeds to step S6 or S26. That is, the reset circuit 20 outputs a reset signal after a first predetermined time has elapsed since the point at which it determined that the USB communication was disconnected through step S5 or S23.

[0071] According to the above scheme, the USB device controller 10 performs the process of restoring USB communication when USB communication is interrupted. To this end, the reset circuit 20 outputs a reset signal after a first predetermined time has elapsed since the point at which the interruption of USB communication was determined. Thus, if the USB device controller 10 fails to restore USB communication within the first predetermined time, the USB device controller 10 can be restarted.

[0072] Furthermore, if the reset circuit 20 determines that the link signal indicates that USB communication has been established within the first predetermined time period, it will not output a reset signal. Therefore, if USB communication is successfully established or restored within the first predetermined time period, the reset circuit 20 will not output a reset signal. Thus, compared to the case where the reset circuit 20 outputs a reset signal, USB communication can be established or restored earlier.

[0073] [Implementation Method 2] The following describes Embodiment 2 of the present invention. Here, for ease of explanation, components that have the same function as those described in Embodiment 1 are labeled with the same reference numerals and their descriptions are not repeated. Figure 5 This is a block diagram of an example of the electronic device 1A and PC2 according to Embodiment 2 of the present invention.

[0074] Electronic device 1A is a device larger in scale than electronic device 1. For example... Figure 5 As shown, the difference between electronic device 1A and electronic device 1 is that electronic device 1A has a device controller 10A instead of USB device controller 10. Device controller 10A is not limited to a device controller for USB communication, but can also be used for other purposes, and has a control unit 11A and an output unit 12A.

[0075] Device controller 10A can also send data to output unit 12A while sending data to USB host controller 40. In this case, output unit 12A sends the data received from device controller 10A to USB host controller 40 via USB device interface 30. Here, if the control of electronic device 1A requires real-time performance, device controller 10A may send data to USB host controller 40 via USB device interface 30 instead of output unit 12A.

[0076] Compared to control unit 11, control unit 11A differs in that it does not include an output unit. The functions of control unit 11A are the same as those of control unit 11, except that it lacks the output unit. Control unit 11A may include, for example, a processor such as a CPU, and a microcomputer dedicated to USB communication. Output unit 12A, in addition to the functions of output unit 12, also has the function of communicating with the USB host controller 40. Output unit 12A may be, for example, a single-chip microcomputer. Reset circuit 20 outputs a reset signal to control unit 11A and output unit 12A.

[0077] 〔Summarize〕 An electronic device according to aspect 1 of the present invention includes: a device controller that establishes USB communication with a host controller; and a reset circuit that outputs a request signal requesting the device controller to restart, wherein the device controller outputs a link signal indicating the establishment state of the USB communication, the reset circuit outputs the request signal when it determines that the USB communication is in a disconnected state based on the link signal, and the device controller restarts upon detecting the request signal.

[0078] In an electronic device according to aspect 2 of the present invention based on aspect 1, the following approach may also be adopted: the reset circuit outputs the request signal when the link signal indicates the disconnection of the USB communication as the established state.

[0079] In an electronic device according to aspect 3 of the present invention based on aspect 1, the following approach may also be adopted: if the reset circuit does not receive the link signal indicating the established state of the USB communication from the device controller within a specified period, the request signal may be output.

[0080] In the electronic device according to aspect 4 of the present invention based on any one of aspects 1 to 3, the following approach may also be adopted: when the USB communication is in a disconnected state, the device controller performs the process of restoring the USB communication.

[0081] In the electronic device according to aspect 5 of the present invention based on aspect 4, the following scheme may also be adopted: the reset circuit outputs the request signal after a predetermined time has elapsed since the point at which the USB communication is determined to be in a disconnected state based on the link signal.

[0082] The recovery method according to aspect 6 of the present invention is a recovery method for restoring USB communication between a host controller and a device controller, comprising: a link signal output step, wherein the device controller outputs a link signal indicating the establishment state of the USB communication; a determination step, wherein the device controller determines whether the USB communication is in a disconnected state based on the link signal; a request signal output step, wherein if the determination step determines that the USB communication is in a disconnected state, the device controller outputs a request signal requesting the device controller to restart; and a restart step, wherein the device controller restarts upon detecting the request signal.

[0083] (Additional Notes) This invention is not limited to the foregoing embodiments. Various modifications can be made within the scope of the technical concept shown in the entire specification. Embodiments obtained by appropriately combining the technical means disclosed in different embodiments are also included within the technical scope of this invention.

[0084] <Explanation of Figure Markers> 1. 1A Electronic Devices 10USB Device Controller 10A Device Controller 12, 12A Output Section 20 Reset Circuit 40 USB host controller (host controller).

Claims

1. An electronic device comprising: The device controller establishes USB communication with the host controller; and The reset circuit outputs a request signal to restart the device controller. and, The device controller outputs a connection signal indicating the establishment status of the USB communication. The reset circuit outputs the request signal when it determines that the USB communication is disconnected based on the link signal. The device controller restarts upon detecting the request signal.

2. The electronic device according to claim 1, wherein, The reset circuit outputs the request signal when the link signal indicates that the USB communication has been cut off as the established state.

3. The electronic device according to claim 1, wherein, If the reset circuit does not receive the link signal indicating the established state of the USB communication from the device controller within a specified period, it outputs the request signal.

4. The electronic device according to any one of claims 1 to 3, wherein, The device controller performs a process to restore USB communication when the USB communication is interrupted.

5. The electronic device according to claim 4, wherein, The reset circuit outputs the request signal after a predetermined period of time has elapsed since the point at which the USB communication is determined to be in a disconnected state based on the link signal.

6. A recovery method for restoring USB communication between a host controller and a device controller, the recovery method comprising: In the link signal output step, the device controller outputs a link signal indicating the establishment status of the USB communication; The determination step involves determining whether the USB communication is in a disconnected state based on the connection signal. The request signal output step involves outputting a request signal to the device controller to restart if the USB communication is determined to be in a disconnected state after the determination step. as well as In the restart step, the device controller restarts upon detecting the request signal.

Citation Information

Patent Citations

  • Electronic apparatus, communication control method and program

    JP2019061402A