Simulation Core
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

98 lines
2.8 KiB

  1. # 1 "/mnt/c/Projects/VSIM/SimulationCore2/Equipments/Pumps/Pumps_Outputs.f90"
  2. subroutine Pumps_Outputs
  3. use CDataDisplayConsole
  4. use SimulationVariables
  5. ! Use CSimulationVariables
  6. use SimulationVariables
  7. Use MudSystemModule
  8. use SimulationVariables !@
  9. Use CSounds
  10. IMPLICIT NONE
  11. !>>>>>>>>>>>>>>>>>>>>>>> PUMP 1 <<<<<<<<<<<<<<<<<<<<<<<<<<<
  12. If (data%State%Pump(1)%Open_Close==1) then
  13. Call OpenPump1()
  14. Else if (data%State%Pump(1)%Open_Close==0) then
  15. Call ClosePump1()
  16. End if
  17. data%Equipments%DrillingConsole%MP1BLWR = data%State%Pump(1)%BLWR
  18. Call SetSoundBlowerMP1( data%State%Pump(1)%SoundBlower ) !.true. or .false.
  19. Call SetSoundMP1( data%State%Pump(1)%SoundSPM ) ![spm] , integer
  20. if ((data%State%Pump(1)%Switch==-1) .or. (data%State%Pump(1)%Switch==0)) then
  21. Call Set_MP1SPMGauge( sngl(1-data%State%Pump(1)%SPMGaugeMalf)*real((data%State%Pump(1)%Speed/data%State%Pump(1)%Trans_Ratio),8) ) ![spm] , real
  22. data%Equipments%DrillingWatch%SPM1 = data%Equipments%DataDisplayConsole%MP1SPMGauge
  23. end if
  24. !data%State%Pump(1)%Flow_Rate !to other modules , [gpm]
  25. !>>>>>>>>>>>>>>>>>>>>>>> PUMP 2 <<<<<<<<<<<<<<<<<<<<<<<<<<<
  26. If (data%State%Pump(2)%Open_Close==1) then
  27. Call OpenPump2()
  28. Else if (data%State%Pump(2)%Open_Close==0) then
  29. Call ClosePump2()
  30. End if
  31. data%Equipments%DrillingConsole%MP2BLWR = data%State%Pump(2)%BLWR
  32. Call SetSoundBlowerMP2( data%State%Pump(2)%SoundBlower )
  33. Call SetSoundMP2( data%State%Pump(2)%SoundSPM )
  34. Call Set_MP2SPMGauge( sngl(1-data%State%Pump(2)%SPMGaugeMalf)*real((data%State%Pump(2)%Speed/data%State%Pump(2)%Trans_Ratio),8) )
  35. data%Equipments%DrillingWatch%SPM2 = data%Equipments%DataDisplayConsole%MP2SPMGauge
  36. !data%State%Pump(2)%Flow_Rate !to other modules
  37. !!>>>>>>>>>>>>>>>>>>>>>>> PUMP 3 <<<<<<<<<<<<<<<<<<<<<<<<<<<
  38. If (data%State%Pump(3)%Open_Close==1) then
  39. Call OpenCementPump()
  40. Else if (data%State%Pump(3)%Open_Close==0) then
  41. Call CloseCementPump()
  42. End if
  43. Call SetSoundMP3( data%State%Pump(3)%SoundSPM )
  44. if (data%State%Pump(3)%Switch==1) then
  45. Call Set_MP1SPMGauge( real((data%State%Pump(3)%Speed/data%State%Pump(3)%Trans_Ratio),8) )
  46. data%Equipments%DrillingWatch%SPM1 = data%Equipments%DataDisplayConsole%MP1SPMGauge
  47. end if
  48. !data%State%Pump(3)%Flow_Rate !to other modules
  49. !>>>>>>>>>>>>>>>>>>>>>>> Total Pumps <<<<<<<<<<<<<<<<<<<<<<<<<<<
  50. !data%State%MPumps%Total_Pump_Gpm = 100.d0 !???????????
  51. !data%State%MPumps%Total_Pump_SPM = 1000.d0 !?????????????
  52. !SCR1LED=1
  53. !SCR2LED=1
  54. !SCR3LED=1
  55. !SCR4LED=1
  56. end subroutine Pumps_Outputs