Many commercial systems and consumer products rely on embedded computer systems to perform their functions. Embedded computer systems often take the form of general purpose microprocessors or microcontrollers to carry out specialized functions by firmware, i.e., software instructions stored in a nonvolatile memory. Because this design does not rely on customized hardware components, it offers flexibility and a reduced-time to market. In many cases, the firmware may be updated to fix software defects or to introduce new features. However, such updates carry a risk—if for some reason the nonvolatile memory becomes corrupted, the embedded system ceases to operate properly. Typically, such a failure is difficult to correct because the embedded system ceases communicating. The consequences of such a failure can be substantial in many systems where manual access to the embedded system is limited, e.g., industrial equipment in hazardous environments, spacecraft, and borehole logging instrumentation. Yet it is precisely in such environments where such failures are prone to occur due to communications fade-outs, power fluctuations, or stray radiation. Existing update methods do not adequately insure against the risk of failure.
For a detailed description of illustrative embodiments of the invention, reference will now be made to the accompanying drawings in which:
Certain terms are used throughout the following description and claims to refer to particular system components. As one skilled in the art will appreciate, companies may refer to a component by different names. This document does not intend to distinguish between components that differ in name but not function. In the following discussion and in the claims, the terms “Including” and “comprising” are used in an open-ended fashion, and thus should be interpreted to mean “including, but not limited to . . . .” Also, the term “couple” or “couples” is intended to mean either an indirect or direct electrical connection. Thus, if a first device couples to a second device, that connection may be through a direct electrical connection, or through an indirect electrical connection via other devices and connections. Further, the term “update” is intended to encompass modifiations of any kind, including an “upgrade,” an “overwrite,” etc. Further still, in at least some cases, the terms “software” and “software image” may be used interchangeably. Yet further still, the term “flag” may be interpreted to mean any suitable type of indicator, including a single bit, a set of bits or some other type of indicator.
The following discussion is directed to various embodiments of the invention. Although one or more of these embodiments may be preferred, the embodiments disclosed should not be interpreted, or otherwise used, as limiting the scope of the disclosure, including the claims. In addition, one skilled in the art will understand that the following description has broad application, and the discussion of any embodiment is meant only to be illustrative of that embodiment, and not intended to suggest that the scope of the disclosure, including the claims, is limited to that embodiment.
Described herein is a technique by which software stored on an embedded computer system is updated with little or no risk of system infirmity. More specifically, the technique enables the software to be updated such that, even in the event that the software update is interrupted, the system still maintains operability. The disclosed systems and methods are particularly suitable for use with oilfield equipment including logging tools that are part of a larger assembly.
A LWD tool 26 is integrated into the bottom-hole assembly near the bit 14. As the bit extends the borehole through the formations, logging tool 26 collects measurements relating to various formation properties as well as the bit position and various other drilling conditions. The logging tool 26 may take the form of a drill collar, i.e., a thick-walled tubular that provides weight and rigidity to aid the drilling process. A telemetry sub 28 may be included to transfer tool measurements to a surface receiver 30 and to receive commands from the surface receiver 30.
At various times during the drilling process, the drill string 8 may be removed from the borehole. Once the drill string has been removed, logging operations can be conducted. Such logging operations are shown in
Any suitable portion of the drill string 8 (e.g., the tool 26) and/or any suitable portion of the sonde 34 may contain processing logic 300 (i.e. an embedded system), an illustrative embodiment of which is shown in
If, by executing the SUA 310, the processor 302 determines (e.g., using the technique described above) that the updated software is available for download (block 402), the method 400 then includes the SUA 310 causing the processor 302 to instruct the bootloader 312 to download the updated software upon the next reboot of the processing logic 300 (block 404). The SUA 310, when executed by the processor 302, causes the processor 302 to program a predefined area of storage 304 with the information needed by the bootloader 312 to download the updated software upon next reboot. In alternative embodiments, the updated software may be downloaded as soon as the processor 302 determines that the updated software is available for download (i.e., prior to a re-boot). In at least some such embodiments, the SUA 310 causes the processor 302 to begin download of the updated application and to program the predefined area of storage 304 with information needed by the bootloader 312 to resume updated software download if the current download is interrupted and the processing logic 300 is re-booted. In such cases, an indicator (e.g., the flag 506, described below) may be used to indicate to the bootloader 312 that the update software download needs to be resumed upon reboot.
Regardless of whether the updated software is downloaded prior to or after a re-boot, the predefined area of storage 304 is programmed using a data structure such as that shown in
The method 400 then includes the SUA 310 causing the processor 302 to re-boot the processing logic 300 (block 406). In some embodiments, the SUA 310 may cause the processor 302 to provide a user of the processing logic 300 the option of re-booting the processing logic 300 at a later time. For example, using a computer coupled to the I/O port 306, the user may be able to specify a future time at which to re-boot the processing logic 300. During re-boot, the status of the flag 506 indicates the status of an associated updated software download. For example, a set flag may indicate that the processing logic 300 re-booted before the downloaded, updated software was properly stored. Alternatively, a set flag may indicate that no software was downloaded at all. Similarly, a reset flag may indicate that updated software was downloaded and properly installed.
Upon re-booting, the bootloader 312 is executed by the processor 302 (block 408). The bootloader 312 is programmed to cause the processor 302 to determine the status of the flag 506 upon execution (block 410). If the processor 302 determines that the flag 506 is set, the bootloader 312 causes the processor 302 to download (or resume downloading) the updated software (block 412) having filename(s) and/or release version(s) that match Fl 504. The updated software is downloaded from the entity whose IP address matches IP address 502. The bootloader 312 may cause the processor 302 to write the downloaded software image or files to an unused portion of the storage 304. Alternatively, the bootloader 312 causes the processor 302 to overwrite a portion of, or all of, software already stored on the storage 304 with the updated software. In some embodiments, such an overwrite includes the replacement of one software image with a different software image.
For example, if, by executing the SUA 310, the processor 302 determines that updated software (having a filename “SOFTWARE_UPDATE.EXE”) is available for download from a server having an IP address of 65.70.55.89, the SUA 310 causes the processor 302 to program an entry 501 in the data structure 500 with the IP address 65.70.55.89 and the filename SOFTWARE_UPDATE.EXE. The SUA 310 also causes the processor 302 to set the flag in the entry 501. Upon reboot, the bootloader 312, in tandem with the processor 302, will detect the set flag and take the set flag as a cue to begin downloading the file SOFTWARE_UPDATE.EXE from the entity at the IP address 65.70.55.89. As previously mentioned, although any type of updated software file(s) may be downloaded (such as the illustrative, executable file mentioned above), entire software images preferably are downloaded.
The bootloader 312 causes the processor 302 to monitor the status of the download and/or storage of the updated software (block 414). In at least some embodiments, the processor 302 monitors the status of the download by, e.g., verifying a checksum of a downloaded software image and verifying that the downloaded image is stored in non-volatile memory.
If the download and/or storage process is interrupted for any reason (e.g., events that leave the software only partially installed or updated, such as a power failure, a hardware or software failure, interconnect problems, operator/user error, etc.) or is otherwise unsuccessful (block 416), the bootloader 312 prevents the processor 302 from altering the status of the flag 506. Instead, the flag 506 is kept in a “set” state (block 418). In this way, upon re-start of the processing logic 300, the bootloader 312 determines the flag 506 is still set, indicating that the updated software has not yet been property downloaded and stored to the storage 304. In that case, the bootloader 312 may cause the processor 302 to re-start the download and storage operation altogether. Preferably, however, the boottoader 312 causes the processor 302 to resume the previous download/storage operation.
The previous download/storage operation may be resumed using the data structure 500. Although not specifically shown in
When the processor 302 determines that the updated software has been properly downloaded and stored to storage 304 (block 416), the bootloader 312 causes the processor 302 to reset the flag 506 (block 420). Because the flag 506 is no longer set, at the next re-boot, the processor 302 will not attempt to download the updated software. After the bootloader 312 causes the processor 302 to reset the flag 506 (block 420), the method 400 includes the bootloader loading the OS 308 (block 422).
In some cases, multiple flags in multiple entries 501 may be set. Each set flag may be associated with a different software update that is to be performed. In such cases, the steps of blocks 406 to 420 of
In some cases, a hardware or software glitch may prevent the successful update of software. In such cases, at least some of the steps of process 400 may be repeatedly performed with little or no success. Accordingly, the bootloader 312 may be programmed to quit attempting software updates after a predetermined number of attempts. For example, the bootloader 312 may be programmed to quit attempting software updates after ten update attempts have failed. In such a case, after the tenth update attempt fails, the bootloader 312 may cause the processor 302 to cease from further update attempts (e.g., by resetting the corresponding flag in the data structure 500) and may further cause the processor 302 to generate an alert signal. In some embodiments, such an alert signal may take the form of a lit light-emitting-diode (LED) (not specifically shown) coupled to the processing logic 300. In other embodiments, such an alert signal may take the form of an electronic message or signal delivered to an electronic device (e.g., a computer) external to the processing logic 300 (e.g., the facility 44) via the I/O port 306. Upon receiving the signal, a user may then attempt to correct the glitch and resume attempts to update the software.
The process described in context of
In some embodiments, the processing logic 300 is included in the drill string 8, such as in the tool 26. A partially disassembled tool 600 is shown in
In some embodiments, the sidewall readout port 602 may couple to the I/O port 306. In other embodiments, the sidewall readout port 602 may be considered to be the I/O port 306. A more detailed view of the sidewall readout port 602 is provided in
The above discussion is meant to be illustrative of the principles and various embodiments of the present invention. Numerous variations and modifications will become apparent to those skilled in the art once the above disclosure is fully appreciated. It is intended that the following claims be interpreted to embrace all such variations and modifications.
Filing Document | Filing Date | Country | Kind | 371c Date |
---|---|---|---|---|
PCT/US06/62311 | 12/19/2006 | WO | 00 | 6/11/2009 |