|
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129 |
- module CBopControlPanel
- ! use CBopControlPanel
- use SimulationVariables
- implicit none
- public
- contains
-
- subroutine BopControlPanelToJson(parent)
-
- type(json_value),pointer :: parent
- type(json_core) :: json
- type(json_value),pointer :: p
-
- ! 1. create new node
- call json%create_object(p,'BopControl')
-
- call json%add(p,"AnnularRegulatorSetControl",data%EquipmentControl%BopControlPanel%AnnularRegulatorSetControl)
- call json%add(p,"AirMasterValve",data%EquipmentControl%BopControlPanel%AirMasterValve)
- call json%add(p,"ByePassValve",data%EquipmentControl%BopControlPanel%ByePassValve)
- call json%add(p,"AnnularValve",data%EquipmentControl%BopControlPanel%AnnularValve)
- call json%add(p,"UpperRamsValve",data%EquipmentControl%BopControlPanel%UpperRamsValve)
- call json%add(p,"MiddleRamsValve",data%EquipmentControl%BopControlPanel%MiddleRamsValve)
- call json%add(p,"KillLineValve",data%EquipmentControl%BopControlPanel%KillLineValve)
- call json%add(p,"ChokeLineValve",data%EquipmentControl%BopControlPanel%ChokeLineValve)
- call json%add(p,"LowerRamsValve",data%EquipmentControl%BopControlPanel%LowerRamsValve)
- call json%add(p,"ManifoldPressureGauge",data%EquipmentControl%BopControlPanel%ManifoldPressureGauge)
- call json%add(p,"AirSupplyPressureGauge",data%EquipmentControl%BopControlPanel%AirSupplyPressureGauge)
- call json%add(p,"AccumulatorPressureGauge",data%EquipmentControl%BopControlPanel%AccumulatorPressureGauge)
- call json%add(p,"AnnularPressureGauge",data%EquipmentControl%BopControlPanel%AnnularPressureGauge)
- call json%add(p,"AnnularOpenLED",data%EquipmentControl%BopControlPanel%AnnularOpenLED)
- call json%add(p,"AnnularCloseLED",data%EquipmentControl%BopControlPanel%AnnularCloseLED)
- call json%add(p,"UpperRamsOpenLED",data%EquipmentControl%BopControlPanel%UpperRamsOpenLED)
- call json%add(p,"UpperRamsCloseLED",data%EquipmentControl%BopControlPanel%UpperRamsCloseLED)
- call json%add(p,"MiddleRamsOpenLED",data%EquipmentControl%BopControlPanel%MiddleRamsOpenLED)
- call json%add(p,"MiddleRamsCloseLED",data%EquipmentControl%BopControlPanel%MiddleRamsCloseLED)
- call json%add(p,"KillLineOpenLED",data%EquipmentControl%BopControlPanel%KillLineOpenLED)
- call json%add(p,"KillLineCloseLED",data%EquipmentControl%BopControlPanel%KillLineCloseLED)
- call json%add(p,"ChokeLineOpenLED",data%EquipmentControl%BopControlPanel%ChokeLineOpenLED)
- call json%add(p,"ChokeLineCloseLED",data%EquipmentControl%BopControlPanel%ChokeLineCloseLED)
- call json%add(p,"LowerRamsOpenLED",data%EquipmentControl%BopControlPanel%LowerRamsOpenLED)
- call json%add(p,"LowerRamsCloseLED",data%EquipmentControl%BopControlPanel%LowerRamsCloseLED)
- call json%add(p,"AnnularStatus",data%EquipmentControl%BopControlPanel%AnnularStatus)
- call json%add(p,"UpperRamsStatus",data%EquipmentControl%BopControlPanel%UpperRamsStatus)
- call json%add(p,"MiddleRamsStatus",data%EquipmentControl%BopControlPanel%MiddleRamsStatus)
- call json%add(p,"LowerRamsStatus",data%EquipmentControl%BopControlPanel%LowerRamsStatus)
-
-
- call json%add(parent,p)
- end subroutine
-
-
-
- subroutine OpenAnnular()
- use CManifolds
- implicit none
- call ChangeValve(52, .true.)
- end subroutine
-
- subroutine CloseAnnular()
- use CManifolds
- implicit none
- call ChangeValve(52, .false.)
- end subroutine
-
- subroutine OpenUpperRams()
- use CManifolds
- implicit none
- call ChangeValve(51, .true.)
- end subroutine
-
- subroutine CloseUpperRams()
- use CManifolds
- implicit none
- call ChangeValve(51, .false.)
- end subroutine
-
- subroutine OpenMiddleRams()
- use CManifolds
- implicit none
- call ToggleMiddleRams(.true.)
- end subroutine
-
- subroutine CloseMiddleRams()
- use CManifolds
- implicit none
- call ToggleMiddleRams(.false.)
- end subroutine
-
- subroutine OpenKillLine()
- use CManifolds
- implicit none
- call ChangeValve(46, .true.)
- end subroutine
-
- subroutine CloseKillLine()
- use CManifolds
- implicit none
- call ChangeValve(46, .false.)
- end subroutine
-
- subroutine OpenChokeLine()
- use CManifolds
- implicit none
- call ChangeValve(47, .true.)
- !WRITE (*,*) ' valve 47 true '
- end subroutine
-
- subroutine CloseChokeLine()
- use CManifolds
- implicit none
- call ChangeValve(47, .false.)
- !WRITE (*,*) ' valve 47 false '
- end subroutine
-
- subroutine OpenLowerRams()
- use CManifolds
- implicit none
- call ChangeValve(49, .true.)
- !WRITE (*,*) ' valve 49 true '
- end subroutine
-
- subroutine CloseLowerRams()
- use CManifolds
- implicit none
- call ChangeValve(49, .false.)
- !WRITE (*,*) ' valve 49 false '
- end subroutine
-
- end module CBopControlPanel
|