|
@@ -900,39 +900,129 @@ |
|
|
}, |
|
|
}, |
|
|
{ |
|
|
{ |
|
|
"cell_type": "code", |
|
|
"cell_type": "code", |
|
|
"execution_count": 1, |
|
|
|
|
|
|
|
|
"execution_count": 4, |
|
|
"metadata": {}, |
|
|
"metadata": {}, |
|
|
"outputs": [ |
|
|
"outputs": [ |
|
|
{ |
|
|
{ |
|
|
"name": "stdout", |
|
|
"name": "stdout", |
|
|
"output_type": "stream", |
|
|
"output_type": "stream", |
|
|
"text": [ |
|
|
"text": [ |
|
|
"\t\tcall json%get(p,'ElevatorConnectionPossible',pval)\n", |
|
|
|
|
|
"\t\tcall json%get(pval,data%Equipments%UnityInputs%ElevatorConnectionPossible)\n", |
|
|
|
|
|
"\t\tcall json%get(p,'JointConnectionPossible',pval)\n", |
|
|
|
|
|
"\t\tcall json%get(pval,data%Equipments%UnityInputs%JointConnectionPossible)\n", |
|
|
|
|
|
"\t\tcall json%get(p,'IsKellyBushingSetInTable',pval)\n", |
|
|
|
|
|
"\t\tcall json%get(pval,data%Equipments%UnityInputs%IsKellyBushingSetInTable)\n", |
|
|
|
|
|
"\t\tcall json%get(p,'ElevatorPickup',pval)\n", |
|
|
|
|
|
"\t\tcall json%get(pval,data%Equipments%UnityInputs%ElevatorPickup)\n", |
|
|
|
|
|
"\t\tcall json%get(p,'NearFloorPosition',pval)\n", |
|
|
|
|
|
"\t\tcall json%get(pval,data%Equipments%UnityInputs%NearFloorPosition)\n", |
|
|
|
|
|
"\t\tcall json%get(p,'SingleSetInMouseHole',pval)\n", |
|
|
|
|
|
"\t\tcall json%get(pval,data%Equipments%UnityInputs%SingleSetInMouseHole)\n", |
|
|
|
|
|
"\t\tcall json%get(p,'TdsConnectionPossible',pval)\n", |
|
|
|
|
|
"\t\tcall json%get(pval,data%Equipments%UnityInputs%TdsConnectionPossible)\n", |
|
|
|
|
|
"\t\tcall json%get(p,'TdsStemIn',pval)\n", |
|
|
|
|
|
"\t\tcall json%get(pval,data%Equipments%UnityInputs%TdsStemIn)\n" |
|
|
|
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.AssignmentSwitch',data%Equipments%DrillingConsole%AssignmentSwitch,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: AssignmentSwitch\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.EmergencySwitch',data%Equipments%DrillingConsole%EmergencySwitch,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: EmergencySwitch\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.RTTorqueLimitKnob',data%Equipments%DrillingConsole%RTTorqueLimitKnob,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: RTTorqueLimitKnob\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.MP1CPSwitchI',data%Equipments%DrillingConsole%MP1CPSwitchI,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: MP1CPSwitchI\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.MP1CPSwitchT',data%Equipments%DrillingConsole%MP1CPSwitchT,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: MP1CPSwitchT\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.MP1CPSwitch',data%Equipments%DrillingConsole%MP1CPSwitch,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: MP1CPSwitch\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.MP1ThrottleUpdate',data%Equipments%DrillingConsole%MP1ThrottleUpdate,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: MP1ThrottleUpdate\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.MP1Throttle',data%Equipments%DrillingConsole%MP1Throttle,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: MP1Throttle\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.MP2SwitchI',data%Equipments%DrillingConsole%MP2SwitchI,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: MP2SwitchI\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.MP2SwitchT',data%Equipments%DrillingConsole%MP2SwitchT,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: MP2SwitchT\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.MP2Switch',data%Equipments%DrillingConsole%MP2Switch,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: MP2Switch\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.MP2ThrottleUpdate',data%Equipments%DrillingConsole%MP2ThrottleUpdate,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: MP2ThrottleUpdate\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.MP2Throttle',data%Equipments%DrillingConsole%MP2Throttle,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: MP2Throttle\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.DWSwitch',data%Equipments%DrillingConsole%DWSwitch,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: DWSwitch\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.DWThrottle',data%Equipments%DrillingConsole%DWThrottle,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: DWThrottle\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.RTSwitch',data%Equipments%DrillingConsole%RTSwitch,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: RTSwitch\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.RTThrottle',data%Equipments%DrillingConsole%RTThrottle,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: RTThrottle\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.DWBreak',data%Equipments%DrillingConsole%DWBreak,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: DWBreak\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.PreviousDWBreak',data%Equipments%DrillingConsole%PreviousDWBreak,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: PreviousDWBreak\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.ForceBreak',data%Equipments%DrillingConsole%ForceBreak,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: ForceBreak\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.DWAcceleretor',data%Equipments%DrillingConsole%DWAcceleretor,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: DWAcceleretor\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.DWTransmisionLever',data%Equipments%DrillingConsole%DWTransmisionLever,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: DWTransmisionLever\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.DWPowerLever',data%Equipments%DrillingConsole%DWPowerLever,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: DWPowerLever\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.TongLever',data%Equipments%DrillingConsole%TongLever,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: TongLever\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.RTTransmissionLever',data%Equipments%DrillingConsole%RTTransmissionLever,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: RTTransmissionLever\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.DWClutchLever',data%Equipments%DrillingConsole%DWClutchLever,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: DWClutchLever\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.EddyBreakLever',data%Equipments%DrillingConsole%EddyBreakLever,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: EddyBreakLever\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.AutoDW',data%Equipments%DrillingConsole%AutoDW,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: AutoDW\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.GEN1',data%Equipments%DrillingConsole%GEN1,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: GEN1\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.GEN2',data%Equipments%DrillingConsole%GEN2,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: GEN2\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.GEN3',data%Equipments%DrillingConsole%GEN3,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: GEN3\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.GEN4',data%Equipments%DrillingConsole%GEN4,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: GEN4\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.Permission_OpenKellyCock',data%Equipments%DrillingConsole%Permission_OpenKellyCock,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: Permission_OpenKellyCock\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.OpenKellyCock',data%Equipments%DrillingConsole%OpenKellyCock,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: OpenKellyCock\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.Permission_CloseKellyCock',data%Equipments%DrillingConsole%Permission_CloseKellyCock,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: Permission_CloseKellyCock\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.CloseKellyCock',data%Equipments%DrillingConsole%CloseKellyCock,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: CloseKellyCock\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.Permission_OpenSafetyValve',data%Equipments%DrillingConsole%Permission_OpenSafetyValve,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: Permission_OpenSafetyValve\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.OpenSafetyValve',data%Equipments%DrillingConsole%OpenSafetyValve,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: OpenSafetyValve\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.Permission_CloseSafetyValve',data%Equipments%DrillingConsole%Permission_CloseSafetyValve,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: Permission_CloseSafetyValve\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.CloseSafetyValve',data%Equipments%DrillingConsole%CloseSafetyValve,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: CloseSafetyValve\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.Permission_IRSafetyValve',data%Equipments%DrillingConsole%Permission_IRSafetyValve,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: Permission_IRSafetyValve\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.IRSafetyValve',data%Equipments%DrillingConsole%IRSafetyValve,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: IRSafetyValve\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.Permission_IRIBop',data%Equipments%DrillingConsole%Permission_IRIBop,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: Permission_IRIBop\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.IRIBop',data%Equipments%DrillingConsole%IRIBop,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: IRIBop\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.LatchPipe',data%Equipments%DrillingConsole%LatchPipe,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: LatchPipe\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.UnlatchPipe',data%Equipments%DrillingConsole%UnlatchPipe,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: UnlatchPipe\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.Swing',data%Equipments%DrillingConsole%Swing,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: Swing\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.FillMouseHole',data%Equipments%DrillingConsole%FillMouseHole,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: FillMouseHole\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.Slips',data%Equipments%DrillingConsole%Slips,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: Slips\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.BrakeLeverCoefficient',data%Equipments%DrillingConsole%BrakeLeverCoefficient,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: BrakeLeverCoefficient\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.HideDrillingBrake',data%Equipments%DrillingConsole%HideDrillingBrake,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: HideDrillingBrake\" \n", |
|
|
|
|
|
"\t\tcall json%get('Equipments.Drilling.ParkingBrakeBtn',data%Equipments%DrillingConsole%ParkingBrakeBtn,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: ParkingBrakeBtn\" \n" |
|
|
] |
|
|
] |
|
|
} |
|
|
} |
|
|
], |
|
|
], |
|
|
"source": [ |
|
|
"source": [ |
|
|
"pattern=\"\"\"\t\tcall json%get(p,'@@@',pval)\n", |
|
|
|
|
|
"\t\tcall json%get(pval,data%Equipments%UnityInputs%@@@)\"\"\"\n", |
|
|
|
|
|
|
|
|
"pattern=\"\"\"\t\tcall json%get('Equipments.Drilling.@@@',data%Equipments%DrillingConsole%@@@,found)\n", |
|
|
|
|
|
"\t\tif ( .not. found ) print *,\"Not found: @@@\" \"\"\"\n", |
|
|
"\n", |
|
|
"\n", |
|
|
"input = open(\"Text1.txt\")\n", |
|
|
"input = open(\"Text1.txt\")\n", |
|
|
"lines = input.readlines()\n", |
|
|
"lines = input.readlines()\n", |
|
|
"for line in lines:\n", |
|
|
"for line in lines:\n", |
|
|
|
|
|
"\tif '::' not in line:\n", |
|
|
|
|
|
"\t\tcontinue\n", |
|
|
"\tparts = line.split(\"::\")\n", |
|
|
"\tparts = line.split(\"::\")\n", |
|
|
"\tif len(parts)!=2:\n", |
|
|
"\tif len(parts)!=2:\n", |
|
|
"\t\tcontinue\n", |
|
|
"\t\tcontinue\n", |
|
|