Method for controlling MWD tool in bottom hole assembly

11225864 · 2022-01-18

Assignee

Inventors

Cpc classification

International classification

Abstract

A method for controlling a MWD tool in a bottom hole assembly in a borehole includes the steps of installing a plurality of firmware in the MWD tool, turning a mud pump on an earth surface ON or OFF according to a pre-determined sequence; determining a mud flow in the borehole to be ON or OFF so as to form a binary signal; and sending the binary signal to the MWD tool. The plurality of firmware are pre-programmed to perform a plurality of tasks while the binary signal executes one of the plurality of firmware in the MWD tool.

Claims

1. A method for controlling a MWD tool in a bottom hole assembly in a borehole, comprising: installing a plurality of firmware in the MWD tool, wherein the plurality of firmware are pre-programmed to perform a plurality of tasks; turning a mud pump on an earth surface ON or OFF according to a pre-determined sequence; determining a mud flow in the borehole to be ON or OFF so as to form a binary signal; and sending the binary signal to the MWD tool, wherein the binary signal executes one of the plurality of firmware in the MWD tool, wherein a first task firmware among the plurality of firmware performs a first task and a second task firmware of the plurality of firmware performs a second task, the first task and the second task are different and each controls one of more parameters of the MWD tool, and wherein the one or more parameters are chosen from a number of sensors that are running, a sampling frequency, and combinations thereof.

2. The method according to claim 1, wherein a mud flow sensor in a mud pulser in the bottom hole assembly determines whether the mud flow is ON or OFF.

3. The method according to claim 2, wherein a mud flow sensor driver circuit outputs the binary signal to the MWD tool.

4. The method according to claim 1, wherein the plurality of firmware further comprises a front firmware and a plurality of task firmware, wherein the plurality of task firmware comprises the first task firmware and the second task firmware, and the front firmware is pre-programmed to determine whether or which of the plurality of task firmware to be executed.

5. The method according to claim 4, wherein each of the plurality of task firmware are pre-programmed to run at one of a plurality of temperatures of the bottom hole assembly.

6. The method according to claim 1, wherein turning the mud pump ON or OFF by an operator to cause the execution of the first task firmware or the second task firmware.

7. The method according to claim 6, wherein the execution of the first task firmware or the second task firmware is determined according to a temperature of the bottom hole assembly.

8. The method according to claim 7, wherein the first task firmware is executed when the temperature of the bottom hole assembly is below 180° C. and the second task firmware is executed when the temperature of the bottom hole assembly is between 180° C. and 200° C.

9. The method according to claim 4, wherein at least one of the plurality of task firmware is pre-programmed to run when a battery supplying power to the MWD tool is fully charged and at least one of the plurality of task firmware is pre-programmed to run when the battery supplying power to the MWD tool is exhausted.

Description

BRIEF DESCRIPTION OF THE DRAWINGS

(1) For a more complete understanding of the embodiments described in this disclosure, reference is made to the following detailed description taken in conjunction with the accompanying drawings, in which:

(2) FIG. 1 is a schematic illustration of a drilling rig of the current disclosure;

(3) FIG. 2 is an exemplary encoded wave form of the mud flow;

(4) FIG. 3 is a schematic diagram showing functional blocks and the data structure of the firmware embedded on the MWD tool; and

(5) FIG. 4 is a schematic flow diagram showing the execution of the firmware in the MWD tool.

DETAILED DESCRIPTION

(6) Reference will now be made in detail to several embodiments of the present disclosure(s), examples of which are illustrated in the accompanying figures. It is noted that wherever practicable similar or like reference numbers may be used in the figures and may indicate similar or like functionality. The figures depict embodiments of the present disclosure for purposes of illustration only. One skilled in the art will readily recognize from the following description that alternative embodiments of the structures and methods illustrated herein may be employed without departing from the principles of the disclosure described herein.

(7) FIG. 1 schematically illustrates a drilling operation. The drill string 2 extends from the derrick 1 on the surface into the borehole 3. The drill bit 4 is installed at the distal end of the drill string 2. The BHA 5 is installed above the drill bit 4. The mud pump 6 pumps the mud flow from the mud tank 7 downhole through the drill string 1. The mud flow circulates back to the mud tank 7 via the annulus between the drill string 1 and the borehole 3.

