anchor.diff:     ! Initialize mesh-mapping data
      ! -------------------------------------------------------------------------
   
  -   CALL InitModuleMappings()
  +   CALL InitModuleMappings(p_FAST, ED, AD, HD, SD, SrvD, MAPp, FEAM, IceF, IceD, MeshMapData, ErrStat, ErrMsg)
   
      ! -------------------------------------------------------------------------
      ! Write initialization data to FAST summary file:
  
positive.code: 
  CONTAINS
     !...............................................................................................................................
     SUBROUTINE SetModuleSubstepTime(ModuleID)
     ! This module sets the number of subcycles (substeps) for modules, checking to make sure that their requested time step is valid 
     !...............................................................................................................................
        INTEGER(IntKi), INTENT(IN)          :: ModuleID                  ! ID of the module to check time step and set
         ! Local variable
        REAL(DbKi)                          :: ModuleTimeStep            ! Used to determine if output should be generated at this simulation time
        
              
        IF ( EqualRealNos( p_FAST%dt_module( ModuleID ), p_FAST%dt ) ) THEN
           p_FAST%n_substeps(ModuleID) = 1
        ELSE
           IF ( p_FAST%dt_module( ModuleID ) > p_FAST%dt ) THEN
              CALL CheckError( ErrID_Fatal, "The "//TRIM(y_FAST%Module_Ver(ModuleID)%Name)//" module time step ("//&
                                            TRIM(Num2LStr(p_FAST%dt_module( ModuleID )))// &
                                            " s) cannot be larger than FAST time step ("//TRIM(Num2LStr(p_FAST%dt))//" s).")
           ELSE
                 ! calculate the number of subcycles:
              p_FAST%n_substeps(ModuleID) = NINT( p_FAST%dt / p_FAST%dt_module( ModuleID ) )
              
                 ! let's make sure THE module DT is an exact integer divisor of the global (FAST) time step:
              IF ( .NOT. EqualRealNos( p_FAST%dt, p_FAST%dt_module( ModuleID ) * p_FAST%n_substeps(ModuleID) )  ) THEN
                 CALL CheckError( ErrID_Fatal, "The "//TRIM(y_FAST%Module_Ver(ModuleID)%Name)//" module time step ("//&
                                               TRIM(Num2LStr(p_FAST%dt_module( ModuleID )))// &
                                               " s) must be an integer divisor of the FAST time step ("//TRIM(Num2LStr(p_FAST%dt))//" s).")
              END IF
              
           END IF
        END IF      
                   
        RETURN
        
     END SUBROUTINE SetModuleSubstepTime   
     !...............................................................................................................................
     SUBROUTINE WriteOutputToFile()
     ! This routine determines if it's time to write to the output files, and calls the routine to write to the files
     ! with the output data. It should be called after all the output solves for a given time have been completed.
  
negative.code:    p_FAST%ModuleInitialized(Module_ED) = .TRUE.
        CALL CheckError( ErrStat, 'Message from ED_Init: '//NewLine//ErrMsg )
  
     CALL SetModuleSubstepTime(Module_ED, p_FAST, y_FAST, ErrStat, ErrMsg)
        CALL CheckError(ErrStat, ErrMsg)
        
        ! bjj: added this check per jmj; perhaps it would be better in ElastoDyn, but I'll leave it here for now:
     IF ( p_FAST%TurbineType == Type_Offshore_Floating ) THEN
        IF ( ED%p%TowerBsHt < 0.0_ReKi .AND. .NOT. EqualRealNos( ED%p%TowerBsHt, 0.0_ReKi ) ) THEN
  