def get_motion_default(settings, motion_frames, queue_com, name):
    """
    Set the default values for the motion correction software.

    settings - TranSPHIRE settings.
    motion_frames - Sub frame settings.
    queue_com - Queue for communication.
    name - Name of the process.

    Returns:
    True, if dose weighting will be applied.
    """
    motion_name = settings['Copy']['Motion']
    if (motion_name == 'MotionCor2 v1.0.0' or motion_name ==
        'MotionCor2 v1.0.5' or motion_name == 'MotionCor2 v1.1.0'):
        motion_frames['last'] = int(settings['General']['Number of frames']
            ) - int(settings[motion_name]['-Trunc'])
        motion_frames['first'] = int(settings[motion_name]['-Throw']) + 1
        return bool(settings[motion_name]['-FmDose'] != '0' and settings[
            motion_name]['-PixSize'] != '0' and settings[motion_name]['-kV'
            ] != '0')
    else:
        message = '\n'.join(['{0}: Motion version not known.'.format(
            motion_name), 'Please contact the TranSPHIRE authors!'])
        queue_com['error'].put(message, name)
        raise IOError(message)
