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.
 
 
 
 
 
 

61 lines
1.8 KiB

  1. module CFillMouseHoleLedNotification
  2. use OperationScenariosModule
  3. use NotificationModule
  4. implicit none
  5. contains
  6. subroutine Evaluate_FillMouseHoleLed()
  7. implicit none
  8. end subroutine
  9. subroutine ButtonPress_FillMouseHole()
  10. ! use OperationScenariosModule
  11. use UnitySignalsModule
  12. implicit none
  13. if (data%Configuration%Hoisting%DriveType == TopDrive_DriveType) then
  14. !TOPDRIVE-CODE=71
  15. if (Get_FillMouseHoleLed()) then
  16. call Set_FillMouseHoleLed(.false.)
  17. call Set_MouseHole(MOUSE_HOLE_NEUTRAL)
  18. return
  19. end if
  20. !TOPDRIVE-CODE=72
  21. if (Get_TdsElevatorModes() /= TDS_ELEVATOR_CONNECTION_STRING .and.&
  22. Get_FillMouseHoleLed() == .false.) then
  23. call Set_FillMouseHoleLed(.true.)
  24. return
  25. end if
  26. endif
  27. if (data%Configuration%Hoisting%DriveType == Kelly_DriveType) then
  28. !OPERATION-CODE=81
  29. if (Get_FillMouseHoleLed()) then
  30. call Set_FillMouseHoleLed(.false.)
  31. call Set_MouseHole(MOUSE_HOLE_EMPTY)
  32. return
  33. end if
  34. !OPERATION-CODE=82
  35. if (Get_KellyConnection() /= KELLY_CONNECTION_SINGLE .and.&
  36. Get_ElevatorConnection() /= ELEVATOR_CONNECTION_SINGLE .and.&
  37. Get_FillMouseHoleLed() == .false.) then
  38. call Set_FillMouseHoleLed(.true.)
  39. call Set_MouseHole(MOUSE_HOLE_FILL)
  40. return
  41. end if
  42. endif
  43. end subroutine
  44. end module CFillMouseHoleLedNotification