(8) The BHA 5 includes a mud pulser 10, a mud motor (not shown), a measurement-while-drilling (MWD) instruments (not shown), and logging-while-drilling (LWD) instruments (not shown). In this disclosure, the MWD instruments and LWD instruments are collectively referred to as the MWD tool. The MWD tool is powered by the mud motor, the battery, or both the mud motor and the battery (not shown). The MWD tool has one or more internal memory, a microprocessor, software and/or firmware with pre-programed instructions installed on the memory, and input/output communication ports for communications with other tools in the BHA, e.g., a mud pulser. The firmware controls the operation of the MWD tools, e.g., controlling the operation of the sensors.

(9) The mud pulser 10 is in communication with a MWD digital signal processor (DSP) 11. The MWD DSP 11 is connected to a plurality of measurement sensors 12 that measure earth formation information and/or directional information, including gamma ray detectors that measure naturally occurring gamma ray in the formation, directional sensors that monitor inclination and azimuth, etc. The MWD DSP 11 sends encoded commands to the mud pulser 10, which in turn generates pressure pulses that propagates uphole. The pressure transducer 8 is installed in the mud flow passage and detects the pressure pulses. It sends the mud pulse signals to the surface data acquisition system 9, which then decodes the pressure pulse signals to obtain information downhole.

(10) In the embodiment of FIG. 1, the mud pulser 10 includes a pulser driver (not shown), which controls the mechanism that restricts or opens the mud flow passage, such as a solenoid valve or a oscillating shear valve (not shown). The pulser may also include a flow sensor (not shown) that detects the mud flow. In one embodiment, the flow sensor has one or more vibration sensitive devices, such as accelerometers. The flow sensor determines whether the drilling mud is flowing or not based on the acceleration force on the accelerometers and output a binary signal. As a result, the modulated mud flow carries the binary signal, which in turn carries commands from the surface down the borehole.

(11) The flow sensor circuit (not shown) may include a memory, a microprocessor, and input/output communication ports that interface with the MWD DSP firmware and/or with other tools in the BHA. In the embodiment of FIG. 1, the MWD DSP firmware controls the mud pulser 10 and is stored in an onboard memory and run by a microprocessor. The flow sensor circuitry may be located on the same printed circuit board that the pulser driver circuitry is located. Independent from the control signal from the MWD tool to the mud pulser 10, the flow sensor circuit determines the ON or OFF state of the mud flow and sends the binary signal to MWD DSP accordingly.

(12) FIG. 2 shows an exemplary mud flow binary signal output from the flow sensor. It defines an initial OFF time t1 followed by three ON periods within a time period of t2, which in turn is followed by another OFF period t3. This combination of binary signals is used as a command signal to the MWD tool and executes the firmware installed in the memory in the MWD tool. Various combinations of such ON and OFF periods during specific time intervals constitute different flow commands. For example, the command signal of FIG. 2 can be a flow command that initiate a switch between different tasks, i.e., a command to execute certain firmware installed in the MWD tool. More details are provided later in this disclosure.

(13) FIGS. 3 and 4 illustrate the firmware in the MWD system and execution of the firmware. As shown in FIG. 3, there is a front firmware and multiple task firmware (Task Firmware 1 to Task Firmware N) stored in a non-volatile memory such as ROM, EPRROM, or flash memory in the MWD system. The firmware can be saved on different sections of a same memory in a microprocessor or on different interconnected memory throughout the MWD tool. The front firmware and task firmware can receive and/or to decode the command signals from the mud pulser, i.e., flow commands. The front firmware determines which specific task the flow command is directed to while the task firmware executes specific tasks (e.g., for low temperature operation vs. for high temperature operation).

(14) FIG. 3 also shows the data structure in the memory, which includes an index table containing IDs and addresses for the front firmware and the task firmware, with pointers to the sections of memory where the corresponding firmware is saved on. The index table may be a part of the front firmware, which determines the task to be executed (i.e., the active task) and determines its active task ID. The active task ID identifies the address of the specific task amongst Tasks 1 to N (Firmware Address) and points to the section of the memory where the code for the corresponding task is saved on (Firmware Area) and executes the code.

