US-12625697-B2 - Method for automatically updating firmware and host device using the same
Abstract
The embodiments of the disclosure provide a method for automatically updating a firmware and a host device. The method includes: accessing, by the host device, a target firmware from at least one detachable I/O device connected with the host device; and updating, by the host device, a host firmware of the host device based on the target firmware.
Inventors
- Po-Hung Lin
- Chien-Yu LAI
- Chi-ting Chang
- Wei-Hsi HSU
Assignees
- MOXA INC.
Dates
- Publication Date
- 20260512
- Application Date
- 20240417
Claims (16)
- 1 . A method for automatically updating a firmware, applied to a host device, comprising: accessing, by the host device, a target firmware from at least one detachable I/O device connected with the host device; in response to determining, by a processor of the host device, that all of the at least one detachable I/O device connected with the host device are not recognizable to the host device, accessing the target firmware from the at least one detachable I/O device connected with the host device; and updating, by the host device and without connecting with any external storage device, a host firmware of the host device based on the target firmware.
- 2 . The method according to claim 1 , further comprising: determining a latest firmware stored on the at least one detachable I/O device as the target firmware.
- 3 . The method according to claim 1 , wherein accessing the target firmware from the at least one detachable I/O device connected with the host device comprises: in response to determining that a first detachable I/O device is connected with the host device as one of the at least one detachable I/O device, accessing, by the host device, a first firmware associated with the first detachable I/O device from the first detachable I/O device as the target firmware.
- 4 . The method according to claim 3 , further comprising: in response to determining that the first detachable I/O device is not recognizable to the host device, accessing the first firmware associated with the first detachable I/O device from the first detachable I/O device as the target firmware.
- 5 . The method according to claim 4 , further comprising: in response to determining that the identifier of the first detachable I/O device is not on the compatible list of the host device, determining that the first detachable I/O device is not recognizable to the host device.
- 6 . The method according to claim 1 , further comprising: in response to determining a firmware updating function has been manually triggered, accessing the target firmware from the at least one detachable I/O device connected with the host device.
- 7 . The method according to claim 6 , further comprising: in response to determining that a control element disposed on the host device is triggered, determining that the firmware updating function has been triggered.
- 8 . The method according to claim 1 , wherein the host device does not comprise any communication interface and any connecting interface connectable with any external storage device.
- 9 . A host device, comprising: a non-transitory storage circuit, storing a program code; and a processor, coupled to the non-transitory storage circuit and accessing the program code to perform: accessing a target firmware from at least one detachable I/O device connected with the host device; in response to determining that all of the at least one detachable I/O device connected with the host device are not recognizable to the host device, accessing the target firmware from the at least one detachable I/O device connected with the host device and updating a host firmware of the host device based on the target firmware without connecting with any external storage device.
- 10 . The host device according to claim 9 , wherein the processor further performs: determining a latest firmware stored on the at least one detachable I/O device as the target firmware.
- 11 . The host device according to claim 9 , wherein the processor performs: in response to determining that a first detachable I/O device is connected with the host device as one of the at least one detachable I/O device, accessing, by the host device, a first firmware associated with the first detachable I/O device from the first detachable I/O device as the target firmware.
- 12 . The host device according to claim 11 , wherein the processor further performs: in response to determining that the first detachable I/O device is not recognizable to the host device, accessing the first firmware associated with the first detachable I/O device from the first detachable I/O device as the target firmware.
- 13 . The host device according to claim 12 , wherein the processor further performs: in response to determining that the identifier of the first detachable I/O device is not on the compatible list of the host device, determining that the first detachable I/O device is not recognizable to the host device.
- 14 . The host device according to claim 9 , wherein the processor further performs: in response to determining a firmware updating function has been manually triggered, accessing the target firmware from the at least one detachable I/O device connected with the host device.
- 15 . The host device according to claim 14 , wherein the processor further performs: in response to determining that a control element disposed on the host device is triggered, determining that the firmware updating function has been triggered.
- 16 . The host device according to claim 9 , wherein the host device does not comprise any communication interface and any connecting interface connectable with any external storage device.
Description
BACKGROUND 1. Field of the Invention The present disclosure generally relates to a mechanism for providing a reality service, in particular, to a method for automatically updating a firmware and a host device. 2. Description of Related Art Conventionally, it is common for many connected devices or embedded systems to update the firmware thereof over the Internet. In general, these devices may need to connect to the Internet through, for example, Wi-Fi, Ethernet, cellular networks, or other built-in communication interfaces, and then these devices may download the required firmware from the Internet and accordingly update the firmware thereof. However, for some devices without the abilities to access to the Internet (e.g., lacking of built-in communication interfaces), the above way may not be feasible. Specifically, for a device without any communication interface, the device may need to be connected with external communication interfaces, such that the device may access the Internet via the external communication interfaces. However, in a case where the device cannot recognize the external communication interfaces connected thereto, the device may not be able to correctly interact with the external communication interfaces connected thereto in the first place, not to mention to access the Internet via the external communication interfaces. SUMMARY OF THE INVENTION Accordingly, the disclosure is directed to a method for automatically updating a firmware and a host device, which may be used to solve the above technical problems. The embodiments of the disclosure provide a method for automatically updating a firmware, applied to a host device. The method includes: accessing, by the host device, a target firmware from at least one detachable I/O device connected with the host device; and updating, by the host device, a host firmware of the host device based on the target firmware. The embodiments of the disclosure provide a host device including a storage circuit and a processor. The storage circuit stores a program code. The processor is coupled to the storage circuit and accesses the program code to perform: accessing a target firmware from at least one detachable I/O device connected with the host device; and updating a host firmware of the host device based on the target firmware. BRIEF DESCRIPTION OF THE DRAWINGS The accompanying drawings are included to provide a further understanding of the invention, and are incorporated in and constitute a part of this specification. The drawings illustrate embodiments of the invention and, together with the description, serve to explain the principles of the disclosure. FIG. 1 shows a schematic diagram of a host device and several detachable I/O devices according to an embodiment of the disclosure. FIG. 2 shows a flow chart of the method for automatically updating a firmware according to an embodiment of the disclosure. DESCRIPTION OF THE EMBODIMENTS Reference will now be made in detail to the present preferred embodiments of the invention, examples of which are illustrated in the accompanying drawings. Wherever possible, the same reference numbers are used in the drawings and the description to refer to the same or like parts. See FIG. 1, which shows a schematic diagram of a host device and several detachable I/O devices according to an embodiment of the disclosure. In the embodiments of the disclosure, each of the detachable I/O device 11 to 1N (N is a positive integer) can be detachably connected to the host device 100 to provide certain I/O (i.e., input/output) functions. For example, the detachable I/O device 11 may be configured with wired/wireless communication interfaces/circuits (e.g., Ethernet ports, Wi-Fi circuits, etc.) for providing wired/wireless communication functions, such that the host device 100 may access the Internet via the detachable I/O device 11 after the detachable I/O device 11 is connected with the host device 100. Additionally or alternatively, the detachable I/O device 11 may be configured with other interface, such as General Purpose Input Output (GPIO), USB, secure digital (SD) interfaces, but the disclosure is not limited thereto. In one embodiment, the host device 100 may be disposed with docking portions 1061-106N, which can be respectively used to be docking with the corresponding docking portions 11a-1Na on the detachable I/O device 11-1N. For example, the docking portion 11a on the detachable I/O device 11 can be detachably docked/connected with the docking portion 1061 on the host device 100. Likewise, the docking portion 1Na on the detachable I/O device 1N can be detachably docked/connected with the docking portion 106N on the host device 100. In various embodiments, the docking portions 1061-106N and the corresponding docking portions 11a-1Na can be designed in various forms based on the designer's requirements, such as corresponding magnetic portions, buckles, clamps, etc. In some embodiments, the host device 100 can be conne