def repack_fileheader(dic):
    """
    Repack blockheader dic bit flag parameters into status and mode.
    """
    dic['status'] = dic['S_DATA'] * 1 + dic['S_SPEC'] * 2 + dic['S_32'
        ] * 4 + dic['S_FLOAT'] * 8 + dic['S_COMPLEX'] * 16 + dic[
        'S_HYPERCOMPLEX'] * 32 + dic['S_ACQPAR'] * 128 + dic['S_SECND'
        ] * 256 + dic['S_TRANSF'] * 512 + dic['S_NP'] * 2048 + dic['S_NF'
        ] * 4096 + dic['S_NI'] * 8192 + dic['S_NI2'] * 16384
    return dic