(15) The active task can be an active task currently running or an active task prior to the system is powered off or reset. In one embodiment, the active task ID is saved in the memory. When the flow commend does not command changing tasks, the front firmware reads the active task ID and selects the corresponding task firmware amongst task firmware 1 to N. The front firmware then enters a sleep mode. When the flow command requests changing the active task, e.g., from task 1 to task 2, the front firmware initiates a process to accomplish the switch.

(16) In one embodiment, the front firmware distributes tasks to various task firmware. It may be in a sleep mode when the task firmware is running. When the flow command demands a switch, the currently running task firmware initiates a reset to start the front firmware so the front firmware can assign a task to a different task firmware.

(17) Further details of the operation are provided with reference to FIG. 4, which is a simplified flow chart showing an embodiment of the method to execute the front firmware and the task firmware. As shown in FIG. 4, the front firmware is started in step 401 and run the front task in step 402, and reads the active task ID currently written in the active task ID memory (step 403). In step 404, the front firmware determines whether the active task ID is valid or not. If valid, the front firmware finds the address of the corresponding task firmware and from there finds the corresponding task firmware area to execute the task firmware (step 405). If the active ID is invalid, the front firmware reads the flow command (step 406). If the flow command is valid (a flow command that matches a preset sequence of signals), the front firmware decodes the flow command and determines the content of the flow command (step 407). Once the flow command is decoded, the front firmware assigns the corresponding task and executes the corresponding task firmware (step 408). If the flow command is invalid, the front firmware enters a “self test/debug” mode (step 409) and returns to read the flow command.

(18) During normal operation, one of the task firmware is being executed. When a different task is required, a flow command (such as the one shown in FIG. 2) is sent to the front firmware and the task firmware to announce that a switching of task firmware is pending. Afterwards, a second flow command is sent to the MWD tool to announce which new task is being switched to. In this process, the task firmware detects the flow command (step 501) and determine whether the flow command is valid or not (step 502). If the flow command is not valid, the task firmware continues to run the current task and monitors the flow command until it receives a valid flow command (step 503). Once it is determined that the flow command is valid, the task firmware decodes the flow command (step 504) to obtain the ID of the task being switched to, writes the new task ID as the active ID in the memory (step 505), and then restarts the microprocessor to terminate the current task and hand over the control to the front firmware (step 506).

(19) In some embodiments of this disclosure, exemplary tasks run by task firmware are related to the downhole conditions, such as temperature and pressure in the borehole. For example, Task 1 is designated to run a plurality of sensors at a temperature at or below a certain temperature, e.g., 120° C. or 150° C. The sensors can be for temperature, pressure, flow rate, azimuth, inclination, total H field, total G field, dip angle, etc. Task 1 defines conditions such as which sensors are running, the sampling frequency, data logging frequency, data being transmitting to the surface in real time, data being stored in an internal memory, etc. Task 2 is activated when the downhole temperature each a threshold, e.g., 180° C. Task 2 may change the type, the number, and/or the location of the sensors from Task 1, as well as the other conditions of the sensors. When the downhole temperature surpasses 200° C., Task 2 is switched to Task 3, which executes another set of conditions.

(20) The changing of the task may be initiated by an operator who monitors the downhole temperature. When the temperature reaches a threshold level, the operator turns the mud pump ON or OFF according to a certain sequence to encode the mud flow with the appropriate flow command that switches the active task from Task 1 to Task to or from Task 2 to Task 3.

(21) In other embodiments, the system can be used to test different versions of a task firmware. In one such example, two different versions of the firmware written for Task 3 for operation at or above 200° C. can be installed in the MWD tool. During the drilling operation, the operator can manipulate the mud pump to switch from one version of the firmware to another, while the BHA remain in the bottomhole, avoiding the expensive tripping operation.

(22) Additional scenarios when switching tasks is needed include the status of the battery pack (e.g., fully charged vs. exhausted), the status of formation (relatively uniform formation vs. fast changing formation). The former requires adjusting sensor conditions (e.g., number of sensors, sampling frequency) to reduce power consumption while the latter may require increasing the sampling frequency.

(23) While in the foregoing specification this disclosure has been described in relation to certain preferred embodiments thereof, and many details have been set forth for purpose of illustration, it will be apparent to those skilled in the art that the disclosure is susceptible to alteration and that certain other details described herein can vary considerably without departing from the basic principles of the disclosure. In addition, it should be appreciated that structural features or method steps shown or described in any one embodiment herein can be used in other embodiments as well.